name: QPP Benchmarks Data Slack Notification

on:
  push:
    branches:
    - develop
    paths:
    - 'benchmarks/**'

jobs:

  # make an announcement to relevant slack channels
  notify-slack-channel:
    name: Notify ITT via Benchmarks Channel
    runs-on: ubuntu-latest
    steps:
    - uses: 8BitJonny/gh-get-current-pr@2.1.2
      id: PR
    - uses: rtCamp/action-slack-notify@06cc13f74fa8d4d2296c09455d91e9453e4025f4 #v2.4.1
      env:
        SLACK_WEBHOOK: ${{ secrets.CMS_SLACK_WEBHOOK }}
        SLACK_CHANNEL: "qpp-benchmarks"
        SLACK_MESSAGE: "The Benchmarks in `qpp-measures-data` have been updated. Check <https://github.com/CMSgov/qpp-measures-data/pull/${{steps.PR.outputs.number}}|the related PR> for more info."
        SLACK_TITLE: New qpp-measures-data release
        SLACK_USERNAME: Benchmark Bot
