0

我最近有一个外部的迅雷 sata 适配器,我在使用 git 时遇到了一些问题。由于我是一名开发人员,这对我来说是一个巨大的巨大问题!而且由于迅雷技术太新了,这些问题没有得到很好的记录。

当我第一次 git clone 到我的迅雷上时,一切正常。但是如果我重新启动我的计算机,或者换掉硬盘,git 就不能再识别 repo。

git status

致命:不是 git 存储库(或任何父目录):.git

不确定这是否与如何使用 Thunderbolt 安装驱动器直接相关,或者这是否只是人们在外部驱动器上使用 git repo 时遇到的问题。但是这个问题已经花费了我数小时的生产力。想象一下,如果您git clone每次想解决问题时都必须这样做。想象一下,如果您不知道您是否正在丢失重要的更改,甚至不能git status

另外,我已经设置了 GIT_DISCOVERY_ACROSS_FILESYSTEM 标志/etc/zshenv

export GIT_DISCOVERY_ACROSS_FILESYSTEM=1

到目前为止,我已经尝试过 git 克隆和比较 .git 文件夹,但我不知道原始文件夹是否包含任何差异。我想象重新挂载文件系统时某些东西的标签不同,但我不知道是什么。这是这样一个 diff 的输出(ccnx3 repo 被 git 识别):

diff -rq CCNx-Federated-Wiki-Prototype/.git ccnx3/.git

Only in CCNx-Federated-Wiki-Prototype/.git: ._sourcetreeconfig
Only in CCNx-Federated-Wiki-Prototype/.git: COMMIT_EDITMSG
Only in CCNx-Federated-Wiki-Prototype/.git: FETCH_HEAD
Files CCNx-Federated-Wiki-Prototype/.git/HEAD and ccnx3/.git/HEAD differ
Only in CCNx-Federated-Wiki-Prototype/.git: MERGE_RR
Only in CCNx-Federated-Wiki-Prototype/.git: ORIG_HEAD
Files CCNx-Federated-Wiki-Prototype/.git/index and ccnx3/.git/index differ
Files CCNx-Federated-Wiki-Prototype/.git/logs/HEAD and ccnx3/.git/logs/HEAD differ
Only in CCNx-Federated-Wiki-Prototype/.git/logs/refs/heads: dc
Files CCNx-Federated-Wiki-Prototype/.git/logs/refs/heads/master and ccnx3/.git/logs/refs/heads/master differ
Files CCNx-Federated-Wiki-Prototype/.git/logs/refs/remotes/origin/HEAD and ccnx3/.git/logs/refs/remotes/origin/HEAD differ
Only in CCNx-Federated-Wiki-Prototype/.git/logs/refs/remotes/origin: master
Only in CCNx-Federated-Wiki-Prototype/.git/logs/refs: stash
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 00
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 0b
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 21
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 38
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 3a
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 42
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 5c
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 76
Only in CCNx-Federated-Wiki-Prototype/.git/objects: 9d
Only in CCNx-Federated-Wiki-Prototype/.git/objects: b2
Only in CCNx-Federated-Wiki-Prototype/.git/objects: b6
Only in CCNx-Federated-Wiki-Prototype/.git/objects: cc
Only in CCNx-Federated-Wiki-Prototype/.git/objects: d7
Only in CCNx-Federated-Wiki-Prototype/.git/objects: e5
Only in CCNx-Federated-Wiki-Prototype/.git/objects: fd
Only in ccnx3/.git/objects/pack: pack-4f050d825152b9fbe1b2d2c0e2a63d102fca151c.idx
Only in ccnx3/.git/objects/pack: pack-4f050d825152b9fbe1b2d2c0e2a63d102fca151c.pack
Only in CCNx-Federated-Wiki-Prototype/.git/objects/pack: pack-995c1e8dbf16bee47ff923bf210e0331f0242fa1.idx
Only in CCNx-Federated-Wiki-Prototype/.git/objects/pack: pack-995c1e8dbf16bee47ff923bf210e0331f0242fa1.pack
Files CCNx-Federated-Wiki-Prototype/.git/packed-refs and ccnx3/.git/packed-refs differ
Only in CCNx-Federated-Wiki-Prototype/.git/refs/heads: dc
Only in CCNx-Federated-Wiki-Prototype/.git/refs/remotes/origin: master
Only in CCNx-Federated-Wiki-Prototype/.git/refs: stash
Only in CCNx-Federated-Wiki-Prototype/.git: rr-cache
Only in CCNx-Federated-Wiki-Prototype/.git: sourcetreeconfig
4

0 回答 0