The json does not include an url field, but it does have an input field that is
"file url" when using --batch and ["file", "url"] when using the command line.
I chose not to change that because it would complicate batchInput.
An url field could be added if it turns out to be useful.
Sponsored-By: the NIH-funded NICEMAN (ReproNim TR&D3) project
of core.sharedRepository and umask.
* initremote: Avoid creating a remote that is not encrypted when gpg is
broken.
- * unannex: Support --json and --json-error-messages.
+ * rmurl, unannex: Support --json and --json-error-messages.
-- Joey Hess <id@joeyh.name> Sat, 08 Apr 2023 13:57:18 -0400
type Outputter = LogChange -> POSIXTime -> [UUID] -> Annex ()
cmd :: Command
-cmd = withAnnexOptions [annexedMatchingOptions] $
+cmd = withAnnexOptions [jsonOptions, annexedMatchingOptions] $
command "log" SectionQuery "shows location log"
paramPaths (seek <$$> optParser)
import Annex.WorkTree
cmd :: Command
-cmd = notBareRepo $
+cmd = notBareRepo $ withAnnexOptions [jsonOptions] $
command "rmurl" SectionCommon
"record file is not available at url"
(paramRepeating (paramPair paramFile paramUrl))
Makes the `--batch` input be delimited by nulls instead of the usual
newlines.
+* `--json`
+
+ Enable JSON output. This is intended to be parsed by programs that use
+ git-annex. Each line of output is a JSON object.
+
+* `--json-error-messages`
+
+ Messages that would normally be output to standard error are included in
+ the JSON instead.
+
* Also the [[git-annex-common-options]](1) can be used.
# SEE ALSO