spaceship has asked for the wisdom of the Perl Monks concerning the following question:
I do not understand how and what does the ~ do as it just seems to remove the ./ off the front off the script name.my $this_proc = $0 =~ /^.+\/(.+)$/ ? $1 : $0;
Thanks in advance
Janitored by Arunbear - added code tags, as per Monastery guidelines
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Regular expression problemette
by eibwen (Friar) on Apr 21, 2005 at 00:14 UTC | |
|
Re: Regular expression problemette
by tlm (Prior) on Apr 20, 2005 at 23:09 UTC | |
|
Re: Regular expression problemette
by bart (Canon) on Apr 21, 2005 at 00:44 UTC | |
|
Re: Regular expression problemette
by friedo (Prior) on Apr 21, 2005 at 00:05 UTC | |
|
Re: Regular expression problemette
by phaylon (Curate) on Apr 21, 2005 at 00:51 UTC | |
|
Re: Regular expression problemette
by spaceship (Initiate) on Apr 21, 2005 at 07:23 UTC |