diff options
Diffstat (limited to 'Command/ContentLocation.hs')
-rw-r--r-- | Command/ContentLocation.hs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/Command/ContentLocation.hs b/Command/ContentLocation.hs index 3f4775f57..10879f5b1 100644 --- a/Command/ContentLocation.hs +++ b/Command/ContentLocation.hs @@ -9,19 +9,20 @@ module Command.ContentLocation where import Common.Annex import Command +import CmdLine.Batch import Annex.Content cmd :: [Command] -cmd = [noCommit $ noMessages $ +cmd = [withOptions [batchOption] $ noCommit $ noMessages $ command "contentlocation" (paramRepeating paramKey) seek SectionPlumbing "looks up content for a key"] seek :: CommandSeek -seek = withKeys start +seek = batchable withKeys start -start :: Key -> CommandStart -start k = do - liftIO . maybe exitFailure putStrLn +start :: Batchable Key +start batchmode k = do + maybe (batchBadInput batchmode) (liftIO . putStrLn) =<< inAnnex' (pure True) Nothing check k stop where |