Goal:
When I do git push -u origin master
I want my local PC to push to GitHub instead of BitBucket.
Background: I had BitBucket setup in my Mac as default website to push code to. But I decided to switched to GitHub for a new project. Here is my cmds and error I got:
Commands:
cd proj1
git init
echo "# tmp" >> README.md
git add README.md
git commit -m "first commit"
git remote add origin git@github.com:myusername/proj1.git
git push -u origin master
Error:
git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Thanks in advance for your help.