OC系列教程之gitError:unable to access

2018-10-25  本文已影响0人  wenjunyeah

xcode中git进行commit时提示“warning: unable to access '.config/git/attributes': Permission denied”这种错误~

解决方案如下:

打开终端,依次输入如下命令:

cd  ~/


ls -al


查看弹出的文件的归属,若是".config权限归属于root",如下图所示,


若config如上图所示,则终端接着输入“sudo chown my_user_name .config”,注意替换my_user_name;

之后git 中提交commit命令代码正确上传

参考链接:

https://stackoverflow.com/questions/27150926/unable-to-access-git-attributes

上一篇 下一篇

猜你喜欢

热点阅读