Visual Studio for Mac Enterprise Edition version 7.3.3 build 23 is unable to connect to TFS 2017 remote GIT repository, the Git-CredentialManager-for-Mac is installed, git clone works perfectly from terminal, but the VS for Mac is not able to present AD credentials and keep asking to reenter credentials in a infinite loop.
I am unable to run any commands against my remote repository at Visual Studio Team Services (VSTS) because authentication fails.
I am able to do pulls, etc. through Visual Studio. But only through Visual Studio. Not through Git Bash, or any other tool like SourceTree.

Visual Studio for Mac.NET. Azure DevOps. Can't git clone remote repository with correct username and password. Azure DevOps. At_robert reported Oct 13, 2017 at 04:36 AM. I used the correct username and password and tried to git clone the remote repository. However, it always said 'Authentication failed'. How do I get the Visual Studio Online credentials cached in the registry? Ask Question. Using Git with Visual Studio. How to disable all caps menu titles in Visual Studio. Can you force Visual Studio to always run as an Administrator in Windows 8? We would run user triggered commands unchanged, so when the credentials indeed expire these commands will have the credentials removed and the user will be asked for new credentials at a time when the user's attention already is on running a git command. Secure Git credential storage for Windows with support for Visual Studio Team Services, GitHub, and Bitbucket multi-factor authentication. Why am always prompted for my username and password? Mac OS, or Linux? The Git Credential Manager does not work on Windows XP, Max OS, or Linux because we had to scope our work and we decided to. Connect to your Git repos through SSH when you can't use the recommended Git Credential Managers or Personal Access Tokens to securely connect using HTTPS authentication. In Visual Studio, go to Repository Settings, and edit your remotes. Changing your password is always a good first step to defend against this attack vector.
Peter Mortensen
onefootswillonefootswill7 Answers
You need to enable Alternate Authentication Credentials if you want to use other Git clients outside of Visual Studio...
To set up alternate creds in Visual Studio Team Services (VSTS), click on your name/icon on the top right -> Security -> Alternate Authentication Credentials
Edit: Add more details about this from VSTS (taken from the alternate credentials screen)...
ALTERNATE AUTHENTICATION CREDENTIALS
Some applications that work outside the browser (including Team Explorer Everywhere command line client and the git-tf utility) require basic authentication credentials. Other applications do not properly handle using an e-mail address for the user name during authentication.
To work with these applications, you need to enable alternate credentials, set a password, and optionally set a secondary user name not in the form of an e-mail address. Please note that alternate credentials cannot be used to sign in to the service from a web browser or outside of these applications.
Anthony ChuAnthony ChuEnable alternate authentication credentials and set secondary username
Create a personal access token for your Visual Studio Team Services account and copy the token
Open Git Bash and go to the folder that you cloned your repository to and enter the following command to make sure it stores the credentials and you don't need to enter it every time:
git pull origin [your branch]It asks for user name and password. Enter user name and token as password
On Windows, you can easily create a Personal Access Token using the Git Credential Manager. It's what Visual Studio Team Services now seems to recommend over the Alternate authentication credentials.
Just install that utility, and then the next time you git pull from Git Bash, it will prompt you for your Visual Studio Team Services access credentials. It will then create a Personal Access Token in your VSTS account, and add a couple of entries to your local Windows Credentials store.
Quote from the site:
It magically works when credentials are needed. For example, when pushing to Visual Studio Team Services, it automatically opens a window and initializes an oauth2 flow to get your token.
I noticed the wording (and location) of the menus changed in Visual Studio Team Services. It is now located in the drop-down menu at the top-right corner (with your initials or photo) Security → Alternate authentication credentials. Just enable and make up your username and password.
Peter MortensenWhen using Atlassian SourceTree you need the basic credentials setup in Visual Studio Team Services (VSTS) like in the accepted answer.
Then in SourceTree go to menu Tools → Options → Authentication tab.
You need to set the non-email username that you set up as basic username credentials for the XXX.visualstudio.com host.

You will then be prompted for the password when accessing that VSTS Git repository.
Peter MortensenDownloading the latest version of Git and including the Git Credential Manager worked for me.
Kolappan NathanVisual Studio For Mac Always Asking For Git Credentials Cache
As per 2017-06-21, the page to enable alternate authentication settings is at the link https://*YOUR_USER_NAME*.visualstudio.com/_details/security/altcreds.
protected by Shaun LuttinApr 22 '16 at 14:32
Visual Studio For Mac Always Asking For Git Credentials Windows
Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).
Would you like to answer one of these unanswered questions instead?