summaryrefslogtreecommitdiff
path: root/Command/Sync.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-10-11 18:39:21 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-10-11 18:39:21 -0400
commitccfda0a1b479f131e69e0158b4269dc98982b268 (patch)
treef2ade0df2e6b5238615b56037bd01268f7ac7dfd /Command/Sync.hs
parent76090d48b97a2b29da03a2955e90da71d3842e82 (diff)
git config remote.name.annex-sync can be used to control whether a remote gets synced.
Diffstat (limited to 'Command/Sync.hs')
-rw-r--r--Command/Sync.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Command/Sync.hs b/Command/Sync.hs
index 11ea30a52..1795a6104 100644
--- a/Command/Sync.hs
+++ b/Command/Sync.hs
@@ -26,6 +26,7 @@ import Git.Types (BlobType(..))
import qualified Types.Remote
import qualified Remote.Git
import Types.Key
+import Config
import qualified Data.ByteString.Lazy as L
import Data.Hash.MD5
@@ -71,7 +72,8 @@ syncRemotes rs = ifM (Annex.getState Annex.fast) ( nub <$> pickfast , wanted )
unwords (map Types.Remote.name s)
return l
available = filter (not . Remote.specialRemote)
- <$> Remote.enabledRemoteList
+ <$> (filterM (repoSyncable . Types.Remote.repo)
+ =<< Remote.enabledRemoteList)
good = filterM $ Remote.Git.repoAvail . Types.Remote.repo
fastest = fromMaybe [] . headMaybe . Remote.byCost