Resurrect cpanget as a symlink to cpanspec

- Update the POD in cpanspec to document its use as cpanget
- Subclass Module::Build to create the symlinks to cpanspec and
  cpanspec.1p at build time.
This commit is contained in:
Dennis Kaarsemaker
2011-09-01 22:25:11 +02:00
parent e73f961c6a
commit 7eb1084445
3 changed files with 39 additions and 6 deletions
+16 -1
View File
@@ -2,7 +2,22 @@ use strict;
use warnings;
use Module::Build;
my $builder = Module::Build->new(
my $class = Module::Build->subclass(
class => 'CpanSpec::Build',
code => q{
use File::Basename qw(dirname);
use FindBin;
sub ACTION_build {
my $self = shift;
$self->SUPER::ACTION_build(@_);
symlink("cpanspec", "$FindBin::Bin/blib/script/cpanget");
symlink("cpanspec.1p", "$FindBin::Bin/blib/bindoc/cpanget.1p");
}
}
);
my $builder = $class->new(
dist_name => 'cpanspec',
license => 'perl',
dist_author => 'Steven Pritchard <steve@cpan.org>',