in reply to Regular expression question

Frankly, I would not use a regexp for this (untested) :
my %opts; undef @opts{ qw|-config -files -params -driverPath -appPath -batchPath NONE| }; my %seen; for my $e (split /,/ $str) { print "BAD op: $e\n" unless exists $opts{$e}; print "Duplicate: $e\n" if $seen{$e}; print "Incompatible with NONE\n" if $seen{NONE} && scalar keys %see +n > 1; $seen{$e}; }

-Mark