refactor(zsh): improve handling of ssh-agent
This commit is contained in:
parent
10e869744d
commit
0c02db7cc5
@ -59,10 +59,9 @@ export TIMEFMT
|
||||
export REPORTTIME=600
|
||||
|
||||
### SSH ###
|
||||
export SSH_AUTH_SOCK="${XDG_RUNTIME_DIR}/ssh-agent.sock"
|
||||
ssh-add -l >/dev/null
|
||||
[ $? -ge 2 ] && ssh-agent -a "$SSH_AUTH_SOCK" -t 24h >/dev/null
|
||||
|
||||
export SSH_AUTH_SOCK="${SSH_AUTH_SOCK:-$XDG_RUNTIME_DIR/ssh-agent.sock}"
|
||||
ssh-add &>/dev/null
|
||||
[[ "${?}" -gt 2 ]] && eval "$(ssh-agent -a "${SSH_AUTH_SOCK}")" &>/dev/null
|
||||
|
||||
### FZF ###
|
||||
export FZF_DEFAULT_COMMAND='fd --hidden --exclude .git --color=always'
|
||||
|
Loading…
Reference in New Issue
Block a user