how to allow the access of git/config in mac os?

核能气质少年 提交于 2020-06-16 17:01:39

问题


I having this problem because when I run flutter doctor it says . btw I'm using mac os

Failed to find the latest git commit date: VersionCheckError: Command exited
with code 128: git -c log.showSignature=false log -n 1 --pretty=format:%ad
--date=iso
Standard out: 
Standard error: warning: unable to access '.git/config': Permission denied
fatal: unable to access '.git/config': Permission denied

I ask this question in this link but one person said that I should check the user and I see that I'm the user registered there. I think I need to go to git folder and allow permission in properties but I don't know to get into git folder in mac os


回答1:


The .config folder is supposed to be owned by the user. It appears that the ownership got changed to system by mistake on your machine.

With following command, you can restore the default permission on your MacOS:

sudo chown -R <username> .config

(Substitute <username> with your username. You can find your username as follows: whoami)

When prompted for a password, enter your login password.



来源:https://stackoverflow.com/questions/61811373/how-to-allow-the-access-of-git-config-in-mac-os

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