gpt4 book ai didi

git初始化: fatal: could not set 'core.filemode' to 'false'

转载 作者:行者123 更新时间:2023-12-02 20:51:53 75 4
gpt4 key购买 nike

使用 Team City 从 Git 存储库中 checkout 。 (Gitlabs,如果重要的话)

从空构建目录开始。收到此错误:

致命:无法将“core.filemode”设置为“false”

(在 Windows 计算机上运行,​​如果重要的话)

为了以防万一,运行 Team City 的用户已更改为管理员。

此命令退出时,.Git 目录不是有效的存储库。

删除整个“工作”目录没有帮助。

它随机地来来去去......

还有这个:git config --global --replace-all core.fileMode false

没有做任何有用的事情 - 无论是否带有 --replace-all,并以管理员或其他用户身份运行(如果将“false”更改为“true”,如果将其更改为“falseCD”,则会出现相同的错误它将错误更改为无效值 - 很明显,它正在更改它。

有人有什么想法吗?

最佳答案

就我而言,使用“sudo”对我有用。例如:

asif@asif-vm:/mnt/prog/protobuf_tut$ git clone https://github.com/protocolbuffers/protobuf.git
Cloning into 'protobuf'...
error: chmod on /mnt/prog/protobuf_tut/protobuf/.git/config.lock failed: Operation not permitted
fatal: could not set 'core.filemode' to 'false'

执行“sudo”后,我可以让它工作:

asif@asif-vm:/mnt/prog/protobuf_tut$ sudo git clone https://github.com/protocolbuffers/protobuf.git
Cloning into 'protobuf'...
remote: Enumerating objects: 5, done.
remote: Counting objects: 100% (5/5), done.
remote: Compressing objects: 100% (5/5), done.
remote: Total 66782 (delta 0), reused 0 (delta 0), pack-reused 66777
Receiving objects: 100% (66782/66782), 55.83 MiB | 2.04 MiB/s, done.
Resolving deltas: 100% (45472/45472), done.
Checking out files: 100% (2221/2221), done.

关于git初始化: fatal: could not set 'core.filemode' to 'false' ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50108363/

75 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com