15
5
I recently setup openssh
so I could use it with git
.
In the process of setting it up (as per this article) I ran the commands:
$ eval "$(ssh-agent -s)"
$ ssh-add ~/.ssh/<name of key>
Some time later, after I logged out and back in I tried to use git push
I got an error. The solution to this error was running those same commands again.
Please tell me how I can
- Keep the
ssh-agent
running so I don't have to start a new one - Remember the keys I've added so I don't have to add them everytime
Just to clarify, I use zsh so certain bash features won't work in my .zshrc.
You should start with understanding what is
ssh-agent
for and how does it work before trying to suit it your twisted use case. – Jakuje – 2016-12-04T18:55:54.463What error you got? – Jakuje – 2016-12-04T19:05:57.173
@Jakuje The error was about a missing pubkey and asked "Have you started ssh-agent?". – timotree – 2016-12-04T19:28:25.167