From 28324296aa141d59d633398d41d602ab3d255729 Mon Sep 17 00:00:00 2001 From: "http://joeyh.name/" Date: Wed, 12 Nov 2014 21:00:41 +0000 Subject: [PATCH] Added a comment --- ...t_2_98c01a756c5f2dda28cffa5dd1dea385._comment | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 doc/forum/Recovering_deleted_file_in_direct_mode/comment_2_98c01a756c5f2dda28cffa5dd1dea385._comment diff --git a/doc/forum/Recovering_deleted_file_in_direct_mode/comment_2_98c01a756c5f2dda28cffa5dd1dea385._comment b/doc/forum/Recovering_deleted_file_in_direct_mode/comment_2_98c01a756c5f2dda28cffa5dd1dea385._comment new file mode 100644 index 0000000000..007160ab25 --- /dev/null +++ b/doc/forum/Recovering_deleted_file_in_direct_mode/comment_2_98c01a756c5f2dda28cffa5dd1dea385._comment @@ -0,0 +1,16 @@ +[[!comment format=mdwn + username="http://joeyh.name/" + subject="comment 2" + date="2014-11-12T21:00:41Z" + content=""" +A new `git annex proxy` command was just added that allows safely running commands like `git revert` in a direct mode repsitory. + +So, you might do: + + rm myfile # oops! + git annex sync + git annex proxy -- git revert HEAD + git annex get myfile + +The sync is needed to commit the deletion, and then that commit gets reverted. Finally, you can use git-annex get to download the file from some other repository that still has a copy. (Assuming you didn't delete the last copy.) +"""]]