diff options
author | Joey Hess <joeyh@joeyh.name> | 2016-02-27 10:55:02 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2016-02-27 10:55:02 -0400 |
commit | 00361f2bf9da7bb8244445eae2bcee5487c809d1 (patch) | |
tree | 5236ede82937a35ae4e2ff94cbc1aa0619c420f6 /doc | |
parent | f684572aef9d12cf0881ce6cfc053a87579182a3 (diff) |
Support --metadata field<number, --metadata field>number etc to match ranges of numeric values.
Similarly (well, for free), support preferred content expressions like
metadata=field<number and metadata=field>number
Diffstat (limited to 'doc')
-rw-r--r-- | doc/git-annex-matching-options.mdwn | 9 | ||||
-rw-r--r-- | doc/git-annex-preferred-content.mdwn | 9 | ||||
-rw-r--r-- | doc/preferred_content.mdwn | 1 |
3 files changed, 19 insertions, 0 deletions
diff --git a/doc/git-annex-matching-options.mdwn b/doc/git-annex-matching-options.mdwn index 34cc05c6a..d94c0faf1 100644 --- a/doc/git-annex-matching-options.mdwn +++ b/doc/git-annex-matching-options.mdwn @@ -115,6 +115,15 @@ file contents are present at either of two repositories. matches the glob. The values of metadata fields are matched case insensitively. +* `--metadata field<number` / `--metadata field>number` +* `--metadata field<=number` / `--metadata field>=number` + + Matches only files that have a metadata field attached with a value that + is a number and is less than or greater than the specified number. + + (Note that you will need to quote the second parameter to avoid + the shell doing redirection.) + * `--want-get` Matches files that the preferred content settings for the repository diff --git a/doc/git-annex-preferred-content.mdwn b/doc/git-annex-preferred-content.mdwn index bea82654f..5e2a7a9c5 100644 --- a/doc/git-annex-preferred-content.mdwn +++ b/doc/git-annex-preferred-content.mdwn @@ -119,6 +119,15 @@ elsewhere to allow removing it). To match author metadata, use `metadata=author=*Smith` +* `metadata=field<number` / `metadata=field>number` +* `metadata=field<=number` / `metadata=field>=number` + + Matches only files that have a metadata field attached with a value that + is a number and is less than or greater than the specified number. + + To match PDFs with between 100 and 200 pages (assuming something has set + that metadata), use `metadata=pagecount>=100 and metadata=pagecount<=200` + * `present` Makes content be wanted if it's present, but not otherwise. diff --git a/doc/preferred_content.mdwn b/doc/preferred_content.mdwn index f8c6ce6cd..d7b9870e5 100644 --- a/doc/preferred_content.mdwn +++ b/doc/preferred_content.mdwn @@ -67,3 +67,4 @@ they were added in. * "metadata=" 5.20140221 * "lackingcopies=", "approxlackingcopies=", "unused=" 5.20140127 * "inpreferreddir=" 4.20130501 +* "metadata=field<number" etc 6.20160227 |