BitBucket - Set up SSH key pair for Git

preview_player
Показать описание
Note: It is required that you download and install Git Bash first. Installation of Git is not covered in this tutorial, you can find "Git - Initial Setup on Windows" on my channel for more details on this topic.

This short video shows how you can create a public/private SSH key pair and register your public key with BitBucket.

Similar approach can be used for GitHub, the only difference is in the last part when you have to register your key using GitHub interface.

This will allow you to clone your repos with this command:

Important: Your private key should be available only to you, and your public key is meant to be shared with everyone.
Рекомендации по теме
Комментарии
Автор

Incredible that a video from 8 years ago saved me. Thank you for this.

fernandogutierrez
Автор

Finally to the point video. Thanks. It is helpful rather than another tutorial. So confused beyond. I downloaded the video :)

Rizkiaqa
Автор

Bitbucket changed a bit, so it's Profile > Bitbucket settings > (Security) SSH keys. Thanks for the tutorial. :)

KatRollo
Автор

Ok, with this video I can have some sleep finally. Thanks - is applicable for GitLab too.

teddymarkov
Автор

Thanks Goran, this video really helped me :)

bijay
Автор

To set up it for Sourcetree
Tools->Options->General tab, switch SSH client to "Open SSH" and make sure that the path to id_rsa is correct. Click OK, in console window you'll be asked to enter password, then click enter. Enjoy!

alewarten
Автор

It's very good!
And the description the comands?
Please :)

infantito
Автор

Excelent tutorial. I have a question. What's the meaning of the "-C" in the command line?

brownie
Автор

I am on Win7 and when I do clip < it cannot find the file, even though it is there. What do I do now? I have tried a variety of formatting for this string, but it just would not see the file...

JoshuaMartinez-hubg
Автор

Hi Goran, At the point of copying the key (clip) the file is not found for some reason, even though it has been created and exists. I have checked the / and everything several times, as well as going into the directory and copying the path; it just wouldn't find it. I am confused how I should proceed...

JoshyHJoshy
Автор

Hi Goran, is it okay not to set any password?

KatRollo
Автор

seems people only want to show how to set up a key...nobody knows how to actually use it to push and pull stuff...and how to disable other forms of pushing and pulling
this is the only thing that matters..they key set up is easy peasy....but how to use it. ?
for your information people it all depends on how you clone the repo.... you can clone over ssh which basically sets up the repo to use ssh push and pull rather than https...you shold also on your bitbucket or github disable https access...so nobody can even attempt to get your code via https
a good command for you to see how your repo is set up currently is git remote -v...
anyway this muppet missed out all the important shit so i thought id tell you.

runthomas