Avoid non-zero exit code at end of .bashrc
The previous syntax caused the last command to evaluate to a non-zero exit code when .bashrc.local does not exist. This was annoying because we show a non-zero exit code in the prompt, so the first prompt on every bash session would show this exit code.
This commit is contained in:
parent
abfa79b015
commit
0a6ac8fca2
1 changed files with 5 additions and 1 deletions
|
@ -290,5 +290,9 @@ bashrc_customize_ls
|
||||||
|
|
||||||
[ -f ~/.config/shell/git-prompt.sh ] && . ~/.config/shell/git-prompt.sh
|
[ -f ~/.config/shell/git-prompt.sh ] && . ~/.config/shell/git-prompt.sh
|
||||||
[ -f ~/.config/shell/git-completion.bash ] && . ~/.config/shell/git-completion.bash
|
[ -f ~/.config/shell/git-completion.bash ] && . ~/.config/shell/git-completion.bash
|
||||||
[ -f ~/.bashrc.local ] && . ~/.bashrc.local
|
|
||||||
|
# Source a local bashrc if available
|
||||||
|
if [ -f "$HOME/.bashrc.local" ]; then
|
||||||
|
source "$HOME/.bashrc.local"
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue