summaryrefslogtreecommitdiff
path: root/Assistant
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-07-26 16:53:50 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-07-26 16:54:20 -0400
commit29436c57435a44dff91e3408f535d44ffe99f577 (patch)
treee7a8eda0848c4c942846136e085fcb88ae0a9c1e /Assistant
parent8a5226ec12a0851abf2c86222ed5446f45657768 (diff)
assistant: Fix NetWatcher to not sync with remotes that have remote.<name>.annex-sync set to false.
This affected both the hourly NetWatcherFallback thread and the syncing when network connection is detected. It was a reversion of sorts, introduced in 8655ea7f8e853b7de4defbca2655b741362ecd21, when annex-ignore was changed to not control git syncing. I forgot to make it check annex-sync at that point.
Diffstat (limited to 'Assistant')
-rw-r--r--Assistant/Threads/NetWatcher.hs8
1 files changed, 4 insertions, 4 deletions
diff --git a/Assistant/Threads/NetWatcher.hs b/Assistant/Threads/NetWatcher.hs
index 6ac7203b0..5974de11d 100644
--- a/Assistant/Threads/NetWatcher.hs
+++ b/Assistant/Threads/NetWatcher.hs
@@ -13,8 +13,8 @@ module Assistant.Threads.NetWatcher where
import Assistant.Common
import Assistant.Sync
import Utility.ThreadScheduler
-import Remote.List
import qualified Types.Remote as Remote
+import Assistant.DaemonStatus
#if WITH_DBUS
import Utility.DBus
@@ -125,7 +125,7 @@ listenWicdConnections client callback =
handleConnection :: Assistant ()
handleConnection = reconnectRemotes True =<< networkRemotes
-{- Finds network remotes. -}
+{- Network remotes to sync with. -}
networkRemotes :: Assistant [Remote]
-networkRemotes = liftAnnex $
- filter (isNothing . Remote.localpath) <$> remoteList
+networkRemotes = filter (isNothing . Remote.localpath) . syncRemotes
+ <$> getDaemonStatus