glob instead of regexp (was: Re: [PATCH 0 of 4] Add locate command)

Thomas Arendsen Hein thomas at intevation.de
Tue Jul 12 20:52:13 UTC 2005


* Dan Christensen <jdc at uwo.ca> [20050712 21:34]:
> Thomas Arendsen Hein <thomas at intevation.de> writes:
> > I suggest:
> > /foo matches from the repo root
> > foo matches anywhere
> > foo/ matches directory foo
> > *?[ works like in the shell: stop at slashes, quoted with \
> 
> rsync adds "**" which matches "/" as well.

I know, and in fact I added it to the above list, but removed it
again before posting. I think if someone really needs something more
complicated than plain glob patterns, regexps are the way to go.

But maybe I thought too much from a programmer's point of view:
The python glob module doesn't support rsync's ** notation.

Thomas

-- 
Email: thomas at intevation.de
http://intevation.de/~thomas/



More information about the Mercurial mailing list