gpt4 book ai didi

Git - 断开的链接、丢失和悬挂的树

转载 作者:行者123 更新时间:2023-12-02 15:53:43 25 4
gpt4 key购买 nike

我很高兴使用 Git - 几天前做了一些提交,这些提交反射(reflect)在远程存储库中。昨晚我打开 Smartgit Hg,它告诉我缺少树木。我运行了 git fsck --full 并得到了下面相当大的输出。

我是一名 Git 业余爱好者。我使用 GUI 来完成我需要做的事情。我已经尝试阅读这篇文章( https://git.wiki.kernel.org/index.php/GitFaq#How_to_fix_a_broken_repository.3F ),但它并没有多大意义,而且盲目跟随它似乎不起作用。

我做了一个 git ls-tree c957fc03bb53181547142045917211fbc380a8df ,它显示了一个文件列表。我有 3 个开头带有 100644 的文件,因此我进入该目录,运行 git hash-object -w filename ,它输出与 相同的哈希值>ls-tree 向我展示了。

维基页面说现在我已经完成了。除了 git fsck --full 仍然显示该树的相同消息。我感觉我可能在错误的地方运行了这些命令。

我尝试阅读这里的其他 git 帖子,但它们对我来说没有意义。我不会说谎。

git fsck --fullChecking object directories: 100% (256/256), done.Checking objects: 100% (1149/1149), done.broken link from    tree c957fc03bb53181547142045917211fbc380a8df              to    tree e7822f570245310f4b475e043f5fb02fa45c0d9ebroken link from    tree 8005ba4728321473684e670feb9c1ada8783c007              to    tree 4df5de19988a1fd7088da6e8214404cda2069852broken link from    tree 3b1b915c6f306ae4f80a2b61767c4267d48df53d              to    tree 4dc2258f8d36dbeea64b859ab5dff0fadc5bd591broken link from    tree c850459b3bd5899bd0a9eca40d69e49582f44a19              to    tree 912613a23bcb22f211ce0d8ab4fe2a8fddde78b6broken link from  commit 8775851e59bd5072ab98a739cfc00b231be54eab              to    tree 90e5f62642dde43c110b9882c564349074097955broken link from    tree 331b16c460e6f9dd3bae9b0206857fc2c57bacb8              to    tree fdead5b5ff4ae53b54104ab5b7fa2369f0adb4f7broken link from    tree 3ca3d56fd7eabe9efb0d4212615cf85ced8f663f              to    tree 099070c9c54a16ca6b78c384a43c2e45d56eed71broken link from    tree ffe425a5a568e5e515fa5745e8dd0a3f9148ac6a              to    tree 91ec315f9730d3541bba2603f09d69b2b6d5ead0broken link from    tree e38aa29f31a314bf71c40d800ea9d4b9422a09c3              to    tree b9760875bb7b8be0799435625fd686c985860de2broken link from    tree 920755bbb97bcf526bfbd492451182bec66e6d39              to    tree d4dcb141f4ea62228e85f6b35c5b4d2f22a8720ebroken link from    tree 298bbba4562267349db2539e43cd2f12cd4317dd              to    tree b8234d1f9efcc9691f2b35b8e4237dfa08bc140abroken link from  commit f106420cddf314c6efa2e015e348006b82cd6348              to    tree a5b976cb4f82b339f22c74811f47ad31d353764bbroken link from  commit 5968e9e1479fdbba079ab64a6171f98b0f869b41              to    tree 64171c569ea7f74f59dc8f3dcc957220aa09f343broken link from  commit c54b5f446988645caf935382ea7bbc7ec57092f2              to    tree fda728fd6e61790133f15e073335e2e6c43dc31bbroken link from  commit 37a6d43e9645873ab2315e641ef8bf55afc08012              to    tree 90c19ab5f9cb64e40cfcad2e30e1cf98ad586502broken link from    tree 32009a6e84fd8639b411433d13bb707ed25a8992              to    tree 691f8fac71c39b2182acf51f56ac39c4bc4759d5broken link from    tree 41db7d6238919ea58c2c64d9f333c63650e0e95a              to    tree 649a4fc0f5a9d06c67223a36116c7c8aeaa2c6b9broken link from    tree 84f823c8d4032a3fe09ba4d962603fcb975dbf98              to    tree 7bb4a11dd10def2f1f4f9bae4eea02848fb833cbbroken link from  commit 1b85354dd48be428b4d3937da24a9951efa9f451              to    tree 3d437dcff812a0e123d2e4b741dba47ad08a6b9ebroken link from  commit 2cbfbe123e1a61584c519f190015622ae5b5c8c0              to    tree 0013af31f091e2d22b7ff7e63badf305597e63b4broken link from    tree fef036d59eb8944bb494a0eff85325c108fccf34              to    tree 896deb89905c80893512a61d9f8e9fc3760f3a53broken link from    tree f26d568cf61282aa1f04e7828bddf8f9d7cf8ecb              to    tree 3d7994b9dad00c47c64b99e30693c0215b0aa5ebbroken link from    tree bc7d7d62d92c8989d9e398c8cbf036f1e205f855              to    tree ea29c58710d7d3aa7cce589de9b46503d0e9565ebroken link from    tree 447585f3684b9915ba0ce99f41359da197ee8f54              to    tree 0992afc3aa3aa332fe3dc927a5e334f69638a898broken link from  commit 5e622e95cb5336521cbbdb7c03b860bb74eb9f8c              to    tree 7f91438587057ac610e44a5cf3318440e004a9bcbroken link from    tree 32f13f592d0a56d467234b838930039c0438e019              to    tree 9d3328f820a9308bab950ee9e513a200acd6d3f4missing tree 099070c9c54a16ca6b78c384a43c2e45d56eed71dangling tree 5a0069463363b395881958eb8d9aac7ba1b9ddd8dangling tree 932053ef04d4f540d250d5e74332d141b4037009dangling tree c7a04a22febdeb307f38019aff2e4f7645a7ea9fdangling tree cf10f1a8c2bb57520c6e0ad256e9fb344961c13adangling tree 2c51ad373aef4844fc9e6babd878dfae5f5592b3missing tree 7f91438587057ac610e44a5cf3318440e004a9bcmissing tree 90c19ab5f9cb64e40cfcad2e30e1cf98ad586502missing tree 0992afc3aa3aa332fe3dc927a5e334f69638a898dangling blob 24226e3db997d21dc10aa70a9a8aa279aa55fb8amissing tree 4dc2258f8d36dbeea64b859ab5dff0fadc5bd591dangling tree 9c322d15436be34a99fcea442ad97ae40715ac61dangling tree b4d2505972386aba42282232843d4e1b73148be4missing tree e7822f570245310f4b475e043f5fb02fa45c0d9emissing tree 0013af31f091e2d22b7ff7e63badf305597e63b4missing blob 35e3ddbc07214e74d8ad516736ee0e90b0a285c8missing tree 3d437dcff812a0e123d2e4b741dba47ad08a6b9edangling tree 6d637bdae8eff5490df307fce3fd8a1bb2e5ce14dangling tree 79934929fc8423ec1c277ab21d14b7434cde7544missing tree 9d3328f820a9308bab950ee9e513a200acd6d3f4missing tree b8234d1f9efcc9691f2b35b8e4237dfa08bc140adangling tree d1333fd1a2c9fed8bc3cc6f58ae00bf7fbe7c482missing blob 20149c8fb22e309a26f477f0e500e122f6e99e66dangling tree 4054641b41208cc98387806a877855db15a109f9missing tree 7bb4a11dd10def2f1f4f9bae4eea02848fb833cbdangling tree f4948b5302a1fe79ea09c5959e0f3902d022a2b3missing tree 4df5de19988a1fd7088da6e8214404cda2069852missing tree 90e5f62642dde43c110b9882c564349074097955dangling tree 7966c4a2fc16a5559b569f5e200c0f01f0b186dbmissing tree 912613a23bcb22f211ce0d8ab4fe2a8fddde78b6missing commit b976d2df1880cb6c90db5bdf856440904cd22574missing tree b9760875bb7b8be0799435625fd686c985860de2missing commit 35e7e9f65cf5950ae2855afaf764672dd48a8b9bmissing tree 64171c569ea7f74f59dc8f3dcc957220aa09f343missing tree fda728fd6e61790133f15e073335e2e6c43dc31bdangling tree 29088a01bfe6bde49cf1176b7ed1171dd8f8e334missing commit e27876491d426b8d9f3932eb2ee494145f8776b5dangling tree e3c8535db10a99db65fbd5c2e58e2c3b59159d24missing tree 3d7994b9dad00c47c64b99e30693c0215b0aa5ebdangling tree 6129fef595c71128c0dc24ebd4248ef231cfe90dmissing tree a5b976cb4f82b339f22c74811f47ad31d353764bmissing tree ea29c58710d7d3aa7cce589de9b46503d0e9565emissing tree 649a4fc0f5a9d06c67223a36116c7c8aeaa2c6b9missing commit 8f2ad8d3aaccfcfad8cd7c30ea938008378591fdmissing blob ea1ae4f5cd2a6ec1e9982108cdbce7de5858d0d9dangling tree f69a44eac9426e3fcfb4eb1545c966beb72b37b0missing tree fdead5b5ff4ae53b54104ab5b7fa2369f0adb4f7missing commit a69b6f1a1b224b2ba846590d6ddd65ca0079a1bbmissing blob 453c02a0bbce4748a3e3d3da4c29498cbf4b01d0missing tree 91ec315f9730d3541bba2603f09d69b2b6d5ead0missing tree d4dcb141f4ea62228e85f6b35c5b4d2f22a8720emissing tree 896deb89905c80893512a61d9f8e9fc3760f3a53dangling tree deeec6312c058722ffcf1b5cf14d997c14890eb1dangling blob 0b7fc81faf339d77c2146f406a9f90c4431da4e2missing tree 691f8fac71c39b2182acf51f56ac39c4bc4759d5missing blob 7fef3c0e58d6c2825703576b3ecb148040e2b0cfdangling tree 95cf9c35987a0b715d4f736d2cf9dacf82c958aedangling tree ce4feefca69bd3fbc82205c4c3f1c116f73b623c

最佳答案

对我来说,一个简单的 git gc 就完成了这项工作...这给了我一些rm:无法取消链接...权限被拒绝消息。但最终,它似乎对我的情况起作用了。

但可能取决于存储库损坏的具体程度。

关于Git - 断开的链接、丢失和悬挂的树,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16955523/

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