diff options
author | 2012-08-26 15:39:02 -0400 | |
---|---|---|
committer | 2012-08-26 15:39:02 -0400 | |
commit | 271ea499789410e7c5c1352abe835af0a5001c38 (patch) | |
tree | 1672342ee6f1d0c83e98d75562b96e18de96c10a /Assistant/Threads/TransferScanner.hs | |
parent | 4d269db5208dca3ce043e716d05a1c7bcc7a6755 (diff) |
add support for readonly remotes
Currently only the web special remote is readonly, but it'd be possible to
also have readonly drives, or other remotes. These are handled in the
assistant by only downloading from them, and never trying to upload to
them.
Diffstat (limited to 'Assistant/Threads/TransferScanner.hs')
-rw-r--r-- | Assistant/Threads/TransferScanner.hs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Assistant/Threads/TransferScanner.hs b/Assistant/Threads/TransferScanner.hs index b4ceac17d..a76453b53 100644 --- a/Assistant/Threads/TransferScanner.hs +++ b/Assistant/Threads/TransferScanner.hs @@ -16,6 +16,7 @@ import Assistant.Alert import Logs.Transfer import Logs.Location import qualified Remote +import qualified Types.Remote as Remote import Utility.ThreadScheduler import qualified Git.LsFiles as LsFiles import Command @@ -122,6 +123,7 @@ expensiveScan st dstatus transferqueue rs = do , use $ check Download True ) check direction want key locs r + | direction == Upload && Remote.readonly r = Nothing | (Remote.uuid r `elem` locs) == want = Just $ (r, Transfer direction (Remote.uuid r) key) | otherwise = Nothing |