Created
May 26, 2011 08:26
-
-
Save bonyiii/992770 to your computer and use it in GitHub Desktop.
how to know when a file was deleted from git
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # source: http://stackoverflow.com/questions/953481/restore-a-deleted-file-in-a-git-repo | |
| Use git log --diff-filter=D --summary to get all the commits which have deleted files and the files deleted; | |
| Use git revert $commit to revert that particular commit. | |
| Using --summary instead of --name-only displays the actions taken. | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment