dotfiles/dot_config/zsh/dot_zshrc

67 lines
1.9 KiB
Plaintext
Raw Normal View History

2023-07-21 15:35:28 -04:00
### This configuration makes zsh fully "XDG compliant". One change is needed to
### /etc/zsh/zshenv (or equivalent upstream profile):
### `export ZDOTDIR="$HOME"/.config/zsh`
#
# Lines configured by zsh-newuser-install
export HISTFILE="$XDG_STATE_HOME"/zsh/history
2023-07-25 10:04:30 -04:00
mkdir -p "$(dirname $HISTFILE)"
2023-07-21 15:35:28 -04:00
HISTSIZE=1000
SAVEHIST=1000
setopt autocd
unsetopt beep
bindkey -v
# End of lines configured by zsh-newuser-install
# The following lines were added by compinstall
zstyle :compinstall filename "$ZDOTDIR/.zshrc"
2023-07-21 15:35:28 -04:00
autoload -Uz compinit
compinit -d "$XDG_CACHE_HOME"/zsh/zcompdump-"$ZSH_VERSION"
# End of lines added by compinstall
prependpath() {
case ":$PATH:" in
*:"$1":*)
;;
*)
PATH="$1:${PATH:+$PATH}"
esac
}
prependpath ~/bin
prependpath ~/repos/xxtools
### User configuration
# prompt configuration
autoload -Uz vcs_info
precmd_vcs_info () { vcs_info }
precmd_functions+=( precmd_vcs_info )
setopt prompt_subst
zstyle ':vcs_info:*' formats ' %F{green}%b'
PROMPT='%F{yellow}%n@%m %F{white}%1~%(?.. %?) $ '
RPROMPT='%f$vcs_info_msg_0_ '
alias bt='bluetoothctl'
alias c='clear'
alias daybreak='mosh daybreak -p 60101'
alias epoch='mosh epoch -p 60104'
2023-07-25 09:36:14 -04:00
alias grc='gridcoinresearchd'
2023-07-21 15:35:28 -04:00
alias l='exa -lh --git --all --octal-permissions'
alias ls='exa'
alias lsa='exa -a'
alias lss='exa -a'
alias xrm='sudo xbps-remove'
# GPG setup (and SSH)
if command -v keychain; then
alias keychain='keychain --dir "$XDG_RUNTIME_DIR" --absolute'
eval `keychain --quiet --eval --agents gpg D7F966B85D985743C76A17AC5A9572AE7B2E7E1C`
fi
if command -v gpgconf; then
SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
export SSH_AUTH_SOCK
fi
2023-07-21 15:35:28 -04:00
### End user configuration
### hooks/includes
. /usr/share/zsh/plugins/zsh-history-substring-search/zsh-history-substring-search.zsh
. /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
. /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh