split out generic url stuff into a helper library from Remote.Web
This commit is contained in:
parent
07f2e7ee72
commit
4545a0e78c
3 changed files with 77 additions and 34 deletions
|
@ -14,6 +14,7 @@ import System.Directory
|
|||
|
||||
import Command
|
||||
import qualified Backend
|
||||
import qualified Remote.Helper.Url
|
||||
import qualified Remote.Web
|
||||
import qualified Command.Add
|
||||
import qualified Annex
|
||||
|
@ -52,7 +53,7 @@ download url file = do
|
|||
let dummykey = Backend.URL.fromUrl url
|
||||
let tmp = gitAnnexTmpLocation g dummykey
|
||||
liftIO $ createDirectoryIfMissing True (parentDir tmp)
|
||||
ok <- Remote.Web.download [url] tmp
|
||||
ok <- Remote.Helper.Url.download url tmp
|
||||
if ok
|
||||
then do
|
||||
[(_, backend)] <- Backend.chooseBackends [file]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue