Commit ef4aaa4a authored by AlexStocks's avatar AlexStocks

remark dingding notification

parent 1bcef0bc
...@@ -71,43 +71,43 @@ jobs: ...@@ -71,43 +71,43 @@ jobs:
- name: Coverage - name: Coverage
run: bash <(curl -s https://codecov.io/bash) run: bash <(curl -s https://codecov.io/bash)
# Because the contexts of push and PR are different, there are two Notify. # # Because the contexts of push and PR are different, there are two Notify.
# Notifications are triggered only in the apache/dubbo-getty repository. # # Notifications are triggered only in the apache/dubbo-getty repository.
- name: DingTalk Message Notify only Push # - name: DingTalk Message Notify only Push
uses: zcong1993/actions-ding@v3.0.1 # uses: zcong1993/actions-ding@v3.0.1
# Whether job is successful or not, always () is always true. # # Whether job is successful or not, always () is always true.
if: | # if: |
always() && # always() &&
github.event_name == 'push' && # github.event_name == 'push' &&
github.repository == 'apache/dubbo-getty' # github.repository == 'apache/dubbo-getty'
with: # with:
# DingDing bot token # # DingDing bot token
dingToken: ${{ env.DING_TOKEN }} # dingToken: ${{ env.DING_TOKEN }}
secret: ${{ env.DING_SIGN }} # secret: ${{ env.DING_SIGN }}
# Post Body to send # # Post Body to send
body: | # body: |
{ # {
"msgtype": "markdown", # "msgtype": "markdown",
"markdown": { # "markdown": {
"title": "Github Actions", # "title": "Github Actions",
"text": "## Github Actions \n - name: CI \n - repository: ${{ github.repository }} \n - trigger: ${{ github.actor }} \n - event: ${{ github.event_name }} \n - ref: ${{ github.ref }} \n - status: [${{ job.status }}](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) \n - environment: ${{ runner.os }} \n - SHA: [${{ github.sha }}](${{ github.event.compare }})" # "text": "## Github Actions \n - name: CI \n - repository: ${{ github.repository }} \n - trigger: ${{ github.actor }} \n - event: ${{ github.event_name }} \n - ref: ${{ github.ref }} \n - status: [${{ job.status }}](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) \n - environment: ${{ runner.os }} \n - SHA: [${{ github.sha }}](${{ github.event.compare }})"
} # }
} # }
#
- name: DingTalk Message Notify only PR # - name: DingTalk Message Notify only PR
uses: zcong1993/actions-ding@v3.0.1 # uses: zcong1993/actions-ding@v3.0.1
if: | # if: |
always() && # always() &&
github.event_name == 'pull_request' && # github.event_name == 'pull_request' &&
github.repository == 'apache/dubbo-getty' # github.repository == 'apache/dubbo-getty'
with: # with:
dingToken: ${{ env.DING_TOKEN }} # dingToken: ${{ env.DING_TOKEN }}
secret: ${{ env.DING_SIGN }} # secret: ${{ env.DING_SIGN }}
body: | # body: |
{ # {
"msgtype": "markdown", # "msgtype": "markdown",
"markdown": { # "markdown": {
"title": "Github Actions", # "title": "Github Actions",
"text": "## Github Actions \n - name: CI \n - repository: ${{ github.repository }} \n - pr_title: **${{ github.event.pull_request.title }}** \n - trigger: ${{ github.actor }} \n - event: ${{ github.event_name }} \n - ref: [${{ github.ref }}](${{ github.event.pull_request._links.html.href }}) \n - status: [${{ job.status }}](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) \n - environment: ${{ runner.os }} \n > SHA: [${{ github.sha }}](${{ github.event.pull_request._links.html.href }})" # "text": "## Github Actions \n - name: CI \n - repository: ${{ github.repository }} \n - pr_title: **${{ github.event.pull_request.title }}** \n - trigger: ${{ github.actor }} \n - event: ${{ github.event_name }} \n - ref: [${{ github.ref }}](${{ github.event.pull_request._links.html.href }}) \n - status: [${{ job.status }}](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) \n - environment: ${{ runner.os }} \n > SHA: [${{ github.sha }}](${{ github.event.pull_request._links.html.href }})"
} # }
} # }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment