[Bps-public-commit] r9798 - bpsbuilder/BPB/lib/BPB/Script
sunnavy at bestpractical.com
sunnavy at bestpractical.com
Mon Dec 3 10:02:03 EST 2007
Author: sunnavy
Date: Mon Dec 3 10:02:01 2007
New Revision: 9798
Modified:
bpsbuilder/BPB/lib/BPB/Script/Import.pm
Log:
make the import order right
Modified: bpsbuilder/BPB/lib/BPB/Script/Import.pm
==============================================================================
--- bpsbuilder/BPB/lib/BPB/Script/Import.pm (original)
+++ bpsbuilder/BPB/lib/BPB/Script/Import.pm Mon Dec 3 10:02:01 2007
@@ -23,9 +23,11 @@
sub run {
my $self = shift;
+ my $source = shift;
+ $self->source( $source ) if $source;
my $bpb = BPB->new( config => $self->config, moniker => $self->moniker );
- $bpb->backend->import( map { $_, $self->$_ } qw/category comment source/ );
$self->import_req( $self->source, $bpb );
+ $bpb->backend->import( map { $_, $self->$_ } qw/category comment source/ );
}
my %imported;
@@ -33,7 +35,7 @@
sub import_req {
my $self = shift;
my $source = shift;
- my $bpb = shift;
+ my $bpb = shift;
my $require_file = File::Spec->catfile( $source, '_require.yml' );
if ( -e $require_file ) {
@@ -50,20 +52,19 @@
warn "we don't have $module in source which is for "
. $self->source
unless $dir;
+ $self->import_req( $source, $bpb );
$bpb->backend->import(
category => 'dependance',
comment => 'deps for ' . $source,
- source => File::Spec->catfile(
+ source => File::Spec->catfile(
$bpb->config->moniker->{source}{directory}, $dir
)
);
- $self->import_req( $source, $bpb );
}
-
}
}
-}
+}
1;
More information about the Bps-public-commit
mailing list