-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbashrc
More file actions
23 lines (19 loc) · 694 Bytes
/
Copy pathbashrc
File metadata and controls
23 lines (19 loc) · 694 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
export DOTDOT="${HOME}/bin/nix_conf"
export DOT=${DOTDOT}
# Detect Homebrew prefix: Apple Silicon uses /opt/homebrew, Intel uses /usr/local
if [[ -f /opt/homebrew/bin/brew ]]; then
export HOMEBREW_PREFIX="/opt/homebrew"
else
export HOMEBREW_PREFIX="/usr/local"
fi
# Force upgrade to modern Bash if available (interactive shells only)
if [[ $- == *i* ]] && [[ "$BASH_VERSION" == 3.2* ]]; then
export BASH_SILENCE_DEPRECATION_WARNING=1
if [ -x "${HOMEBREW_PREFIX}/bin/bash" ]; then
exec "${HOMEBREW_PREFIX}/bin/bash" --login
fi
fi
. ${DOTDOT}/bash/aliases
. ${DOTDOT}/bash/config
. ${DOTDOT}/bash/env
[ -f "$HOME/.local/bin/env" ] && source "$HOME/.local/bin/env"