File tree Expand file tree Collapse file tree 3 files changed +45
-0
lines changed
Expand file tree Collapse file tree 3 files changed +45
-0
lines changed Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ color=" "
4+ if [ $2 == " success" ]
5+ then
6+ echo " success"
7+ color=" info"
8+ else
9+ echo " fail"
10+ color=" warning"
11+ fi
12+
13+ curl " https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=$IOT_WECOM_CID_ROBOT_KEY " \
14+ -H ' Content-Type: application/json' \
15+ -d '
16+ {
17+ "msgtype": "markdown",
18+ "markdown": {
19+ "content": "**repo: \"' " $1 " ' \"**\n
20+ >result:<font color=\"' " $color " ' \">\"' " $2 " ' \"</font>\n
21+ >[action](https://github.com/tencentyun/iot-link-android/actions)"\n
22+ }
23+ }'
Original file line number Diff line number Diff line change 1414 IOT_SONATYPE_USERNAME : ${{ secrets.IOT_SONATYPE_USERNAME }}
1515 IOT_SONATYPE_PASSWORD : ${{ secrets.IOT_SONATYPE_PASSWORD }}
1616 GPG_DECRYPT_PASSPHRASE : ${{ secrets.GPG_DECRYPT_PASSPHRASE }}
17+ IOT_WECOM_CID_ROBOT_KEY : ${{ secrets.IOT_WECOM_CID_ROBOT_KEY }}
1718
1819jobs :
1920 build :
8485 fir publish $demoApk -T $IOT_FIRIM_API_TOKEN -c "$rl" --oversea_turbo --force_pin_history -V
8586 env :
8687 IOT_FIRIM_API_TOKEN : ${{ secrets.IOT_FIRIM_API_TOKEN }}
88+ - name : Report success result to wecom
89+ if : ${{ success() }}
90+ run : |
91+ echo success!!!
92+ bash .github/scripts/send_result_to_wecom.sh ${{ github.event.repository.name }} success
93+ - name : Report fail result to wecom
94+ if : ${{ failure() }}
95+ run : |
96+ echo fail!!!
97+ bash .github/scripts/send_result_to_wecom.sh ${{ github.event.repository.name }} fail
Original file line number Diff line number Diff line change 1212 IOT_GPG_KEYNAME : ${{ secrets.IOT_GPG_KEYNAME }}
1313 IOT_GPG_PASSPHRASE : ${{ secrets.IOT_GPG_PASSPHRASE }}
1414 IOT_GITHUB_ACCESS_TOKEN : ${{ secrets.IOT_GITHUB_ACCESS_TOKEN }}
15+ IOT_WECOM_CID_ROBOT_KEY : ${{ secrets.IOT_WECOM_CID_ROBOT_KEY }}
1516
1617jobs :
1718 build :
@@ -163,3 +164,13 @@ jobs:
163164 fir publish $demoApk -T $IOT_FIRIM_API_TOKEN -c "$rl" --oversea_turbo --force_pin_history -V
164165 env :
165166 IOT_FIRIM_API_TOKEN : ${{ secrets.IOT_FIRIM_API_TOKEN }}
167+ - name : Report success result to wecom
168+ if : ${{ success() }}
169+ run : |
170+ echo success!!!
171+ bash .github/scripts/send_result_to_wecom.sh ${{ github.event.repository.name }} success
172+ - name : Report fail result to wecom
173+ if : ${{ failure() }}
174+ run : |
175+ echo fail!!!
176+ bash .github/scripts/send_result_to_wecom.sh ${{ github.event.repository.name }} fail
You can’t perform that action at this time.
0 commit comments