-
Notifications
You must be signed in to change notification settings - Fork 0
/
profile.zsh
executable file
·93 lines (70 loc) · 1.75 KB
/
profile.zsh
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# Run this script from .zprofile
false && alias _='print' || alias _=':'
######## Begin alternate system-level package managers
if [[ -d "$HOME/.local/bin" ]]; then
_ local-bin
export PATH="$PATH:$HOME/.local/bin"
fi
if (( $+commands[snap] )); then
_ snap
export PATH="$PATH:/snap/bin"
fi
if [[ -x '/opt/local/bin/port' ]]; then
_ port
export PATH="/opt/local/bin:/opt/local/sbin:$PATH"
fi
######## End system-level package managers
if (( $+commands[cargo] )) || (( $+commands[rustup] )) || [[ -x "$HOME/.cargo/bin/rustup" ]]; then
_ cargo
export PATH="/usr/lib/cargo/bin:$HOME/.cargo/bin:$PATH"
fi
if [[ -e '/opt/local/share/dotnet' ]]; then
_ dotnet
export DOTNET_ROOT='/opt/local/share/dotnet'
fi
if [[ -x "$HOME/.elan/bin/elan" ]]; then
_ elan
export PATH="$HOME/.elan/bin:$PATH"
fi
if (( $+commands[ruby] )) && (( $+commands[gem] )); then
_ gem
export PATH="$PATH:$(ruby -r rubygems -e 'puts Gem.user_dir')/bin"
fi
if [[ -s "$GOPATH" ]]; then
_ go
export PATH="$PATH:$GOPATH/bin"
fi
_ gpg
. "$(dirname "$0")"/gpg.zsh
() {
local f="$commands[nodenv]"
if [[ -z "$f" && -d "$HOME/.nodenv" ]]; then
export PATH="$PATH:$HOME/.nodenv/bin"
f="$commands[nodenv]"
else
return
fi
_ nodenv
. <("$f" init - zsh | cat)
}
if (( $+commands[rbenv] )); then
_ rbenv
. <(rbenv init - zsh | cat)
elif [[ -s "$HOME/.rvm/scripts/rvm" ]]; then
_ rvm
. "$HOME/.rvm/scripts/rvm"
fi
if [[ -d "$HOME/.rakudobrew" ]]; then
_ rakudobrew
. <("$HOME/.rakudobrew/bin/rakudobrew" init - | cat)
fi
if (( $+commands[yarn] )); then
_ yarn
export PATH="$PATH:$HOME/.yarn/bin"
fi
######## Begin PATH overrides
if (( $+commands[port] )); then
export PATH="/opt/local/libexec/gnubin:$PATH"
fi
######## End PATH overrides
unalias _