diff options
author | Marcelo Leitner <mrl@mandriva.com> | 2007-01-25 13:18:15 +0000 |
---|---|---|
committer | Marcelo Leitner <mrl@mandriva.com> | 2007-01-25 13:18:15 +0000 |
commit | b7542886542c2805b26140d2a011acc897311e1e (patch) | |
tree | 5e9a7cd8f287a865006c24036e379b6c7de0eaf0 | |
parent | f2a011f58eb46a0c693a73fc054b77f29594c364 (diff) | |
download | mga-youri-core-b7542886542c2805b26140d2a011acc897311e1e.tar mga-youri-core-b7542886542c2805b26140d2a011acc897311e1e.tar.gz mga-youri-core-b7542886542c2805b26140d2a011acc897311e1e.tar.bz2 mga-youri-core-b7542886542c2805b26140d2a011acc897311e1e.tar.xz mga-youri-core-b7542886542c2805b26140d2a011acc897311e1e.zip |
- get_revisions should look only on the target media, not on all them.
This was preventing from uploading a stable release to main while having
a newer and beta one on testing, for example.
-rw-r--r-- | lib/Youri/Repository/Mandriva_upload.pm | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/lib/Youri/Repository/Mandriva_upload.pm b/lib/Youri/Repository/Mandriva_upload.pm index fd41ea4..9573eab 100644 --- a/lib/Youri/Repository/Mandriva_upload.pm +++ b/lib/Youri/Repository/Mandriva_upload.pm @@ -358,7 +358,7 @@ sub package_in_svn { my $svn_entry = $ctx->ls("$self->{_svn}/$srpm_name", 'HEAD', 0); if ($svn_entry) { - print "Package $_ is in the SVN\n"; + print "Package $srpm_name is in the SVN\n"; return 1 } } @@ -376,15 +376,12 @@ sub get_revisions { my $arch = $user_context->{arch} || $package->get_arch(); my $media_arch = $arch eq 'noarch' ? $self->{_noarch} : $arch; my $path = $arch eq 'src' ? "$target/SRPMS/" : "$target/$media_arch/media"; - my $media = $self->_get_media_config($target); - my @packages; + my $media = $self->_get_section($package, $target, $user_context, $app_context); my $name = $package->get_name(); - foreach my $m (keys %{$media->{$media_arch}}) { - push @packages, - map { $self->get_package_class()->new(file => $_) } + my @packages = map { $self->get_package_class()->new(file => $_) } $self->get_files( $self->{_install_root}, - "$path/$m", + "$path/$media", $self->get_package_class()->get_pattern( $name, undef, @@ -392,7 +389,6 @@ sub get_revisions { $arch, ) ); - } @packages = grep { $filter->($_) } @packages if $filter; |