diff --exclude format
Matt Mackall
mpm at selenic.com
Wed Jun 2 21:53:26 CDT 2010
On Thu, 2010-06-03 at 12:48 +1000, Matthew Watson wrote:
> Hi Guys,
>
> I'm trying to write and extension and I'm calling commands.diff and
> I'm passing a --exclude option. I'm trying to figure out from the doco
> what the format of this "pattern" is: Seems to variously take shell
> type globs or regexps with varying results.
>
> OK, so I can't find doco really, so I looked through the source. Seems
> the best way is to specify what it is by saying:
>
> --exclude "re:regexp"
> or
> --exclude "glob:shellglob"
>
> Is the only doco for this to be got by reading _patsplit in mercurial/match.py??
hg help patterns
> FYI: I' trying to cope with weird file names that may have regex/glob
> shars in them, so was calling re.escape(path), but this produce
> "\.hgignore" for input of ".hgignore" which isn't good on windows
> because the glob format thinks this is a path separator (works fine on
> mac though). Finally figured out I should prepend "re:" and treat the
> whole as a regexp.
path:
--
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial-devel
mailing list