Skip to content

Update discord.yml

Update discord.yml #6

Workflow file for this run

name: Create and Send JSON to Discord
on:
push:
branches:
- main
jobs:
generate-json:
runs-on: ubuntu-latest
steps:
- name: Create File
uses: devops-actions/json-to-file@v1.0.4
with:
json: '{"content":null,"embeds":[{"title":"New Release 🧰","color":6291288,"fields":[{"name":"Commit ⚡","value":"Message » `${{ github.event.head_commit.message }}`\n\nCommit SHA » `${{ github.sha }}`"},{"name":"Workflow ☢️","value":"Branch » `${{ github.ref.name }}`\n\nWorkflow Runtime » `${{ }}`"},{"name":"Release 📦","value":"Download » `${{ }}`"}],"author":{"name":"${{ github.actor.login }}"},"footer":{"text":"[Main Repository 🔑](https://github.com/Hyphonic/Conquest)"}}],"attachments":[]}'

Check failure on line 15 in .github/workflows/discord.yml

View workflow run for this annotation

GitHub Actions / Create and Send JSON to Discord

Invalid workflow file

The workflow is not valid. .github/workflows/discord.yml (Line: 15, Col: 17): An expression was expected
filename: file.json
send-webhook:
runs-on: ubuntu-latest
needs: generate-json
steps:
- uses: actions/checkout@v2
- name: Send Webhook
uses: tsickert/discord-webhook@v6.0.0
with:
webhook-url: ${{ secrets.WEBHOOK_URL }}
raw-data: file.json
cleanup:
runs-on: ubuntu-latest
needs: send-webhook
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Delete JSON file
run: rm file.json