mirror of
https://github.com/jayfunc/BetterLyrics.git
synced 2026-01-13 03:34:55 +08:00
Create notify-discord.yml
This commit is contained in:
20
.github/workflows/notify-discord.yml
vendored
Normal file
20
.github/workflows/notify-discord.yml
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
name: Notify Discord on Release
|
||||
|
||||
on:
|
||||
release:
|
||||
types: [published, edited] # 支持发布和编辑
|
||||
|
||||
jobs:
|
||||
notify:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Send release message to Discord
|
||||
env:
|
||||
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
|
||||
run: |
|
||||
curl -H "Content-Type: application/json" \
|
||||
-X POST \
|
||||
-d "{
|
||||
\"content\": \"📢 Release update: *${{ github.event.release.name }}* by ${{ github.actor }}\n🔗 ${{ github.event.release.html_url }}\"
|
||||
}" \
|
||||
$DISCORD_WEBHOOK
|
||||
Reference in New Issue
Block a user