mirror of
https://github.com/nodejs/node.git
synced 2026-11-24 21:50:36 -05:00
meta: notify slack when someone force pushes
Notify #nodejs-dev on the OpenJS Foundation slack when someone force-pushes, removing one manual step from force-pushing. PR-URL: https://github.com/nodejs/node/pull/35131 Reviewed-By: Michael Dawson <midawson@redhat.com> Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
1 parent
8bda9f4dce
commit
e0df3bc751
1 file changed
+25
@@ -0,0 +1,25 @@
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
name: Notify on Force Push
|
||||
jobs:
|
||||
slackNotification:
|
||||
name: Slack Notification
|
||||
if: ${{ github.event.forced && github.repository == 'nodejs/node' }}
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Slack Notification
|
||||
uses: rtCamp/action-slack-notify@master
|
||||
env:
|
||||
SLACK_COLOR: '#DE512A'
|
||||
SLACK_ICON: https://github.com/nodejs.png?size=48
|
||||
SLACK_TITLE: '${{ github.actor }} force-pushed to ${{ github.ref }}'
|
||||
SLACK_MESSAGE: |
|
||||
A commit was force-pushed to <https://github.com/${{ github.repository }}/tree/master|${{ github.repository }}@master> by <https://github.com/${{ github.actor }}|${{ github.actor }}>
|
||||
|
||||
Before: <https://github.com/${{ github.repository }}/commit/${{ github.event.before }}|${{ github.event.before }}>
|
||||
After: <https://github.com/${{ github.repository }}/commit/${{ github.event.after }}|${{ github.event.after }}>
|
||||
SLACK_USERNAME: nodejs-bot
|
||||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
|
||||
Reference in new issue
Block a user