[Bps-public-commit] r19036 - Shipwright/trunk/lib/Shipwright/Script

sunnavy at bestpractical.com sunnavy at bestpractical.com
Thu Apr 2 13:43:49 EDT 2009


Author: sunnavy
Date: Thu Apr  2 13:43:48 2009
New Revision: 19036

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

Log:
if no_follow, store an empty require.yml

Modified: Shipwright/trunk/lib/Shipwright/Script/Import.pm
==============================================================================
--- Shipwright/trunk/lib/Shipwright/Script/Import.pm	(original)
+++ Shipwright/trunk/lib/Shipwright/Script/Import.pm	Thu Apr  2 13:43:48 2009
@@ -189,7 +189,13 @@
 
             }
 
-            unless ( $self->no_follow ) {
+            if ( $self->no_follow ) {
+                open my $fh, '>', catfile( $script_dir, 'require.yml' ) or
+                    confess "can't write to $script_dir/require.yml: $!\n";
+                print $fh "---\n";
+                close $fh;
+            }
+            else {
                 $self->_import_req( $source, $shipwright, $script_dir );
 
                 if ( -e catfile( $source, '__require.yml' ) ) {



More information about the Bps-public-commit mailing list