aboutsummaryrefslogtreecommitdiff
path: root/shell/zsh/.zshrc
blob: 96264ff88f4d7a956ad6e336cd5f0e4b24473d99 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
HISTFILE=~/.zsh_history
HISTSIZE=1000
SAVEHIST=1000

export GPG_TTY=$(tty)

bindkey -v

fpath=(~/.dotfiles/shell/zsh/tabcompletion $fpath)
autoload -Uz compinit
compinit

. ~/.dotfiles/shell/zsh/zsh-git-prompt/zshrc.sh
PROMPT='[%F{green}%n%f@%m %F{green}%~%f $(git_super_status)]$ '

[ -n "$(command -v fzf)" ] && . ~/.dotfiles/shell/zsh/fzf/key-bindings.zsh

[ -n "$(command -v broot)" ] && . ~/.dotfiles/shell/zsh/broot.zsh

SYSTEM_PLUGINS=(/usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
                /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
                /usr/share/zsh/plugins/zsh-history-substring-search/zsh-history-substring-search.zsh)
for plugin in $SYSTEM_PLUGINS; do
    [ -e "$plugin" ] && . $plugin
done

bindkey '\e[1~'       beginning-of-line                 # Home
bindkey '\e[4~'       end-of-line                       # End
bindkey '\e[3~'       delete-char                       # Delete
[ -n "$(command -v history-substring-search-up)" ] && \
    bindkey '^[[A'    history-substring-search-up       # Up
[ -n "$(command -v history-substring-search-down)" ] && \
    bindkey '^[[B'    history-substring-search-down     # Down

bindkey '^[[1;5D' backward-word                     # Ctrl+Left
bindkey '^[[1;5C' forward-word                      # Ctrl+Right