## python
export PYTHONSTARTUP=${XDG_CONFIG_HOME:-~/.config}/pythonrc
## vim
-export VIMINIT='execute "source" ($XDG_CONFIG_HOME??($HOME."/.config"))."/vim/.vimrc"'
+export VIMINIT='let$MYVIMRC=($XDG_CONFIG_HOME??($HOME."/.config"))."/vim/.vimrc"|execute"source"$MYVIMRC'
## wayland/sway
# XXX: only do this if we're actually in wayland, but without a start script
export XDG_SESSION_TYPE=wayland
} else {
alias ll='ls -lAFh'
}
-alias p=$PAGER
-alias e=$EDITOR
+alias p=\$PAGER
+alias e=\$EDITOR
alias se=sudoedit
# be paranoid
alias cp='cp -ip'
### specialized aliases
## go up directories
function up {
- cd $(printf '../%.0s' {1..${1:-1}})
+ \cd $(printf '../%.0s' {1..${1:-1}})
}
alias u=up
## zoxide
-[[ -v commands[zoxide] ]] && eval "$(zoxide init zsh)"
+if [[ -v commands[zoxide] ]] {
+ eval "$(zoxide init zsh)"
+ alias cd=z
+}
+## git
+alias ga='git add'
+alias gdh='git diff HEAD'
### hooks
autoload -Uz add-zsh-hook
cache=${XDG_CACHE_HOME:-~/.cache}/zsh
[[ -d $cache ]] || mkdir -p $cache
compinit -d $cache/.zcompdump
+unset cache
### prompt
autoload -Uz promptinit && promptinit
prompt arrows
### load site-specific
-if [[ -f ${ZDOTDIR:-~}/.zshrc.local ]] { source ${ZDOTDIR:-~}/.zshrc.local }
-
-# vim: et sts=4 sw=4 ts=8 tw=79
+load-site-dotfile zshrc