diff options
author | Joey Hess <joey@kitenet.net> | 2014-03-04 17:45:11 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2014-03-04 19:35:55 -0400 |
commit | 34eb9b2fdc036e1dab4008751e88b312315928d1 (patch) | |
tree | 16ac8a3091a86f49f8c43b1486032f571a3d183e /Assistant/Threads/Merger.hs | |
parent | a59665ca42c4215f0f1a66f0bbcc9618fa0e53e7 (diff) |
sync: Automatically resolve merge conflict between and annexed file and a regular git file.
This is a new feature, it was not handled before, since it's a bit of an
edge case. However, it can be handled exactly the same as a file/dir
conflict, just leave the non-annexed item alone.
While implementing this, the core resolveMerge' function got a lot simpler
and clearer. Note especially that where before there was an asymetric call to
stagefromdirectmergedir, now graftin is called symmetrically in both cases.
And, in order to add that `graftin us`, the current branch needed to be
known (if there is no current branch, there cannot be a merge conflict).
This led to some cleanups of how autoMergeFrom behaved when there is no
current branch.
This commit was sponsored by Philippe Gauthier.
Diffstat (limited to 'Assistant/Threads/Merger.hs')
-rw-r--r-- | Assistant/Threads/Merger.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Assistant/Threads/Merger.hs b/Assistant/Threads/Merger.hs index 74f67aab7..12489b590 100644 --- a/Assistant/Threads/Merger.hs +++ b/Assistant/Threads/Merger.hs @@ -83,7 +83,7 @@ onChange file [ "merging", Git.fromRef changedbranch , "into", Git.fromRef current ] - void $ liftAnnex $ autoMergeFrom changedbranch + void $ liftAnnex $ autoMergeFrom changedbranch (Just current) mergecurrent _ = noop handleDesynced = case fromTaggedBranch changedbranch of |