Add annex.httpheaders and annex.httpheader-command config settings
Allow custom headers to be sent with all HTTP requests. (Requested by the Internet Archive)
This commit is contained in:
parent
5fbe83f595
commit
84ac8c58db
9 changed files with 66 additions and 27 deletions
|
@ -310,7 +310,8 @@ saveState oneshot = do
|
|||
downloadUrl :: [Url.URLString] -> FilePath -> Annex Bool
|
||||
downloadUrl urls file = do
|
||||
o <- map Param . words <$> getConfig "annex.web-options" ""
|
||||
liftIO $ anyM (\u -> Url.download u o file) urls
|
||||
headers <- getHttpHeaders
|
||||
liftIO $ anyM (\u -> Url.download u headers o file) urls
|
||||
|
||||
{- Copies a key's content, when present, to a temp file.
|
||||
- This is used to speed up some rsyncs. -}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue