Fedora-App-ReviewTool
view release on metacpan or search on metacpan
lib/Fedora/App/ReviewTool/Command/submit.pm view on Meta::CPAN
my $end = DateTime->now;
my $dur = $start - $end;
# FIXME we should probably use DateTime::Format::Duration here
my ($min, $sec) = ($dur->minutes, $dur->seconds);
print "Koji build done; we took $min minutes, $sec seconds.\n\n";
if (!$self->_koji_success) {
die "KOJI SCRATCH FAILED! Correct and re-submit.\n\n "
. $self->_koji_uri . "\n\n"
;
}
}
# push to fedorapeople space
# FIXME yeah, I'd rather use Net::SSH2, but ssh-agent is easy...
print "Pushing package and spec to fedorapeople...\n";
$self->push_to_reviewspace($srpm_file, $spec);
print "...done.\n\n";
my $baseuri = $self->baseuri;
my $comment = $self->app->new_tix(
srpm => "$baseuri" . $srpm->rpm->basename,
spec => "$baseuri" . $spec->basename,
koji => $self->_koji_uri,
description => $self->repack($info->{description}),
version => $Fedora::App::ReviewTool::VERSION,
additional_comment => $self->additional_comment,
);
my $sum = $info->{summary};
print $self->app->verbose_submit(
bug => $info,
body => $comment,
);
unless ($self->yes || prompt 'Post for review? ', -YyNn1) {
print "Not posting $name for review.\n";
next SRPM_LOOP;
}
# create bug, etc
print "\nCreating bug...\n";
my $bug = $self->_bz->create_bug(
product => $test ? 'Bugzilla' : 'Fedora',
component => $test ? 'test' : 'Package Review',
version => $test ? 'devel' : 'rawhide',
assigned_to => 'nobody@fedoraproject.org', # easier than $test
#summary => "Review Request: $name - $sum",
summary => $self->gen_summary($srpm),
comment => $comment,
alias => $self->_alias($name),
dependson => $self->depends_on,
blocked => $self->blocks,
bug_file_loc => "$url",
);
print "...done.\n\nReview bug for $name is: $bug\n\n";
}
return;
}
1;
__END__
=head1 NAME
Fedora::App::ReviewTool::Command::submit - [submitter] submit a srpm for review
=head1 DESCRIPTION
Handles the various routine parts of submitting a package for review.
=over 4
=item B<koji scratch build>
=item B<push to publicly-accessible fedorapeople.org>
=item B<create a review bug on bugzilla>
=back
=head1 SUBROUTINES/METHODS
TODO/FIXME!
=head1 SEE ALSO
L<Fedora::App::ReviewTool>.
=head1 AUTHOR
Chris Weyl <cweyl@alumni.drew.edu>
=head1 LICENSE AND COPYRIGHT
Copyright (c) 2009 Chris Weyl <cweyl@alumni.drew.edu>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the
( run in 0.556 second using v1.01-cache-2.11-cpan-97f6503c9c8 )