bashrc: Source `${bash}/etc/bash_completion' when available.
svn path=/nixos/trunk/; revision=16641
This commit is contained in:
parent
4c848efc1a
commit
fe51b0c6c3
@ -30,12 +30,14 @@ in
|
|||||||
# should go into this script.
|
# should go into this script.
|
||||||
source = pkgs.substituteAll {
|
source = pkgs.substituteAll {
|
||||||
src = ./bashrc.sh;
|
src = ./bashrc.sh;
|
||||||
|
|
||||||
|
bash = pkgs.bash;
|
||||||
systemPath = config.system.path;
|
systemPath = config.system.path;
|
||||||
wrapperDir = config.security.wrapperDir;
|
wrapperDir = config.security.wrapperDir;
|
||||||
modulesTree = config.system.modulesTree;
|
modulesTree = config.system.modulesTree;
|
||||||
shellInit = config.environment.shellInit;
|
shellInit = config.environment.shellInit;
|
||||||
};
|
};
|
||||||
target = "bashrc";
|
target = "bashrc";
|
||||||
}
|
}
|
||||||
|
|
||||||
{ # Script executed when the shell starts as a login shell.
|
{ # Script executed when the shell starts as a login shell.
|
||||||
|
@ -61,3 +61,13 @@ alias ll="ls -l"
|
|||||||
alias l="ls -alh"
|
alias l="ls -alh"
|
||||||
alias which="type -p"
|
alias which="type -p"
|
||||||
|
|
||||||
|
# Completion.
|
||||||
|
if [ -d "@bash@/etc/bash_completion.d" ]
|
||||||
|
then
|
||||||
|
export BASH_COMPLETION_DIR="@bash@/etc/bash_completion.d"
|
||||||
|
fi
|
||||||
|
if [ -f "@bash@/etc/bash_completion" ]
|
||||||
|
then
|
||||||
|
export BASH_COMPLETION="@bash@/etc/bash_completion"
|
||||||
|
source "$BASH_COMPLETION"
|
||||||
|
fi
|
||||||
|
Loading…
x
Reference in New Issue
Block a user