The Meowgorithm Dotfiles, Collectors’ Edition
#!/usr/bin/env bash
# Commands that should be applied only for interactive shells.
[[ $- == *i* ]] || return
shopt -s globstar
shopt -s histappend
# shellcheck disable=SC1091
source "$XDG_DATA_HOME/meowgorithm/bash_funcs"
env="$XDG_DATA_HOME/meowgorithm/env.asc"
# shellcheck disable=SC1090
[ -f "$env" ] && source <(gpg --decrypt "$env" 2>/dev/null)
export HISTCONTROL=ignorespace:ignoredups:erasedups
export HISTFILESIZE=100000
export HISTSIZE=10000
export HISTIGNORE="ls:cd:pwd:clear:exit:history:shutdown:reboot"
export PROMPT_DIRTRIM=2
export CLICOLOR=1
# Where our dotfiles repo lives
export DOTFILES="$HOME/.dotfiles"
os="$(which_os)"
# Look for git-prompt and setup the first one we find
gitPromptPaths=(
"/usr/share/git-core/contrib/completion/git-prompt.sh" # fedora
"/usr/share/git/git-prompt.sh" # void
)
for path in "${gitPromptPaths[@]}"; do
[[ -f "$path" ]] && source "$path" && break
done
# OS/Distro specific stuff
case "$os" in
fedora)
alias zzz="sudo systemctl suspend"