From 4fa841e2ca60ddc99a88138704471ac21596c066 Mon Sep 17 00:00:00 2001 From: Lukas Anzinger Date: Thu, 9 Jan 2014 14:12:11 +0100 Subject: [PATCH] The given $REPOS variable may also point to a suite, not only a codename Reprepro accepts suite names as aliases for codenames so we should do so too. --- scripts/generate-reprepro-codename | 2 +- scripts/remove-reprepro-codename | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/generate-reprepro-codename b/scripts/generate-reprepro-codename index a8620c1..e7a4775 100755 --- a/scripts/generate-reprepro-codename +++ b/scripts/generate-reprepro-codename @@ -65,7 +65,7 @@ fi ( flock --timeout 5 9 || bailout 1 "Error: could not lock file ${REPOSITORY}/conf/distributions, giving up." -if grep -q "^Codename: ${REPOS}$" "${REPOSITORY}"/conf/distributions ; then +if grep -q "^\(Codename\|Suite\): ${REPOS}$" "${REPOSITORY}"/conf/distributions ; then echo "Codename/repository $REPOS exists already, ignoring request to add again." exit 0 fi diff --git a/scripts/remove-reprepro-codename b/scripts/remove-reprepro-codename index 8495b23..53fb654 100755 --- a/scripts/remove-reprepro-codename +++ b/scripts/remove-reprepro-codename @@ -27,7 +27,7 @@ if ! [ -r "${REPOSITORY}/conf/distributions" ] ; then exit 1 fi -if ! grep -q "^Codename: ${codename}$" "${REPOSITORY}/conf/distributions" ; then +if ! grep -q "^\(Codename\|Suite\): ${codename}$" "${REPOSITORY}/conf/distributions" ; then echo "*** Codename $codename does not exist in ${REPOSITORY}/conf/distributions - nothing to do." exit 0 fi