This GitHub Action sends a rich-text notification to your Slack channel when there's a new release in your GitHub repository.
We use mack to render the body of the release as Slack blocks.
- Create a Slack app called "Release Bot"
- Click Incoming Webhooks and toggle Activate Incoming Webhooks
- Click Add New Webhook to Workspace
- Pick the channel the app will post to and then click Authorize
- Set your
SLACK_WEBHOOK_URL
to the Webhook URL - Create a workflow file
name: Notify Slack on Release
on:
release:
types:
- created
jobs:
notify_slack:
runs-on: ubuntu-latest
name: Notify Slack on Release
steps:
- name: Notify Slack on Release
uses: instantish/[email protected]
with:
slack_webhook_url: ${{ secrets.SLACK_WEBHOOK_URL }}
Install the dependencies
$ npm install
Build the typescript and package it for distribution
$ npm run build && npm run package
Run the tests ✔️
$ npm test
...
Cut a new release
$ release-it