-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.zshrc
More file actions
66 lines (51 loc) · 1.92 KB
/
.zshrc
File metadata and controls
66 lines (51 loc) · 1.92 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
autoload -Uz promptinit
autoload -Uz compinit
setopt complete_in_word # Complete from both ends of a word.
setopt always_to_end # Move cursor to the end of a completed word.
setopt auto_menu # Show completion menu on a successive tab press.
setopt auto_list # Automatically list choices on ambiguous completion.
setopt auto_param_slash # If completed parameter is a directory, add a trailing slash.
setopt extended_glob # Needed for file modification glob modifiers with compinit
unsetopt menu_complete # Do not autoselect the first completion entry.
unsetopt flow_control # Disable start/stop characters in shell editor.
setopt auto_cd
export ZSH="$HOME/.zsh"
# setup zsh cache dir for for omz completions
export ZSH_CACHE_DIR="${ZSH}/cache"
mkdir -p "$ZSH_CACHE_DIR/completions"
(( ${fpath[(Ie)$ZSH_CACHE_DIR/completions]} )) || fpath=("$ZSH_CACHE_DIR/completions" "${fpath[@]}")
# configure .local/bin/e folders
export E_PROJECTS_PATH="$HOME/.config:$HOME/workspace"
export E_PROJECTS_DEPTH="1"
# Disable async prompts
# https://github.com/ohmyzsh/ohmyzsh/blob/b8c69d265257fae88fe504ea43cbcf2728bc1308/README.md#disable-async-git-prompt
zstyle ':omz:alpha:lib:git' async-prompt no
source "${HOME}/.antidote/antidote.zsh"
antidote load
compinit
handle_completion_insecurities &|
WORDCHARS=''
source "${HOME}/.zsh/aliases.zsh"
source "${HOME}/.zsh/completion.zsh"
source "${HOME}/.zsh/functions.zsh"
source "${HOME}/.zsh/history.zsh"
source "${HOME}/.zsh/prompt.zsh"
# pnpm
export PNPM_HOME="$HOME/.local/share/pnpm"
export PATH="$PNPM_HOME:$PATH"
source "$HOME/.zsh/pnpm.completion.zsh"
# z
if type zoxide &>/dev/null; then
eval "$(zoxide init zsh --cmd z --hook pwd)"
fi
if type mise &>/dev/null; then
eval "$(mise activate zsh)"
fi
# local config
if [[ -f "$HOME/.zshrc.local" ]]; then
source "$HOME/.zshrc.local"
fi
# gpg pinentry in vscode
if [[ -n "$VSCODE_INJECTION" ]]; then
export GPG_TTY=$(tty)
fi