diff options
Diffstat (limited to 'CmdLine/Seek.hs')
-rw-r--r-- | CmdLine/Seek.hs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/CmdLine/Seek.hs b/CmdLine/Seek.hs index 7bfea45d0..b5726f53e 100644 --- a/CmdLine/Seek.hs +++ b/CmdLine/Seek.hs @@ -173,13 +173,12 @@ withNothing _ _ = error "This command takes no parameters." - - Otherwise, fall back to a regular CommandSeek action on - whatever params were passed. -} -withKeyOptions :: (Key -> CommandStart) -> CommandSeek -> CommandSeek -withKeyOptions keyop fallbackop params = do +withKeyOptions :: Bool -> (Key -> CommandStart) -> CommandSeek -> CommandSeek +withKeyOptions auto keyop fallbackop params = do bare <- fromRepo Git.repoIsLocalBare allkeys <- Annex.getFlag "all" unused <- Annex.getFlag "unused" specifickey <- Annex.getField "key" - auto <- Annex.getState Annex.auto when (auto && bare) $ error "Cannot use --auto in a bare repository" case (allkeys, unused, null params, specifickey) of |