diff options
-rwxr-xr-x | .bash_profile | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/.bash_profile b/.bash_profile index 36ca384..28a1166 100755 --- a/.bash_profile +++ b/.bash_profile @@ -1,9 +1,9 @@ # Load ~/.bash_prompt, ~/.exports, ~/.aliases, ~/.functions and ~/.extra # ~/.extra can be used for settings you don’t want to commit -for file in bash_prompt exports aliases functions extra; do - file="$HOME/.$file" - [ -e "$file" ] && source "$file" +for file in ~/.{bash_prompt,exports,aliases,functions,extra}; do + [ -r "$file" ] && source "$file" done +unset file # Case-insensitive globbing (used in pathname expansion) shopt -s nocaseglob @@ -12,4 +12,5 @@ shopt -s nocaseglob [ -e "$HOME/.ssh/config" ] && complete -o "default" -o "nospace" -W "$(grep "^Host" ~/.ssh/config | grep -v "[?*]" | cut -d " " -f2)" scp sftp ssh # Add tab completion for `defaults read|write NSGlobalDomain` +# You could just use `-g` instead, but I like being explicit complete -W "NSGlobalDomain" defaults
\ No newline at end of file |