diff options
author | Joey Hess <joey@kitenet.net> | 2012-04-22 01:13:09 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2012-04-22 01:13:09 -0400 |
commit | 84ac8c58db30637db4fb88566530b6293f12dab0 (patch) | |
tree | 72b7d1bae98ee22b34d722554069b68eea47513f /Git | |
parent | 5fbe83f595bf5957376544ee83b3cc46cc2323ed (diff) |
Add annex.httpheaders and annex.httpheader-command config settings
Allow custom headers to be sent with all HTTP requests.
(Requested by the Internet Archive)
Diffstat (limited to 'Git')
-rw-r--r-- | Git/Config.hs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Git/Config.hs b/Git/Config.hs index 8190a62ad..38b9ade45 100644 --- a/Git/Config.hs +++ b/Git/Config.hs @@ -20,6 +20,10 @@ import qualified Git.Construct get :: String -> String -> Repo -> String get key defaultValue repo = M.findWithDefault defaultValue key (config repo) +{- Returns a list with each line of a multiline config setting. -} +getList :: String -> Repo -> [String] +getList key repo = M.findWithDefault [] key (fullconfig repo) + {- Returns a single git config setting, if set. -} getMaybe :: String -> Repo -> Maybe String getMaybe key repo = M.lookup key (config repo) |