export: Added options for json output
Just worked, no need to do anything except add the options.
This commit is contained in:
parent
bbdba72624
commit
fc9833f68d
4 changed files with 26 additions and 3 deletions
|
@ -1,3 +1,9 @@
|
||||||
|
git-annex (8.20200523) UNRELEASED; urgency=medium
|
||||||
|
|
||||||
|
* export: Added options for json output.
|
||||||
|
|
||||||
|
-- Joey Hess <id@joeyh.name> Tue, 26 May 2020 10:20:52 -0400
|
||||||
|
|
||||||
git-annex (8.20200522) upstream; urgency=medium
|
git-annex (8.20200522) upstream; urgency=medium
|
||||||
|
|
||||||
* Fix bug that made enableremote of S3 and webdav remotes, that
|
* Fix bug that made enableremote of S3 and webdav remotes, that
|
||||||
|
|
|
@ -44,7 +44,8 @@ import qualified Data.Map as M
|
||||||
import Control.Concurrent
|
import Control.Concurrent
|
||||||
|
|
||||||
cmd :: Command
|
cmd :: Command
|
||||||
cmd = command "export" SectionCommon
|
cmd = withGlobalOptions [jsonOptions, jsonProgressOption] $
|
||||||
|
command "export" SectionCommon
|
||||||
"export content to a remote"
|
"export content to a remote"
|
||||||
paramTreeish (seek <$$> optParser)
|
paramTreeish (seek <$$> optParser)
|
||||||
|
|
||||||
|
|
|
@ -86,6 +86,20 @@ so the overwritten modification is not lost.)
|
||||||
the remote. You can later run `git annex sync --content` to upload
|
the remote. You can later run `git annex sync --content` to upload
|
||||||
the files to the export.
|
the files to the export.
|
||||||
|
|
||||||
|
* `--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-progress`
|
||||||
|
|
||||||
|
Include progress objects in JSON output.
|
||||||
|
|
||||||
|
* `--json-error-messages`
|
||||||
|
|
||||||
|
Messages that would normally be output to standard error are included in
|
||||||
|
the json instead.
|
||||||
|
|
||||||
# EXAMPLE
|
# EXAMPLE
|
||||||
|
|
||||||
git annex initremote myremote type=directory directory=/mnt/myremote \
|
git annex initremote myremote type=directory directory=/mnt/myremote \
|
||||||
|
|
|
@ -2,3 +2,5 @@ Pretty much to mimic `copy` in terms of its interfaceability with external comma
|
||||||
|
|
||||||
[[!meta author=yoh]]
|
[[!meta author=yoh]]
|
||||||
[[!tag projects/datalad]]
|
[[!tag projects/datalad]]
|
||||||
|
|
||||||
|
> easy one.. [[done]] --[[Joey]]
|
||||||
|
|
Loading…
Add table
Reference in a new issue