Mercurial > public > mercurial-scm > hg-stable
diff mercurial/help/patterns.txt @ 25284:7072b91ccd20
help: add documentation on include: and subinclude:
Adds some help text about the new include: and subinclude: match syntax.
author | Durham Goode <durham@fb.com> |
---|---|
date | Wed, 20 May 2015 14:54:09 -0700 |
parents | f1a3ae7c15df |
children | 88358446da16 |
line wrap: on
line diff
--- a/mercurial/help/patterns.txt Sat May 16 16:25:05 2015 -0700 +++ b/mercurial/help/patterns.txt Wed May 20 14:54:09 2015 -0700 @@ -30,6 +30,12 @@ feeds. Each string read from the file is itself treated as a file pattern. +To read a set of patterns from a file, use ``include:`` or ``subinclude:``. +``include:`` will use all the patterns from the given file and treat them as if +they had been passed in manually. ``subinclude:`` will only apply the patterns +against files that are under the subinclude file's directory. See :hg:`help +hgignore` for details on the format of these files. + All patterns, except for ``glob:`` specified in command line (not for ``-I`` or ``-X`` options), can match also against directories: files under matched directories are treated as matched. @@ -60,3 +66,9 @@ listfile0:list.txt read list from list.txt with null byte delimiters See also :hg:`help filesets`. + +Include examples:: + + include:path/to/mypatternfile reads patterns to be applied to all paths + subinclude:path/to/subignorefile reads patterns specifically for paths in the + subdirectory