From eca964c24e94ceb9146bcf4c010d9abfc632637a Mon Sep 17 00:00:00 2001 From: Takashi Kokubun Date: Tue, 31 Dec 2019 21:26:39 -0800 Subject: More consistent failure notifications The format is the same as Travis / AppVeyor now. --- .github/workflows/cygwin.yml | 14 ++++++++++++++ .github/workflows/macos.yml | 4 ++-- .github/workflows/mingw.yml | 4 ++-- .github/workflows/mjit.yml | 4 ++-- .github/workflows/ubuntu.yml | 4 ++-- .github/workflows/windows.yml | 4 ++-- 6 files changed, 24 insertions(+), 10 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/cygwin.yml b/.github/workflows/cygwin.yml index 515b47e141..413f14d186 100644 --- a/.github/workflows/cygwin.yml +++ b/.github/workflows/cygwin.yml @@ -77,3 +77,17 @@ jobs: # run: | # make -C build btest # shell: cmd + - uses: k0kubun/action-slack@v2.0.0 + with: + payload: | + { + "attachments": [{ + "text": "${{ github.workflow }} / ${{ matrix.test_task }} " + + "() " + + "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }} failed", + "color": "danger" + }] + } + env: + SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} + if: failure() && github.event_name == 'push' diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index c3af98ad18..87d7a802d7 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -72,9 +72,9 @@ jobs: payload: | { "attachments": [{ - "text": "${{ job.status }}: ${{ github.workflow }} / ${{ matrix.test_task }} " + + "text": "${{ github.workflow }} / ${{ matrix.test_task }} " + "() " + - "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }}", + "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }} failed", "color": "danger" }] } diff --git a/.github/workflows/mingw.yml b/.github/workflows/mingw.yml index f4bbc3c5f4..8283791574 100644 --- a/.github/workflows/mingw.yml +++ b/.github/workflows/mingw.yml @@ -145,9 +145,9 @@ jobs: payload: | { "attachments": [{ - "text": "${{ job.status }}: ${{ github.workflow }} / ${{ matrix.test_task }} " + + "text": "${{ github.workflow }} / ${{ matrix.test_task }} " + "() " + - "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }}", + "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }} failed", "color": "danger" }] } diff --git a/.github/workflows/mjit.yml b/.github/workflows/mjit.yml index cdb41701de..7d6cc10b69 100644 --- a/.github/workflows/mjit.yml +++ b/.github/workflows/mjit.yml @@ -69,9 +69,9 @@ jobs: payload: | { "attachments": [{ - "text": "${{ job.status }}: ${{ github.workflow }} / ${{ matrix.test_task }} ${{ matrix.jit_opts }} " + + "text": "${{ github.workflow }} / ${{ matrix.test_task }} ${{ matrix.jit_opts }} " + "() " + - "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }}", + "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }} failed", "color": "danger" }] } diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index 0b3dea7e68..901bf02be6 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -106,9 +106,9 @@ jobs: payload: | { "attachments": [{ - "text": "${{ job.status }}: ${{ matrix.os }} / ${{ matrix.test_task }} " + + "text": "${{ matrix.os }} / ${{ matrix.test_task }} " + "() " + - "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }}", + "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }} failed", "color": "danger" }] } diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 09e588784c..ebbac19d99 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -79,9 +79,9 @@ jobs: payload: | { "attachments": [{ - "text": "${{ job.status }}: ${{ matrix.os }} / ${{ matrix.test_task }} " + + "text": "${{ matrix.os }} / ${{ matrix.test_task }} " + "() " + - "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }}", + "of ${{ github.repository }}@" + "${{ github.ref }}".split('/').reverse()[0] + " by ${{ github.event.head_commit.committer.name }} failed", "color": "danger" }] } -- cgit v1.2.3