mirror of https://gerrit.osmocom.org/osmo-ci
OBS: move verify_feed to common
Prepare to move the 2021q1 feed from latest to nightly. Related: SYS#5370 Change-Id: I91e4c36d4a04d465fc9ccb933e8060511b7cd145
This commit is contained in:
parent
16f324618f
commit
58d02c5483
|
@ -280,3 +280,17 @@ osmo_obs_get_commit_version() {
|
||||||
|
|
||||||
echo -n "$version"
|
echo -n "$version"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Verify that $FEED is in $FEEDS
|
||||||
|
osmo_obs_verify_feed() {
|
||||||
|
local i
|
||||||
|
|
||||||
|
for i in $FEEDS; do
|
||||||
|
if [ "$i" = "$FEED" ]; then
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
echo "unsupported feed: $FEED"
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
|
@ -24,19 +24,6 @@ TOP=$(pwd)
|
||||||
DEBSRCDIR="$TOP/debsrc"
|
DEBSRCDIR="$TOP/debsrc"
|
||||||
FEED="${FEED:-latest}"
|
FEED="${FEED:-latest}"
|
||||||
|
|
||||||
verify_feed() {
|
|
||||||
local i
|
|
||||||
|
|
||||||
for i in $FEEDS; do
|
|
||||||
if [ "$i" = "$FEED" ]; then
|
|
||||||
return
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "unsupported feed: $FEED"
|
|
||||||
exit 1
|
|
||||||
}
|
|
||||||
|
|
||||||
### OBS build
|
### OBS build
|
||||||
prepare() {
|
prepare() {
|
||||||
# start with a checkout of the project
|
# start with a checkout of the project
|
||||||
|
@ -259,5 +246,5 @@ build_osmocom() {
|
||||||
osc ci -m "$FEED versions of $DT" --noservice
|
osc ci -m "$FEED versions of $DT" --noservice
|
||||||
}
|
}
|
||||||
|
|
||||||
verify_feed
|
osmo_obs_verify_feed
|
||||||
build_osmocom
|
build_osmocom
|
||||||
|
|
|
@ -11,6 +11,11 @@
|
||||||
. "$(dirname "$0")/common.sh"
|
. "$(dirname "$0")/common.sh"
|
||||||
. "$(dirname "$0")/common-obs.sh"
|
. "$(dirname "$0")/common-obs.sh"
|
||||||
|
|
||||||
|
FEEDS="
|
||||||
|
next
|
||||||
|
nightly
|
||||||
|
"
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
|
@ -19,11 +24,6 @@ OSMO_OBS_CONFLICT_PKGVER="$OSMO_OBS_CONFLICT_PKGVER.$DT"
|
||||||
TOP=$(pwd)/$(mktemp -d nightly-3g_XXXXXX)
|
TOP=$(pwd)/$(mktemp -d nightly-3g_XXXXXX)
|
||||||
FEED="${FEED:-nightly}"
|
FEED="${FEED:-nightly}"
|
||||||
|
|
||||||
if [ "$FEED" != "nightly" ] && [ "$FEED" != "next" ]; then
|
|
||||||
echo "unsupported feed: $FEED"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
### OBS build
|
### OBS build
|
||||||
prepare() {
|
prepare() {
|
||||||
# clean up the whole space
|
# clean up the whole space
|
||||||
|
@ -269,4 +269,5 @@ build_osmocom() {
|
||||||
post
|
post
|
||||||
}
|
}
|
||||||
|
|
||||||
|
osmo_obs_verify_feed
|
||||||
build_osmocom
|
build_osmocom
|
||||||
|
|
Loading…
Reference in New Issue