diff options
Diffstat (limited to 'doc/git-annex.mdwn')
-rw-r--r-- | doc/git-annex.mdwn | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/doc/git-annex.mdwn b/doc/git-annex.mdwn index e73c08ca2..32c8ec266 100644 --- a/doc/git-annex.mdwn +++ b/doc/git-annex.mdwn @@ -705,12 +705,20 @@ subdirectories). # METADATA COMMANDS -* `metadata [path ...] [-s field=value -s field+=value -s field-=value ...]` +* `metadata [path ...] [-s field=value -s field+=value -s field-=value ...] [-g field]` Each file can have any number of metadata fields attached to it, - which each in turn have any number of values. This sets metadata - for the specified file or files, or if run without any values, shows - the current metadata. + which each in turn have any number of values. + + This command can be used to set metadata, or show the currently set + metadata. + + To show current metadata, run without any -s parameters. The --json + option will enable json output. + + To only get the value(s) of a single field, use -g field. + The values will be output one per line, with no other output, so + this is suitable for use in a script. To set a field's value, removing any old value(s), use -s field=value. |