diff options
Diffstat (limited to 'Annex.hs')
-rw-r--r-- | Annex.hs | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -28,6 +28,7 @@ module Annex ( getGitConfig, changeGitConfig, changeGitRepo, + getRemoteGitConfig, withCurrentState, ) where @@ -267,6 +268,13 @@ changeGitRepo r = changeState $ \s -> s , gitconfig = extractGitConfig r } +{- Gets the RemoteGitConfig from a remote, given the Git.Repo for that + - remote. -} +getRemoteGitConfig :: Git.Repo -> Annex RemoteGitConfig +getRemoteGitConfig r = do + g <- gitRepo + return $ extractRemoteGitConfig g (Git.repoDescribe r) + {- Converts an Annex action into an IO action, that runs with a copy - of the current Annex state. - |