Repository navigation
Expand file tree
/
Copy pathzshrc.zsh
More file actions
72 lines (54 loc) · 1.95 KB
/
Copy pathzshrc.zsh
File metadata and controls
72 lines (54 loc) · 1.95 KB
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
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi
export ZSH="${HOME}/.oh-my-zsh"
export TERM="xterm-256color"
ZSH_THEME="powerlevel10k/powerlevel10k"
HYPHEN_INSENSITIVE="true"
COMPLETION_WAITING_DOTS="true"
DISABLE_UPDATE_PROMPT="true"
plugins=(k genpass gitfast kubetail colorize docker helm ubuntu zsh-autosuggestions zsh-interactive-cd zsh-syntax-highlighting)
source $ZSH/oh-my-zsh.sh
typeset -gA ZSH_HIGHLIGHT_STYLES
ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets pattern cursor)
ZSH_HIGHLIGHT_STYLES[cursor]='bold'
ZSH_HIGHLIGHT_STYLES[alias]='fg=green,bold'
ZSH_HIGHLIGHT_STYLES[suffix-alias]='fg=green,bold'
ZSH_HIGHLIGHT_STYLES[builtin]='fg=green,bold'
ZSH_HIGHLIGHT_STYLES[function]='fg=green,bold'
ZSH_HIGHLIGHT_STYLES[command]='fg=green,bold'
ZSH_HIGHLIGHT_STYLES[precommand]='fg=green,bold'
ZSH_HIGHLIGHT_STYLES[hashed-command]='fg=green,bold'
rule () {
print -Pn '%F{blue}'
local columns=$(tput cols)
for ((i=1; i<=columns; i++)); do
printf "\u2588"
done
print -P '%f'
}
function _my_clear() {
echo
rule
zle clear-screen
}
zle -N _my_clear
bindkey '^l' _my_clear
export EDITOR='vim'
export PATH="${KREW_ROOT:-$HOME/.krew}/bin:$HOME/.local/bin:$HOME/.bin:/usr/local/bin:${PATH}"
if [[ -e "$HOME/.zsh/kubernetes.sh" ]]; then
source "$HOME/.zsh/kubernetes.sh"
elif [[ -n "$(which kubectl 2>/dev/null)" ]]; then
echo "Generating kubectl completions..."
mkdir "$HOME/.zsh" || true
kubectl completion zsh > "$HOME/.zsh/kubernetes.sh"
source "$HOME/.zsh/kubernetes.sh"
fi
alias pretty="ccat"
alias git-oops="git add . && git commit --amend --no-edit -a && git push --force"
source "${HOME}/.zsh-aliases.zsh"
echo "Pst! Remember about these Krew plugins:"
kubectl krew list
echo "...and tools: pretty, ccat, cless, kdiag, k, kubetail"
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh