Bitbucket repo clone with login credentials
21,453
You can, with:
git clone https://user:[email protected]/myacc/app.git
But this will save your credentials in the origin url in .git/config
.
To avoid that you could change the origin afterwards git remote set-url origin https://[email protected]/myacc/app.git
Related videos on Youtube
Author by
Jon not doe xx
Updated on July 09, 2022Comments
-
Jon not doe xx almost 2 years
I have a Basic git clone command to bitbucket in which I have to add Login credentials, is it possible to add Login credentials to a bitbucket git clone command?
https://[email protected]/myacc/app.git
Something like this?
https://[email protected]/myacc/app.git -Password "123"
-
phd over 5 yearsPossible duplicate of Is there a way to skip password typing when using https:// on GitHub?
-
phd over 5 years
-
-
Jon not doe xx over 5 yearsDo I Need to add the Project Name if in the git remove command if I start like this?
git clone https://user:[email protected]/myacc/app.git MyApp
so should it be this?git remote set-url origin https://[email protected]/myacc/app.git MyApp
-
ColdIV over 5 yearsIt should work the way I posted it. The project should already be included in the URL.
-
Jon not doe xx over 5 yearsOk thanks it seems to work, can you explain me this further I do not understand why this is an issue
But this will save your credentials in the origin url in .git/config.
-
ColdIV over 5 yearsIt does not have to be an isse.<br/>In your projects local
.git
folder is a config file, and whoever has access to this file will then have your credentials, as it stores the origin url in it. But if you are the only one on your PC with access to this file, then there is no issue. -
Marinos An over 4 yearsWhat if password contains a
@
? -
Genki about 4 years@MarinosAn You can type %40 for @. More info: fabianlee.org/2016/09/07/…