aboutsummaryrefslogtreecommitdiff
path: root/Assistant/Sync.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2014-06-16 11:32:13 -0400
committerGravatar Joey Hess <joey@kitenet.net>2014-06-16 11:32:13 -0400
commit5b1ea5fe5af25cd88c45a87d3bbe36ea7eed7145 (patch)
treeecbba4af5cd2f7383bcd07f373c9fa99ca847cd8 /Assistant/Sync.hs
parentf9413b779ee821092af306f30fa9b6e668617432 (diff)
assistant: Fix one-way assistant->assistant sync in direct mode.
When in direct mode, update the master branch after committing to the annex/direct/master branch. Also, update the synced/master branch. This fixes a topology A->B where both A and B are in direct mode and running the assistant, and a change is made to B. Before this fix, A pulled the changes from B, but since they were only on the annex/direct/master branch, it did not merge them. Note that I considered making the assistant merge the remotes/B/annex/direct/master, but decided to keep it simple and only merge the sync branches as before.
Diffstat (limited to 'Assistant/Sync.hs')
-rw-r--r--Assistant/Sync.hs3
1 files changed, 1 insertions, 2 deletions
diff --git a/Assistant/Sync.hs b/Assistant/Sync.hs
index c748f6e1a..4bc63241c 100644
--- a/Assistant/Sync.hs
+++ b/Assistant/Sync.hs
@@ -96,7 +96,7 @@ reconnectRemotes notifypushes rs = void $ do
=<< fromMaybe [] . M.lookup (Remote.uuid r) . connectRemoteNotifiers
<$> getDaemonStatus
-{- Updates the local sync branch, then pushes it to all remotes, in
+{- Pushes the local sync branch to all remotes, in
- parallel, along with the git-annex branch. This is the same
- as "git annex sync", except in parallel, and will co-exist with use of
- "git annex sync".
@@ -148,7 +148,6 @@ pushToRemotes' now notifypushes remotes = do
go _ _ _ _ [] = return [] -- no remotes, so nothing to do
go shouldretry (Just branch) g u rs = do
debug ["pushing to", show rs]
- liftIO $ Command.Sync.updateBranch (Command.Sync.syncBranch branch) g
(succeeded, failed) <- liftIO $ inParallel (push g branch) rs
updatemap succeeded []
if null failed