hgbook

changeset 161:7f07aca44938

Write up the unpleasant effects of change ef1f1a4b2efb in the hg tree.
author Bryan O'Sullivan <bos@serpentine.com>
date Mon Mar 26 21:58:24 2007 -0700 (2007-03-26)
parents 745ff473c8c4
children 3fb7a7841181 d3dd1bedba3c
files en/examples/filenames.glob.range.out en/filenames.tex
line diff
     1.1 --- a/en/examples/filenames.glob.range.out	Mon Mar 26 21:25:34 2007 -0700
     1.2 +++ b/en/examples/filenames.glob.range.out	Mon Mar 26 21:58:24 2007 -0700
     1.3 @@ -1,3 +1,7 @@
     1.4  $ \textbf{hg status 'glob:**[nr-t]'}
     1.5 +A examples/simple.py
     1.6  ? MANIFEST.in
     1.7 +? examples/performant.py
     1.8 +? src/watcher/_watcher.c
     1.9 +? src/watcher/watcher.py
    1.10  ? src/xyzzy.txt
     2.1 --- a/en/filenames.tex	Mon Mar 26 21:25:34 2007 -0700
     2.2 +++ b/en/filenames.tex	Mon Mar 26 21:58:24 2007 -0700
     2.3 @@ -152,6 +152,15 @@
     2.4  token.  This small example illustrates the difference between the two.
     2.5  \interaction{filenames.glob.star-starstar}
     2.6  
     2.7 +When you're writing a glob pattern, bear in mind that Mercurial will
     2.8 +treat a pattern that matches a directory name as ``match every file
     2.9 +under that directory''.  For example, a glob pattern of
    2.10 +``\texttt{**c}'' means \emph{both} ``match files ending in
    2.11 +`\texttt{c}''' ``any file under all directories that end in
    2.12 +`\texttt{c}'''.  I personally find this behaviour counterintuitive.
    2.13 +If you need to write a pattern that means ``match \emph{only} files'',
    2.14 +you'll need to express it as a regular expression instead; see below.
    2.15 +
    2.16  \subsection{Regular expression matching with \texttt{re} patterns}
    2.17  
    2.18  Mercurial accepts the same regular expression syntax as the Python