"Help, I keep getting a 'Permission Denied (publickey)' error when I push!"
This means, on your local machine, you haven't made any SSH keys. Not to worry. Here's how to fix:
- Open git bash (Use the Windows search. To find it, type "git bash") or the Mac Terminal. Pro Tip: You can use any
*nixbased command prompt (but not the default Windows Command Prompt!)
cd ~/.ssh. This will take you to the root directory for Git (Likely
- Within the
.sshfolder, there should be these two files:
id_rsa.pub. These are the files that tell your computer how to communicate with GitHub, BitBucket, or any other Git based service. Type
lsto see a directory listing. If those two files don't show up, proceed to the next step. NOTE: Your SSH keys must be named
id_rsa.pubin order for Git, GitHub, and BitBucket to recognize them by default.
- To create the SSH keys, type
ssh-keygen -t rsa -C "email@example.com". Th