From 6d21a557af6e44808b506b210e125525cf8863e0 Mon Sep 17 00:00:00 2001 From: Michael Schroeder Date: Wed, 28 Nov 2018 14:08:42 +0100 Subject: [PATCH] Generate a .milestone artifact for kiwi product builds --- Build/Kiwi.pm | 1 + build-recipe-kiwi | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Build/Kiwi.pm b/Build/Kiwi.pm index ce02bc582..6e4e00b06 100644 --- a/Build/Kiwi.pm +++ b/Build/Kiwi.pm @@ -130,6 +130,7 @@ sub kiwiparse_product { for my $po (@{$productoptions->{'productoption'} || []}) { $ret->{'sourcemedium'} = $po->{'_content'} if $po->{'name'} eq 'SOURCEMEDIUM'; $ret->{'debugmedium'} = $po->{'_content'} if $po->{'name'} eq 'DEBUGMEDIUM'; + $ret->{'milestone'} = $po->{'_content'} if $po->{'name'} eq 'BETA_VERSION'; } } if ($instsource->{'architectures'}) { diff --git a/build-recipe-kiwi b/build-recipe-kiwi index 68b2d24f8..9a84af435 100644 --- a/build-recipe-kiwi +++ b/build-recipe-kiwi @@ -347,6 +347,7 @@ run_suse_isolinux() { } perform_product_bundle() { + local milestone=$(kiwi_query_recipe milestone) pushd $BUILD_ROOT/$TOPDIR/KIWIROOT/main for i in * ; do test -e "$i" || continue @@ -357,7 +358,10 @@ perform_product_bundle() { fi mv "$i" $BUILD_ROOT/$TOPDIR/KIWI/. ;; *.packages) mv $i $BUILD_ROOT/$TOPDIR/OTHER/. ;; - *.report) mv $i $BUILD_ROOT/$TOPDIR/OTHER/. ;; + *.report) + mv $i $BUILD_ROOT/$TOPDIR/OTHER/. + test -n "$milestone" && echo "$milestone" > $BUILD_ROOT/$TOPDIR/OTHER/${i%.report}.milestone + ;; scripts) ;; *0) ;; *) test -d $i -a "$drop_repo" != true && mv $i $BUILD_ROOT/$TOPDIR/KIWI/. ;;