/
.zshrc
64 lines (49 loc) · 1.4 KB
/
.zshrc
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
export EDITOR=nvim
export KEYTIMEOUT=1
export PAGER=lv
export PS1='%1~ %# '
alias vim='nvim'
# tmux
bindkey '^A' beginning-of-line
bindkey '^E' end-of-line
[ -f ~/.zsh/tmux-attach-or-new-session.sh ] && \
source ~/.zsh/tmux-attach-or-new-session.sh && \
alias t='tmux-attach-or-new-session'
# asdf
[ -f /usr/local/opt/asdf/asdf.sh ] && \
. /usr/local/opt/asdf/asdf.sh
# direnv
eval "$(direnv hook zsh)"
# Ngrok
[ -d ~/ngrok/bin ] && \
export PATH=$PATH:$HOME/ngrok/bin
# Terraform
[ -d ~/terraform/bin ] && \
export PATH=$PATH:$HOME/terraform/bin
# MySQL
[ -d /usr/local/opt/mysql@5.7/bin ] && \
export PATH=$PATH:/usr/local/opt/mysql@5.7/bin
[ -d /usr/local/opt/mysql-client/bin ] && \
export PATH=$PATH:/usr/local/opt/mysql-client/bin
# Google Cloud SDK
[ -d ~/google-cloud-sdk/bin ] && \
export PATH=$PATH:$HOME/google-cloud-sdk/bin
[ -f ~/google-cloud-sdk/path.zsh.inc ] && \
. ~/google-cloud-sdk/path.zsh.inc
[ -f ~/google-cloud-sdk/completion.zsh.inc ] && \
. ~/google-cloud-sdk/completion.zsh.inc
# fzf (Remap Ctrl-T to Ctrl-F)
[ -f ~/.fzf.zsh ] && \
source ~/.fzf.zsh && \
bindkey '^F' fzf-file-widget && \
bindkey '^T' transpose-chars
# fzf-git
[ -L ~/.fzf-git.zsh ] && \
source ~/.fzf-git.zsh && \
bindkey '^G' fzf-git-widget &&\
bindkey '^H' fzf-git-commit-widget
# completion
[ -d ~/.zsh/completion ] && \
fpath=(~/.zsh/completion $fpath)
autoload -U compinit
compinit -u