Home >Backend Development >PHP Tutorial >After using git revert change by this commit using Little Turtle, all my commits were cleared. How can I restore them? ? ...

After using git revert change by this commit using Little Turtle, all my commits were cleared. How can I restore them? ? ...

WBOY
WBOYOriginal
2016-07-06 13:52:492882browse

I originally wanted to revert to a certain commit, so I used this, but it cleared all my previous commits. Can I find the restore in the local repository now?

Reply content:

I originally wanted to revert to a certain commit, so I used this, but it cleared all my previous commits. Can I find the restore in the local repository now?

If you are operating on the remote and central libraries and the local ones are not synchronized, you need to manually copy the modified files out, and then copy them in after synchronization. If synchronization has occurred, it should be irreversible.

The little turtle has not been used much. Can't you restore it with the command? First, use git log to obtain the encrypted node of commit, and then execute git reset c34b7.. to return to the version you want to restore. Hope it helps you

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn