[Bps-public-commit] r12296 - in Shipwright/trunk: lib/Shipwright/Source
sunnavy at bestpractical.com
sunnavy at bestpractical.com
Tue May 13 10:34:51 EDT 2008
Author: sunnavy
Date: Tue May 13 10:34:50 2008
New Revision: 12296
Modified:
Shipwright/trunk/ (props changed)
Shipwright/trunk/lib/Shipwright/Source/CPAN.pm
Log:
r12336 at sunnavys-mb: sunnavy | 2008-05-13 22:01:16 +0800
undo tmp change
Modified: Shipwright/trunk/lib/Shipwright/Source/CPAN.pm
==============================================================================
--- Shipwright/trunk/lib/Shipwright/Source/CPAN.pm (original)
+++ Shipwright/trunk/lib/Shipwright/Source/CPAN.pm Tue May 13 10:34:50 2008
@@ -26,26 +26,26 @@
my $class = shift;
my $self = $class->SUPER::new(@_);
-# CPAN::Config->use;
-#
-# mkdir File::Spec->catfile( $cpan_dir, 'CPAN' );
-# my $config_file = File::Spec->catfile( $cpan_dir, 'CPAN', 'MyConfig.pm' );
-#
-# unless ( -f $config_file ) {
-# $CPAN::Config->{cpan_home} = File::Spec->catfile($cpan_dir);
-# $CPAN::Config->{build_dir} = File::Spec->catfile( $cpan_dir, 'build' );
-# $CPAN::Config->{histfile} =
-# File::Spec->catfile( $cpan_dir, 'histfile' );
-# $CPAN::Config->{keep_source_where} =
-# File::Spec->catfile( $cpan_dir, 'sources' );
-# $CPAN::Config->{prefs_dir} = File::Spec->catfile( $cpan_dir, 'prefs' );
-# $CPAN::Config->{prerequisites_policy} = 'follow';
-# $CPAN::Config->{urllist} = [];
-# write_file( $config_file,
-# Data::Dumper->Dump( [$CPAN::Config], ['$CPAN::Config'] ) );
-#
-# }
-# require CPAN::MyConfig;
+ CPAN::Config->use;
+
+ mkdir File::Spec->catfile( $cpan_dir, 'CPAN' );
+ my $config_file = File::Spec->catfile( $cpan_dir, 'CPAN', 'MyConfig.pm' );
+
+ unless ( -f $config_file ) {
+ $CPAN::Config->{cpan_home} = File::Spec->catfile($cpan_dir);
+ $CPAN::Config->{build_dir} = File::Spec->catfile( $cpan_dir, 'build' );
+ $CPAN::Config->{histfile} =
+ File::Spec->catfile( $cpan_dir, 'histfile' );
+ $CPAN::Config->{keep_source_where} =
+ File::Spec->catfile( $cpan_dir, 'sources' );
+ $CPAN::Config->{prefs_dir} = File::Spec->catfile( $cpan_dir, 'prefs' );
+ $CPAN::Config->{prerequisites_policy} = 'follow';
+ $CPAN::Config->{urllist} = [];
+ write_file( $config_file,
+ Data::Dumper->Dump( [$CPAN::Config], ['$CPAN::Config'] ) );
+
+ }
+ require CPAN::MyConfig;
return $self;
}
More information about the Bps-public-commit
mailing list