vs推送git失败,修改git下config的Log

一开始写完程序套推送到Git中,然后就来了一下,下面的异常:

异常1

发布到远程存储库时遇到错误: Git failed with a fatal error.
fatal: HttpRequestException encountered.
   ��������ʱ�����
error: cannot spawn askpass: No such file or directory
fatal: could not read Username for 'https://github.com': terminal prompts disabled
Pushing to https://github.com/ZhuKaiBin/ConsoleAsync

 这个呢,首先从网上找到的是修改.git 下的Config的文件

原文
git remote add origin https://{username}:{password}@github.com/{username}/project.git 如:https://github.com/zhangsan:123456@github.com/zhangsan/project.git 或者直接修改 .git/config 隐藏文件 为git remote add origin https://{username}:{password}@github.com/{username}/project.git 格式

 就是上面这样的:值得注意的是:标黄色的

https://github.com/zhangsan:123456@github.com/zhangsan/project.git

 我用的是qq邮箱登陆的,就是这样的 

https://github.com/9124xxx@qq.com:123456@github.com/zhangsan/project.git
一直就是不行呢,后来替换成账号和账户名称名称一样的就ok了。
有点瘪嘴了:账号是9125aaa@qq.com 账户名称是:zhangsan
就好比你的qq号和昵称一样的关系。
统一更改成昵称。




原文地址:https://www.cnblogs.com/ZkbFighting/p/11803164.html