warning: templates not found /usr/local/git/share/git-core/templates

简介: 今天在 Mac 上用 SourceTree 克隆 svn 的时候, 出现了 warning: templates not found /usr/local/Git/share/git-core/templates 警告,导致克隆失败.

今天在 Mac 上用 SourceTree 克隆 svn 的时候, 出现了 warning: templates not found /usr/local/Git/share/git-core/templates 警告,导致克隆失败. 怎么办呢.

在终端输入 

open‍ /usr/local/

在打开的目录中可以看到:

  • 如果没有 git 目录

 

打开下面的地址,下载 git-osx 并安装,

http://git-scm.com/download/mac

  • 如果有 git 目录

 

并且相应的 share,git-core,templates 目录都有,,说明是权限的问题.

在终端输入:

sudo chmod -R 755 /usr/local/git/share/git-core/templates

 注意 sudo 创建目录需要输入当前 Mac 用户的密码

  •  最后重新 clone 项目

目录
相关文章
|
网络协议 Linux 网络安全
weavescope curl -L git.io/scope -o /usr/local/xx failed to connect to 2001: Network is unreachable
weavescope curl -L git.io/scope -o /usr/local/xx failed to connect to 2001: Network is unreachable
291 0
|
IDE Shell 网络安全
Visual Studio 2022 git error Unable to negotiate with xx.xxx.xxxx port 22: no matching host key type found. Their offer: ssh-rsa
Visual Studio 2022 git error Unable to negotiate with xx.xxx.xxxx port 22: no matching host key type found. Their offer: ssh-rsa
1087 0
Visual Studio 2022 git error Unable to negotiate with xx.xxx.xxxx port 22: no matching host key type found. Their offer: ssh-rsa
|
8月前
|
Shell Linux 网络安全
宝塔服务器面板部署安装git通过第三方应用安装收费怎么办—bash: git: command not found解决方案-优雅草卓伊凡
宝塔服务器面板部署安装git通过第三方应用安装收费怎么办—bash: git: command not found解决方案-优雅草卓伊凡
1381 3
宝塔服务器面板部署安装git通过第三方应用安装收费怎么办—bash: git: command not found解决方案-优雅草卓伊凡
|
开发工具 git
project is registered as a Git root, but no Git repositories were found there
报错如下 我一开始想把项目推到git,但是发现右键没有git选项。于是我去搜为什么右键没git选项。给出的答案就是在版本控制中添加。 上图这个我添加的本身就是一个git项目,所以没有出现问题,但是如果本身项目还没有关联远程仓库的话,这样搞是会出现问题。
1256 0
project is registered as a Git root, but no Git repositories were found there
|
IDE 网络安全 开发工具
【Azure App Service】Local Git App Service的仓库代码遇见卡住不Clone代码的问题
【Azure App Service】Local Git App Service的仓库代码遇见卡住不Clone代码的问题
258 1
【Azure App Service】Local Git App Service的仓库代码遇见卡住不Clone代码的问题
|
开发工具 git 索引
warning: You ran ‘git add’ with neither ‘-A (—all)’ or ‘—ignore-removal’,报错如何解决 git报错 ‘git add —ignore-removal <pathspec>优雅草卓伊凡
warning: You ran ‘git add’ with neither ‘-A (—all)’ or ‘—ignore-removal’,报错如何解决 git报错 ‘git add —ignore-removal <pathspec>优雅草卓伊凡
310 21
warning: You ran ‘git add’ with neither ‘-A (—all)’ or ‘—ignore-removal’,报错如何解决 git报错 ‘git add —ignore-removal <pathspec>优雅草卓伊凡
|
存储 开发工具 数据安全/隐私保护
git报错The project you were looking for could not be found 解决方式
git报错The project you were looking for could not be found 解决方式
4413 1
|
开发工具 git Windows
【Git】warning: LF will be replaced by CRLF in .gitignore解决方案
warning: LF will be replaced by CRLF in .gitignore解决方案
|
网络安全 开发工具 git
使用git克隆仓库报错:Warning: Permanently added‘github.com’ to the .....(ssh )
所以,你可以安全地忽略这个警告,它不会影响到你使用git克隆仓库。如果你已经成功克隆了仓库,那么一切都在正常工作。如果你在克隆过程中遇到其他问题,那可能需要查看具体的错误信息来解决。
953 0
|
开发工具 git
git push xxx not found问题解决
git push xxx not found问题解决
270 0