summaryrefslogtreecommitdiff
path: root/Assistant
diff options
context:
space:
mode:
Diffstat (limited to 'Assistant')
-rw-r--r--Assistant/DaemonStatus.hs9
-rw-r--r--Assistant/Sync.hs4
-rw-r--r--Assistant/Threads/MountWatcher.hs2
-rw-r--r--Assistant/Threads/NetWatcher.hs2
4 files changed, 10 insertions, 7 deletions
diff --git a/Assistant/DaemonStatus.hs b/Assistant/DaemonStatus.hs
index c966fc93a..f94521117 100644
--- a/Assistant/DaemonStatus.hs
+++ b/Assistant/DaemonStatus.hs
@@ -48,18 +48,19 @@ modifyDaemonStatus a = do
calcSyncRemotes :: Annex (DaemonStatus -> DaemonStatus)
calcSyncRemotes = do
rs <- filter (remoteAnnexSync . Remote.gitconfig) .
- concat . Remote.byCost <$> Remote.enabledRemoteList
+ concat . Remote.byCost <$> Remote.remoteList
alive <- trustExclude DeadTrusted (map Remote.uuid rs)
let good r = Remote.uuid r `elem` alive
let syncable = filter good rs
- let nonxmpp = filter (not . isXMPPRemote) syncable
+ let syncdata = filter (not . remoteAnnexIgnore . Remote.gitconfig) $
+ filter (not . isXMPPRemote) syncable
return $ \dstatus -> dstatus
{ syncRemotes = syncable
, syncGitRemotes =
filter (not . Remote.specialRemote) syncable
- , syncDataRemotes = nonxmpp
- , syncingToCloudRemote = any iscloud nonxmpp
+ , syncDataRemotes = syncdata
+ , syncingToCloudRemote = any iscloud syncdata
}
where
iscloud r = not (Remote.readonly r) && Remote.globallyAvailable r
diff --git a/Assistant/Sync.hs b/Assistant/Sync.hs
index 78fdbab1a..727749c4f 100644
--- a/Assistant/Sync.hs
+++ b/Assistant/Sync.hs
@@ -68,7 +68,9 @@ reconnectRemotes notifypushes rs = void $ do
go = do
(failed, diverged) <- sync
=<< liftAnnex (inRepo Git.Branch.current)
- addScanRemotes diverged nonxmppremotes
+ addScanRemotes diverged $
+ filter (not . remoteAnnexIgnore . Remote.gitconfig)
+ nonxmppremotes
return failed
{- Updates the local sync branch, then pushes it to all remotes, in
diff --git a/Assistant/Threads/MountWatcher.hs b/Assistant/Threads/MountWatcher.hs
index c03eac4f1..143ae9cee 100644
--- a/Assistant/Threads/MountWatcher.hs
+++ b/Assistant/Threads/MountWatcher.hs
@@ -157,7 +157,7 @@ handleMount :: FilePath -> Assistant ()
handleMount dir = do
debug ["detected mount of", dir]
rs <- filter (Git.repoIsLocal . Remote.repo) <$> remotesUnder dir
- reconnectRemotes True $ filter (not . remoteAnnexIgnore . Remote.gitconfig) rs
+ reconnectRemotes True rs
{- Finds remotes located underneath the mount point.
-
diff --git a/Assistant/Threads/NetWatcher.hs b/Assistant/Threads/NetWatcher.hs
index 6d15d414e..6ac7203b0 100644
--- a/Assistant/Threads/NetWatcher.hs
+++ b/Assistant/Threads/NetWatcher.hs
@@ -128,4 +128,4 @@ handleConnection = reconnectRemotes True =<< networkRemotes
{- Finds network remotes. -}
networkRemotes :: Assistant [Remote]
networkRemotes = liftAnnex $
- filter (isNothing . Remote.localpath) <$> enabledRemoteList
+ filter (isNothing . Remote.localpath) <$> remoteList