Skip to content

Commit

Permalink
chore: refrain notification
Browse files Browse the repository at this point in the history
  • Loading branch information
matinnuhamunada committed Apr 22, 2024
1 parent f74806a commit c0db2a4
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 141 deletions.
69 changes: 0 additions & 69 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -115,72 +115,3 @@ jobs:
password: ${{ secrets.TEST_PYPI_API_TOKEN}}
repository_url: https://test.pypi.org/legacy/
skip_existing: true

notification:
needs: [test,publish_dev_build]
if: always()
runs-on: ubuntu-latest
steps:
- uses: martialonline/workflow-status@v2
id: check

- name: build success notification via email
if: ${{ steps.check.outputs.status == 'success' }}
uses: dawidd6/action-send-mail@v3
with:
server_address: ${{ secrets.BUILD_NOTIFY_MAIL_SERVER }}
server_port: ${{ secrets.BUILD_NOTIFY_MAIL_PORT }}
username: ${{ secrets.BUILD_NOTIFY_MAIL_FROM }}
password: ${{ secrets.BUILD_NOTIFY_MAIL_PASSWORD }}
from: build-bot
to: ${{ secrets.BUILD_NOTIFY_MAIL_RCPT }}
subject: ${{ needs.test.outputs.package_name }}.${{ needs.test.outputs.package_version}}.dev.${{ github.run_number }} build successfully
convert_markdown: true
html_body: |
## Build Success
${{ needs.test.outputs.package_name }}.${{ needs.test.outputs.package_version }}.dev.${{ github.run_number }} is built and published to test pypi
## Change Details
${{ github.event.head_commit.message }}
For more information, please check change history at https://${{ needs.test.outputs.repo_owner }}.github.io/${{ needs.test.outputs.repo_name }}/${{ needs.test.outputs.package_version }}.dev/history
## Package Download
The pacakge is available at: https://test.pypi.org/project/${{ needs.test.outputs.package_name }}/
- name: build failure notification via email
if: ${{ steps.check.outputs.status == 'failure' }}
uses: dawidd6/action-send-mail@v3
with:
server_address: ${{ secrets.BUILD_NOTIFY_MAIL_SERVER }}
server_port: ${{ secrets.BUILD_NOTIFY_MAIL_PORT }}
username: ${{ secrets.BUILD_NOTIFY_MAIL_FROM }}
password: ${{ secrets.BUILD_NOTIFY_MAIL_PASSWORD }}
from: build-bot
to: ${{ secrets.BUILD_NOTIFY_MAIL_RCPT }}
subject: ${{ needs.test.outputs.package_name }}.${{ needs.test.outputs.package_version}}.dev.${{ github.run_number }} build failure
convert_markdown: true
html_body: |
## Change Details
${{ github.event.head_commit.message }}
## View Log
https://github.com/${{ needs.test.outputs.repo_owner }}/${{ needs.test.outputs.repo_name }}/actions
# - name: Dingtalk Robot Notify
# if: always()
# uses: leafney/[email protected]
# env:
# DINGTALK_ACCESS_TOKEN: ${{ secrets.DINGTALK_ACCESS_TOKEN }}
# DINGTALK_SECRET: ${{ secrets.DINGTALK_SECRET }}
# with:
# msgtype: markdown
# title: CI Notification | Success
# text: |
# ### Build Success
# ${{ needs.test.outputs.package_version }}.dev.${{ github.run_number }}published to TEST pypi
# ### Change History
# Please check change history at https://${{ needs.test.outputs.repo_owner }}.github.io/${{ needs.test.outputs.repo_name }}/${{ needs.test.outputs.package_version }}.dev/history
# ### Package Download
# The pacakge is availabled at: https://test.pypi.org/project/${{ needs.test.outputs.repo_name }}/
72 changes: 0 additions & 72 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,75 +91,3 @@ jobs:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
skip_existing: true

notification:
needs: release
if: always()
runs-on: ubuntu-latest
steps:
- uses: martialonline/workflow-status@v2
id: check

- name: build success notification via email
if: ${{ steps.check.outputs.status == 'success' }}
uses: dawidd6/action-send-mail@v3
with:
server_address: ${{ secrets.BUILD_NOTIFY_MAIL_SERVER }}
server_port: ${{ secrets.BUILD_NOTIFY_MAIL_PORT }}
username: ${{ secrets.BUILD_NOTIFY_MAIL_FROM }}
password: ${{ secrets.BUILD_NOTIFY_MAIL_PASSWORD }}
from: build-bot
to: ${{ secrets.BUILD_NOTIFY_MAIL_RCPT }}
subject: ${{ needs.release.outputs.package_name }}.${{ needs.release.outputs.package_version}} build successfully
convert_markdown: true
html_body: |
## Build Success
${{ needs.release.outputs.package_name }}.${{ needs.release.outputs.package_version }} has been published to PYPI
## Change Details
${{ github.event.head_commit.message }}
For more information, please check change history at https://${{ needs.release.outputs.repo_owner }}.github.io/${{ needs.release.outputs.repo_name }}/${{ needs.release.outputs.package_version }}/history
## Package Download
The pacakge is available at: https://pypi.org/project/${{ needs.release.outputs.package_name }}/
- name: build failure notification via email
if: ${{ steps.check.outputs.status == 'failure' }}
uses: dawidd6/action-send-mail@v3
with:
server_address: ${{ secrets.BUILD_NOTIFY_MAIL_SERVER }}
server_port: ${{ secrets.BUILD_NOTIFY_MAIL_PORT }}
username: ${{ secrets.BUILD_NOTIFY_MAIL_FROM }}
password: ${{ secrets.BUILD_NOTIFY_MAIL_PASSWORD }}
from: build-bot
to: ${{ secrets.BUILD_NOTIFY_MAIL_RCPT }}
subject: ${{ needs.release.outputs.package_name }}.${{ needs.release.outputs.package_version}} build failure
convert_markdown: true
html_body: |
## Change Details
${{ github.event.head_commit.message }}
## Status: ${{ steps.check.outputs.status }}
## View Log
https://github.com/${{ needs.release.outputs.repo_owner }}/${{ needs.release.outputs.repo_name }}/actions
# - name: Dingtalk Robot Notify
# if: always()
# uses: leafney/[email protected]
# env:
# DINGTALK_ACCESS_TOKEN: ${{ secrets.DINGTALK_ACCESS_TOKEN }}
# DINGTALK_SECRET: ${{ secrets.DINGTALK_SECRET }}
# with:
# msgtype: markdown
# title: CI Notification | Success
# text: |
# ### ${{ needs.release.outputs.package_name }} Build Success
# ${{ needs.release.outputs.package_version }} has been published to PYPI
# ### Change History
# Please check change history at https://${{ needs.release.outputs.repo_owner }}.github.io/${{ needs.release.outputs.repo_name }}/latest/history
# ### Package Download
# Please download the pacakge at: https://pypi.org/project/${{ needs.release.outputs.repo_name }}/

0 comments on commit c0db2a4

Please sign in to comment.