Skip to content

Commit

Permalink
Improve messages in slack-message-broker.yml (IntersectMBO#6260)
Browse files Browse the repository at this point in the history
  • Loading branch information
zeme-wana authored and v0d1ch committed Dec 6, 2024
1 parent f3ec008 commit 2dd44d3
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/slake-message-broker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,19 @@ on:
jobs:
Send:
runs-on: [ubuntu-latest]
# if: contains(fromJson('["success", "failure", "null", "skipped", "cancelled", "action_required", "neutral", "timed_out"]'), github.event.workflow_job.conclusion)
# if: contains(fromJson('["success", "failure", "null", "skipped", "cancelled", "action_required", "neutral", "timed_out"]'), github.event.workflow_run.conclusion)
steps:
- name: Prepare Slack Message
uses: actions/github-script@main
id: prepare-slack-message
with:
script: |
const name = "${{ github.event.workflow_job.name }}";
const url = "${{ github.event.workflow_job.html_url }}";
const status = "${{ github.event.workflow_job.status }}";
const name = "${{ github.event.workflow_run.name }}";
const url = "${{ github.event.workflow_run.html_url }}";
const status = "${{ github.event.workflow_run.status }}";
const action = "${{ github.event.action }}";
const conclusion = "${{ github.event.workflow_job.conclusion }}";
const message = `Workflow ${name} - ${status} - ${action}: ${conclusion} 👉🏻 <${url}|view logs>`;
const conclusion = "${{ github.event.workflow_run.conclusion }}";
const message = `Workflow "${name}" \`${action}\`: \`${status}\`, \`${conclusion}\`, <${url}|View Logs>`;
core.setOutput("message", message);
- name: Notify Slack
Expand Down

0 comments on commit 2dd44d3

Please sign in to comment.