Configuration files
1ZINIT_HOME="${XDG_DATA_HOME:-${HOME}/.local/share}/zinit/zinit.git"
2[ ! -d $ZINIT_HOME ] && mkdir -p "$(dirname $ZINIT_HOME)"
3[ ! -d $ZINIT_HOME/.git ] && git clone https://github.com/zdharma-continuum/zinit.git "$ZINIT_HOME"
4source "${ZINIT_HOME}/zinit.zsh"
5
6ZSH_AUTOSUGGEST_STRATEGY=(history completion)
7
8if [ -x "$(which jj)" ]; then
9 JJ_INSTALLED="$(which jj)"
10fi
11
12zinit wait lucid for \
13 atinit"zicompinit; zicdreplay" \
14 zdharma-continuum/fast-syntax-highlighting \
15 atload"_zsh_autosuggest_start" \
16 zsh-users/zsh-autosuggestions \
17 blockf atpull'zinit creinstall -q .' \
18 atload"if [ -v JJ_INSTALLED ]; then; source <(jj util completion zsh); fi" \
19 atload"if [ -v JJ_INSTALLED ]; then; source <(COMPLETE=zsh jj); fi" \
20 zsh-users/zsh-completions
21
22zinit id-as"auto" for \
23 atload"bindkey -e" \
24 "https://git.sr.ht/~kareigu/zsh-utils/blob/main/editor/editor.plugin.zsh" \
25 atload'eval "$(fzf --zsh)"' \
26 "https://git.sr.ht/~kareigu/zsh-utils/blob/main/history/history.plugin.zsh" \
27
28zstyle ':completion:*' menu yes select
29unsetopt LIST_BEEP
30
31export PATH=~/.cargo/bin/:$PATH
32export PATH=~/.zvm/bin:$PATH
33export PATH=~/.local/bin:$PATH
34
35if [ -x "$(which starship)" ]; then
36 eval "$(starship init zsh)"
37else
38 echo "starship not in path"
39fi
40
41if [ -x "$(which zoxide)" ]; then
42 eval "$(zoxide init zsh --cmd cd)"
43else
44 echo "zoxide not in path"
45fi
46
47export GPG_TTY=$(tty)
48
49if [ -x "$(which nvim)" ]; then
50 export EDITOR='nvim'
51elif [ -x "$(which vim)" ]; then
52 export EDITOR='vim'
53else
54 export EDITOR='vi'
55fi
56
57if [ -x "$(which batman)" ]; then
58 eval "$(batman --export-env)"
59fi
60
61# git
62alias gs="git status"
63alias gap="git add -p"
64alias gpl="git pull"
65alias gp="git push"
66alias gc="git commit"
67alias lzg=lazygit
68
69
70alias ls="lsd"
71alias l="ls -la"
72alias la="ls -lA"