r29487 - /trunk/dh-make-perl/lib/DhMakePerl/Config.pm
dmn at users.alioth.debian.org
dmn at users.alioth.debian.org
Fri Jan 9 14:24:11 UTC 2009
Author: dmn
Date: Fri Jan 9 14:24:08 2009
New Revision: 29487
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=29487
Log:
Config: add different set of defaults when invoked as 'cpan2deb'
Modified:
trunk/dh-make-perl/lib/DhMakePerl/Config.pm
Modified: trunk/dh-make-perl/lib/DhMakePerl/Config.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/dh-make-perl/lib/DhMakePerl/Config.pm?rev=29487&op=diff
==============================================================================
--- trunk/dh-make-perl/lib/DhMakePerl/Config.pm (original)
+++ trunk/dh-make-perl/lib/DhMakePerl/Config.pm Fri Jan 9 14:24:08 2009
@@ -38,6 +38,7 @@
'_explicitly_set',
);
+use File::Basename qw(basename);
use File::Spec::Functions qw(catfile);
use Getopt::Long;
use Tie::IxHash ();
@@ -55,11 +56,26 @@
verbose => 1,
};
+use constant cpan2deb_DEFAULTS => {
+ verbose => 0,
+ build => 1,
+
+ #recursive => 1,
+};
+
sub new {
my $class = shift;
my $values = shift || {};
- my $self = $class->SUPER::new( { %{ $class->DEFAULTS }, @_ } );
+ my $self = $class->SUPER::new(
+ { %{ $class->DEFAULTS },
+ ( ( basename($0) eq 'cpan2deb' )
+ ? %{ $class->cpan2deb_DEFAULTS }
+ : ()
+ ),
+ @_,
+ },
+ );
$self->_explicitly_set( {} );
More information about the Pkg-perl-cvs-commits
mailing list