From d615b900dde4a36ebf67e1b3b5320df494fd0b74 Mon Sep 17 00:00:00 2001 From: Filip Leonarski Date: Mon, 3 Aug 2026 20:52:52 +0200 Subject: [PATCH] ci: correct the tools the viewer archive is said to carry, and two dead conditions rugnux_scale and azint have not been separate binaries since they became rugnux --scale and rugnux --azint-only; the viewer component carries rugnux, jfjoch_extract_hkl and jfjoch_recompress. Two job conditions tested github.ref_type against 'workflow_dispatch'. ref_type is only ever 'branch' or 'tag', so that test never matched and never did anything: build-rpm's whole condition was that test, and half of the unit-test one was. Both jobs ran on a dispatch, as the release flow needs them to. Drop the dead tests rather than repair them - the behaviour they read as intending is not the behaviour that is wanted - and write down why unit-tests is skipped on a tag, which is the part that is deliberate: the dispatch run is the one that tests, and the tag it creates only rebuilds and uploads. Co-Authored-By: Claude Opus 5 (1M context) --- .gitea/workflows/build_and_test.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.gitea/workflows/build_and_test.yml b/.gitea/workflows/build_and_test.yml index 6d8c5b37..ff8241e9 100644 --- a/.gitea/workflows/build_and_test.yml +++ b/.gitea/workflows/build_and_test.yml @@ -43,7 +43,11 @@ jobs: unit-tests: name: Unit tests runs-on: jfjoch_rocky8 - if: github.ref_type != 'tag' && github.ref_type != 'workflow_dispatch' + # Not on a tag, on purpose. Releasing is a two-step dance because artifacts do not carry between + # runs: the manual dispatch below runs the whole CI (this job included) and then creates the tag, + # and the tag push re-runs the workflow only to rebuild and upload. The tag run has therefore + # already been tested by the dispatch run it came from. + if: github.ref_type != 'tag' container: image: gitea.psi.ch/leonarski_f/jfjoch_rocky8:2511 options: --gpus all @@ -160,8 +164,8 @@ jobs: run: | cd build # Build the whole viewer-only tree, not just the GUI: the "viewer" CPack component also - # contains the portable CLI tools (rugnux/rugnux_scale/azint/recompress/extract_hkl), - # which must exist on disk before cpack installs the component. + # contains the portable CLI tools (rugnux, jfjoch_extract_hkl, jfjoch_recompress), which + # must exist on disk before cpack installs the component. ninja -j16 cpack - name: Upload viewer tgz to release @@ -186,7 +190,6 @@ jobs: done build-rpm: name: build:rpm (${{ matrix.distro }}) - if: github.ref_type != 'workflow_dispatch' runs-on: ${{ matrix.runner }} strategy: fail-fast: false