我正在使用 Atlassian 的 SourceTree 在 Mac OS 上使用 git,并选择 AWS CodeCommit 作为远程托管服务器。
按照这些 steps对于 AWS 和我的本地存储库之间的 HTTPS 连接,
这是我的 git config --global --edit
的样子:
然后尝试将创建的空存储库从 AWS 克隆到 SourceTree:
然后我打印出错误:
abort: HTTP Error 403: Forbidden aws --profile default codecommit credential-helper $@ get: aws: command not found fatal: unable to access 'https://git-codecommit.us-east-1.amazonaws.com/v1/repos/my-git-repo/': The requested URL returned error: 403
更新
尝试了@Steffen Opel 提供的答案,得到的答案更像:
我错过了什么吗?
最佳答案
我刚在这里找到这个答案 ( https://geekprotem.com/2015/07/10/aws-codecommit-with-sourcetree/ )
在亚马逊网站上完成 AWS CLI 的设置步骤后,最后一步是在 SourceTree 中编辑我存储库的配置文件以包括以下内容:
[credential]
helper = /usr/local/bin/aws codecommit credential-helper $@
UseHttpPath = true
关于git - 无法将 SourceTree 连接到 AWS CodeCommit,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33009036/