-
Notifications
You must be signed in to change notification settings - Fork 0
/
.zshrc##distro.Ubuntu
53 lines (41 loc) · 1.42 KB
/
.zshrc##distro.Ubuntu
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
#!/usr/bin/env zsh
# nvm setup
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
# add default nvm node to path
NODE_VERSION=$(nvm version)
export PATH="$NVM_DIR/versions/node/$NODE_VERSION/bin:$PATH"
# initalize starship
eval "$(starship init zsh)"
# install plugins with zsh_unplugged
ZPLUGINDIR="${HOME}/.config/zsh/plugins"
if [[ ! -d $ZPLUGINDIR/zsh_unplugged ]]; then
git clone --quiet https://github.com/mattmc3/zsh_unplugged $ZPLUGINDIR/zsh_unplugged
fi
source $ZPLUGINDIR/zsh_unplugged/zsh_unplugged.zsh
plugin_repos=(
zsh-users/zsh-completions
zsh-users/zsh-syntax-highlighting
zsh-users/zsh-autosuggestions
softmoth/zsh-vim-mode
)
plugin-load $plugin_repos
# configure fzf shortcuts
if [[ ! "$PATH" == *$HOME/.fzf/bin* ]]; then
PATH="${PATH:+${PATH}:}$HOME/.fzf/bin"
fi
source <(fzf --zsh)
# add cargo to path
if [[ ! "$PATH" == *$HOME/.cargo/bin* ]]; then
export PATH="$HOME/.cargo/bin:$PATH"
fi
# add nvim to path
if [[ ! "$PATH" == *$HOME/opt/nvim-linux64/bin* ]]; then
export PATH="$PATH:/opt/nvim-linux64/bin"
fi
# alias for other nvim distributions
alias nvim-lazy="NVIM_APPNAME=lazyvim nvim"
alias nvim-kickstart="NVIM_APPNAME=kickstart nvim"
alias nvim-chad="NVIM_APPNAME=nvchad nvim"
alias nvim-lunar="${HOME}/.local/bin/lvim"