aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS2
-rw-r--r--lib/Iurt/Emi.pm10
2 files changed, 9 insertions, 3 deletions
diff --git a/NEWS b/NEWS
index f41fd62..8869cea 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,5 @@
+- emi: skip all posts for non finishers instead of hardcoding a list
+
0.6.27
- emi: fix a bug where genhdlist2 was skipped when doing a secondary upload
containing a noarch at the same time as some other uploads
diff --git a/lib/Iurt/Emi.pm b/lib/Iurt/Emi.pm
index 9e326e1..9e98125 100644
--- a/lib/Iurt/Emi.pm
+++ b/lib/Iurt/Emi.pm
@@ -136,10 +136,14 @@ sub upload_prefix_in_media {
return unless @packages;
$user ||= $config->{upload_user};
- # FIXME we want to skip all post, we should not hardcode them here
- my $skip = $o_finish ? "" : "--skip-post genhdlist2 --skip-post mirror --skip-post clean_rpmsrate";
- my $command = "/usr/bin/perl -I/usr/share/mga-youri-submit/lib /usr/share/mga-youri-submit/bin/youri-submit --verbose --config /etc/youri/submit-upload.conf --define user=$user --define prefix=$prefix --define section=$media $skip $target @packages &> $done$path/$youri_file";
+ my $base_command = "/usr/bin/perl -I/usr/share/mga-youri-submit/lib /usr/share/mga-youri-submit/bin/youri-submit --config /etc/youri/submit-upload.conf";
+ my $all_posts = `$base_command --list posts $target`;
+ $all_posts =~ s/\n/ /g;
+ $all_posts =~ s/(^| +)/ --skip-post /g;
+ $all_posts =~ s/--skip-post *$//;
+ my $skip = $o_finish ? "" : $all_posts;
+ my $command = "$base_command --verbose --define user=$user --define prefix=$prefix --define section=$media $skip $target @packages &> $done$path/$youri_file";
plog('DEBUG', "running $command");
if (!system($command)) {
plog('INFO', "upload succeeded");