-
Notifications
You must be signed in to change notification settings - Fork 0
/
.zshrc
75 lines (58 loc) · 2.1 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
66
67
68
69
70
71
72
73
74
eval "$(/opt/homebrew/bin/brew shellenv)"
. "$HOME/.cargo/env"
### func or alias
function cd_ghq_list() {
local destination_dir="$(ghq list --full-path| fzf)"
if [ -n "$destination_dir" ]; then
cd $destination_dir
fi
echo $destination_dir
}
alias ls="ls -G"
alias lg="lazygit"
alias fgh=cd_ghq_list
alias v="nvim"
alias vi="nvim"
alias vim="nvim"
alias atheme="npx alacritty-themes"
alias memomv="cd ~/.memolist"
### Added by Zinit's installer
if [[ ! -f $HOME/.local/share/zinit/zinit.git/zinit.zsh ]]; then
print -P "%F{33} %F{220}Installing %F{33}ZDHARMA-CONTINUUM%F{220} Initiative Plugin Manager (%F{33}zdharma-continuum/zinit%F{220})…%f"
command mkdir -p "$HOME/.local/share/zinit" && command chmod g-rwX "$HOME/.local/share/zinit"
command git clone https://github.com/zdharma-continuum/zinit "$HOME/.local/share/zinit/zinit.git" && \
print -P "%F{33} %F{34}Installation successful.%f%b" || \
print -P "%F{160} The clone has failed.%f%b"
fi
source "$HOME/.local/share/zinit/zinit.git/zinit.zsh"
autoload -Uz _zinit
(( ${+_comps} )) && _comps[zinit]=_zinit
### zinit plugins
zinit wait lucid blockf light-mode for \
@'zsh-users/zsh-syntax-highlighting' \
@'zsh-users/zsh-autosuggestions' \
@'zsh-users/zsh-completions' \
@'paulirish/git-open'
### pure prompt
PROMPT='%F{white}%* '$PROMPT
eval "$(starship init zsh)"
### anyenv
# eval "$(anyenv init - --no-rehash)"
if [ -x /usr/local/bin/anyenv ]
then
if ! [ -f /tmp/anyenv.cache ]
then
anyenv init - > /tmp/anyenv.cache
zcompile /tmp/anyenv.cache
fi
source /tmp/anyenv.cache
fi
. /opt/homebrew/opt/asdf/libexec/asdf.sh
### paths
#### goenv
export PATH="$PATH:$(go env GOPATH)/bin"
# The next line updates PATH for the Google Cloud SDK.
if [ -f '/Users/s09104/Downloads/google-cloud-sdk/path.zsh.inc' ]; then . '/Users/s09104/Downloads/google-cloud-sdk/path.zsh.inc'; fi
# The next line enables shell command completion for gcloud.
if [ -f '/Users/s09104/Downloads/google-cloud-sdk/completion.zsh.inc' ]; then . '/Users/s09104/Downloads/google-cloud-sdk/completion.zsh.inc'; fi
eval "$(direnv hook zsh)"