Nautilus pattern matching.
James "Doc" Livingston
doclivingston at gmail.com
Sat Jul 8 12:24:09 BST 2006
On 7/8/06, Klaus Bitto <klaus.bitto at gmail.com> wrote:
> For the Regex thing, there has to be two modesm one of which uses simple
> pattern matching for non-geeks.
What exactly would "simple" be? I can think of several variants, and
supporting more than two (simple and regexp) would be heading towards
insane to use.
1) Contains exactly what the user entered. So "foo bar" would match any
file with "foo bar" in the name.
2) Contains the words the user entered. So "foo bar" would match any
file with the words "foo" and "bar" in the name
3) Windows-style pattern matching.
Personally I don't think (3) would be a great option because it's not
really simpler than regexps, just different (although many dos/windows
people may know then).
(2) is handy for searching in many things, such as music or email, but
I'm not sure how much more useful than (1) it would be for searching
filenames.
On Sat, 2006-07-08 at 11:53 +0100, Aigars Mahinovs wrote:
> That is another either another option or there must be a way to tell a
> simple pattern matching and a regex apart just by what the user enters
> into the box. The simplest way would be to require to include the
> regex in <> for example.
Starting with forward-slash is probably better, because it is guaranteed
not to be in any file name and isn't a special regexp character, so
won't ever be in a valid filename regexp. It also happens to be the same
character vi uses for a regexp search.
Cheers,
James "Doc" Livingston
--
If you wish to live wisely, ignore sayings -- including this one.
More information about the ubuntu-devel
mailing list