aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorMichal Hrusecky <michal.hrusecky@turris.com>2020-10-03 19:31:24 +0200
committerPaul Spooren <mail@aparcar.org>2020-10-10 11:16:13 -1000
commit7951e29297bd707949fdf9d2fc8f0920cdf2b381 (patch)
tree6e6eeb89bfbd3b70a89007754ae2152f35bd9f2c /.github
parent61c4202766bfcfd5091b7bd421934b65cab531a4 (diff)
CI: Export few helpful variables for CI tests
Export PKG_NAME and PKG_VERSION to make test scripts better readable and also export a path to the helper script providing colorful output. Signed-off-by: Michal Hrusecky <michal.hrusecky@turris.com>
Diffstat (limited to '.github')
-rwxr-xr-x.github/workflows/entrypoint.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/.github/workflows/entrypoint.sh b/.github/workflows/entrypoint.sh
index 7ec81c46d..37fb37323 100755
--- a/.github/workflows/entrypoint.sh
+++ b/.github/workflows/entrypoint.sh
@@ -4,6 +4,8 @@ mkdir -p /var/lock/
opkg update
+[ -n "$CI_HELPER" ] || CI_HELPER="/ci/.github/workflows/ci_helpers.sh"
+
for PKG in /ci/*.ipk; do
tar -xzOf "$PKG" ./control.tar.gz | tar xzf - ./control
# package name including variant
@@ -17,6 +19,8 @@ for PKG in /ci/*.ipk; do
opkg install "$PKG"
+ export PKG_NAME PKG_VERSION CI_HELPER
+
TEST_SCRIPT=$(find /ci/ -name "$PKG_SOURCE" -type d)/test.sh
if [ -f "$TEST_SCRIPT" ]; then