-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.setup_env.fish
executable file
·48 lines (40 loc) · 1.12 KB
/
.setup_env.fish
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
#!/usr/bin/env fish
mkdir -p ~/.config/fish/conf.d
mkdir -p ~/.config/fish/functions
# Activate brew
set -l brew_paths \
/opt/homebrew/bin/brew \
/usr/local/bin/brew \
/home/linuxbrew/.linuxbrew/bin/brew
for path in $brew_paths
if test -x $path
eval (parse_shellenv $path shellenv | string replace -- ' --path' '' | string replace -- --global -U | source)
break
end
end
# Activate mise
if command -v mise > /dev/null
mise activate fish > ~/.config/fish/conf.d/mise.fish
end
# Integrate fzf
if command -v fzf &>/dev/null
fzf --fish > ~/.config/fish/functions/fzf_key_bindings.fish
end
# Integrate starship
if command -v starship &>/dev/null
starship init fish > ~/.config/fish/conf.d/starship.fish
end
set -U LC_ALL en_US.UTF-8
# Set PATH
set -l paths \
~/.local/share/google-cloud-sdk/bin \
~/.local/share/yabridge \
~/.rd/bin \
~/.local/bin
for path in $paths
if test -d $path
fish_add_path -Upm $path
end
end
# Fisher plugin manager
curl -sL https://raw.githubusercontent.com/jorgebucaran/fisher/main/functions/fisher.fish | source && fisher install jorgebucaran/fisher