libmodule-starter-perl-1.710+dfsg.orig/0000755000175000017500000000000012556531230017272 5ustar gregoagregoalibmodule-starter-perl-1.710+dfsg.orig/MANIFEST0000644000175000017500000000144112556531230020423 0ustar gregoagregoaChanges
MANIFEST
Makefile.PL
README
bin/module-starter
lib/Module/Starter.pm
lib/Module/Starter/App.pm
lib/Module/Starter/Simple.pm
lib/Module/Starter/BuilderSet.pm
lib/Module/Starter/Plugin.pod
lib/Module/Starter/Plugin/Template.pm
t/00-load.t
t/pod-coverage.t
t/pod.t
t/module-starter.t
t/test-dist.t
t/BuilderSet.t
t/lib/Module/Starter/TestPlugin.pm
t/data/templates/Module.pm
t/data/templates/t/boilerplate.t
t/data/templates/t/pod.t
t/data/templates/t/pod-coverage.t
t/data/templates/t/00-load.t
t/data/templates/Makefile.PL
t/data/templates/Changes
t/data/templates/Build.PL
t/data/templates/README
t/test-dist.t
perlcriticrc
META.yml Module YAML meta-data (added by MakeMaker)
META.json Module JSON meta-data (added by MakeMaker)
libmodule-starter-perl-1.710+dfsg.orig/Changes0000644000175000017500000002654712462674444020616 0ustar gregoagregoaRevision history for Perl extension Module::Starter
1.71 Fri Jan 30 13:28:31 2015
* GH #47: create_t breaks plugins. (David Pottage)
1.70 Tue Jan 20 20:56:31 2015
* Change the url for issues from rt.cpan.org to GitHub (David Pottage)
* Added a missing module to prerequisites (David Pottage)
* Marked t/pod* test scripts as RELEASE_TESTING (David Pottage)
* Moved boilerplate test to xt/ directory (David Pottage)
* Added a --fatalize option to generate code where warnings are fatal
This changes the default behaviour, as fatal warnings are now considered
unwise for any public module that many others depend on.
See: http://blogs.perl.org/users/peter_rabbitson/2014/01/fatal-warnings-are-a-ticking-time-bomb-via-chromatic.html
1.62 Sun Dec 8 11:49:21 2013
* Fix regexp in tests to stop failing on 5.8.x (Sawyer X).
* Fix FSF address in template block and tests (Brian Manning).
* Typo fixes (David Steinbrunner).
1.61 Fri Dec 6 14:01:19 2013
* Stop getpwuid calls on Windows, instead prompt user for author.
(Martin McGrath)
1.60 Thu Oct 25 20:29:50 2012
* Guess author from getpwuid if not provided (Hilko Bengen).
* Guess email from $ENV{'EMAIL'} if not provided (Hilko Bengen).
1.59 Thu Oct 25 19:54:05 2012
* Skip POD tests unless RELEASE_TESTING environment is on.
(Alberto Simoes)
1.58_03 Fri May 11 16:24:44 2012
-- Trying to clean up test failures. More to come.
1.58_02 Wed Apr 25 12:53:34 2012
-- All changes in this release are by Brendan Byrd (SineSwiper).
Thank you! :)
Licenses:
* Add GPL3 licenses (fixes RT #72321).
* Add all other supported licenses, including Software::License
support (fixes RT #68634).
New Params:
* Make ignores_type an arrayref (closes Pull Request #8).
* Add new --ignores parameter (also repeatable).
* Add new --minperl parameter (Minimum Perl version).
File Creation:
* Fix MANIFEST.SKIP to skip creation of MANIFEST.
* Make all warnings FATAL in created .t/.pm files.
* Add config/build requires to Makefile/Build.PL.
* Bulk up Module::Install Makefile.PL.
* Fix ignores_guts to use different contents for MANIFEST.SKIP and
other ignore files.
test-dist.t Revamp:
* Complete refactor of test-dist.t to make it more standardized.
* Create new TestParseFile::parse_file_start method that handles
parsing of all current created file types (outside of .pm files).
* Use subtest for better organization.
* Add verification that existing files are there and no new surprise
files are not there.
* Add new mega-loop to "test all variations of everything" (uses 1%
sample size to keep test speed fast for average users).
* Use .gitignore and MANIFEST.SKIP.
1.58_01
* Fix repository URL by Shlomi Fish (GH #7).
1.58 Sat Jul 2 15:58:46 2011
* Added prereq on Path::Class (RT #68360).
* Doc fixes by Nicholas Bamber and Salvatore Bonaccorso (RT #68385).
1.57 Tue Apr 12 11:07:01 IDT 2011
* No functional changes.
* Removing English from unnecessary tests that confuse a tester.
1.56 Thu Apr 7 17:01:11 IDT 2011
* No functional changes, productionizing.
1.55_01 Fri Jun 11 16:56:00 IDT 2010
Special thanks goes to Andy Lester, who has been, still is and
will remain an inspiration to many programmers, myself included.
[ENHANCEMENTS]
Added hooks for distribution building in App. Thanks to brian d foy.
MANIFEST is now created via the proper builder.
Kept create_MANIFEST to act as hook.
Added Apache license by pfig.
* [RT #53539] Refactoring, adding hooks, described above.
(Patch provided by brian d. foy)
* [RT #27304] Minimal version of perl (5.006)
(Patch provided by Alexandr Ciornii)
* [RT #53339] ::Simple uses the builder to create the MANIFEST
* Moved repository to Github
* Some more refactoring in Simple::create_builder()
1.54 Tue Dec 8 09:11:00 CST 2009
This release could not have happened without Sawyer X.
[ENHANCEMENTS]
Added more exclusions. Thanks to Olivier Mengué.
* [RT #45941] Correcting POD sections for Perl Critic (Sawyer X)
* [RT #13847] Bail out if load fails, minimum Test::Harness (Sawyer X)
* [RT #24110] Support for Test::CheckManifest + tests for it (Sawyer X)
* [RT #22648] Pod::Parser (Pod::Usage) >= 1.21 (Sawyer X)
(earliest Backpan version tested to work)
* [RT #48723] Add metadata to META.yml (Sawyer X)
(Patch provided by Olivier Mengué, thank you!)
* [RT #39397] Add option to create .gitignore (Sawyer X)
1.52 Mon Jul 27 01:25:03 CDT 2009
* Support for more licenses. Thanks to Shlomi Fish.
* Fix slashing problems for Windows. Thanks Olivier Mengué.
* Complains about extra unparsed options to try to detect
problems that come out of misquoted variables. Thanks to Gunnar Wolf.
* The list of files to ignore is now called ignore.txt,
which you can turn into .cvsignore, .gitignore, MANIFEST.SKIP
or whatever.
* Handles authors with apostrophes in their names better.
Thanks to, not surprisingly, Dave O'Neill.
* Removed module requirements on Test::Pod and Test::Pod::Coverage
for Module::Starter to be built and installed. However,
t/pod.t and t/pod-coverage.t do still both get created even
if either of their two main modules are not installed.
1.50 Tue Oct 28 00:27:37 CDT 2008
* Added Perl Training Australia's getting-started.html
* Add license setting to default Makefile.PL output (Thanks, Gabor!)
* Fixed the RT link in the boilerplate. (Thanks, Shlomi)
1.46 Fri Nov 9 18:36 America/New_York 2007
[ENHANCEMENTS]
* add Module::Install compat for ::Template plugin
* boilerplate.t no longer appears in default MANIFEST
* META.yml no longer appears in default MANIFEST
[FIXES]
* undo some bugs introduced by changing API of subclassable "guts"
methods
* remove some duplicated code
1.46 Wed Oct 31 08:49 America/New_York 2007
* put nearly all of the module-starter program into a module (to test)
* add license to META.yml
1.44 Sun Oct 11 19:09 America/New_York 2007
* no changes since 1.43_03
1.43_03
[FIXES]
* pod-coverage.t includes Pod::Coverage version check
* Test::Pod and Test::Pod::Coverage are now requirements.
Thanks, David Golden.
1.43_02 Wed Apr 25 09:37-Wed May 09 14:46 PDT 2007
[ENHANCEMENTS]
* broke Module::Starter::Simple's README_guts and module_guts
methods into smaller, override-able pieces
* re-factored Module::Starter::Simple's build system; the
build metadata now lives in Module::Starter::BuildSet. This
allows us access to the metadata from the test suite. It
also makes it a bit easier to add supported builders.
* added a test Plugin module (based on Module::Starter::PBP)
* wrote a test suite for running module-starter
* wrote a test suite for Module::Starter::BuildSet
* modified the critic Makefile target to name the policy which
raised the violation
* Split most long lines (>80 chars) on whitespace
[FIXES]
* Ensured that perlcritic succeeds without errors or warnings
* Added perlcriticrc to the MANIFEST
* corrected build -> builder in module-starter --help docs
1.43_01 Wed Mar 28 12:21:00 EDT 2007
[FIXES]
* Now properly reports on all files in --verbose mode.
[ENHANCEMENTS]
* Add support for Module::Install
1.42 Wed Nov 9 11:25:10 CST 2005
[FIXES]
* Don't build Build.PL or Makefile.PL multiple times
* Move Test::More from require to build_require in Build.PL
[ENHANCEMENTS]
* Documentation now includes references to search.cpan, AnnoCPAN,
RT and CPAN Ratings.
* Email addresses are now obfuscated very basically as
"andy at petdance.com".
* Include boilerplate.t to notice unchanged boilerplate text
* Experimental new method to handle plugin loading
1.40 Wed Jul 6 19:30:00 CDT 2005
[FIXES]
* Document --dir option to module-starter
* Proper escaping of $] and $^X
* Never use \ for path delimiters in {Makefile,Build}.PL
* Don't always completely ignore --license
1.38 Wed Mar 16 20:28:00 CST 2005
[FIXES]
* Don't allow invalid module names
1.36 Mon Mar 7 08:38:00 CST 2005
[FIXES]
* 00.load.t is now 00-load.t, so VMS and RiscOS folks can use it.
* Escape apostrophes in author name in Makefile.PL
* Add a link directly to this dist's queue in RT, not just to RT
* Don't set configdir to something in $HOME if it's undef
1.34 Mon Sep 20 19:15:00 CDT 2004
[ENHANCEMENTS]
* module-starter now reads a config file
1.30 Mon Aug 16 14:00:00 CDT 2004
[ENHANCEMENTS]
* Module::Starter is now merely a public interface to plugins
* Module::Starter::Simple, the old M::S is now a plugin
* Module::Starter::Plugin::Template added
* module-starter now shows usage if no parms are passed.
* The t/pod.t and t/pod-coverage.t files now use tainting,
and require the appropriate versions of Test::Pod and
Test::Pod::Coverage, respectively.
1.22 Mon Jul 12 17:05:26 CDT 2004
[FIXES]
* Another fix to inline POD, to cope with brain damage in Pod::Parser
1.20 Sun Jul 11 22:28:57 CDT 2004
[ENHANCEMENTS]
* Moved some data (distro, basedir) from parameters to object data
* Moved some data (rtname) from routine-local to parameter data
* Correted lies in POD regarding args to create_distro
* Every create_file method now calls a file_guts method to get
contents.
* All the quoted POD inline should now not render in perldoc.
* The module-build script now respects --class
* Minor refactoring of parameters to create_directory and _module
* Everything is now an overridable object method. Thanks to
Ricardo Signes.
* Added verbose() method.
* Added progress() method so subclass can decide how progress
is reported.
All of the above is courtesy the diligent work of Ricard Signes.
[DOCUMENTATION]
* Large expansion of POD (Starter.pm and module-starter)
1.00 Fri Jun 25 17:57:31 CDT 2004
[ENHANCEMENTS]
* Added a README file. The README file is somewhat intelligently
constructed, too.
* Now you can specify both EU::MM and M::B as your builders,
so the module can have a double life.
Thanks to Sébastien Aperghis-Tramonifor the help.
0.04 Mon Apr 5 20:45:58 CDT 2004
[ENHANCEMENTS]
* Added support for Module::Build. Thanks, Randy Sims.
0.02 Thu Feb 26 00:11:57 CST 2004
First real version, released on an unsuspecting world.
libmodule-starter-perl-1.710+dfsg.orig/README0000644000175000017500000000126612334432332020154 0ustar gregoagregoaNAME
Module::Starter - a simple starter kit for any module
Module::Starter is used to create a skeletal CPAN distribution,
including basic builder scripts, tests, documentation, and module code.
For more information, refer to the documentation for module-starter,
Module::Starter, and Module::Starter::Simple.
AUTHORS
Andy Lester, ""
Ricardo Signes, ""
C.J. Adams-Collier, ""
COPYRIGHT
Copyright 2004-7 Andy Lester, Ricardo Signes, C.J. Adams-Collier,
All Rights Reserved.
This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.
libmodule-starter-perl-1.710+dfsg.orig/perlcriticrc0000644000175000017500000000117512334432332021703 0ustar gregoagregoa[-CodeLayout::ProhibitParensWithBuiltins]
[CodeLayout::ProhibitHardTabs]
allow_leading_tabs = 0
[-ControlStructures::ProhibitPostfixControls]
[-Documentation::RequirePodAtEnd]
[-Documentation::RequirePodSections]
[-InputOutput::ProhibitInteractiveTest]
[-InputOutput::ProhibitBacktickOperators]
[-Miscellanea::RequireRcsKeywords]
[-Modules::RequireVersionVar]
[-NamingConventions::ProhibitMixedCaseSubs]
[-RegularExpressions::RequireExtendedFormatting]
[-RegularExpressions::RequireLineBoundaryMatching]
[-ValuesAndExpressions::ProhibitEmptyQuotes]
[-Variables::ProhibitPunctuationVars]
[-BuiltinFunctions::ProhibitStringyEval]
libmodule-starter-perl-1.710+dfsg.orig/t/0000755000175000017500000000000012462674660017550 5ustar gregoagregoalibmodule-starter-perl-1.710+dfsg.orig/t/pod.t0000644000175000017500000000060512334432332020502 0ustar gregoagregoa#!perl -T
use strict;
use warnings;
use Test::More;
BEGIN {
unless ($ENV{RELEASE_TESTING}) {
require Test::More;
Test::More::plan(skip_all => 'these tests are for release candidate testing');
}
}
# Ensure a recent version of Test::Pod
my $min_tp = 1.22;
eval "use Test::Pod $min_tp";
plan skip_all => "Test::Pod $min_tp required for testing POD" if $@;
all_pod_files_ok();
libmodule-starter-perl-1.710+dfsg.orig/t/lib/0000755000175000017500000000000012462674660020316 5ustar gregoagregoalibmodule-starter-perl-1.710+dfsg.orig/t/lib/Module/0000755000175000017500000000000012462674660021543 5ustar gregoagregoalibmodule-starter-perl-1.710+dfsg.orig/t/lib/Module/Starter/0000755000175000017500000000000012462674660023167 5ustar gregoagregoalibmodule-starter-perl-1.710+dfsg.orig/t/lib/Module/Starter/TestPlugin.pm0000644000175000017500000005341712334432332025617 0ustar gregoagregoapackage Module::Starter::TestPlugin; # Module::Starter::PBP
use base 'Module::Starter::Simple';
use version; $VERSION = qv('0.0.3');
use warnings;
use strict;
use Carp;
sub module_guts {
my $self = shift;
my %context = (
'MODULE NAME' => shift,
'RT NAME' => shift,
'DATE' => scalar localtime,
'YEAR' => $self->_thisyear(),
);
return $self->_load_and_expand_template('Module.pm', \%context);
}
sub Makefile_PL_guts {
my $self = shift;
my %context = (
'MAIN MODULE' => shift,
'MAIN PM FILE' => shift,
'DATE' => scalar localtime,
'YEAR' => $self->_thisyear(),
);
return $self->_load_and_expand_template('Makefile.PL', \%context);
}
sub Build_PL_guts {
my $self = shift;
my %context = (
'MAIN MODULE' => shift,
'MAIN PM FILE' => shift,
'DATE' => scalar localtime,
'YEAR' => $self->_thisyear(),
);
return $self->_load_and_expand_template('Build.PL', \%context);
}
sub Changes_guts {
my $self = shift;
my %context = (
'DATE' => scalar localtime,
'YEAR' => $self->_thisyear(),
);
return $self->_load_and_expand_template('Changes', \%context);
}
sub README_guts {
my $self = shift;
my %context = (
'BUILD INSTRUCTIONS' => shift,
'DATE' => scalar localtime,
'YEAR' => $self->_thisyear(),
);
return $self->_load_and_expand_template('README', \%context);
}
sub t_guts {
my $self = shift;
my @modules = @_;
my %context = (
'DATE' => scalar localtime,
'YEAR' => $self->_thisyear(),
);
my %t_files;
for my $test_file ( map { s{\A .*/t/}{}xms; $_; }
glob "$self->{template_dir}/t/*" ) {
$t_files{$test_file}
= $self->_load_and_expand_template("t/$test_file", \%context);
}
my $nmodules = @modules;
my $main_module = $modules[0];
my $use_lines = join( "\n", map { "use_ok( '$_' );" } @modules );
$t_files{'00-load.t'} = <<"END_LOAD";
use Test::More tests => $nmodules;
BEGIN {
$use_lines
}
diag( "Testing $main_module \$${main_module}::VERSION" );
END_LOAD
return %t_files;
}
sub _load_and_expand_template {
my ($self, $rel_file_path, $context_ref) = @_;
@{$context_ref}{map {uc} keys %$self} = values %$self;
die "Can't find directory that holds Module::Starter::PBP templates\n",
"(no 'template_dir: ' in config file)\n"
if not defined $self->{template_dir};
die "Can't access Module::Starter::PBP template directory\n",
"(perhaps 'template_dir: $self->{template_dir}' is wrong in config file?)\n"
if not -d $self->{template_dir};
my $abs_file_path = "$self->{template_dir}/$rel_file_path";
die "The Module::Starter::PBP template: $rel_file_path\n",
"isn't in the template directory ($self->{template_dir})\n\n"
if not -e $abs_file_path;
die "The Module::Starter::PBP template: $rel_file_path\n",
"isn't readable in the template directory ($self->{template_dir})\n\n"
if not -r $abs_file_path;
open my $fh, '<', $abs_file_path or croak $!;
local $/;
my $text = <$fh>;
$text =~ s{<([A-Z ]+)>}
{ $context_ref->{$1}
|| die "Unknown placeholder <$1> in $rel_file_path\n"
}xmseg;
return $text;
}
sub import {
my $class = shift;
my ($setup, @other_args) = @_;
# If this is not a setup request,
# refer the import request up the hierarchy...
if (@other_args || !$setup || $setup ne 'setup') {
return $class->SUPER::import(@_);
}
# Otherwise, gather the necessary tools...
use ExtUtils::Command qw( mkpath );
use File::Spec;
local $| = 1;
# Locate the home directory...
if (!defined $ENV{HOME}) {
print 'Please enter the full path of your home directory: ';
$ENV{HOME} = <>;
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;
if ( -e $config_file ) {
print {*STDERR} "Backing up $config_file...";
my $backup
= File::Spec->catfile( $ENV{HOME}, '.module-starter', 'config.bak' );
rename($config_file, $backup);
print {*STDERR} "done.\n";
print {*STDERR} "Updating $config_file...";
open my $fh, '<', $backup or die "$config_file: $!\n";
@config_info
= grep { not /\A (?: template_dir | plugins ) : /xms } <$fh>;
close $fh or die "$config_file: $!\n";
}
else {
print {*STDERR} "Creating $config_file...\n";
my $author = _prompt_for('your full name');
my $email = _prompt_for('an email address');
@config_info = (
"author: $author\n",
"email: $email\n",
"builder: ExtUtils::MakeMaker Module::Build\n",
);
print {*STDERR} "Writing $config_file...\n";
}
push @config_info, (
"plugins: Module::Starter::PBP\n",
"template_dir: $template_dir\n",
);
open my $fh, '>', $config_file or die "$config_file: $!\n";
print {$fh} @config_info or die "$config_file: $!\n";
close $fh or die "$config_file: $!\n";
print {*STDERR} "done.\n";
print {*STDERR} "Installing templates...\n";
# Then install the various files...
my @files = (
['Build.PL'],
['Makefile.PL'],
['README'],
['Changes'],
['Module.pm'],
['t', 'pod-coverage.t'],
['t', 'pod.t'],
['t', 'perlcritic.t'],
);
my %contents_of = do { local $/; "", split /_____\[ (\S+) \]_+\n/, };
for (values %contents_of) {
s/^!=([a-z])/=$1/gxms;
}
for my $ref_path ( @files ) {
my $abs_path
= File::Spec->catfile( $ENV{HOME}, '.module-starter', 'PBP', @{$ref_path} );
print {*STDERR} "\t$abs_path...";
open my $fh, '>', $abs_path or die "$abs_path: $!\n";
print {$fh} $contents_of{$ref_path->[-1]} or die "$abs_path: $!\n";
close $fh or die "$abs_path: $!\n";
print {*STDERR} "done\n";
}
print {*STDERR} "Installation complete.\n";
exit;
}
sub _prompt_for {
my ($requested_info) = @_;
my $response;
RESPONSE: while (1) {
print "Please enter $requested_info: ";
$response = <>;
if (not defined $response) {
warn "\n[Installation cancelled]\n";
exit;
}
$response =~ s/\A \s+ | \s+ \Z//gxms;
last RESPONSE if $response =~ /\S/;
}
return $response;
}
1; # Magic true value required at end of module
=pod
=head1 NAME
Module::Starter::PBP - Create a module as recommended in "Perl Best Practices"
=head1 VERSION
This document describes Module::Starter::PBP version 0.0.3
=head1 SYNOPSIS
# In your ~/.module-starter/config file...
author:
email:
plugins: Module::Starter::PBP
template_dir:
# Then on the command-line...
> module-starter --module=Your::New::Module
# Or, if you're lazy and happy to go with
# the recommendations in "Perl Best Practices"...
> perl -MModule::Starter::PBP=setup
=head1 DESCRIPTION
This module implements a simple approach to creating modules and their support
files, based on the Module::Starter approach. Module::Starter needs to be
installed before this module can be used.
When used as a Module::Starter plugin, this module allows you to specify a
simple directory of templates which are filled in with module-specific
information, and thereafter form the basis of your new module.
The default templates that this module initially provides are based on
the recommendations in the book "Perl Best Practices".
=head1 INTERFACE
Thsi module simply acts as a plugin for Module::Starter. So it uses the same
command-line interface as that module.
The template files it is to use are specified in your Module::Starter
C file, by adding a C configuration variable that
gives the full path name of the directory in which you want to put
the templates.
The easiest way to set up this C file, the associated directory, and
the necessary template files is to type:
> perl -MModule::Starter::PBP=setup
on the command line. You will then be asked for your name, email address, and
the full path name of the directory where you want to keep the templates,
after which they will be created and installed.
Then you can create a new module by typing:
> module-starter --module=Your::New::Module
=head2 Template format
The templates are plain files named:
Build.PL
Makefile.PL
README
Changes
Module.pm
t/whatever_you_like.t
The C file is the template for the C<.pm> file for your module. Any
files in the C subdirectory become the templates for the testing files of
your module. All the remaining files are templates for the ditribution files
of the same names.
In those files, the following placeholders are replaced by the appropriate
information specific to the file:
=over
=item
The nominated author. Taken from the C setting in
your Module::Starter C file.
=item
Makefile or Module::Build instructions. Computed automatically according to
the C setting in your Module::Starter C file.
=item
The current date (as returned by C). Computed automagically
=item
The name of the complete module distribution. Computed automatically from the
name of the module.
=item
Where to send feedback. Taken from the C setting in
your Module::Starter C file.
=item
The licence under which the module is released. Taken from the C
setting in your Module::Starter C file.
=item
The name of the main module of the distribution.
=item
The name of the C<.pm> file for the main module.
=item
The name of the current module being created within the distribution.
=item