1
0
Fork 0
mirror of https://github.com/kastdeur/dotfiles.git synced 2024-11-17 17:03:32 +01:00

[bash] rename bash/rc and bash/bash.d

This commit is contained in:
Eric Teunis de Boone 2022-02-10 20:07:37 +01:00
parent f67517fdec
commit 6b0d6af2f8
10 changed files with 8 additions and 6 deletions

View file

@ -6,7 +6,7 @@
- clean: ['~']
- link:
~/.bashrc: bash/rc
~/.bashrc: bash/bashrc
~/.bash_profile: bash/profile
~/.config/git/config: git/config
~/.config/git/ignore_global: git/ignore

View file

@ -30,8 +30,8 @@ if [ -f /etc/bash_completion ] && ! shopt -oq posix; then
fi
# Load main things
if [ -d "$DOTBASH/bash.d" ]; then
for f in colours aliases history prompt_command password-store
if [ -d "$DOTBASH/bashrc.d" ]; then
for f in colours.bash aliases.bash history.bash prompt_command.bash password-store.bash network.bash
do
if [ -r "$DOTBASH/bash.d/$f" ]; then
source "$DOTBASH/bash.d/$f"

View file

@ -22,7 +22,7 @@ alias l='ls -CF'
alias mkdir='mkdir -p -v'
# Use vim if possible instead of vi
if [[ $(command -v vim) ]]; then
if command -v vim > /dev/null; then
alias vi='vim'
else
alias vim='vi'

View file

@ -40,7 +40,9 @@ then
fi
# if this is BASH source BASHRC
if [ "$BASH" ] && [ -f $DOTFILES/bash/rc ]
DOTBASHRC="$DOTFILES/bash/bashrc"
if [ "$BASH" ] && [ -r "$DOTBASHRC" ]
then
source $DOTFILES/bash/rc
source "$DOTBASHRC"
fi
unset DOTBASHRC