fish path entries only if they exist

This commit is contained in:
Ben Harris 2018-08-08 14:55:26 -04:00
parent 98b1daf9d6
commit e1c64477bd
Signed by untrusted user: ben
GPG Key ID: 4E0AF802FFF7960C
2 changed files with 14 additions and 3 deletions

View File

@ -6,11 +6,20 @@ set -g theme_nerd_fonts yes
set -g theme_color_scheme dark
set -g theme_display_date no
set -x MAIL /home/ben/Maildir
if test -d ~/Maildir
set -x MAIL ~/Maildir
end
set -x GOPATH (/usr/local/go/bin/go env GOPATH)
if test -d /usr/local/go
set -x GOPATH (/usr/local/go/bin/go env GOPATH)
end
set -x fish_user_paths $fish_user_paths ~/bin /usr/local/go/bin ~/.yarn/bin $GOPATH/bin ~/.local/bin ~/.cargo/bin
set user_paths ~/bin /usr/local/go/bin ~/.yarn/bin $GOPATH/bin ~/.local/bin ~/.cargo/bin /snap/bin
for path in $user_paths
if test -d $path
set -x fish_user_paths $fish_user_paths $path
end
end
set -x SSH_AGENT_PID ""
set -x SSH_AUTH_SOCK (gpgconf --list-dirs agent-ssh-socket)

View File

@ -1,3 +1,5 @@
enable-ssh-support
keep-display
default-cache-ttl 300
max-cache-ttl 1200