Skip to content

Fix Discord PR extension workflow output (#3046) #6

Fix Discord PR extension workflow output (#3046)

Fix Discord PR extension workflow output (#3046) #6

name: Discuss "help-wanted" PR on Discord
on:
pull_request:
types:
- labeled
workflow_dispatch:
inputs:
pull_request_number:
description: 'Pull request number'
required: true
permissions:
pull-requests: write
jobs:
discord:
runs-on: ubuntu-latest
steps:
- name: "Discuss on Discord-PR (Non-maintainer only)"
if: ${{ github.event.label.name == 'help wanted' }}
uses: EndBug/[email protected]
with:
discord_bot_token: ${{ secrets.DISCORD_BOT_TOKEN }}
destination: ${{ secrets.DISCORD_BOT_DESTINATION }}
issue_number: ${{ github.event.inputs.pull_request_number || github.event.pull_request.number }}
issue_comment: Hey 👋, I've just created a [thread]($THREAD_LINK$) for this pull request on [PyTorch-Ignite Discord](https://pytorch-ignite.ai/chat) where you can quickly talk to the community on the topic.
discord_message: New PR created in `${{ github.repository }}`:<https://github.com/${{ github.repository }}/pull/${{ github.event.pull_request_number || github.event.pull_request.number }}>