解决credential-cache‘ is not a git command. See ‘git --help

昨天使用sourceTree下载gitee上面的仓库代码碰到一个问题:

命令: git -c diff.mnemonicprefix=false -c core.quotepath=false --no-optional-locks ls-remote https://gitee.com/xxx/xxx.git
输出: 
错误: git: 'credential-cache' is not a git command. See 'git --help'.
git: 'credential-cache' is not a git command. See 'git --help'.
remote: [: Incorrect username or password (access token)[0m
fatal: Authentication failed for 'https://gitee.com/xxx/xxx.git/'

我一直以为是我们sourceTree没有添加托管账号 向下面这张图一样

实际不是,原因是因为Git Credential Manager for Windows v1.20 这个管理工具没有安装,它没有唤醒弹窗用于输入用户名密码。

下载好之后就ok了,下载地址如下:https://github-production-release-asset-2e65be.s3.amazonaws.com/42456996/40583700-d08d-11e9-8ae2-c58bfd9e3989?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20210109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20210109T055756Z&X-Amz-Expires=300&X-Amz-Signature=59aba230e1515dae842e6cec900c28ea2747948b732ab1f4fee65c803397d4a9&X-Amz-SignedHeaders=host&actor_id=22340625&key_id=0&repo_id=42456996&response-content-disposition=attachment%3B%20filename%3DGCMW-1.20.0.exe&response-content-type=application%2Foctet-stream

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值