version fixup

BRANCH was missing in the generate_targets.sh script.

Signed-off-by: Paul Spooren <mail@aparcar.org>
pull/65/head
Paul Spooren 2020-09-10 21:04:49 -10:00
parent 962d0fb6c0
commit c3b582b50e
5 changed files with 11 additions and 10 deletions

View File

@ -19,10 +19,8 @@
generate-targets:
stage: generate_targets
script: |
git clone --depth 1 --branch "$BRANCH" https://github.com/openwrt/openwrt.git
cd openwrt/
bash ../generate_targets.sh
script:
- bash ./generate_targets.sh
artifacts:
paths:
- targets.yml

View File

@ -10,10 +10,8 @@ export DOWNLOAD_FILE="openwrt-imagebuilder*x86_64.tar.xz"
if [ "$VERSION" == "snapshot" ]; then
DOWNLOAD_PATH="snapshots/targets/$(echo "$TARGET" | tr '-' '/')"
export BRANCH="master"
else
DOWNLOAD_PATH="releases/$VERSION/targets/$(echo "$TARGET" | tr '-' '/')"
export BRANCH="openwrt-$VERSION"
fi
export DOWNLOAD_PATH

View File

@ -11,10 +11,8 @@ export DOCKERFILE="Dockerfile.rootfs"
if [ "$VERSION" = "snapshot" ]; then
DOWNLOAD_PATH="snapshots/targets/$(echo "$TARGET" | tr '-' '/')"
export BRANCH="master"
else
DOWNLOAD_PATH="releases/$VERSION/targets/$(echo "$TARGET" | tr '-' '/')"
export BRANCH="openwrt-$VERSION"
fi
export DOWNLOAD_PATH

View File

@ -12,10 +12,8 @@ export DOWNLOAD_FILE="openwrt-sdk-*.Linux-x86_64.tar.xz"
if [ "$VERSION" == "snapshot" ]; then
DOWNLOAD_PATH="snapshots/targets/$(echo "$TARGET" | tr '-' '/')"
export BRANCH="master"
else
DOWNLOAD_PATH="releases/$VERSION/targets/$(echo "$TARGET" | tr '-' '/')"
export BRANCH="openwrt-$VERSION"
fi
export DOWNLOAD_PATH

View File

@ -1,5 +1,14 @@
#!/bin/sh
if [ "$VERSION" = "snapshot" ]; then
export BRANCH="master"
else
export BRANCH="openwrt-$VERSION"
fi
git clone --depth 1 --branch "$BRANCH" https://github.com/openwrt/openwrt.git
cd openwrt/ || exit 1
gen_targets_sdk() {
perl ./scripts/dump-target-info.pl architectures | while read -r LINE; do
ARCH=$(echo "$LINE" | cut -d ' ' -f 1)