if [ -f ~/.wal_alias ]; then . ~/.wal_alias fi [ -f ~/.fzf.bash ] && source ~/.fzf.bash # Cargo config [ -f ~/.cargo ] && source "$HOME/.cargo/env" if [ -f ~/.cache/wal/sequences ]; then cat ~/.cache/wal/sequences fi export EDITOR=$(which vim) EXA_PATH=$(which exa) if [ ! -z "$EXA_PATH" ]; then alias ls="$EXA_PATH" alias ll="$EXA_PATH -lah" alias lg="$EXA_PATH -lah --git" fi # Platform agnostic aliases export TMUX_PATH=$(which tmux --skip-alias) alias tmuxn="$TMUX_PATH new -s $1" alias tmuxa="$TMUX_PATH attach -t $1" alias tmuxl="$TMUX_PATH ls" alias tmuxq="echo $TMUX" alias httpserver="python -m SimpleHTTPServer" # Case defines platform specific configs # Platform agnostic configs above case $(hostname) in Simons-MBP) export PS1="\w λ > \[$(tput sgr0)\]" # Mac aliases alias shorten-ps1="PS1='λ > '" alias default-ps1='PS1="\w λ > \[$(tput sgr0)\]"' alias emacs="/Applications/Emacs.app/Contents/MacOS/Emacs" # PATH setups PATH='/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/homebrew/bin:/opt/homebrew/sbin:/Users/swatson/.fzf/bin:/Users/swatson/Library/Python/3.8/bin' default-ps1 clear echo "Loaded MacM1 config" ;; watsonsi-fedora) if ! [[ "$PATH" =~ "$HOME/.local/bin:$HOME/bin:" ]] then PATH="$HOME/.local/bin:$HOME/bin:$PATH" fi export PATH export PS1="[\[\033[36m\]\u\[\033[m\]@\[\033[32m\]\h:\[\033[33;1m\]\w\[\033[m\]]\$ " alias start_od="rclone --vfs-cache-mode writes mount ipconedrive: /home/watonsi/OneDrive/" alias tmuxn="systemd-run --scope --user tmux new -s $1" # function to set terminal title function set-title() { if [[ -z "$ORIG" ]]; then ORIG=$PS1 fi TITLE="\[\e]2;$*\a\]" PS1=${ORIG}${TITLE} } echo "Loaded Work Fedora config" ;; esac