diff --git a/fish/config.fish b/fish/config.fish index f693fb8..f1177c0 100644 --- a/fish/config.fish +++ b/fish/config.fish @@ -55,18 +55,17 @@ set -Ux NATS_CA /srv/nats/minica.pem set -Ux NATS_CERT /srv/nats/odin.packetlost.dev/cert.pem set -Ux NATS_KEY /srv/nats/odin.packetlost.dev/key.pem -if test -d "$HOME/.cargo" - fish_add_path "$HOME/.cargo/bin" +function add_to_path_if_exists -a directory + if test -d "$directory" + fish_add_path "$directory" + end end -if test -d "$HOME/.local" - fish_add_path "$HOME/.local/bin" -end - - -if test -d "$HOME/.local/share/solana/install/active_release/bin" - fish_add_path "$HOME/.local/share/solana/install/active_release/bin" -end +add_to_path_if_exists "$HOME/.local/share/solana/install/active_release/bin" +add_to_path_if_exists "$HOME/.local/bin" +add_to_path_if_exists "$HOME/.cargo/bin" +add_to_path_if_exists "$HOME/go/bin" +add_to_path_if_exists "$HOME/.gerbil/bin" +add_to_path_if_exists "/opt/gerbil/bin" -# Keybindings fish_default_key_bindings