To `git push` to Bitbucket with SSH key, create an SSH key as follows:
ssh-keygen -t rsa -b 4096 -C "izeye@naver.com"
Add `~/.ssh/id_rsa.pub` to your Bitbucket settings as follows:
Bitbucket settings -> SSH keys -> Add key
Change the remote URL as follows:
git remote set-url bitbucket git+ssh://git@bitbucket.org/ctb-return/ask-anything.git
and now you can `git push` as follows:
git push bitbucket
References:
https://help.github.com/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent/
http://stackoverflow.com/questions/8588768/git-push-username-password-how-to-avoid
No comments:
Post a Comment