S
Steve Linberg
For whatever reason, I'm suffering a massive brain cramp today and I
just can't figure this simple thing out, and I'm already embarrassed
about it so please don't rub it in too hard. Digging through man
pages, google, and the Camel isn't putting an answer in front of me that
my addled head can grok. If anybody can supply a hefty dope-slap for
what I'm sure is a simple task, I'd be most appreciative.
I just need a regexp that says "match any complete string not equal to
'mysql' or 'test'."
I can't use "!~ /^(mysql|test)$/" because this is an argument to feed to
a script that uses a positive search and puts the regexp in
$opt{regexp}, for use as in "=~ /$opt{regexp}/". Yes, I can hack the
script, but I'd rather not if I can avoid it.
The specific task is for mysqlhotcopy, where you can provide a regexp
for databases to dump. I want to tell it to dump everything EXCEPT
"mysql" and "test", so I need a single positive regexp that matches
everything except those two strings. For the life of me, I just can't
get my brain to spit it out.
(holding still for dope-slap)
TIA.
just can't figure this simple thing out, and I'm already embarrassed
about it so please don't rub it in too hard. Digging through man
pages, google, and the Camel isn't putting an answer in front of me that
my addled head can grok. If anybody can supply a hefty dope-slap for
what I'm sure is a simple task, I'd be most appreciative.
I just need a regexp that says "match any complete string not equal to
'mysql' or 'test'."
I can't use "!~ /^(mysql|test)$/" because this is an argument to feed to
a script that uses a positive search and puts the regexp in
$opt{regexp}, for use as in "=~ /$opt{regexp}/". Yes, I can hack the
script, but I'd rather not if I can avoid it.
The specific task is for mysqlhotcopy, where you can provide a regexp
for databases to dump. I want to tell it to dump everything EXCEPT
"mysql" and "test", so I need a single positive regexp that matches
everything except those two strings. For the life of me, I just can't
get my brain to spit it out.
(holding still for dope-slap)
TIA.