[Bps-public-commit] r12091 - in Shipwright/trunk/lib/Shipwright: Script
sunnavy at bestpractical.com
sunnavy at bestpractical.com
Tue May 6 04:04:58 EDT 2008
Author: sunnavy
Date: Tue May 6 04:04:57 2008
New Revision: 12091
Modified:
Shipwright/trunk/lib/Shipwright/Backend/SVK.pm
Shipwright/trunk/lib/Shipwright/Backend/SVN.pm
Shipwright/trunk/lib/Shipwright/Script/Import.pm
Log:
added version info when import
Modified: Shipwright/trunk/lib/Shipwright/Backend/SVK.pm
==============================================================================
--- Shipwright/trunk/lib/Shipwright/Backend/SVK.pm (original)
+++ Shipwright/trunk/lib/Shipwright/Backend/SVK.pm Tue May 6 04:04:57 2008
@@ -95,6 +95,11 @@
$self->log->info(
"import $args{source} to " . $self->repository );
$self->_add_to_order($name);
+ $self->version(
+ dist => $name,
+ version => $args{version},
+ );
+
Shipwright::Util->run(
$self->_cmd( import => %args, name => $name ) );
}
Modified: Shipwright/trunk/lib/Shipwright/Backend/SVN.pm
==============================================================================
--- Shipwright/trunk/lib/Shipwright/Backend/SVN.pm (original)
+++ Shipwright/trunk/lib/Shipwright/Backend/SVN.pm Tue May 6 04:04:57 2008
@@ -101,6 +101,11 @@
$self->log->info(
"import $args{source} to " . $self->repository );
$self->_add_to_order( $name );
+ $self->version(
+ dist => $name,
+ version => $args{version},
+ );
+
Shipwright::Util->run(
$self->_cmd( import => %args, name => $name ) );
}
Modified: Shipwright/trunk/lib/Shipwright/Script/Import.pm
==============================================================================
--- Shipwright/trunk/lib/Shipwright/Script/Import.pm (original)
+++ Shipwright/trunk/lib/Shipwright/Script/Import.pm Tue May 6 04:04:57 2008
@@ -43,7 +43,7 @@
);
}
-my %imported;
+my (%imported, $version);
=head2 run
=cut
@@ -106,6 +106,9 @@
)
);
+ $version =
+ Shipwright::Util::LoadFile( $shipwright->source->version_path );
+
my ($name) = $self->source =~ m{.*/(.*)$};
$imported{$name}++;
@@ -132,6 +135,7 @@
source => $self->source,
comment => $self->comment || 'import ' . $self->source,
overwrite => 1, # import anyway for the main dist
+ version => $version->{$name},
);
$shipwright->backend->import(
source => $self->source,
@@ -232,6 +236,7 @@
comment => 'deps for ' . $source,
source => $s,
overwrite => $self->overwrite,
+ version => $version->{$dist},
);
$shipwright->backend->import(
source => $s,
More information about the Bps-public-commit
mailing list