diff --git a/.github/workflows/comment-and-close-reusable.yml b/.github/workflows/comment-and-close-reusable.yml new file mode 100644 index 00000000..afb39676 --- /dev/null +++ b/.github/workflows/comment-and-close-reusable.yml @@ -0,0 +1,15 @@ +on: + workflow_call: + secrets: + DHIS2_BOT_GITHUB_TOKEN: + required: true + +jobs: + comment-and-close: + runs-on: ubuntu-latest + steps: + - uses: vardevs/candc@v1 + with: + close-comment: 'If you would like to file a bug report or feature request, please refer to our issue tracker: https://dhis2.atlassian.net' + exempt-users: dhis2-bot,dependabot,kodiakhq + github-token: ${{secrets.DHIS2_BOT_GITHUB_TOKEN}} diff --git a/.github/workflows/comment-and-close.yml b/.github/workflows/comment-and-close.yml index 6aa782a0..8ee496f7 100644 --- a/.github/workflows/comment-and-close.yml +++ b/.github/workflows/comment-and-close.yml @@ -4,10 +4,5 @@ on: jobs: comment-and-close: - runs-on: ubuntu-latest - steps: - - uses: vardevs/candc@v1 - with: - close-comment: 'If you would like to file a bug report or feature request, please refer to our issue tracker: https://jira.dhis2.org' - exempt-users: dhis2-bot,dependabot,kodiakhq - github-token: ${{secrets.DHIS2_BOT_GITHUB_TOKEN}} + uses: ./.github/workflows/comment-and-close-reusable.yml + secrets: inherit