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

夙愿已清 提交于 2019-12-20 11:34:08

问题


I get this error warning: templates not found /usr/local/git/share/git-core/templates when I cloning repo in local repository this link, this link, and this link I tried this method and I just waiting more than 20 minutes but repo doesn't clone. I use source-tree and OS X El Capitan. How can I fix it?


回答1:


Create a templates folder.

In your case, it should be: mkdir /usr/local/git/share/git-core/templates




回答2:


I was also getting same error warning: templates not found /usr/local/git/share/git-core/templates when I cloning repo in local repository then i found solution which solved my issue. I Added the [init] section to .gitconfig in home directory, so that it looked at SourceTree's git templates directory when cloning a repo:

[init] templatedir = /Applications/SourceTree.app/Contents/Resources/git_local/share/git-core/templates

Hope it will help you!.




回答3:


In case of Source tree on macOS Steps:

Source tree Menu
Preferences
Git
Click on System Git under Embedded Git Version 2.2.1
Reset to embedded Git
Restart source tree



回答4:


Similar to Rohit's answer, I went into SourceTree's Tools->Options->Git and selected "Update Embedded Git". After the latest Embedded Git version was installed, the warning stopped occurring.




回答5:


Make sure you have git installed in your system. Check by typing git on command prompt/terminal.



来源:https://stackoverflow.com/questions/34877649/warning-templates-not-found-usr-local-git-share-git-core-templates

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!