-
Notifications
You must be signed in to change notification settings - Fork 0
/
.zshrc
65 lines (49 loc) · 1.79 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
# Colors.
unset LSCOLORS
export CLICOLOR=1
export CLICOLOR_FORCE=1
# Don't require escaping globbing characters in zsh.
unsetopt nomatch
ZSH_THEME="powerlevel10k/powerlevel10k"
# Path to your oh-my-zsh installation.
export ZSH="${HOME}/.oh-my-zsh"
# Enable plugins.
plugins=(
history-substring-search
per-directory-history
zsh-syntax-highlighting
zsh-autosuggestions
)
source $ZSH/oh-my-zsh.sh
# Custom $PATH with extra locations.
export PATH=$HOME/Library/Python/3.9/bin:/opt/homebrew/bin:/usr/local/bin:/usr/local/sbin:$HOME/bin:$HOME/go/bin:/usr/local/git/bin:$HOME/.krew/bin:$PATH
# Bash-style time output.
export TIMEFMT=$'\nreal\t%*E\nuser\t%*U\nsys\t%*S'
# Set architecture-specific brew share path.
arch_name="$(uname -m)"
if [ "${arch_name}" = "x86_64" ]; then
share_path="/usr/local/share"
elif [ "${arch_name}" = "arm64" ]; then
share_path="/opt/homebrew/share"
else
echo "Unknown architecture: ${arch_name}"
fi
# Allow history search via up/down keys.
bindkey "^[[A" history-substring-search-up
bindkey "^[[B" history-substring-search-down
# Completions.
autoload -Uz compinit && compinit
# Case insensitive.
zstyle ':completion:*' matcher-list 'm:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]} l:|=* r:|=*' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]} l:|=* r:|=*' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]} l:|=* r:|=*'
# Once a week
export HOMEBREW_AUTO_UPDATE_SECS=604800
# K9s config
export K9SCONFIG=$HOME/.k9s
# Include alias file (if present)
[[ ! -f ~/.aliases ]] || source ~/.aliases
# Include funcion file (if present)
[[ ! -f ~/.functions ]] || source ~/.functions
# Include ANZ specific config
[[ ! -f ~/.anz ]] || source ~/.anz
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh