Skip to content

Commit

Permalink
Send notification only on failure or cancelled
Browse files Browse the repository at this point in the history
Closes gh-59
  • Loading branch information
sjohnr committed Jan 15, 2025
1 parent 5a72b65 commit fdfb70a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions .github/actions/send-notification/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,5 +63,6 @@ runs:
# Output status
echo "result=$runStatus" >> $GITHUB_OUTPUT
- shell: bash
if: ${{ contains(fromJSON('["failed", "cancelled", "unsuccessful"]'), steps.run-info.outputs.result) }}
run: |
curl -X POST '${{ inputs.webhook-url }}' -H 'Content-Type: application/json' -d '{ "text": "${{ env.WORKFLOW_STATUS }}\n${{ env.WORKFLOW_INFO }}: ${{ env.RUN_INFO }}\n\n${{ env.JOB_INFO }}" }' || true

0 comments on commit fdfb70a

Please sign in to comment.