From 9b2b5a920dc1b44088705131d6bb6763a7539224 Mon Sep 17 00:00:00 2001 From: Eric Chanudet Date: Mon, 28 Sep 2015 19:22:19 +0200 Subject: [PATCH] [upgrade] upgradable version globbing Accept bash globbing to describe versions from which upgrade is supported, for that release. Signed-off-by: Eric Chanudet OXT-380 --- part2/stages/Find-existing-install | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/part2/stages/Find-existing-install b/part2/stages/Find-existing-install index 78a97f7..6d9271e 100755 --- a/part2/stages/Find-existing-install +++ b/part2/stages/Find-existing-install @@ -55,9 +55,7 @@ is_upgradeable_release() RELEASE="$1" for CHECK in ${UPGRADEABLE_RELEASES} ; do - [ "${CHECK}" != "*" ] || return 0 - - if [ "${RELEASE}" = "${CHECK}" ] ; then + if [ -z "${RELEASE%%${CHECK}}" ] ; then echo "Upgrade allowed from detected release: ${RELEASE}" >&2 return 0 fi