'logfile=s', 'timeout=s',
'dist-opts=s%', 'set-config=s%',
'default-banlist!', 'set-program=s%',
- 'default-ignorelist!', 'edit-metafile!'
+ 'default-ignorelist!', 'edit-metafile!',
+ 'install!'
);
die usage() if exists $opts->{'help'};
}
- my $dist = eval {
+ my $target = $opts->{'install'} ? 'install' : 'create';
+ my $dist = eval {
local $SIG{ALRM} = sub { die bless {}, ALARM_CLASS }
if $timeout;
my $dist_opts = $opts->{'dist-opts'} || {};
my $rv = $obj->install(
- prereq_target => 'create',
- target => 'create',
+ prereq_target => $target,
+ target => $target,
keep_source => $keep,
prereq_build => $prereqbuild,
### take no argument:
--help Show this help message
+ --install Install this package (and any prerequisites you built)
+ after building it.
--skiptest Skip tests. Can be negated using --noskiptest
--force Force operation. Can be negated using --noforce
--verbose Be verbose. Can be negated using --noverbose
### don't bother running tests
cpan2dist --format CPANPLUS::Dist::Deb --buildprereq --skiptest DBI
+ ### build a debian package of DBI and it's prerequisites and install them
+ cpan2dist --format CPANPLUS::Dist::Deb --buildprereq --install DBI
+
### Build a package, whose format is determined by your config, of
### the local tarball, reloading cpanplus' indices first and using
### the tarballs Makefile.PL if it has one.