summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Remote/Bup.hs2
-rw-r--r--Remote/Directory.hs4
-rw-r--r--Remote/Git.hs4
-rw-r--r--Remote/Glacier.hs72
-rw-r--r--Remote/Helper/Chunked.hs5
-rw-r--r--Remote/Helper/Encryptable.hs7
-rw-r--r--Remote/Hook.hs4
-rw-r--r--Remote/List.hs2
-rw-r--r--Remote/Rsync.hs8
-rw-r--r--Remote/S3.hs59
-rw-r--r--Remote/Web.hs6
-rw-r--r--Remote/WebDAV.hs61
-rw-r--r--Types/Remote.hs6
-rw-r--r--Utility/SRV.hs1
-rw-r--r--doc/design/assistant.mdwn8
-rw-r--r--doc/design/assistant/android.mdwn4
-rw-r--r--doc/design/assistant/cloud.mdwn2
-rw-r--r--doc/design/assistant/configurators.mdwn4
-rw-r--r--doc/design/assistant/pairing.mdwn1
-rw-r--r--doc/design/assistant/polls/Android.mdwn18
-rw-r--r--doc/design/assistant/syncing.mdwn9
-rw-r--r--doc/design/assistant/transfer_control.mdwn14
-rw-r--r--doc/design/assistant/webapp.mdwn2
-rw-r--r--doc/todo/wishlist:_move_pending_transfers_for_a_host_to_the_end_of_the_queue_when_one_fails.mdwn2
24 files changed, 152 insertions, 153 deletions
diff --git a/Remote/Bup.hs b/Remote/Bup.hs
index 62db01a7b..116a43321 100644
--- a/Remote/Bup.hs
+++ b/Remote/Bup.hs
@@ -38,7 +38,7 @@ remote = RemoteType {
setup = bupSetup
}
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
gen r u c = do
buprepo <- getRemoteConfig r "buprepo" (error "missing buprepo")
cst <- remoteCost r (if bupLocal buprepo then semiCheapRemoteCost else expensiveRemoteCost)
diff --git a/Remote/Directory.hs b/Remote/Directory.hs
index 737ae6312..c202ddb1d 100644
--- a/Remote/Directory.hs
+++ b/Remote/Directory.hs
@@ -33,7 +33,7 @@ remote = RemoteType {
setup = directorySetup
}
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
gen r u c = do
dir <- getRemoteConfig r "directory" (error "missing directory")
cst <- remoteCost r cheapRemoteCost
@@ -52,7 +52,7 @@ gen r u c = do
hasKey = checkPresent dir chunksize,
hasKeyCheap = True,
whereisKey = Nothing,
- config = Nothing,
+ config = M.empty,
repo = r,
localpath = Just dir,
readonly = False,
diff --git a/Remote/Git.hs b/Remote/Git.hs
index 24dd9bf80..0933a1cae 100644
--- a/Remote/Git.hs
+++ b/Remote/Git.hs
@@ -83,7 +83,7 @@ configRead r = do
repoCheap :: Git.Repo -> Bool
repoCheap = not . Git.repoIsUrl
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
gen r u _ = new <$> remoteCost r defcst
where
defcst = if repoCheap r then cheapRemoteCost else expensiveRemoteCost
@@ -98,7 +98,7 @@ gen r u _ = new <$> remoteCost r defcst
, hasKey = inAnnex r
, hasKeyCheap = repoCheap r
, whereisKey = Nothing
- , config = Nothing
+ , config = M.empty
, localpath = if Git.repoIsLocal r || Git.repoIsLocalUnknown r
then Just $ Git.repoPath r
else Nothing
diff --git a/Remote/Glacier.hs b/Remote/Glacier.hs
index a4d658d1b..edb9225aa 100644
--- a/Remote/Glacier.hs
+++ b/Remote/Glacier.hs
@@ -36,34 +36,31 @@ remote = RemoteType {
setup = glacierSetup
}
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
-gen r u c = do
- cst <- remoteCost r veryExpensiveRemoteCost
- return $ gen' r u c cst
-gen' :: Git.Repo -> UUID -> Maybe RemoteConfig -> Int -> Remote
-gen' r u c cst =
- encryptableRemote c
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
+gen r u c = new <$> remoteCost r veryExpensiveRemoteCost
+ where
+ new cst = encryptableRemote c
(storeEncrypted this)
(retrieveEncrypted this)
this
- where
- this = Remote {
- uuid = u,
- cost = cst,
- name = Git.repoDescribe r,
- storeKey = store this,
- retrieveKeyFile = retrieve this,
- retrieveKeyFileCheap = retrieveCheap this,
- removeKey = remove this,
- hasKey = checkPresent this,
- hasKeyCheap = False,
- whereisKey = Nothing,
- config = c,
- repo = r,
- localpath = Nothing,
- readonly = False,
- remotetype = remote
- }
+ where
+ this = Remote {
+ uuid = u,
+ cost = cst,
+ name = Git.repoDescribe r,
+ storeKey = store this,
+ retrieveKeyFile = retrieve this,
+ retrieveKeyFileCheap = retrieveCheap this,
+ removeKey = remove this,
+ hasKey = checkPresent this,
+ hasKeyCheap = False,
+ whereisKey = Nothing,
+ config = c,
+ repo = r,
+ localpath = Nothing,
+ readonly = False,
+ remotetype = remote
+ }
glacierSetup :: UUID -> RemoteConfig -> Annex RemoteConfig
glacierSetup u c = do
@@ -115,13 +112,13 @@ retrieveEncrypted r (cipher, enck) k d = metered Nothing k $ \meterupdate ->
storeHelper :: Remote -> Key -> (Handle -> IO ()) -> Annex Bool
storeHelper r k feeder = go =<< glacierEnv c u
where
- c = fromJust $ config r
+ c = config r
u = uuid r
params = glacierParams c
[ Param "archive"
, Param "upload"
, Param "--name", Param $ archive r k
- , Param $ remoteVault r
+ , Param $ getVault $ config r
, Param "-"
]
go Nothing = return False
@@ -135,13 +132,13 @@ storeHelper r k feeder = go =<< glacierEnv c u
retrieveHelper :: Remote -> Key -> (Handle -> IO ()) -> Annex Bool
retrieveHelper r k reader = go =<< glacierEnv c u
where
- c = fromJust $ config r
+ c = config r
u = uuid r
params = glacierParams c
[ Param "archive"
, Param "retrieve"
, Param "-o-"
- , Param $ remoteVault r
+ , Param $ getVault $ config r
, Param $ archive r k
]
go Nothing = return False
@@ -163,14 +160,14 @@ remove :: Remote -> Key -> Annex Bool
remove r k = glacierAction r
[ Param "archive"
, Param "delete"
- , Param $ remoteVault r
+ , Param $ getVault $ config r
, Param $ archive r k
]
checkPresent :: Remote -> Key -> Annex (Either String Bool)
checkPresent r k = do
showAction $ "checking " ++ name r
- go =<< glacierEnv (fromJust $ config r) (uuid r)
+ go =<< glacierEnv (config r) (uuid r)
where
go Nothing = return $ Left "cannot check glacier"
go (Just e) = do
@@ -190,7 +187,7 @@ checkPresent r k = do
params =
[ Param "archive"
, Param "checkpresent"
- , Param $ remoteVault r
+ , Param $ getVault $ config r
, Param "--quiet"
, Param $ archive r k
]
@@ -205,7 +202,7 @@ checkPresent r k = do
return $ Right False
glacierAction :: Remote -> [CommandParam] -> Annex Bool
-glacierAction r params = runGlacier (fromJust $ config r) (uuid r) params
+glacierAction r params = runGlacier (config r) (uuid r) params
runGlacier :: RemoteConfig -> UUID -> [CommandParam] -> Annex Bool
runGlacier c u params = go =<< glacierEnv c u
@@ -231,16 +228,13 @@ glacierEnv c u = go =<< getRemoteCredPairFor "glacier" c creds
creds = AWS.creds u
(uk, pk) = credPairEnvironment creds
-remoteVault :: Remote -> Vault
-remoteVault = getVault . fromJust . config
-
getVault :: RemoteConfig -> Vault
getVault = fromJust . M.lookup "vault"
archive :: Remote -> Key -> Archive
archive r k = fileprefix ++ key2file k
where
- fileprefix = M.findWithDefault "" "fileprefix" $ fromJust $ config r
+ fileprefix = M.findWithDefault "" "fileprefix" $ config r
-- glacier vault create will succeed even if the vault already exists.
genVault :: RemoteConfig -> UUID -> Annex ()
@@ -260,11 +254,11 @@ genVault c u = unlessM (runGlacier c u params) $
- keys when the remote is encrypted.
-}
jobList :: Remote -> [Key] -> Annex ([Key], [Key])
-jobList r keys = go =<< glacierEnv (fromJust $ config r) (uuid r)
+jobList r keys = go =<< glacierEnv (config r) (uuid r)
where
params = [ Param "job", Param "list" ]
nada = ([], [])
- myvault = remoteVault r
+ myvault = getVault $ config r
go Nothing = return nada
go (Just e) = do
diff --git a/Remote/Helper/Chunked.hs b/Remote/Helper/Chunked.hs
index 4f04a1c38..04bde4c29 100644
--- a/Remote/Helper/Chunked.hs
+++ b/Remote/Helper/Chunked.hs
@@ -20,9 +20,8 @@ import qualified Control.Exception as E
type ChunkSize = Maybe Int64
{- Gets a remote's configured chunk size. -}
-chunkSize :: Maybe RemoteConfig -> ChunkSize
-chunkSize Nothing = Nothing
-chunkSize (Just m) =
+chunkSize :: RemoteConfig -> ChunkSize
+chunkSize m =
case M.lookup "chunksize" m of
Nothing -> Nothing
Just v -> case readSize dataUnits v of
diff --git a/Remote/Helper/Encryptable.hs b/Remote/Helper/Encryptable.hs
index 05aca9a41..d322a5cf8 100644
--- a/Remote/Helper/Encryptable.hs
+++ b/Remote/Helper/Encryptable.hs
@@ -44,7 +44,7 @@ encryptionSetup c = case (M.lookup "encryption" c, extractCipher c) of
- Two additional functions must be provided by the remote,
- to support storing and retrieving encrypted content. -}
encryptableRemote
- :: Maybe RemoteConfig
+ :: RemoteConfig
-> ((Cipher, Key) -> Key -> MeterUpdate -> Annex Bool)
-> ((Cipher, Key) -> Key -> FilePath -> Annex Bool)
-> Remote
@@ -103,9 +103,8 @@ embedCreds c
| otherwise = False
{- Gets encryption Cipher, and encrypted version of Key. -}
-cipherKey :: Maybe RemoteConfig -> Key -> Annex (Maybe (Cipher, Key))
-cipherKey Nothing _ = return Nothing
-cipherKey (Just c) k = maybe Nothing make <$> remoteCipher c
+cipherKey :: RemoteConfig -> Key -> Annex (Maybe (Cipher, Key))
+cipherKey c k = maybe Nothing make <$> remoteCipher c
where
make ciphertext = Just (ciphertext, encryptKey ciphertext k)
diff --git a/Remote/Hook.hs b/Remote/Hook.hs
index 7173a5b80..e6e1231a8 100644
--- a/Remote/Hook.hs
+++ b/Remote/Hook.hs
@@ -29,7 +29,7 @@ remote = RemoteType {
setup = hookSetup
}
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
gen r u c = do
hooktype <- getRemoteConfig r "hooktype" (error "missing hooktype")
cst <- remoteCost r expensiveRemoteCost
@@ -47,7 +47,7 @@ gen r u c = do
hasKey = checkPresent r hooktype,
hasKeyCheap = False,
whereisKey = Nothing,
- config = Nothing,
+ config = M.empty,
localpath = Nothing,
repo = r,
readonly = False,
diff --git a/Remote/List.hs b/Remote/List.hs
index 3179456eb..4622f1e99 100644
--- a/Remote/List.hs
+++ b/Remote/List.hs
@@ -81,7 +81,7 @@ remoteListRefresh = do
remoteGen :: (M.Map UUID RemoteConfig) -> RemoteType -> Git.Repo -> Annex Remote
remoteGen m t r = do
u <- getRepoUUID r
- addHooks =<< generate t r u (M.lookup u m)
+ addHooks =<< generate t r u (fromMaybe M.empty $ M.lookup u m)
{- Updates a local git Remote, re-reading its git config. -}
updateRemote :: Remote -> Annex Remote
diff --git a/Remote/Rsync.hs b/Remote/Rsync.hs
index a3ad21f73..2ad5482ec 100644
--- a/Remote/Rsync.hs
+++ b/Remote/Rsync.hs
@@ -38,7 +38,7 @@ remote = RemoteType {
setup = rsyncSetup
}
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
gen r u c = do
o <- genRsyncOpts r c
cst <- remoteCost r expensiveRemoteCost
@@ -56,7 +56,7 @@ gen r u c = do
, hasKey = checkPresent r o
, hasKeyCheap = False
, whereisKey = Nothing
- , config = Nothing
+ , config = M.empty
, repo = r
, localpath = if rsyncUrlIsPath $ rsyncUrl o
then Just $ rsyncUrl o
@@ -65,12 +65,12 @@ gen r u c = do
, remotetype = remote
}
-genRsyncOpts :: Git.Repo -> Maybe RemoteConfig -> Annex RsyncOpts
+genRsyncOpts :: Git.Repo -> RemoteConfig -> Annex RsyncOpts
genRsyncOpts r c = do
url <- getRemoteConfig r "rsyncurl" (error "missing rsyncurl")
opts <- map Param . filter safe . words
<$> getRemoteConfig r "rsync-options" ""
- let escape = maybe True (\m -> M.lookup "shellescape" m /= Just "no") c
+ let escape = M.lookup "shellescape" c /= Just "no"
return $ RsyncOpts url opts escape
where
safe o
diff --git a/Remote/S3.hs b/Remote/S3.hs
index ba5fb949b..512b3f778 100644
--- a/Remote/S3.hs
+++ b/Remote/S3.hs
@@ -36,34 +36,31 @@ remote = RemoteType {
setup = s3Setup
}
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
-gen r u c = do
- cst <- remoteCost r expensiveRemoteCost
- return $ gen' r u c cst
-gen' :: Git.Repo -> UUID -> Maybe RemoteConfig -> Int -> Remote
-gen' r u c cst =
- encryptableRemote c
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
+gen r u c = new <$> remoteCost r expensiveRemoteCost
+ where
+ new cst = encryptableRemote c
(storeEncrypted this)
(retrieveEncrypted this)
this
- where
- this = Remote {
- uuid = u,
- cost = cst,
- name = Git.repoDescribe r,
- storeKey = store this,
- retrieveKeyFile = retrieve this,
- retrieveKeyFileCheap = retrieveCheap this,
- removeKey = remove this,
- hasKey = checkPresent this,
- hasKeyCheap = False,
- whereisKey = Nothing,
- config = c,
- repo = r,
- localpath = Nothing,
- readonly = False,
- remotetype = remote
- }
+ where
+ this = Remote {
+ uuid = u,
+ cost = cst,
+ name = Git.repoDescribe r,
+ storeKey = store this,
+ retrieveKeyFile = retrieve this,
+ retrieveKeyFileCheap = retrieveCheap this,
+ removeKey = remove this,
+ hasKey = checkPresent this,
+ hasKeyCheap = False,
+ whereisKey = Nothing,
+ config = c,
+ repo = r,
+ localpath = Nothing,
+ readonly = False,
+ remotetype = remote
+ }
s3Setup :: UUID -> RemoteConfig -> Annex RemoteConfig
s3Setup u c = handlehost $ M.lookup "host" c
@@ -143,13 +140,13 @@ storeHelper (conn, bucket) r k p file = do
sendObject conn object
where
storageclass =
- case fromJust $ M.lookup "storageclass" $ fromJust $ config r of
+ case fromJust $ M.lookup "storageclass" $ config r of
"REDUCED_REDUNDANCY" -> REDUCED_REDUNDANCY
_ -> STANDARD
getsize = liftIO $ fromIntegral . fileSize <$> getFileStatus file
- xheaders = filter isxheader $ M.assocs $ fromJust $ config r
+ xheaders = filter isxheader $ M.assocs $ config r
isxheader (h, _) = "x-amz-" `isPrefixOf` h
retrieve :: Remote -> Key -> AssociatedFile -> FilePath -> Annex Bool
@@ -207,10 +204,8 @@ s3Bool (Left e) = s3Warning e
s3Action :: Remote -> a -> ((AWSConnection, String) -> Annex a) -> Annex a
s3Action r noconn action = do
- when (isNothing $ config r) $
- error $ "Missing configuration for special remote " ++ name r
- let bucket = M.lookup "bucket" $ fromJust $ config r
- conn <- s3Connection (fromJust $ config r) (uuid r)
+ let bucket = M.lookup "bucket" $ config r
+ conn <- s3Connection (config r) (uuid r)
case (bucket, conn) of
(Just b, Just c) -> action (c, b)
_ -> return noconn
@@ -222,7 +217,7 @@ bucketFile r = munge . key2file
Just "ia" -> iaMunge $ fileprefix ++ s
_ -> fileprefix ++ s
fileprefix = M.findWithDefault "" "fileprefix" c
- c = fromJust $ config r
+ c = config r
bucketKey :: Remote -> String -> Key -> S3Object
bucketKey r bucket k = S3Object bucket (bucketFile r k) "" [] L.empty
diff --git a/Remote/Web.hs b/Remote/Web.hs
index e51a73901..f1eee7feb 100644
--- a/Remote/Web.hs
+++ b/Remote/Web.hs
@@ -17,6 +17,8 @@ import Logs.Web
import qualified Utility.Url as Url
import Types.Key
+import qualified Data.Map as M
+
remote :: RemoteType
remote = RemoteType {
typename = "web",
@@ -33,7 +35,7 @@ list = do
r <- liftIO $ Git.Construct.remoteNamed "web" Git.Construct.fromUnknown
return [r]
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
gen r _ _ =
return Remote {
uuid = webUUID,
@@ -46,7 +48,7 @@ gen r _ _ =
hasKey = checkKey,
hasKeyCheap = False,
whereisKey = Just getUrls,
- config = Nothing,
+ config = M.empty,
localpath = Nothing,
repo = r,
readonly = True,
diff --git a/Remote/WebDAV.hs b/Remote/WebDAV.hs
index a5bba716b..d6fc35f2e 100644
--- a/Remote/WebDAV.hs
+++ b/Remote/WebDAV.hs
@@ -45,34 +45,31 @@ remote = RemoteType {
setup = webdavSetup
}
-gen :: Git.Repo -> UUID -> Maybe RemoteConfig -> Annex Remote
-gen r u c = do
- cst <- remoteCost r expensiveRemoteCost
- return $ gen' r u c cst
-gen' :: Git.Repo -> UUID -> Maybe RemoteConfig -> Int -> Remote
-gen' r u c cst =
- encryptableRemote c
+gen :: Git.Repo -> UUID -> RemoteConfig -> Annex Remote
+gen r u c = new <$> remoteCost r expensiveRemoteCost
+ where
+ new cst = encryptableRemote c
(storeEncrypted this)
(retrieveEncrypted this)
this
- where
- this = Remote {
- uuid = u,
- cost = cst,
- name = Git.repoDescribe r,
- storeKey = store this,
- retrieveKeyFile = retrieve this,
- retrieveKeyFileCheap = retrieveCheap this,
- removeKey = remove this,
- hasKey = checkPresent this,
- hasKeyCheap = False,
- whereisKey = Nothing,
- config = c,
- repo = r,
- localpath = Nothing,
- readonly = False,
- remotetype = remote
- }
+ where
+ this = Remote {
+ uuid = u,
+ cost = cst,
+ name = Git.repoDescribe r,
+ storeKey = store this,
+ retrieveKeyFile = retrieve this,
+ retrieveKeyFileCheap = retrieveCheap this,
+ removeKey = remove this,
+ hasKey = checkPresent this,
+ hasKeyCheap = False,
+ whereisKey = Nothing,
+ config = c,
+ repo = r,
+ localpath = Nothing,
+ readonly = False,
+ remotetype = remote
+ }
webdavSetup :: UUID -> RemoteConfig -> Annex RemoteConfig
webdavSetup u c = do
@@ -201,14 +198,12 @@ withStoredFiles r k baseurl user pass onerr a
keyurl = davLocation baseurl k ++ keyFile k
davAction :: Remote -> a -> ((DavUrl, DavUser, DavPass) -> Annex a) -> Annex a
-davAction r unconfigured action = case config r of
- Nothing -> return unconfigured
- Just c -> do
- mcreds <- getCreds c (uuid r)
- case (mcreds, M.lookup "url" c) of
- (Just (user, pass), Just url) ->
- action (url, toDavUser user, toDavPass pass)
- _ -> return unconfigured
+davAction r unconfigured action = do
+ mcreds <- getCreds (config r) (uuid r)
+ case (mcreds, M.lookup "url" $ config r) of
+ (Just (user, pass), Just url) ->
+ action (url, toDavUser user, toDavPass pass)
+ _ -> return unconfigured
toDavUser :: String -> DavUser
toDavUser = B8.fromString
diff --git a/Types/Remote.hs b/Types/Remote.hs
index 271676d0e..f01ae01f6 100644
--- a/Types/Remote.hs
+++ b/Types/Remote.hs
@@ -27,7 +27,7 @@ data RemoteTypeA a = RemoteType {
-- enumerates remotes of this type
enumerate :: a [Git.Repo],
-- generates a remote of this type
- generate :: Git.Repo -> UUID -> Maybe RemoteConfig -> a (RemoteA a),
+ generate :: Git.Repo -> UUID -> RemoteConfig -> a (RemoteA a),
-- initializes or changes a remote
setup :: UUID -> RemoteConfig -> a RemoteConfig
}
@@ -62,8 +62,8 @@ data RemoteA a = Remote {
hasKeyCheap :: Bool,
-- Some remotes can provide additional details for whereis.
whereisKey :: Maybe (Key -> a [String]),
- -- a Remote can have a persistent configuration store
- config :: Maybe RemoteConfig,
+ -- a Remote has a persistent configuration store
+ config :: RemoteConfig,
-- git configuration for the remote
repo :: Git.Repo,
-- a Remote can be assocated with a specific local filesystem path
diff --git a/Utility/SRV.hs b/Utility/SRV.hs
index 5443b8b1a..bbfc7276d 100644
--- a/Utility/SRV.hs
+++ b/Utility/SRV.hs
@@ -14,6 +14,7 @@ module Utility.SRV (
mkSRVTcp,
mkSRV,
lookupSRV,
+ lookupSRVHost,
) where
import Utility.Process
diff --git a/doc/design/assistant.mdwn b/doc/design/assistant.mdwn
index f8ef510ee..26f298e1a 100644
--- a/doc/design/assistant.mdwn
+++ b/doc/design/assistant.mdwn
@@ -13,8 +13,10 @@ and use cases to add. Feel free to chip in with comments! --[[Joey]]
We are, approximately, here:
-* Months 6-7 "9k bonus round": [[!traillink Android]] [[!traillink partial_content]] [[!traillink leftovers]]
-* Months 8-11: more user-driven features and polishing (see remaining TODO items in all pages above)
+* Month 6 "9k bonus round": [[!traillink Android]] or [[!traillink desymlink]]
+* Month 7: user-driven features and polishing
+* Month 8: whatever I don't get to in month 6
+* Months 9-11: more user-driven features and polishing (see remaining TODO items in all pages above)
* Month 12: "Windows purgatory" [[Windows]]
## porting
@@ -23,7 +25,7 @@ We are, approximately, here:
## not yet on the map:
-* [[desymlink]]
+* [[partial_content]]
* [[deltas]]
* [[leftovers]]
* [[other todo items|todo]]
diff --git a/doc/design/assistant/android.mdwn b/doc/design/assistant/android.mdwn
index 1db2913a7..a3753a39d 100644
--- a/doc/design/assistant/android.mdwn
+++ b/doc/design/assistant/android.mdwn
@@ -40,5 +40,5 @@ transfers when not on wifi. This may need to be configurable.
## FAT
-Due to use of the fat filesystem, which doesn't do symlinks, [[nosymlink]]
-is probably needed.
+Due to use of the FAT filesystem, which doesn't do symlinks, [[desymlink]]
+is probably needed for at least older Android devices that have SD cards.
diff --git a/doc/design/assistant/cloud.mdwn b/doc/design/assistant/cloud.mdwn
index 6b62c9c9f..ebaa28972 100644
--- a/doc/design/assistant/cloud.mdwn
+++ b/doc/design/assistant/cloud.mdwn
@@ -2,7 +2,7 @@ The [[syncing]] design assumes the network is connected. But it's often
not in these pre-IPV6 days, so the cloud needs to be used to bridge between
LANS.
-## The cloud notification problem **done**
+## The cloud notification problem (**done**)
Alice and Bob have repos, and there is a cloud remote they both share.
Alice adds a file; the assistant transfers it to the cloud remote.
diff --git a/doc/design/assistant/configurators.mdwn b/doc/design/assistant/configurators.mdwn
index b682aa9c9..4d08ac54a 100644
--- a/doc/design/assistant/configurators.mdwn
+++ b/doc/design/assistant/configurators.mdwn
@@ -8,11 +8,11 @@ The meat of the configuration will be in configuration assistants that walk
through setting up common use cases.
* Create a repository (run when the web app is started without a configured
- repository too).
+ repository too). **done**
* Clone this repo to a USB drive or other removable drive. **done**
* Make a bare repo on a remote ssh server **done**
* Clone this repo to another host. (Needs [[pairing]]) **done**
-* Set up Amazon S3.
+* Set up Amazon S3. **done**
* Set up encrypted rsync remote. **done**
* Rsync.net special case **done**
* Set up gpg encryption key; gpg key distribution.
diff --git a/doc/design/assistant/pairing.mdwn b/doc/design/assistant/pairing.mdwn
index 30b42a2cc..d09c644ee 100644
--- a/doc/design/assistant/pairing.mdwn
+++ b/doc/design/assistant/pairing.mdwn
@@ -81,4 +81,3 @@ is escaped before going to the browser.
It should be possible for third parties to tell when pairing is done,
but it's actually rather hard since they don't necessarily share the secret.
-* Pairing over XMPP.
diff --git a/doc/design/assistant/polls/Android.mdwn b/doc/design/assistant/polls/Android.mdwn
new file mode 100644
index 000000000..64ef6afc4
--- /dev/null
+++ b/doc/design/assistant/polls/Android.mdwn
@@ -0,0 +1,18 @@
+Help me choose a goal for the month of December. The last poll showed
+a lot of interest in using the git-annex assistant with phones, etc.
+
+Background: git-annex uses symbolic links in its repositories. This makes it
+hard to use with filesystems, such as FAT, that do not support symbolic links.
+FAT filesystems are the main storage available on some Android devices that
+have a micro-SD card. Other, newer Android devices don't have a SD card and so
+avoid this problem.
+
+I can either work on the idea described in
+[[design/assistant/desymlink]], which could solve the symlink problem and
+also could lead to a nicer workflow to editing files that are stored in
+git-annex.
+
+Or, I can work on [[Android_porting|design/assistant/android]], and try to
+get the assistant working on Android's built-in storage.
+
+[[!poll open=yes 0 "solve the symlink problem first" 0 "port to Android first" 0 "other"]]
diff --git a/doc/design/assistant/syncing.mdwn b/doc/design/assistant/syncing.mdwn
index a7592d84b..3274c634a 100644
--- a/doc/design/assistant/syncing.mdwn
+++ b/doc/design/assistant/syncing.mdwn
@@ -18,13 +18,9 @@ all the other git clones, at both the git level and the key/value level.
airport somewhere.
* Find a way to probe available outgoing bandwidth, to throttle so
we don't bufferbloat the network to death.
-* Investigate the XMPP approach like dvcs-autosync does, or other ways of
- signaling a change out of band.
* Add a hook, so when there's a change to sync, a program can be run
and do its own signaling.
* --debug will show often unnecessary work being done. Optimise.
-* This assumes the network is connected. It's often not, so the
- [[cloud]] needs to be used to bridge between LANs.
* Configurablity, including only enabling git syncing but not data transfer;
only uploading new files but not downloading, and only downloading
files in some directories and not others. See for use cases:
@@ -41,14 +37,11 @@ all the other git clones, at both the git level and the key/value level.
working copy and checks each file. That probably needs to be done once,
but further calls to the TransferScanner could eg, look at the delta
between the last scan and the current one in the git-annex branch.
-* Ensure that when a remote receives content, and updates its location log,
- it syncs that update back out. Currently, it does not, unless the master
- branch also changed. Prerequisite for:
* After git sync, identify new content that we don't have that is now available
on remotes, and transfer. (Needed when we have a uni-directional connection
to a remote, so it won't be uploading content to us.) Note: Does not
need to use the TransferScanner, if we get and check a list of the changed
- files.
+ files. done?
* [[use multiple transfer slots|todo/Slow_transfer_for_a_lot_of_small_files.]]
* The TransferQueue's list of deferred downloads could theoretically
grow without bounds in memory. Limit it to a given number of entries,
diff --git a/doc/design/assistant/transfer_control.mdwn b/doc/design/assistant/transfer_control.mdwn
index c21c4a170..b0a14ed2b 100644
--- a/doc/design/assistant/transfer_control.mdwn
+++ b/doc/design/assistant/transfer_control.mdwn
@@ -19,9 +19,6 @@ something smart with such remotes.
log is not updated in time, it will fail to drop unwanted content.
(There's a 10 second sleep there now to avoid the race, but that's hardly
a fix.)
-* When a file is renamed into an archive directory, it's not immediately
- transferred to archive remotes. (Next expensive scan does successfully
- cause the transfer to happen).
### dropping no longer preferred content
@@ -48,7 +45,7 @@ the same content, this gets tricky. Let's assume there are not.)
That's all! Of these, 1-4 are by far the most important.
-## specifying what data a remote prefers to contain **done**
+## specifying what data a remote prefers to contain (**done**)
Imagine a per-remote preferred content setting, that matches things that
should be stored on the remote.
@@ -67,7 +64,7 @@ check if preferred content settings rejects the data, and if so, drop it
from the repo. So once all three laptops have the data, it is
pruned from the transfer drive.
-## repo groups **done**
+## repo groups (**done**)
Seems like git-annex needs a way to know the groups of repos. Some
groups:
@@ -79,7 +76,7 @@ groups:
it does not hold data for long periods of time, and tends to have a
limited size.
-Add a group.log that can assign repos to these or other groups. **done**
+Add a group.log that can assign repos to these or other groups. (**done**)
Some examples of using groups:
@@ -104,7 +101,10 @@ Currently, we have a simple drop down list to select between a few
predefined groups with pre-defined preferred content recipes. Is this good
enough?
-## the state change problem **done**
+I think so; useful recipes can be developed on the wiki and included in
+git-annex.
+
+## the state change problem (**done**)
Imagine that a trusted repo has setting like `not copies=trusted:2`
This means that `git annex get --auto` should get files not in 2 trusted
diff --git a/doc/design/assistant/webapp.mdwn b/doc/design/assistant/webapp.mdwn
index fc110a8f2..f71490373 100644
--- a/doc/design/assistant/webapp.mdwn
+++ b/doc/design/assistant/webapp.mdwn
@@ -28,7 +28,7 @@ The webapp is a web server that displays a shiny interface.
See: [[todo/wishlist:_an_"assistant"_for_web-browsing_--_tracking_the_sources_of_the_downloads]]
* Display the `inotify max_user_watches` exceeded message. **done**
* Display something sane when kqueue runs out of file descriptors.
-* allow removing git remotes
+* allow removing git remotes **done**
* allow disabling syncing to here, which should temporarily disable all
local syncing.
diff --git a/doc/todo/wishlist:_move_pending_transfers_for_a_host_to_the_end_of_the_queue_when_one_fails.mdwn b/doc/todo/wishlist:_move_pending_transfers_for_a_host_to_the_end_of_the_queue_when_one_fails.mdwn
index 966c59d95..e50ebbde5 100644
--- a/doc/todo/wishlist:_move_pending_transfers_for_a_host_to_the_end_of_the_queue_when_one_fails.mdwn
+++ b/doc/todo/wishlist:_move_pending_transfers_for_a_host_to_the_end_of_the_queue_when_one_fails.mdwn
@@ -3,3 +3,5 @@ Right now the assistant can have a huge list of pending transfers for certain ho
I suggest that if a transfer fails for host X, and there are other pending transfers, say to host Y and from Z, then all other pending transfers to/from X gets pushed to the back of the queue, to avoid having to wait a long time for several transfers to time out before doing useful stuff.
The prime example for me was this morning, when a laptop that was turned off had a huge amount of queued transfers to it, resulting in the assistant attempting a load of transfers to that host before it retrieved a new file that I had created on another machine yesterday.
+
+[[!tag design/assistant]]