Start ssh agent everywhere.
This commit is contained in:
parent
605d89896f
commit
a3ca6e4701
2 changed files with 9 additions and 0 deletions
6
zsh/ssh.zsh
Normal file
6
zsh/ssh.zsh
Normal file
|
@ -0,0 +1,6 @@
|
|||
if ! pgrep -u "$USER" ssh-agent > /dev/null; then
|
||||
ssh-agent > "$XDG_CACHE_HOME/ssh-agent.env"
|
||||
fi
|
||||
if [[ ! "$SSH_AUTH_SOCK" ]]; then
|
||||
source "$XDG_CACHE_HOME/ssh-agent.env" >/dev/null
|
||||
fi
|
Loading…
Add table
Add a link
Reference in a new issue