I know how to provide a username and password to an HTTPS request like this:
git clonehttps://username:[email protected]
But I'd like to know how to provide a username and password to the remote like this:
git clone[email protected]
I've tried like this:
git clone username:[email protected]@remote.git
git clone[email protected]:[email protected]
git clone[email protected]@username:password
But they haven't worked.
The following can be used:
$ git clonehttps://username:[email protected]/username/repository.git
You can also leave out the password, after the following command git will ask you and it will not be saved in .git/config nor in your bash history
$ git clonehttps://[email protected]/username/repository.git