Reputation: 51
git init
git add .
git commit -m 'nazwa commita'
git remote add origin https://NazwaUż[email protected]/NazwaUżytkownika/test.git
git push -u origin --all
I must enter pass and email. When I enter mail and pass I get the error " failed to auth".
I tried
git remote add origin https://username:[email protected]/username/projekt.git
and that worked.
Now I must use
git clone (here link to bitbucket)
and this doesn't work: I get the error
remote: Unauthorized fatal: Authentication failed for.
When I'm using username:pass@bitbucket I get error 500 ....
Upvotes: 5
Views: 18752
Reputation: 1866
So, I was having this problem on a project recently. I went to my ~/.ssh/confg
file (mac) and checked it. It looked correct as I had all my identity files listed under bitbucket.org
example:
Host bitbucket.org
HostName bitbucket.org
User git
IdentityFile ~/.ssh/identity_file_1
IdentityFile ~/.ssh/identify_file_2
IdentityFile ~/.ssh/identify_file_3
IdentitiesOnly yes
But, it wasn't working.
This is what worked:
Host bitbucket.org
HostName bitbucket.org
User git
IdentityFile ~/.ssh/identity_file_1
# IdentityFile ~/.ssh/identify_file_2
# IdentityFile ~/.ssh/identify_file_3
IdentitiesOnly yes
Yeah, just commenting it out for now. Just want to be able to switch between identities for different projects.
Hope this helps!
Upvotes: 0
Reputation: 2512
I faced a similar issue while cloning a repository from Bitbucket. Here is one possible solution that worked out for me. As per their access management system, Bitbucket has this security thing known as "App passwords". You can find it under 'Personal settings → Access Management → App passwords' as shown below.
Upvotes: 9
Reputation: 1442
What worked for me was changing my password. Not through the admin page ("My Atlassian Account"), which also didn't work. Instead, log out of BitBucket, click on the password recovery link, and follow that process. Try again with your new account password.
Upvotes: 1
Reputation: 8417
This should work; I have used it many times with bitbucket for my Scala courses:
git clone https://username:[email protected]/username/projekt.git
Git credentials is a way for you to not have to type in username and password all the time.
You might want to look at URL encoding for the special characters.
SSH is best. Yes, it is confusing at first. Eventually you will need to learn this.
Upvotes: 1