From cd2ea60fbd9c4fbfcb5ffe328325258a6715fb7b Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Wed, 25 Sep 2019 15:47:57 +0200 Subject: [PATCH] script to release into Univention AppCenter: currently new app is created and 19.1 changelog is uploaded --- doc/rpm-build/release-appcenter.sh | 61 ++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100755 doc/rpm-build/release-appcenter.sh diff --git a/doc/rpm-build/release-appcenter.sh b/doc/rpm-build/release-appcenter.sh new file mode 100755 index 0000000000..9710a54fb1 --- /dev/null +++ b/doc/rpm-build/release-appcenter.sh @@ -0,0 +1,61 @@ +#!/bin/bash + +# To update univention-appcenter-control run: +# curl https://provider-portal.software-univention.de/appcenter-selfservice/univention-appcenter-control > ~/bin/univention-appcenter-control + +version=19.1 +packaging=`date +%Y%m%d` +# default is now Docker! +postfix='' +project=stylite-epl + +while [ $# -gt 0 ] +do + case "$1" in + "--packaging") + packaging=$2 + shift; shift + ;; + "--postfix") + postfix=$2 + shift; shift + ;; + "--debug") + debug=echo + shift + ;; + "--help") + echo "Usage: release-appcenter [--packaging ] [--postfix -docker] [--debug] [--help]" + echo " --packaging specifiy packaging, default current date '$packaging'" + echo " --postfix eg. '-docker' used to find old package to copy and appended to packaging" + echo " --debug only echo out (modifying commands), does NOT execute them" + exit 0 + ;; + esac +done + +#echo "version=$version, packaging=$packaging, postfix=$postfix, debug=$debug" + +[ ! -f ~/download/archives/egroupware-$version/egroupware-docker-$version.$packaging.tar.bz2 ] && { + echo "No $version.$packaging packages found!" + echo "You probably need to use --packaging " + exit 1 +} + +ucs=4.4 + +univention-appcenter-control list | tee /tmp/ucs-apps | egrep "$ucs/egroupware=$version.$packaging$postfix" || { + copy_app=$(cat /tmp/ucs-apps | egrep "$ucs/egroupware=$version\.[0-9.]+$postfix$" | tail -1) + [ -z "$copy_app" ] && copy_app=$ucs/egroupware + $debug univention-appcenter-control new-version $copy_app $ucs/egroupware=$version.$packaging$postfix +} + +# only use 19.1 part of changelog +sed '/egroupware-epl/q' $(dirname $0)/debian.changes | sed -e '$ d' | \ +# converting changelog to html with

version

  • ...
+sed -e 's/egroupware-docker (/

/g' \ + -e 's/) hardy; urgency=low/<\/h3>
    /g' \ + -e 's/^ -- .*/<\/ul>/g' \ + -e 's/^ \* \(.*\)/
  • \1<\/li>/g' > /tmp/README_UPDATE + +$debug univention-appcenter-control upload $ucs/egroupware=$version.$packaging$postfix /tmp/README_UPDATE