Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 8a0249c

Browse files
committed
fix: gracefully skip Discord notification if webhook URL is not configured
1 parent b7a0c15 commit 8a0249c

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,12 @@ jobs:
7171
PUBLISHED_PACKAGES: ${{ steps.changesets.outputs.publishedPackages }}
7272
IS_TEST: ${{ inputs.test_discord == true }}
7373
run: |
74+
# Check if webhook URL is configured
75+
if [ -z "$DISCORD_WEBHOOK_URL" ]; then
76+
echo "::warning::DISCORD_WEBHOOK_URL secret is not configured. Skipping Discord notification."
77+
exit 0
78+
fi
79+
7480
# Determine if this is a test run
7581
if [ "$IS_TEST" = "true" ]; then
7682
TEST_PREFIX="[TEST] "

0 commit comments

Comments
 (0)