From b0fee9c1910c0d1e508dfa9467d3002392187e30 Mon Sep 17 00:00:00 2001 From: Howard Wu <40033067+Howard20181@users.noreply.github.com> Date: Sun, 25 Sep 2022 22:24:52 +0800 Subject: [PATCH] Update issue validation workflow --- .github/ISSUE_TEMPLATE/bug_report.yml | 2 +- .github/ISSUE_TEMPLATE/feature_request.yml | 2 +- .../{anti_spam.yml => issue_moderator.yml} | 27 +++++++++---------- 3 files changed, 14 insertions(+), 17 deletions(-) rename .github/workflows/{anti_spam.yml => issue_moderator.yml} (52%) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index ad3c06b..0213dfb 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -1,7 +1,7 @@ name: Bug report/反馈 Bug description: Report errors or unexpected behavior./反馈错误或异常行为。 labels: [bug] -title: "[Bug] " +title: "[Bug] Short description." body: - type: markdown attributes: diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml index 239a4d1..9f82683 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yml +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -2,7 +2,7 @@ name: Feature request/新特性请求 description: Suggest an idea./提出建议 labels: [enhancement] -title: "[Feature Request] " +title: "[Feature Request] Short description." body: - type: textarea attributes: diff --git a/.github/workflows/anti_spam.yml b/.github/workflows/issue_moderator.yml similarity index 52% rename from .github/workflows/anti_spam.yml rename to .github/workflows/issue_moderator.yml index b48b89d..4dda6d2 100644 --- a/.github/workflows/anti_spam.yml +++ b/.github/workflows/issue_moderator.yml @@ -1,4 +1,4 @@ -name: Anti-spam +name: Issue moderator on: issues: @@ -18,20 +18,17 @@ jobs: retain_days: 0 keep_minimum_runs: 0 - name: Check issue - uses: dessant/repo-lockdown@v2 + uses: tachiyomiorg/issue-moderator-action@v1 with: - exclude-issue-labels: | - bug - enhancement - issue-lock-reason: spam - exclude-pr-labels: | - bugfix - enhancement - do-not-autoclose - pr-labels: spam - pr-lock-reason: spam - skip-closed-pr-comment: true - skip-closed-issue-comment: true - process-only: issues + repo-token: ${{ secrets.GITHUB_TOKEN }} + auto-close-rules: | + [ + { + "type": "title", + "regex": ".*Short description.*", + "message": "You did not fill out the description in the title" + } + ] + auto-close-ignore-label: do-not-autoclose - name: Check PR uses: sumally/github-check-tasklist-action@v1