diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 22a2b10..65acbf2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,6 +5,7 @@ on: - "v*" pull_request: branches: [master] + workflow_dispatch: name: CI jobs: test: @@ -68,7 +69,7 @@ jobs: publish-amo: name: "Publish to AMO" - if: startsWith(github.ref, 'refs/tags/') + if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' needs: [build-webextension] runs-on: ubuntu-latest steps: @@ -85,7 +86,7 @@ jobs: publish-cws: name: "Publish to Chrome Web Store" - if: startsWith(github.ref, 'refs/tags/') + if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' needs: [build-webextension] runs-on: ubuntu-latest steps: @@ -98,7 +99,10 @@ jobs: run: npm ci && npm run build - name: Package extension working-directory: webextension - run: zip -r ../switchyard-webextension.zip manifest.json popup.html build icons + run: | + jq 'del(.key)' manifest.json > manifest.cws.json + mv manifest.cws.json manifest.json + zip -r ../switchyard-webextension.zip manifest.json popup.html build icons - name: Submit to Chrome Web Store run: npx chrome-webstore-upload-cli@3 upload --source switchyard-webextension.zip --auto-publish env: @@ -109,7 +113,7 @@ jobs: publish-github: name: "Publish GitHub Release" - if: startsWith(github.ref, 'refs/tags/') + if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' needs: [build-flatpak, test, publish-amo, publish-cws] runs-on: ubuntu-latest permissions: