sourceTree 更新svn提示can't locate SVN/Core.pm

Posted 淘^*(- -)*^

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sourceTree 更新svn提示can't locate SVN/Core.pm相关的知识,希望对你有一定的参考价值。

装了sourceTree一直没有怎么用,今天试着用用,居然报错 can‘t locate SVN/Core.pm

详细报错如下:

Cant locate SVN/Core.pm in @INC (you may need to install the SVN::Core module) (@INC contains: 
/usr/local/git/lib/perl5/site_perl /Applications/SourceTree.app/Contents/Resources/git_local/lib/perl5/site_perl /Library/Perl/5.18/darwin-thread-multi-2level /Library/Perl/5.18 /Network/Library/Perl/5.18/darwin-thread-multi-2level /Network/Library/Perl/5.18 /Library/Perl/Updates/5.18.2 /System/Library/Perl/5.18/darwin-thread-multi-2level /System/Library/Perl/5.18 /System/Library/Perl/Extras/5.18/darwin-thread-multi-2level /System/Library/Perl/Extras/5.18 .) at /Applications/SourceTree.app/Contents/Resources/git_local/lib/perl5/site_perl/Git/SVN/Editor.pm line 5.
BEGIN failed--compilation aborted at /Applications/SourceTree.app/Contents/Resources/git_local/lib/perl5/site_perl/Git/SVN/Editor.pm line 5.
Compilation failed in require at /Applications/SourceTree.app/Contents/Resources/git_local/libexec/git-core/git-svn line 81.
BEGIN failed--compilation aborted at /Applications/SourceTree.app/Contents/Resources/git_local/libexec/git-core/git-svn line 81.
Completed with errors, see above

网上找到解决办法

 sudo ln -s /Applications/Xcode.app/Contents/Developer/Library/Perl/5.18/darwin-thread-multi-2level/SVN /System/Library/Perl/Extras/5.18/SVN
 sudo ln -s /Applications/Xcode.app/Contents/Developer/Library/Perl/5.18/darwin-thread-multi-2level/auto/SVN/ /System/Library/Perl/Extras/5.18/auto/SVN

但是运行发现提示错误

ln: /System/Library/Perl/Extras/5.18/SVN: Operation not permitted

最后在一个国外的网友分享下找到了解决办法

sudo ln -s /Applications/Xcode.app/Contents/Developer/Library/Perl/5.18/darwin-thread-multi-2level/SVN/ /Library/Perl/5.18/SVN
sudo mkdir /Library/Perl/5.18/auto
sudo ln -s /Applications/Xcode.app/Contents/Developer/Library/Perl/5.18/darwin-thread-multi-2level/auto/SVN/ /Library/Perl/5.18/auto/SVN

完美运行了

以上是关于sourceTree 更新svn提示can't locate SVN/Core.pm的主要内容,如果未能解决你的问题,请参考以下文章

svn更新出现“svn: Can't read from connection: 您的主机中的软件中止了一个已建”的提示!

svn连接提示can't connect to the host'***':由于目标机积极拒绝,无法连接。

Can't use Subversion command line client:svn

Can't use Subversion command line client: svn

svn服务器配置

Idea中配置svn时报 Can't use Subversion command line client: svn.Errors found while svn working copies