Bitbucket git credentials if signed up with Google
Asked Answered
F

12

449

I have an account on bitbucket.org that I created by signing up with my Google account. Now everytime I log in I just click "Log in with Google" and that's fine.

How can I access my repos from git command line? It requests me username and password. I have a username, but no password. How do I log in then?

Future answered 26/1, 2016 at 7:23 Comment(5)
March 2019 and this is still an obscure and undocumented process... I have never heard of an application where the login credentials to the site are different between the website and the command line interface. The explanation as to why this is necessary should be much more prominent.Mend
My first time using bitbucket and I still face this same issue, In fact i now have two accounts with the same email [email protected] is different from [email protected], even a beginner website syncs [email protected] and [email protected] to a single account.Echo
October 2021 and I'm still here.Presentiment
Me too, I am here also @MichałLeonOlsson
July 2022 and it took me forever to figure not to use bitbucket account password but having to create an app password. Dear Lord!Visible
F
168

Solved:

  • Went on the log-in screen and clicked forgot my password.
  • I entered my Google account email and I received a reset link.
  • As you enter there a new password you'll have bitbucket id and password to use.

Sample:

git clone https://<bitbucket_id>@bitbucket.org/<repo>
Future answered 6/2, 2016 at 8:6 Comment(5)
Will this introduce the need to enter the password when logging in on the website?Hill
I can do both waysFuture
Today i received an error page on reseting password ;( it's very sadLyse
Didn't solved for me (yet), after 10 minutes still waiting for reset password email link.Meroblastic
I have received an error as well. Also, using Login with Google is to prevent creating (and possibly losing in a security incident) new credentials, so this "workaround" introduces security issues.Antiquary
C
580

You should do a one-time setup of creating an "App password" in Bitbucket web UI with permissions to at least read your repositories and then use it in the command line.

How-to:

  1. Login to Bitbucket
  2. Click on your profile image in the top-right
  3. Choose Personal settings
  4. Under Access management section look for the App passwords option (https://bitbucket.org/account/settings/app-passwords/)
  5. Create an app password with permissions at least to Read under Repositories section. A password will be generated for you. Remember to save it, it will be shown only once!
  6. The username will be your BitBucket username (how to find it)
Cinchona answered 3/12, 2016 at 10:40 Comment(8)
They should so much simply create the a password after the first connection using the SSO...Thanks a lot, this step was really unclear. Now the screen is [Click you avatar bottom left] > [settings] > [App Password] > [Create App Password] > Select many options (Follow your desire) and voila. Note that the username is the one selected after the first connection using the Google SSO.Gynandrous
What to use as "label" and what to use as "username" in this case?Coetaneous
Sorry, It will not be the google account username. It will be the BitBucket username which is chosen by a user at the time of account creation. Anyway, your answer helped except the mentioned problem.Microphotograph
username is found on the same page in the General > Account settings > Bitbucket Profile settings > section.Onions
this is the correct answer ...now if you can tell me why set ssh key isn't working either! :)Capsicum
Not sure why so many person think this is correct answer? It doesn't work at all. Second, the auto-generated so-long passwod can't be remembered at all. Even you successful set it, it will be useless. The current accepted answer to use forget my password is the easy and fast way to set your nomiated password.Myrmidon
this worked for me but not with point 6 using my google username. i had to use my bitbucket username, which is found in the account settings section about half way down the pageSymposium
Use your usernames in your account instead of your gmail as username guys, the rest works fine! thanksRoman
F
168

Solved:

  • Went on the log-in screen and clicked forgot my password.
  • I entered my Google account email and I received a reset link.
  • As you enter there a new password you'll have bitbucket id and password to use.

Sample:

git clone https://<bitbucket_id>@bitbucket.org/<repo>
Future answered 6/2, 2016 at 8:6 Comment(5)
Will this introduce the need to enter the password when logging in on the website?Hill
I can do both waysFuture
Today i received an error page on reseting password ;( it's very sadLyse
Didn't solved for me (yet), after 10 minutes still waiting for reset password email link.Meroblastic
I have received an error as well. Also, using Login with Google is to prevent creating (and possibly losing in a security incident) new credentials, so this "workaround" introduces security issues.Antiquary
E
36

It's March 2019, and I just did it this way:

  1. Access https://id.atlassian.com/login/resetpassword
  2. Fill your email and click "Send recovery link"
  3. You will receive an email, and this is where people mess it up. Don't click the Log in to my account button, instead, you want to click the small link bellow that says Alternatively, you can reset your password for your Atlassian account.
  4. Set a password as you normally would

Now try to run git commands on terminal.

It might ask you to do a two-step verification the first time, just follow the steps and you're done!

Examen answered 7/3, 2019 at 20:8 Comment(2)
Now you don't get the small link in the 3rd step because they have changed it. You get one login for all Atlassian products. Just type the new password and VoilaShopping
As of July 2019 this appears to be a working solution Kinda understand how the situation has evolved for the Atlassian company, but some UI hints and documentation are sorely missed. Apparently 'login with Google' is fine for folks only wanting to browse repos, but not so much for actual active developers.Putty
P
18

One way to skip this is by creating a specific app password variable.

  1. Settings
  2. App passwords
  3. Create app password

And you can use that generated password to access or to push commits from your terminal, when using a Google Account to sign in into Bitbucket.

Purposeful answered 6/1, 2019 at 23:58 Comment(3)
Use the avatar bottom-left; not the google avator top-right. Then note that there is an extra step, 1a) App Marketplace.Mend
Which permissions did you choose? Is Repository Read/Write enough for git cli client? A git push worked for me with r/w only.Cache
I think this is the best/most modern solution in terms of security: dedicated, limited access credentials for daily work which can be revoked anytime from your bitbucket account, while keeping your bitbucket account passwordless.Cache
T
8

You can setup SSH key authorization like described here - https://support.atlassian.com/bitbucket-cloud/docs/set-up-an-ssh-key/.

Tally answered 26/1, 2016 at 7:27 Comment(2)
ssh: connect to host bitbucket.org port 22: Bad file numberFuture
Kindly verify and post an update regarding the current status of the proposed solution.Putty
O
7

Update as at September, 2019:

This whole process is now way easier than it used to be. It doesn't matter if your auth style is regular or Google-dependent, it works regardless. Follow these four easy steps:

  • Visit this link and enter your email.
  • Check your mail for the reactivation email and click the big blue button therein.
  • Change your password!

I hope this helps. Merry coding!

Offload answered 25/9, 2019 at 11:58 Comment(1)
It does not work currently as it asks us to directly login thorough gmail again.Kawasaki
A
4

you don't have a bitbucket password because you log with google, but you can "reset" the password here https://bitbucket.org/account/password/reset/

you will receive an email to setup a new password and that's it.

Augend answered 6/3, 2019 at 20:3 Comment(0)
W
3

Follow these steps:

  1. login to bitbucket
  2. Click on Personal Settings
  3. Click on Create App Password, here give permission to read and write and the login to GitHub desktop using the same password. Note: Take a screenshot of the password as you won't retrieve it again.

steps updated as on 13th July 2020 Thank You: Rahul Daksh

Whoosh answered 13/7, 2020 at 5:34 Comment(0)
E
2

You can attach a "proper" Bitbucket account password to your account. Go to https://id.atlassian.com/manage/change-password (sign in using your Google account) and then enter a new password in both the old and new password boxes. Now you can use your email address and this new password to access your account on the command line.

Note: App passwords are the official way of doing this (per @Christian Tingino's answer), but IMO they don't work very nicely. No way of changing the password, and they are big unwieldly things to type into the command line.

Enact answered 15/2, 2018 at 22:35 Comment(1)
I tried, but the Old/New Password fields were disabled. Even the mouse cursor changes to show you can't input anything in them... Then I closed the tab, reopened with Ctrl+T and the fields were enabled. However, it asked for the old password. Neither the new password nor my Google password worked.Wayworn
A
0

The correct solution I guess is as follows:

First lot out from the account. Then click in "can't login". After that you will be able to recover your email. So, you will get recovery link and click on that email and set new password.

A1 answered 4/4, 2022 at 13:15 Comment(0)
G
0

I just got into this problem, but I installed GitCredentialManager from here and when I tried to clone a repository, this opened up a window to make an OAuth with Bitbucket, and internally this credential manager took managed everything. I'm using a MacBook pro by the way.

Gherardi answered 2/3, 2023 at 23:11 Comment(0)
R
-1

I found this while reading the docs:

This image... Doesn't know whether it works and you have to enter your Google password!

Link to this tutorial

Rosabelle answered 10/11, 2021 at 7:54 Comment(2)
While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference. Link-only answers can become invalid if the linked page changes. - From ReviewMaritamaritain
Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.Examine

© 2022 - 2024 — McMap. All rights reserved.