我在路径/home/bhishan/Copy/try下创建了一个名为"try"的文件夹,然后在该文件夹中输入了一些命令:
我的命令如下:
curl -s -O \
http://github-media-downloads.s3.amazonaws.com/osx/git-credential-osxkeychain
chmod u+x git-credential-osxkeychain
sudo mv git-credential-osxkeychain `dirname \`which git\``
git config --global credential.helper osxkeychain
git init
git remote add origin https:
git remote add origin https:
git push origin master
==============================
它运行得很好,但是当我尝试删除“try”文件夹时,我无法删除该文件夹。 我也无法执行以下命令:
git init
在try文件夹中(我有一个.git文件夹)
=====================================================
我的命令行和错误报告如下:
bhishan@bhishan-HP-Pavilion-dv6-Notebook-PC:~/Copy/try$ git init
error: could not lock config file /home/bhishan/Copy/try/.git/config: Permission denied
现在,我的问题是如何删除名为“try”的文件夹?
git config --system --unset credential.helper
,但它显示权限被拒绝,所以我检查了文件C:\Program Files\Git\mingw64\etc\gitconfig
,发现该文件的所有者是管理员,因此我关闭了PowerShell,并再次以管理员身份运行,这次git config --system --unset credential.helper
成功执行了。 - agm1984