Perl-Maker
view release on metacpan or search on metacpan
lib/Perl/Maker.pm view on Meta::CPAN
package Perl::Maker;
use 5.008003;
use strict;
use Mouse;
use YAML::XS;
use File::ShareDir;
use Getopt::Long;
use IPC::Run;
$Perl::Maker::VERSION = '0.01';
has action => (is => 'ro');
has args => (is => 'ro', default => sub {[]});
has file => (is => 'ro');
around BUILDARGS => sub {
my ($orig, $class, $script, @args) = @_;
my $hash = {};
while (1) {
if (not @args) {
$hash->{action} = 'help';
last;
}
if ($args[0] !~ /^-/) {
$hash->{action} = shift(@args);
last;
}
local @ARGV = @args;
GetOptions(
);
@args = @ARGV;
}
$hash->{file} = shift(@args) || '';
die "Extra arguments '@args'\n" if @args;
$class->$orig($hash);
};
sub run {
my $self = shift;
my $action = $self->action;
my $method = "handle_$action";
die "'action' command not supported\n"
unless $self->can($method);
$self->$method(@{$self->args});
}
sub handle_new {
my $self = shift;
}
sub handle_make {
my $self = shift;
}
sub write_makefile {
die "Perl::Maker does not work!\n";
}
1;
=enccoding utf8
=head1 NAME
Perl::Maker - Make a Custom Perl with Modules
=head1 SYNOPSIS
> perl-maker --make ingy-perl-maker.yaml
> make install
> make perlbrew
> make debian
> make dmg
> make rpm
> make msi
=head1 STATUS
This software is pre-alpha quality. Don't use it yet.
=head1 DESCRIPTION
Perl::Maker creates a custom Perl installation, complete with an
entire set of modules, based on a simple YAML specification. You can
share the installation as a system package (like Debian for instance).
( run in 1.593 second using v1.01-cache-2.11-cpan-e1769b4cff6 )