addurl --fast: Verifies that the url can be downloaded (only getting its head), and records the size in the key.

This commit is contained in:
Joey Hess 2012-02-10 19:23:23 -04:00
parent 9030f68452
commit 17fed709c8
3 changed files with 14 additions and 4 deletions

View file

@ -24,5 +24,9 @@ backend = Backend {
fsckKey = Nothing
}
fromUrl :: String -> Key
fromUrl url = stubKey { keyName = url, keyBackendName = "URL" }
fromUrl :: String -> Maybe Integer -> Key
fromUrl url size = stubKey
{ keyName = url
, keyBackendName = "URL"
, keySize = size
}