Copying ssh private key with finder, but can’t see it with console

sshterminal

Background: I generated an additional ssh key-pair on my windows 7 workplace computer. I placed the corresponding public keys in my bitbucket.org and github.com account. I am using atlassian sourcetree as a git gui. I copied the private key into (my mac) the .ssh folder using the finder(drag and drop), and when I use the command ls -lah also ssh-add -l doesn't show the keys I copied.

I am using OSX v10.7.5

Also, I have heard of this thing called keychain access, but I am new to mac, and I don't know if this sort of thing is required to manage my ssh keys.

Question: What is the reason I cannot see my private keys in my ~/ssh directory? How do I fix it so that I can add the new private key.

Best Answer

From Terminal, type:

cd ~/.ssh
sudo ssh-add [keyname]

This will add the key to your computer for you.