diff options
author | 2012-01-06 17:51:01 -0400 | |
---|---|---|
committer | 2012-01-06 17:51:01 -0400 | |
commit | 6055a95c6f55410e010ace1b93268d70318e07dd (patch) | |
tree | 7fcad82a1c0e55c4d9fe09b819447440d2719e9a /Command/DropUnused.hs | |
parent | bc59da72501db1cfac69315798a7359037bb9002 (diff) | |
parent | 3c88d573990d79a5a964567c4a16068ef5ecfa0f (diff) |
Merge branch 'wip'
Diffstat (limited to 'Command/DropUnused.hs')
-rw-r--r-- | Command/DropUnused.hs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Command/DropUnused.hs b/Command/DropUnused.hs index fd3e84fe5..0b2a60216 100644 --- a/Command/DropUnused.hs +++ b/Command/DropUnused.hs @@ -15,6 +15,7 @@ import qualified Annex import qualified Command.Drop import qualified Remote import qualified Git +import qualified Option import Types.Key type UnusedMap = M.Map String Key @@ -51,14 +52,14 @@ start (unused, unusedbad, unusedtmp) s = search next $ a key perform :: Key -> CommandPerform -perform key = maybe droplocal dropremote =<< Annex.getField "from" +perform key = maybe droplocal dropremote =<< Remote.byName =<< from where - dropremote name = do - r <- Remote.byName name + dropremote r = do showAction $ "from " ++ Remote.name r ok <- Remote.removeKey r key next $ Command.Drop.cleanupRemote key r ok droplocal = Command.Drop.performLocal key (Just 0) -- force drop + from = Annex.getField $ Option.name Command.Drop.fromOption performOther :: (Key -> Git.Repo -> FilePath) -> Key -> CommandPerform performOther filespec key = do |