Skip to content

command-dispatcher

command-dispatcher #2

name: command-dispatcher
on:
issue_comment:
types: [created]
##
## This does not work for private repositories anymore.
## You must use a bot token or you will receive the following error:
## Command 'XYZ' is not configured for the user's permission level 'none'.
##
#permissions:
# actions: write
# contents: write # For executing the repository_dispatch event
# issues: write # For doing the emoji reaction on an issue comment
# pull-requests: write # For doing the emoji reaction on a PR comment
# repository-projects: read
# checks: read
# statuses: read
jobs:
dispatcher:
runs-on: ubuntu-latest
if: ${{ github.event.issue.pull_request }}
steps:
- name: Dispatching command
uses: peter-evans/slash-command-dispatch@v3
with:
reaction-token: ${{ secrets.CS_DEVOPS_BOT_TOKEN }}
token: ${{ secrets.CS_DEVOPS_BOT_TOKEN }}
config: >
[
{
"command": "ql:publish",
"permission": "write",
"issue_type": "pull-request"
},
{
"command": "help",
"permission": "write",
"issue_type": "pull-request"
}
]