From 5bc492f3c0f238fa36644b210f7a46102f62a26f Mon Sep 17 00:00:00 2001 From: Space-Banane Date: Tue, 17 Feb 2026 16:18:44 +0100 Subject: [PATCH] fix: improve extension publishing step to handle missing files --- .gitea/workflows/ci.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index d06f677..45ac035 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -59,12 +59,17 @@ jobs: - name: Publish to Mozilla Add-ons if: github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master') run: | - # Ensure dependencies are available (npm ci ran earlier in this job) + # Find the built extension file (zip/xpi) in dist/ + EXT_FILE=$(find dist -maxdepth 1 -type f \( -name "*.zip" -o -name "*.xpi" \) | head -n 1) + if [ -z "$EXT_FILE" ]; then + echo "No extension package found in dist/" + exit 1 + fi npx web-ext sign \ --api-key ${{ secrets.MOZILLA_ADDON_API_KEY }} \ --api-secret ${{ secrets.MOZILLA_ADDON_API_SECRET }} \ --channel listed \ - --source-dir dist \ + --source-dir "$EXT_FILE" \ --artifacts-dir dist - name: Push changes