Dist-Man
view release on metacpan - search on metacpan
view release on metacpan or search on metacpan
lib/Dist/Man/Simple.pm view on Meta::CPAN
sub create_basedir {
my $self = shift;
# Make sure there's no directory
if ( -e $self->{basedir} ) {
die( "$self->{basedir} already exists. ".
"Use --force if you want to stomp on it.\n"
) unless $self->{force};
local @ARGV = $self->{basedir};
rm_rf();
die "Couldn't delete existing $self->{basedir}: $!\n"
if -e $self->{basedir};
}
CREATE_IT: {
$self->progress( "Created $self->{basedir}" );
local @ARGV = $self->{basedir};
mkpath();
die "Couldn't create $self->{basedir}: $!\n" unless -d $self->{basedir};
}
return;
}
=head2 create_modules( @modules )
t/dist-man-app.t view on Meta::CPAN
use Carp;
use lib './t/lib';
use TestParseFile;
my $module_base_dir =
File::Spec->catdir("t", "data", "mymodule-dir")
;
{
local @ARGV = (qw(setup --mb --module=MyModule::Test),
"--dir=$module_base_dir",
qw(--distro=MyModule-Test --author=ShlomiFish
--email=shlomif@cpan.org --license=mit --verbose
),
);
Dist::Man::App->run();
}
{
t/lib/Dist/Man/TestPlugin.pm view on Meta::CPAN
chomp $ENV{HOME};
croak 'Not a valid directory. Aborting.'
if !-d $ENV{HOME};
}
# Create the directories...
my $template_dir
= File::Spec->catdir( $ENV{HOME}, '.module-starter', 'PBP' );
if ( not -d $template_dir ) {
print {*STDERR} "Creating $template_dir...";
local @ARGV = $template_dir;
mkpath;
print {*STDERR} "done.\n";
}
my $template_test_dir
= File::Spec->catdir( $ENV{HOME}, '.module-starter', 'PBP', 't' );
if ( not -d $template_test_dir ) {
print {*STDERR} "Creating $template_test_dir...";
local @ARGV = $template_test_dir;
mkpath;
print {*STDERR} "done.\n";
}
# Create or update the config file (making a backup, of course)...
my $config_file
= File::Spec->catfile( $ENV{HOME}, '.module-starter', 'config' );
my @config_info;
view all matches for this distributionview release on metacpan - search on metacpan
( run in 0.842 second using v1.00-cache-2.02-grep-82fe00e-cpan-c9a218a2bbc )