/
zshrc
81 lines (66 loc) · 1.88 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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
# Path to your oh-my-zsh installation.
export ZSH=$HOME/.oh-my-zsh
ZSH_CUSTOM=$HOME/.config/dotfiles/oh-my-zsh/custom
# # # # #
# Environment Variables
export GOPATH=$HOME/src/go
export PATH=$PATH:$HOME/bin
export PATH=$PATH:$GOPATH/bin
export PATH=$PATH:$HOME/.local/bin
export PATH=$PATH:/usr/local/bin
export PATH=$PATH:/usr/local/go/bin
export PATH=$PATH:$HOME/perl5/bin
export PATH=$PATH:$HOME/.cargo/bin
export PATH=$PATH:$HOME/.gem/ruby/2.5.0/bin
export PATH=$PATH:/usr/local/share/python/
export PATH=$PATH:$HOME/.krew/bin
export NVIM_LISTEN_ADDRESS=/tmp/nvimsocket
export KUBECONFIG="$(find ~/.kube/configs/ -type f -exec printf '%s:' '{}' +)"
export EDITOR=nvim
export GO111MODULE=on
# # # # #
# Themes
#ZSH_THEME="cedi"
ZSH_THEME="zsh-multiline/multiline"
# # # # #
# Git integration config
HYPHEN_INSENSITIVE="true"
COMPLETION_WAITING_DOTS="true"
DISABLE_UNTRACKED_FILES_DIRTY="true"
# # # # #
# Plugins
if [[ "$OSTYPE" == "darwin"* ]]; then
plugins=(git ssh-agent sudo colored-man-pages zsh-autosuggestions debian zsh-syntax-highlighting meaningful-error-codes helm kubectl iterm2 osx)
else
plugins=(git ssh-agent sudo colored-man-pages zsh-autosuggestions debian zsh-syntax-highlighting meaningful-error-codes helm kubectl)
fi
# # # # #
# Load custom modules
source $ZSH/oh-my-zsh.sh
source $ZSH_CUSTOM/aliases.zsh
source $ZSH_CUSTOM/cfunctions.zsh
# # # # #
# tmux config
if [ $TILIX_ID ] || [ $VTE_VERSION ]; then
source /etc/profile.d/vte.sh
fi
precmd() {
if [[ -n "$TMUX" ]]; then
tmux setenv "$(tmux display -p 'TMUX_PWD_#D')" "$PWD"
fi
}
# # # # #
# Load fzf
if [ -d ~/.fzf ]; then
# Setup fzf
# ---------
if [[ ! "$PATH" == */.fzf/bin* ]]; then
export PATH="$PATH:$HOME/.fzf/bin"
fi
# Auto-completion
# ---------------
[[ $- == *i* ]] && source "$HOME/.fzf/shell/completion.zsh" 2> /dev/null
# Key bindings
# ------------
source "$HOME/.fzf/shell/key-bindings.zsh"
fi