[Bps-public-commit] r10484 - bpsbuilder/Shipwright/lib/Shipwright/Script

sunnavy at bestpractical.com sunnavy at bestpractical.com
Thu Jan 24 17:23:23 EST 2008


Author: sunnavy
Date: Thu Jan 24 17:23:23 2008
New Revision: 10484

Modified:
   bpsbuilder/Shipwright/lib/Shipwright/Script/Import.pm

Log:
don't import req if we have --no-follow arg

Modified: bpsbuilder/Shipwright/lib/Shipwright/Script/Import.pm
==============================================================================
--- bpsbuilder/Shipwright/lib/Shipwright/Script/Import.pm	(original)
+++ bpsbuilder/Shipwright/lib/Shipwright/Script/Import.pm	Thu Jan 24 17:23:23 2008
@@ -66,8 +66,6 @@
         my ($name) = $self->source =~ m{.*/(.*)$};
         $imported{$name}++;
 
-        $self->import_req( $self->source, $shipwright );
-
         my $script_dir = tempdir( CLEANUP => 1 );
 
         if ( my $script = $self->build_script ) {
@@ -78,10 +76,14 @@
             $self->generate_build( $self->source, $script_dir, $shipwright );
         }
 
-        move(
-            File::Spec->catfile( $self->source, '__require.yml' ),
-            File::Spec->catfile( $script_dir,   'require.yml' )
-        ) or die "move __require.yml failed: $!";
+        unless ( $self->no_follow ) {
+            $self->import_req( $self->source, $shipwright );
+
+            move(
+                File::Spec->catfile( $self->source, '__require.yml' ),
+                File::Spec->catfile( $script_dir,   'require.yml' )
+            ) or die "move __require.yml failed: $!";
+        }
 
         $shipwright->backend->import(
             source  => $self->source,



More information about the Bps-public-commit mailing list