From 677301bc8aeaf51b5c61b5377b6dfe0be0d55bf4 Mon Sep 17 00:00:00 2001 From: Hans-Christoph Steiner Date: Fri, 25 Apr 2025 22:22:35 +0200 Subject: [PATCH] gitlab-ci: make gradle job show files with trigger it For some reason, this logic thinks that this merge request has changed makebuildserver and/or gradlew-fdroid, though it clearly has not. This should shed some light on it. https://gitlab.com/fdroid/fdroidserver/-/jobs/9835383262 --- .gitlab-ci.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e4d922d0..b8b49c27 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -469,6 +469,8 @@ macOS: gradle: image: debian:bookworm-slim + rules: + - if: "$PERSONAL_ACCESS_TOKEN" <<: *apt-template variables: GIT_DEPTH: 1000 @@ -485,12 +487,15 @@ gradle: python3-requests # if this is a merge request fork, then only check if relevant files changed - if [ "$CI_PROJECT_NAMESPACE" != "fdroid" ]; then + set -x; git fetch https://gitlab.com/fdroid/fdroidserver.git; for f in `git diff --name-only --diff-filter=d FETCH_HEAD...HEAD`; do - test "$f" == "makebuildserver" && export CHANGED="yes"; - test "$f" == "gradlew-fdroid" && export CHANGED="yes"; + test "$f" == "makebuildserver" && export CHANGED="$f $CHANGED"; + test "$f" == "gradlew-fdroid" && export CHANGED="$f $CHANGED"; done; test -z "$CHANGED" && exit; + echo $CHANGED; + set +x; fi - ./tests/gradle-release-checksums.py