Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris

Returning regexp pattern that was used to match

by crabbdean (Pilgrim)
on May 03, 2004 at 14:18 UTC ( #350016=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download

  1. or download this
            '.*\.doc$'    => [qw/delete_me         1/],
            'dean'         => [qw/return_this        rel_file|stat_8/], 
            'F:/dean/     => ['mirror_to',        'C:\test']
  2. or download this
    sub do_this {
        my ($self, $args) = @_;
        $self->{find} = $string;    ## this is the string to match files a
        #print $self->{find};
  3. or download this
    if (/$self->{find}/) {
                    my $this = $&;
                    my $matched = ## find pattern used here
                    process($self, $_, $dir, $matched);

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://350016]
Approved by broquaint
[marto]: good morning all
[Corion]: Hi marto ;)
[Corion]: I hope you're well ;)
[marto]: running late today, get to work and people are just sitting around. "can't delete file, quota exceeded"
[Corion]: marto: Oy :-/
[Corion]: Ah, it's only "quota exceeded", not "filesystem full", so it's "merely" an administrative act to up the FS quota resp. inode quota
[Corion]: I've been on databases where I couldn't drop a table or delete rows because the DB was full. Not so much fun...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (7)
As of 2017-01-24 09:53 GMT
Find Nodes?
    Voting Booth?
    Do you watch meteor showers?

    Results (203 votes). Check out past polls.