move remote removal into separate module

This allows using Git.Remote w/o needing to have Git.BuildVersion, which
requires configure. It will simplify github-backup when these libraries are
used there.
This commit is contained in:
Joey Hess 2014-10-27 11:24:21 -04:00
parent 9ca3e14481
commit 20a497b181
5 changed files with 33 additions and 17 deletions

View file

@ -18,6 +18,7 @@ import Assistant.DaemonStatus
import qualified Remote
import Remote.List
import qualified Git.Remote
import qualified Git.Remote.Remove
import Logs.Trust
import qualified Annex
@ -34,7 +35,7 @@ disableRemote uuid = do
remote <- fromMaybe (error "unknown remote")
<$> liftAnnex (Remote.remoteFromUUID uuid)
liftAnnex $ do
inRepo $ Git.Remote.remove (Remote.name remote)
inRepo $ Git.Remote.Remove.remove (Remote.name remote)
void $ remoteListRefresh
updateSyncRemotes
return remote