1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- if [ -f ~/.dircolors ]; then
- eval $(dircolors ~/.dircolors)
- fi
- alias ls="ls --color=auto --group-directories-first -F --quoting-style literal"
- if whence -p yadm > /dev/null; then
- export YADM_OVERRIDE_REPO="$HOME/.dotfiles"
- else
- alias yadm='git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'
- fi
- zstyle ':completion:*' menu select
- zstyle ':completion:*:default' list-colors ${(s.:.)LS_COLORS}
- zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}'
- REPORTTIME=5
- HISTFILE="${HOME}/.zhistory"
- HISTSIZE=1000
- SAVEHIST=10000
- setopt inc_append_history
- setopt share_history
- setopt extended_history
- setopt histignorealldups
- setopt histignorespace
- setopt autocd
- setopt autopushd
- setopt longlistjobs
- setopt nohup
- setopt extended_glob
- setopt noglobdots
- setopt noshwordsplit
- bindkey -e
- # https://bbs.archlinux.org/viewtopic.php?id=151738
- # ensures terminfo is setup properly
- if [[ -n ${terminfo[smkx]} ]] && [[ -n ${terminfo[rmkx]} ]]; then
- function zle-line-init () {echoti smkx}
- function zle-line-finish () {echoti rmkx}
- zle -N zle-line-init
- zle -N zle-line-finish
- fi
- # https://bbs.archlinux.org/viewtopic.php?pid=1170080#p1170080
- autoload up-line-or-beginning-search
- autoload down-line-or-beginning-search
- zle -N up-line-or-beginning-search
- zle -N down-line-or-beginning-search
- bindkey "${terminfo[kcuu1]}" up-line-or-beginning-search
- bindkey "${terminfo[kcud1]}" down-line-or-beginning-search
- bindkey "^P" up-line-or-beginning-search
- bindkey "^N" down-line-or-beginning-search
- autoload -z edit-command-line
- zle -N edit-command-line
- bindkey "^X^E" edit-command-line
- bindkey '^R' fzf_history
- bindkey "${terminfo[khome]}" beginning-of-line
- bindkey "${terminfo[kend]}" end-of-line
- bindkey "${terminfo[kdch1]}" delete-char # Del
- bindkey "${terminfo[kpp]}" backward-word # PageUp
- bindkey "${terminfo[knp]}" forward-word # PageDown
- alias l="k -h"
- alias ssh="TERM=xterm-256color ssh"
- if whence -p nvr > /dev/null; then
- export EDITOR="nvr -s --remote-wait"
- elif whence -p nvim > /dev/null; then
- export EDITOR=nvim
- else
- export EDITOR=vim
- fi
- alias e="$EDITOR"
- if type -f fzf_cd > /dev/null; then
- alias j="fzf_cd"
- fi
- if whence -p delta > /dev/null; then
- export GIT_PAGER=delta
- fi
|