From 636e930598b73d64e70c868d022e7c80ac5744d9 Mon Sep 17 00:00:00 2001 From: "adamlui@protonmail.com" Date: Wed, 16 Oct 2024 05:44:55 -0700 Subject: [PATCH] Condensed checkout, updated paths accordingly --- .github/workflows/publish-to-amo-on-ff-bump.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish-to-amo-on-ff-bump.yml b/.github/workflows/publish-to-amo-on-ff-bump.yml index c19684c..514576d 100644 --- a/.github/workflows/publish-to-amo-on-ff-bump.yml +++ b/.github/workflows/publish-to-amo-on-ff-bump.yml @@ -13,14 +13,11 @@ jobs: - name: Checkout adamlui/you.com-omnibox uses: actions/checkout@v4 with: - token: ${{ secrets.REPO_SYNC_PAT }} - repository: adamlui/you.com-omnibox - path: adamlui/you-omnibox + sparse-checkout: firefox fetch-depth: 2 - name: Check FF manifest for version bump run: | - cd ${{ github.workspace }}/adamlui/you-omnibox CURRENT_VER=$(cat firefox/extension/manifest.json | grep '"version"' | sed -E 's/.*"version": "(.*)".*/\1/') PREV_VER=$(git show HEAD^:firefox/extension/manifest.json | grep '"version"' | sed -E 's/.*"version": "(.*)".*/\1/') if [ "$(printf '%s\n' "$PREV_VER" "$CURRENT_VER" | sort -V | head -n 1)" != "$CURRENT_VER" ] ; then @@ -31,14 +28,14 @@ jobs: - name: Create zipball if: env.VERSION_CHANGED == 'true' run: | - cd ${{ github.workspace }}/adamlui/you-omnibox/firefox/extension + cd firefox/extension zip -r ../../extension.zip . - name: Publish to AMO if: env.VERSION_CHANGED == 'true' uses: cardinalby/webext-buildtools-firefox-addons-action@v1 with: - zipFilePath: "${{ github.workspace }}/adamlui/you-omnibox/extension.zip" + zipFilePath: 'extension.zip' extensionId: 'you.com.omnibox@adamlui.com' jwtIssuer: ${{ secrets.AMO_ISSUER }} jwtSecret: ${{ secrets.AMO_SECRET }}