From a0a341e3d35b884eb76230af42b4837e39a47af5 Mon Sep 17 00:00:00 2001 From: Lex Christopherson Date: Wed, 18 Mar 2026 11:26:51 -0600 Subject: [PATCH] fix(ci): use env var for Discord webhook secret in if-condition GitHub Actions doesn't allow secrets context in if expressions. Co-Authored-By: Claude Opus 4.6 (1M context) --- .github/workflows/pipeline.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pipeline.yml b/.github/workflows/pipeline.yml index df62ec302..649617e7f 100644 --- a/.github/workflows/pipeline.yml +++ b/.github/workflows/pipeline.yml @@ -178,11 +178,13 @@ jobs: --latest - name: Post to Discord - if: ${{ secrets.DISCORD_CHANGELOG_WEBHOOK != '' }} + if: ${{ env.DISCORD_WEBHOOK != '' }} + env: + DISCORD_WEBHOOK: ${{ secrets.DISCORD_CHANGELOG_WEBHOOK }} run: | VERSION="${{ steps.release.outputs.version }}" NOTES=$(cat /tmp/release-notes.md) - curl -s -X POST "${{ secrets.DISCORD_CHANGELOG_WEBHOOK }}" \ + curl -s -X POST "$DISCORD_WEBHOOK" \ -H "Content-Type: application/json" \ -d "$(jq -n --arg c "**GSD v${VERSION} Released**\n\n${NOTES}\n\n\`npm i gsd-pi@${VERSION}\`" '{content:$c}')"