Visual Studio扩展未知错误-无法推送或获取任何内容 [英] Extension for Visual studio unknown error - unable to push or fetch anything

查看:198
本文介绍了Visual Studio扩展未知错误-无法推送或获取任何内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试通过Visual Studio的Git扩展将任何内容推送到我的Bitbucket存储库时,出现错误:

I have an error when I try to push anything to my bitbucket repository via Git extension for visual studio:

Error encountered while pushing branch to the remote repository: Git failed with a fatal error.
HttpRequestException encountered.
   An error occurred while sending the request.
cannot spawn /C/Program Files (x86)/Microsoft Visual Studio/2017/Community/Common7/IDE/CommonExtensions/Microsoft/TeamFoundation/Team Explorer/Git/mingw32/libexec/git-core/git-askpass.exe: No such file or directory
could not read Password for ......

这里可能是什么问题?

推荐答案

似乎会影响某些Visual Studio用户从几个小时前起,即使在此之前在环境中未进行任何更改.与Visual Studio进行Git集成时,显然出现了问题.

It seems to affect some Visual Studio users since a few hours ago, even with no changes taken place in the environment prior to that. Something apparently went wrong in Git integration with Visual Studio.

当前存在一种解决方法,您可以在存储库的远程设置中设置密码,如此处,但请注意,此操作不安全,因为它需要以纯文本格式存储密码.

There is currently a workaround, where you set the password in the remotes settings of the repository, as shown here, but note that it is insecure as it requires storing the password in plain text.

另一种解决方法是使用命令行使用Git.

Another workaround is to work with Git using command line.

第三个解决方法(也是我发现的最佳解决方法)是配置SSH密钥身份验证.截至目前,它似乎可以在Visual Studio 2017中正常使用.这是我选择的解决方案.

A third workaround, which I also find the best one, is to configure SSH key authentication. As of now, it seems to work with Visual Studio 2017 without any issues. This is the solution I chose.

这篇关于Visual Studio扩展未知错误-无法推送或获取任何内容的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆