@@ -38,27 +38,37 @@ jobs:
3838 name : extension-${{ github.sha }}
3939 path : workspace/extension/build/svelte-devtools.zip
4040
41- - if : |
42- github.repository == 'sveltejs/svelte-devtools' &&
43- github.event_name == 'push' && github.ref == 'refs/heads/master' &&
44- startsWith(github.event.head_commit.message, format('~ v{0}', needs.manifest.outputs.version))
41+ publish :
42+ runs-on : ubuntu-latest
43+ needs : [manifest, bundle]
44+
45+ if : |
46+ github.repository == 'sveltejs/svelte-devtools' &&
47+ github.event_name == 'push' && github.ref == 'refs/heads/master' &&
48+ startsWith(github.event.head_commit.message, format('~ v{0}', needs.manifest.outputs.version))
49+
50+ steps :
51+ - uses : actions/checkout@v4
52+ - uses : pnpm/action-setup@v4
53+ - uses : actions/download-artifact@v4
54+
55+ - working-directory : extension-${{ github.sha }}
56+ run : |
57+ pnpm dlx web-ext sign --channel unlisted \
58+ --api-key ${{ secrets.WEB_EXT_API_KEY }} \
59+ --api-secret ${{ secrets.WEB_EXT_API_SECRET }}
60+
61+ - working-directory : extension-${{ github.sha }}
4562 env :
4663 GH_TOKEN : ${{ github.token }}
4764 run : | # https://cli.github.com/manual/gh_release_create
4865 gh release create v${{ needs.manifest.outputs.version }} \
49- workspace/extension/build/ svelte-devtools.zip \
66+ svelte-devtools.zip web-ext-artifacts/*.xpi#svelte-devtools.xpi \
5067 --title ${{ needs.manifest.outputs.version }} \
5168 --draft --generate-notes --notes '
5269 Built from ${{ github.event.head_commit.id }} at https://github.com/sveltejs/svelte-devtools/actions/runs/${{ github.run_id }}
5370 - Chrome Web Store: https://chrome.google.com/webstore/detail/svelte-devtools/kfidecgcdjjfpeckbblhmfkhmlgecoff
5471 - Firefox Signed Add-on: https://github.com/sveltejs/svelte-devtools/releases/download/v${{ needs.manifest.outputs.version }}/svelte-devtools.xpi
5572 ---'
5673
57- # publish:
58- # runs-on: ubuntu-latest
59- # needs: bundle
60-
61- # steps:
62- # - uses: actions/download-artifact@v3
63- # with:
64- # name: extension-${{ github.sha }}
74+ # TODO: publish to Chrome Web Store
0 commit comments