When trying to pull
or push
using Git installed with Microsoft Visual Studio 2019 on Windows 10, either from IDE or using CLI, the following error is returned:
fatal: could not read Password for 'http://[username]@[hostname]:[port]': No such file or directory
The Git host is an on-prem installation of BitBucket.
The Visual Studio 2019 Git, version 2.29.2.windows.4
, is installed here: "C:\program files (x86)\microsoft visual studio\2019\professional\common7\ide\commonextensions\microsoft\teamfoundation\team explorer\Git"
.
A system default installation of Git CLI (C:\Program Files\Git
, version 2.32.0.windows.1
) works without any issues. If Visual Studio 2019 Git folder is renamed or removed, Visual Studio works correctly with the default Git installation also. However, Visual Studio Git gets reinstalled on every update, resulting in errors coming back.
In case it matters, Git global configuration has credential.helper
set to manager-core
.
How can the Visual Studio Git be configured to work correctly without renaming/removing folders or including passwords in the repository URLs?