請幫助我已經為此作業了一段時間!!!!
所以我正在做一個專案,我開始玩githubDesktop(我能說什么我真的很好奇)并最終洗掉了一個存盤庫。一開始我沒有意識到,但是當我打開專案檔案夾時,我的大部分內容檔案不見了,我只能看到幾個月前的最后一次提交。我不知道它是否與分支有關,但它表明我目前處于領先地位。
當我運行 ls 時,它會顯示我洗掉的所有檔案。(錯誤地,不知何故)
PS C:\Users\curti\Desktop\MFLS> ls
Directory: C:\Users\curti\Desktop\MFLS
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 20/03/2022 10:23 .idea
d----- 04/03/2022 15:03 django-csp
d----- 20/03/2022 09:55 media
d----- 20/03/2022 09:56 MFLS
d----- 20/03/2022 09:56 MFLS_main
d----- 20/03/2022 09:56 registration
-a---- 12/03/2022 17:53 180224 db.sqlite3
-a---- 11/01/2022 14:01 682 manage.py
-a---- 15/01/2022 07:56 164 Pipfile
-a---- 15/01/2022 07:56 4819 Pipfile.lock
像這樣,但我試圖找到已完成的提交,但我不能,我也找不到任何至少接近今天的提交,這會有所幫助,但我不能只顯示來自其他專案的舊提交。當我運行, git log --diff-filter=D --summary 我明白了:
PS C:\Users\curti\Desktop\MFLS> git log --diff-filter=D --summary
warning: refname 'HEAD' is ambiguous.
warning: refname 'HEAD' is ambiguous.
commit 828d61868e0601152849bef2575c0b4142d51a0e
Author: Curtis Arissol <[email protected]>
Date: Wed Aug 4 11:44:03 2021 0400
having problem with task or to-do bar but partially completed and working
delete mode 100644 classy/index.js
delete mode 100644 classy/views/index.js
commit 8cf9c230ad49a3712151ff109b978bb3288257cd (checking-old-auth)
Author: Curtis Arissol <[email protected]>
:
...and other old commits.
注意:當我丟失檔案時,我第一次使用 github 桌面我曾嘗試訪問 github.com 并恢復存盤庫(即使我不確定這是問題所在),但我不能。
uj5u.com熱心網友回復:
如果您還沒有運行分支git gc,可能已經在您的.refloggit refloggit branch <deleted-branch-name> <deleted-branch-last-commit-hash>
請告訴我它是否解決了您的問題。
問候。
轉載請註明出處,本文鏈接:https://www.uj5u.com/gongcheng/447214.html
下一篇:使用gitlabci找不到AWS
