diff options
author | Ilya Zakharevich <ilya@math.ohio-state.edu> | 1997-07-28 16:23:32 +1200 |
---|---|---|
committer | Tim Bunce <Tim.Bunce@ig.co.uk> | 1997-09-05 00:00:00 +0000 |
commit | 0b166b6635cf199f072db516b2a523ee659394d5 (patch) | |
tree | 07b5203ceb675767e5220b43d9d15db7225a839a /utils | |
parent | 464ed3b648d262825ad1bfc5a2e55de2507fd651 (diff) | |
download | perl-0b166b6635cf199f072db516b2a523ee659394d5.tar.gz |
Perldoc tiny patch to avoid $0
Editing $0 may be not-so-portable.
Enjoy,
p5p-msgid: 199709122141.RAA16846@monk.mps.ohio-state.edu
Diffstat (limited to 'utils')
-rw-r--r-- | utils/perldoc.PL | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/utils/perldoc.PL b/utils/perldoc.PL index 38ea9ee5ca..0f43c36c1b 100644 --- a/utils/perldoc.PL +++ b/utils/perldoc.PL @@ -45,10 +45,11 @@ print OUT <<'!NO!SUBS!'; # the perl manuals, though it too is written in perl. if(@ARGV<1) { - $0 =~ s,.*/,,; + $me = $0; # Editing $0 is unportable + $me =~ s,.*/,,; die <<EOF; -Usage: $0 [-h] [-v] [-t] [-u] [-m] [-l] PageName|ModuleName|ProgramName - $0 -f PerlFunc +Usage: $me [-h] [-v] [-t] [-u] [-m] [-l] PageName|ModuleName|ProgramName + $me -f PerlFunc We suggest you use "perldoc perldoc" to get aquainted with the system. |