From 511725d29a1351c74a9e96024e6c35a0cdbd8408 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Wed, 19 Jan 2022 23:22:30 +0100 Subject: [PATCH] Small tweaks to ease buster/bullseye cohabitation/transition --- daily-build | 4 ++-- ynh-build | 12 +++++++++++- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/daily-build b/daily-build index f657ca2..a5c4680 100755 --- a/daily-build +++ b/daily-build @@ -43,8 +43,8 @@ function build_if_needed() local DISTRIB=$2 local LAST_BUILD_FOR_THIS_PACKAGE=$LAST_BUILDS_CACHE/${DISTRIB}_${PACKAGE} - BRANCH_NIGHTLY="$DISTRIB" - [[ $DISTRIB == "buster" ]] && BRANCH_NIGHTLY="dev" + [[ $DISTRIB == "buster" ]] && BRANCH_NIGHTLY="buster" + [[ $DISTRIB == "bullseye" ]] && BRANCH_NIGHTLY="dev" cd $GIT_REPOS/$PACKAGE diff --git a/ynh-build b/ynh-build index 725b990..a54480c 100755 --- a/ynh-build +++ b/ynh-build @@ -3,10 +3,20 @@ readonly THISSCRIPT=$0 readonly PROJECT=$1 readonly BRANCH=$2 -readonly DISTRIB="buster" readonly VERSION=$3 readonly TAG=$(echo "debian/$VERSION" | tr '~' '-') +if [[ "$(echo $VERSION | awk -F'.' '{print $1}')" == "4" ]] +then + readonly DISTRIB="buster" +elif [[ "$(echo $VERSION | awk -F'.' '{print $1}')" == "11" ]] +then + readonly DISTRIB="bullseye" +else + readonly DISTRIB="fixyoversionnumberbruh" +fi + + source /home/vinaigrette/config/config source /home/vinaigrette/scripts/common.sh