refactor sinkResponseFile and add downloadC
Remote.S3 and Remote.Helper.Http both had similar code to sink a http-conduit Response to a file; refactor out sinkResponseFile. downloadC downloads an url to a file using http-conduit, and supports resuming. Falls back to curl to handle urls that http-conduit does not support. This is not used yet, but the goal is to replace download with it. git-annex.cabal: conduit-extra was not actually used for a long time, remove the dep. conduit moves into the main dependency list, but since http-conduit was already in there, and it depends on conduit, that's not really adding a new build dep. This commit was supported by the NSF-funded DataLad project.
This commit is contained in:
parent
0e8564201e
commit
0f6775f1ff
6 changed files with 138 additions and 35 deletions
|
@ -32,3 +32,8 @@ to http-conduit which does not support it. Maybe require users to set
|
|||
supports netrc?
|
||||
|
||||
--[[Joey]]
|
||||
|
||||
> Implemented Utility.Url.downloadC that is the (nontrivial)
|
||||
> download a file with resume support using http-conduit.
|
||||
> It falls back to curl to handle urls that http-conduit does not support.
|
||||
> Now we only have to decide what to do about the above edge cases..
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue