From f1032a7a23d1d5453af74cd4399a21ef68563238 Mon Sep 17 00:00:00 2001 From: enricobuehler Date: Thu, 18 Jun 2026 21:48:17 +0000 Subject: [PATCH] fix(flatpak): pass `stable` branch to build-bundle (matches --default-branch) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The CI added --default-branch=stable, so the repo ref is app/io.unom.Punktfunk/x86_64/stable. build-bundle defaults to `master` when no branch is given → "Refspec app/io.unom.Punktfunk/x86_64/master not found". Pass `stable` explicitly in both flatpak.yml and the local build-flatpak.sh. Co-Authored-By: Claude Opus 4.8 (1M context) --- .gitea/workflows/flatpak.yml | 4 +++- packaging/flatpak/build-flatpak.sh | 5 ++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/flatpak.yml b/.gitea/workflows/flatpak.yml index b81fbc0..c3b3c52 100644 --- a/.gitea/workflows/flatpak.yml +++ b/.gitea/workflows/flatpak.yml @@ -118,7 +118,9 @@ jobs: - name: Export single-file bundle run: | - flatpak build-bundle "$PWD/repo" "$BUNDLE" "$APP_ID" + # Branch must be passed explicitly now that the repo ref is `stable` (--default-branch + # above); build-bundle otherwise defaults to `master` and errors "Refspec … not found". + flatpak build-bundle "$PWD/repo" "$BUNDLE" "$APP_ID" stable ls -lh "$BUNDLE" - name: Publish to the Gitea generic registry diff --git a/packaging/flatpak/build-flatpak.sh b/packaging/flatpak/build-flatpak.sh index 550c45b..fb9dcef 100755 --- a/packaging/flatpak/build-flatpak.sh +++ b/packaging/flatpak/build-flatpak.sh @@ -73,14 +73,17 @@ fi # --- build into a local ostree repo, then export a single-file bundle -------------------- echo "==> flatpak-builder ($APP_ID, version $VERSION)" +# --default-branch=stable matches CI / the hosted repo ref, so a locally-built install can also +# track flatpak.unom.io. build-bundle must then be told the branch (else it defaults to `master`). "${FPB[@]}" --user --force-clean --disable-rofiles-fuse \ + --default-branch=stable \ --install-deps-from=flathub \ "${EXTRA_ARGS[@]}" \ --repo="$ROOTDIR/.flatpak-repo" \ "$ROOTDIR/.flatpak-build" "$MANIFEST" mkdir -p dist -flatpak build-bundle "$ROOTDIR/.flatpak-repo" "$BUNDLE" "$APP_ID" +flatpak build-bundle "$ROOTDIR/.flatpak-repo" "$BUNDLE" "$APP_ID" stable echo "built $BUNDLE" ls -lh "$BUNDLE" echo