diff options
Diffstat (limited to 'Command.hs')
-rw-r--r-- | Command.hs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Command.hs b/Command.hs index e7ce335c7..13ea167bb 100644 --- a/Command.hs +++ b/Command.hs @@ -8,6 +8,7 @@ module Command ( command, noRepo, + oneShot, withOptions, next, stop, @@ -39,7 +40,11 @@ import Annex.CheckAttr {- Generates a normal command -} command :: String -> String -> [CommandSeek] -> String -> Command -command = Command [] Nothing commonChecks +command = Command [] Nothing commonChecks False + +{- Makes a command run in oneshot mode. -} +oneShot :: Command -> Command +oneShot c = c { cmdoneshot = True } {- Adds a fallback action to a command, that will be run if it's used - outside a git repository. -} |