Skip to content

Commit ed8647a

Browse files
committed
chore: gh comment zipped extension
1 parent fb3983d commit ed8647a

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/workflows/release.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,16 @@ jobs:
3838
name: extension-${{ github.sha }}
3939
path: workspace/extension/build/svelte-devtools.zip
4040

41+
- if: github.event_name == 'pull_request'
42+
env:
43+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
44+
run: |
45+
id=$(gh api repos/${{ github.repository }}/actions/runs/${{ github.run_id }}/artifacts --jq '.artifacts[0].id')
46+
url=https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/artifacts/$id
47+
comment="Try the changes in this PR by [side-loading the built extension]($url). :rocket:"
48+
49+
gh pr comment ${{ github.event.pull_request.number }} --edit-last --body "$comment"
50+
4151
publish:
4252
runs-on: ubuntu-latest
4353
needs: [manifest, bundle]

0 commit comments

Comments
 (0)