2022-12-23 00:17:17 -08:00
|
|
|
name: Discord
|
|
|
|
on:
|
|
|
|
release:
|
|
|
|
types: [published]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
notify:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2022-12-24 07:34:27 -08:00
|
|
|
- name: Notes 📝
|
2022-12-24 06:16:45 -08:00
|
|
|
id: notes
|
2023-04-06 18:02:52 -07:00
|
|
|
uses: actions/github-script@d7906e4ad0b1822421a7e6a35d5ca353c962f410
|
2022-12-24 06:16:45 -08:00
|
|
|
with:
|
2022-12-24 07:34:27 -08:00
|
|
|
result-encoding: string
|
|
|
|
script: |
|
2022-12-24 06:16:45 -08:00
|
|
|
notes = context.payload.release.body
|
|
|
|
|
|
|
|
// replace all non-supported characters
|
2022-12-24 07:34:27 -08:00
|
|
|
notes = notes.replaceAll('###', '')
|
2022-12-24 06:16:45 -08:00
|
|
|
notes = notes.trim()
|
|
|
|
return notes
|
2022-12-23 00:17:17 -08:00
|
|
|
- name: Changelog 📝
|
2023-01-12 17:26:43 -08:00
|
|
|
uses: sebastianpopp/discord-action@4f2d5417bc61a79593304a62e71cd32427c17790
|
2022-12-23 00:17:17 -08:00
|
|
|
with:
|
|
|
|
webhook: ${{ secrets.CHANGELOG_WEBHOOK }}
|
|
|
|
message: |
|
|
|
|
📦 ${{ github.event.release.name }}
|
|
|
|
|
2022-12-24 06:16:45 -08:00
|
|
|
${{steps.notes.outputs.result}}
|
2022-12-23 00:17:17 -08:00
|
|
|
|
|
|
|
${{ github.event.release.html_url }}
|