diff --git a/Command/Sync.hs b/Command/Sync.hs index 61ac3802a4..50e709a2dc 100644 --- a/Command/Sync.hs +++ b/Command/Sync.hs @@ -223,11 +223,16 @@ resolveMerge = do top <- fromRepo Git.repoPath (fs, cleanup) <- inRepo (LsFiles.unmerged [top]) merged <- all id <$> mapM resolveMerge' fs + void $ liftIO cleanup + + (deleted, cleanup2) <- inRepo (LsFiles.deleted [top]) + Annex.Queue.addCommand "rm" [Params "--quiet -f --"] deleted + void $ liftIO cleanup2 + when merged $ do Annex.Queue.flush void $ inRepo $ Git.Command.runBool "commit" [Param "-m", Param "git-annex automatic merge conflict fix"] - void $ liftIO cleanup return merged resolveMerge' :: LsFiles.Unmerged -> Annex Bool diff --git a/debian/changelog b/debian/changelog index b1a6146001..f71a5ab635 100644 --- a/debian/changelog +++ b/debian/changelog @@ -13,6 +13,7 @@ git-annex (3.20130115) UNRELEASED; urgency=low * bugfix: Union merges involving two or more repositories could sometimes result in data from one repository getting lost. This could result in the location log data becoming wrong, and fsck being needed to fix it. + * sync: Automatic merge conflict resolution now stages deleted files. * Depend on git 1.7.7.6 for --no-edit. Closes: #698399 -- Joey Hess Mon, 14 Jan 2013 18:35:01 -0400