feat(bash): source local config from ~/.local/etc/bash/profile
This commit is contained in:
parent
37f5dcb035
commit
cda8ae2ab6
1 changed files with 4 additions and 3 deletions
|
@ -20,6 +20,7 @@ export LC_CTYPE="en_US.UTF-8"
|
||||||
export LESS="-i -j.49 -M -R -z-2"
|
export LESS="-i -j.49 -M -R -z-2"
|
||||||
export LESSHISTFILE="$XDG_CACHE_HOME/less/history"
|
export LESSHISTFILE="$XDG_CACHE_HOME/less/history"
|
||||||
export LESSHISTSIZE=1000
|
export LESSHISTSIZE=1000
|
||||||
|
export LOCAL_CONFIG="$HOME/.local/etc"
|
||||||
export LOCAL_PREFIX="/usr/local"
|
export LOCAL_PREFIX="/usr/local"
|
||||||
if command -v brew &>/dev/null; then
|
if command -v brew &>/dev/null; then
|
||||||
LOCAL_PREFIX="$(brew --prefix)"
|
LOCAL_PREFIX="$(brew --prefix)"
|
||||||
|
@ -440,9 +441,9 @@ while read -r d; do [ -d "$d" ] && for f in "$d"/*; do [ -f "$f" ] && . "$f"; do
|
||||||
EOL
|
EOL
|
||||||
unset d f
|
unset d f
|
||||||
|
|
||||||
# Source a local bashrc if available
|
# Source a local bash configuration if available
|
||||||
if [ -f "$XDG_CONFIG_HOME/bash/profile.local" ]; then
|
if [ -f "$LOCAL_CONFIG/bash/profile" ]; then
|
||||||
# shellcheck disable=SC1090
|
# shellcheck disable=SC1090
|
||||||
source "$XDG_CONFIG_HOME/bash/profile.local"
|
source "$LOCAL_CONFIG/bash/profile"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue