AWS Codecommit Git克隆错误:致命错误:找不到“codecommit”的远程助手。

15
我正在尝试从我们的私有代码托管服务 codecommit 中克隆一个仓库,我有必要的访问权限,但每当我尝试在本地克隆时,都会遇到以下错误:

I am trying to clone a repository from our private codecommit, I have necessary access, but whenever i try to clone locally, I am getting the error:

git clone codecommit::us-east-1://my-repo-name

fatal: unable to find remote helper for 'codecommit'

我之前遇到过远程助手错误,但是针对使用https的情况可以通过ssh密钥解决,但这是我第一次见到这种情况。


1
我在使用Sourcetree中的git命令时遇到了相同的问题。 - Mattia
2个回答

10

我找到了解决办法。在安装git-remote-codecommit时,你需要使用版本号为3或以上的Python。

pip install git-remote-codecommit

由于某些原因,在安装 Python 2.7 时,它无法正确安装。

 git clone codecommit::us-east-1://my-repo-name
Cloning into 'my-repo-name'...
remote: Counting objects: 171562, done.
remote: processing
Receiving objects:  98% (118068/171562), 56.20 MiB | 3.09 MiB/s

之后它已经完成并正常工作。


3
我在 macOS 上使用 pip3 ... 进行了安装。我已经安装了 Python 3,名称为 python3。我仍然遇到了什么问题? - meaning-matters

9

我在macOS和venv上遇到了同样的问题,使用纯净的Python 3解决了它。

python3 -m venv ~/Documents/venv
source ~/Documents/venv/bin/activate

激活 venv 后,安装 git-remote-codecommit 并克隆您的代码库。

pip install git-remote-codecommit
git clone codecommit::us-east-1://my-repo-name

太棒了@KaterynaB。你创建虚拟环境的解决方案也解决了我的问题。 - youth4ever
谢谢伙计,你解决了我百万美元的问题 :) - Flash

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接