From c77ac11acc10efc23acfa3d81e1deaac11cb724f Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Tue, 1 Feb 2011 21:26:19 -0400 Subject: unannex: Commit staged changes at end to avoid some confusing behavior with the pre-commit hook, which would see some types of commits after an unannex as checking in of an unlocked file. --- Command/Unannex.hs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Command/Unannex.hs') diff --git a/Command/Unannex.hs b/Command/Unannex.hs index 413443969..3810cca1c 100644 --- a/Command/Unannex.hs +++ b/Command/Unannex.hs @@ -55,5 +55,10 @@ cleanup file key = do fromAnnex key file logStatus key ValueMissing - + + -- Commit staged changes at end to avoid confusing the + -- pre-commit hook if this file is later added back to + -- git as a normal, non-annexed file. + Annex.queue "commit" ["-m", "content removed from git annex"] "--" + return True -- cgit v1.2.3