Android : Update bash sourcing.

This commit is contained in:
Dmitry Voronin 2024-03-06 01:56:27 +03:00
parent 0de15a3d80
commit e7e7fea6ac
2 changed files with 11 additions and 9 deletions

View file

@ -41,15 +41,17 @@
home-manager.config = {
home.stateVersion = const.droidStateVersion;
home.file = {
".nixos".source = inputs.dotfiles;
".nixos".source = inputs.dotfiles;
".bash".source = ./common/bash;
".ssh/config".source = ./common/ssh/Config;
};
home.sessionVariables = {
BASH_MODULE_PATH = "$HOME/.bash/module";
BASH_PATH = "$HOME/.bash";
};
programs.bash = {
enable = true;
bashrcExtra = ''
for module in ~/.nixos/module/common/bash/module/*.sh; do
source ''${module}
done
'';
enable = true;
bashrcExtra = "source ~/.bash/Bashrc.sh";
};
};
}

View file

@ -1,7 +1,7 @@
{ environment, lib, ... }: {
environment.etc.bash.source = ./bash;
environment.shellAliases = lib.mkForce {};
environment.variables.BASH_MODULE_PATH = "/etc/bash/module/";
environment.variables.BASH_PATH = "/etc/bash/";
environment.variables.BASH_MODULE_PATH = "/etc/bash/module";
environment.variables.BASH_PATH = "/etc/bash";
programs.bash.interactiveShellInit = "source /etc/bash/Bashrc.sh";
}