summaryrefslogtreecommitdiff
path: root/Command/Status.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2016-01-20 14:07:13 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2016-01-20 14:10:13 -0400
commit0c4e0046e72aab8216e3fe7d3f4252b1a66e1211 (patch)
treeb977261e78042cc6b11d530578a47a0d25d21359 /Command/Status.hs
parentb51672003cf035ba4595f45746cac343d154266f (diff)
make noMessages disable closing of json object in --json mode
This allows things like Command.Find to use noMessages and generate their own complete json objects. Previouly, Command.Find managed that only via a hack, which wasn't compatable with batch mode. Only Command.Find, Command.Smudge, and Commange.Status use noMessages currently, and none except for Command.Find are impacted by this change. Fixes find --json --batch output
Diffstat (limited to 'Command/Status.hs')
-rw-r--r--Command/Status.hs9
1 files changed, 5 insertions, 4 deletions
diff --git a/Command/Status.hs b/Command/Status.hs
index 3feea7cb4..af0a1282f 100644
--- a/Command/Status.hs
+++ b/Command/Status.hs
@@ -17,10 +17,11 @@ import qualified Git.Ref
import Git.FilePath
cmd :: Command
-cmd = notBareRepo $ noCommit $ noMessages $ withGlobalOptions [jsonOption] $
- command "status" SectionCommon
- "show the working tree status"
- paramPaths (withParams seek)
+cmd = notBareRepo $ noCommit $ noMessages $
+ withGlobalOptions [jsonOption] $
+ command "status" SectionCommon
+ "show the working tree status"
+ paramPaths (withParams seek)
seek :: CmdParams -> CommandSeek
seek = withWords start