I'm switching to using Git instead of Mercurial, and am using Bitbucket for my remote repository. I have things largely working now, except for my credentials for connecting to the remote repo from a different server (with a different username). I cloned the repo with git clone https://person@bitbucket.org/myprojects/myproject.git
to my other server. But I don't actually want to connect as user 'person' from that server, there is a different username I want to connect as, and I want to be prompted for it. With Mercurial, I could in effect miss out the person@
and I would be prompted each time (which is what I want). But if I do that with Git, I get a message saying error: The requested URL returned error: 401 Unauthorized while accessing [the repo]
. So how do I do this with Git?
[LATER: Beginning to think this might be an issue to with the version of Git I'm using on that server, 1.7.1. I'll try to update and see where I get to]