所以我第一次尝试使用 git filter-repo 。
我已经安装了Python 3.9。
我尝试运行:git filter-repo --strip-blobs-bigger-than 100M
每次失败时:
- git 重击:
git: 'filter-repo' is not a git command.
- 电源外壳:
Python was not found;
- CMD:
Python was not found;
请问我缺少什么有什么建议吗?
仔细检查安装过程newren/git-filter-repo/INSTALL https://github.com/newren/git-filter-repo/blob/e9e0308df1e9e792598b8e41d0086d7a785e9cc5/INSTALL.md
您必须首先(在常规 CMD 中)确保git-filter-repo
在你的%PATH%
.
如果你通过安装它pip
,例如,它应该,因为Python 文件夹应在 Python3 安装时添加到您的 PATH 中 https://stackoverflow.com/a/54934172/6309.
一旦那%PATH%
是正确的(你会看到git-filter-repo
中),那么git
会认出filter-repo
命令。
正如评论的 https://stackoverflow.com/questions/65626875/git-filter-repo-python-was-not-found-but-its-installed/65627307#comment118241569_65627307,现在有一个git-filter-repo自制配方 https://formulae.brew.sh/formula/git-filter-repo,它在 Mac 上提供了更简单的安装过程。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)