# $Id: Reorder.pm 1688 2007-06-28 22:44:16Z guillomovitch $ package Youri::Submit::Action::Reorder; =head1 NAME Youri::Submit::Action::Reorder - Reorder packages with source first =head1 DESCRIPTION This action ensures that the source package is the first in the list. =cut use warnings; use strict; use Carp; use base qw/Youri::Submit::Step/; sub process_packages { my ($self, $packages, $repository, $target, $context) = @_; croak "Not a class method" unless ref $self; $packages = [ grep { $_->is_source() } @$packages, grep { !$_->is_source() } @$packages, ]; } =head1 COPYRIGHT AND LICENSE Copyright (C) 2002-2006, YOURI project This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. =cut 1;