Am trying to clone a private Bitbucket repository via a bash task in Azure DevOps. This is the command
git clone --branch master https://username:[email protected]/repo.git
Earlier I was getting this error
"fatal: could not read Password for 'https://***@bitbucket.org': terminal prompts disabled"
which is why I included the password also in the URL to get it to work, but now I get this.
fatal: unable to access 'https://bitbucket.org/realogy-abt/apipublishing.git/': Could not resolve host: ***
I have tried setting the global git configs with user.name and email, and the remote origin url, but nothing works.
git config --global user.email "xxx"
git config --global user.name "xxxx"
I'm trying this from a bash task within Azure DevOps. Any help would be appreciated. Edited to add: The same clone worked seamlessly with Github repo.