1git-annex-matchexpression(1)General Commands Manualgit-annex-matchexpression(1)
2
3
4

NAME

6       git-annex-matchexpression - checks if an expression matches
7

SYNOPSIS

9       git annex matchexpression expression [data]
10

DESCRIPTION

12       This  plumbing-level  command  is given a preferred content expression,
13       and some data, and checks if the expression matches the data. It  exits
14       0 if it matches, and 1 if not. If not enough data was provided, it dis‐
15       plays an error and exits with special code 42.
16
17       For example, this will exit 0:
18
19        git   annex   matchexpression   "include=*.png   and   largerthan=1mb"
20       --file=foo.png --size=10mb
21

OPTIONS

23       --file=
24
25              Provide  the  filename to match against. Note that the file does
26              not have to actually exist on disk.
27
28       --size=
29              Tell what the size of the file is. The  size  can  be  specified
30              with  any  commonly  used  units,  for example, "0.5 gb" or "100
31              KiloBytes".
32
33       --key= Tell what key is being  matched  against.  This  is  needed  for
34              matching  expressions like "copies=N" and "metadata=tag=foo" and
35              "present", which all need to look up the information on file for
36              a key.
37
38              Many  keys  have  a known size, and so --size is not needed when
39              specifying such a key.
40
41       --largefiles
42              Parse the expression as an annex.largefiles  expression,  rather
43              than a preferred content expression.
44
45       --mimetype=
46              Tell  what  the mime type of the file is. Only needed when using
47              --largefiles with a mimetype= expression.
48
49       --mimeencoding=
50              Tell what the mime encoding of the file  is.  Only  needed  when
51              using --largefiles with a mimeencoding= expression.
52

SEE ALSO

54       git-annex(1)
55
56       git-annex-preferred-content(1)
57
58       git-annex-matching-expression(1)
59

AUTHOR

61       Joey Hess <id@joeyh.name>
62
63                                                  git-annex-matchexpression(1)
Impressum