| 1 |
#!/usr/bin/env perl |
| 2 |
# pmls -- show date stamp of module |
| 3 |
|
| 4 |
# ------ pragmas |
| 5 |
use strict; |
| 6 |
use warnings; |
| 7 |
|
| 8 |
our $VERSION = '2.1.0'; |
| 9 |
|
| 10 |
BEGIN { $^W = 1 } |
| 11 |
|
| 12 |
# ------ define variable |
| 13 |
my $module = undef; # module name |
| 14 |
|
| 15 |
use FindBin qw($Bin); |
| 16 |
|
| 17 |
unless (@ARGV) { |
| 18 |
die "usage: $0 module ...\n"; |
| 19 |
} |
| 20 |
for $module (@ARGV) { |
| 21 |
if ( $^O eq "MSWin32" ) { |
| 22 |
my $path = `$^X -S $Bin/pmpath $module`; |
| 23 |
$path =~ s/\//\\/g; |
| 24 |
system "dir " . $path; |
| 25 |
} else { |
| 26 |
system "ls -l " . `$^X -S $Bin/pmpath $module`; |
| 27 |
} |
| 28 |
} |
| 29 |
|
| 30 |
__END__ |
| 31 |
|
| 32 |
=head1 NAME |
| 33 |
|
| 34 |
pmls - long list the module path |
| 35 |
|
| 36 |
=head1 DESCRIPTION |
| 37 |
|
| 38 |
This is mostly here for people too lazy to type |
| 39 |
|
| 40 |
$ ls -l `pmpath CGI` |
| 41 |
|
| 42 |
=head1 EXAMPLES |
| 43 |
|
| 44 |
$ pmls CGI |
| 45 |
-r--r--r-- 1 root root 190901 Dec 6 03:19 |
| 46 |
/usr/local/devperl/lib/5.00554/CGI.pm |
| 47 |
|
| 48 |
|
| 49 |
$ oldperl -S pmls CGI |
| 50 |
-r--r--r-- 1 root root 186637 Sep 10 00:18 |
| 51 |
/usr/lib/perl5/CGI.pm |
| 52 |
|
| 53 |
=head1 SEE ALSO |
| 54 |
|
| 55 |
pmpath(1) |
| 56 |
|
| 57 |
=head1 AUTHORS and COPYRIGHTS |
| 58 |
|
| 59 |
Copyright (C) 1999 Tom Christiansen. |
| 60 |
|
| 61 |
Copyright (C) 2006-2018 Mark Leighton Fisher. |
| 62 |
|
| 63 |
=head1 LICENSE |
| 64 |
|
| 65 |
This is free software; you can redistribute it and/or modify it |
| 66 |
under the terms of either: |
| 67 |
(a) the GNU General Public License as published by the Free |
| 68 |
Software Foundation; either version 1, or (at your option) any |
| 69 |
later version, or |
| 70 |
(b) the Perl "Artistic License". |
| 71 |
(This is the Perl 5 licensing scheme.) |
| 72 |
|
| 73 |
Please note this is a change from the |
| 74 |
original pmtools-1.00 (still available on CPAN), |
| 75 |
as pmtools-1.00 were licensed only under the |
| 76 |
Perl "Artistic License". |