Recover a git repo after accidentally deleting some hash files located under .git/objects.

6 messages, 3 authors, 2021-02-01 · open the first message on its own page

Recover a git repo after accidentally deleting some hash files located under .git/objects.

From: Hongyi Zhao <hidden>
Date: 2021-02-01 02:15:43

Hi,

I accidentally deleted some hash files located under the project's
.git/objects subdirectory. In this case, can I resume the project?

Regards
-- 
Assoc. Prof. Hongyi Zhao [off-list ref]
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China

Re: Recover a git repo after accidentally deleting some hash files located under .git/objects.

From: 胡哲宁 <hidden>
Date: 2021-02-01 06:06:08

Hi,I don't think so unless you have the commit
 in github or gitlab which include this file,
maybe you can use git pull to get it.
By the way ,you can ask questions in irc chatroom #git or #git-devel.
There will be a good place to get help.
--
adlternative

Hongyi Zhao [off-list ref] 于2021年2月1日周一 上午10:16写道:
Hi,

I accidentally deleted some hash files located under the project's
.git/objects subdirectory. In this case, can I resume the project?

Regards
--
Assoc. Prof. Hongyi Zhao [off-list ref]
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China

Re: Recover a git repo after accidentally deleting some hash files located under .git/objects.

From: Hongyi Zhao <hidden>
Date: 2021-02-01 07:05:41

On Mon, Feb 1, 2021 at 1:54 PM 胡哲宁 [off-list ref] wrote:
Hi,I don't think so unless you have the commit
 in github or gitlab which include this file,
maybe you can use git pull to get it.
By the way ,you can ask questions in irc chatroom #git or #git-devel.
There will be a good place to get help.
Thanks a lot for your suggestion. BTW, what's IRC client and server
used by you normally?
--
adlternative

Hongyi Zhao [off-list ref] 于2021年2月1日周一 上午10:16写道:
quoted
Hi,

I accidentally deleted some hash files located under the project's
.git/objects subdirectory. In this case, can I resume the project?

Regards
--
Assoc. Prof. Hongyi Zhao [off-list ref]
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China


-- 
Assoc. Prof. Hongyi Zhao [off-list ref]
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China

Re: Recover a git repo after accidentally deleting some hash files located under .git/objects.

From: 胡哲宁 <hidden>
Date: 2021-02-01 07:30:19

oh,I am using Konversation,it's a good irc client.
You can also use weechat in terminal.
And http://quhno.internetstrahlen.de/Vivaldi/freenode-help.html
may have many helpful usages for you to learn irc command.

说句中文活跃下气氛 :)

Hongyi Zhao [off-list ref] 于2021年2月1日周一 下午3:01写道:
On Mon, Feb 1, 2021 at 1:54 PM 胡哲宁 [off-list ref] wrote:
quoted
Hi,I don't think so unless you have the commit
 in github or gitlab which include this file,
maybe you can use git pull to get it.
By the way ,you can ask questions in irc chatroom #git or #git-devel.
There will be a good place to get help.
Thanks a lot for your suggestion. BTW, what's IRC client and server
used by you normally?
quoted
--
adlternative

Hongyi Zhao [off-list ref] 于2021年2月1日周一 上午10:16写道:
quoted
Hi,

I accidentally deleted some hash files located under the project's
.git/objects subdirectory. In this case, can I resume the project?

Regards
--
Assoc. Prof. Hongyi Zhao [off-list ref]
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China


--
Assoc. Prof. Hongyi Zhao [off-list ref]
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China

Re: Recover a git repo after accidentally deleting some hash files located under .git/objects.

From: Michal Suchánek <hidden>
Date: 2021-02-01 09:53:01

On Mon, Feb 01, 2021 at 01:56:55PM +0800, 胡哲宁 wrote:
Hi,I don't think so unless you have the commit
 in github or gitlab which include this file,
maybe you can use git pull to get it.
How?

fetch/pull complains that the hashes are missing.

In this situation I just delete the repository but it is kind of stupid
that git rells you exactly what is wrong but won't fix it.

Thanks

Michal

Re: Recover a git repo after accidentally deleting some hash files located under .git/objects.

From: 胡哲宁 <hidden>
Date: 2021-02-01 10:02:02

Michal Suchánek [off-list ref] 于2021年2月1日周一 下午5:51写道:
On Mon, Feb 01, 2021 at 01:56:55PM +0800, 胡哲宁 wrote:
quoted
Hi,I don't think so unless you have the commit
 in github or gitlab which include this file,
maybe you can use git pull to get it.
How?

fetch/pull complains that the hashes are missing.

In this situation I just delete the repository but it is kind of stupid
that git rells you exactly what is wrong but won't fix it.
Is it so? I thought it would work normally, and I hope git can fix it one day.
Thanks.

ZheNing Hu
Thanks

Michal
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help