From 0ed493cfc412984dbb794391f5ee2f44a1f93970 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Sun, 7 Aug 2022 01:36:56 +0800 Subject: [PATCH 01/13] =?UTF-8?q?chore:=20=E4=BD=BF=E7=94=A8=20zzyyyl/issu?= =?UTF-8?q?e-checker?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/labeler.yml | 200 +++++++++++++++++++--------------- .github/workflows/labeler.yml | 7 +- 2 files changed, 117 insertions(+), 90 deletions(-) diff --git a/.github/labeler.yml b/.github/labeler.yml index e3e1c1e47c..9694280b4c 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -1,85 +1,115 @@ -# 可以强制加上一个 label -# 可以强制去掉一个 label -# Add 的优先级比 Remove 高 -"module: copilot": - - '(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot)' - - "(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)copilot(?:`|))))[\\s\\S]*$)" -"module: fight": - - '(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle)' - - "(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|^(?![\\s\\S]*(?:\ - 自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot|\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)fight(?:`|))))[\\s\\S]*$)" -"module: GUI": - # 其它模块都匹配不上的时候再尝试匹配GUI - # 因为可能有人说“公招界面”“肉鸽崩溃”“基建闪退”等等 - - '(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|图形化界面|闪退|gui|GUI|インターフェース)' - - "(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|^(?![\\s\\S]*(?:\ - 自动编队|作业|作業|copilot|\ - 刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle|\ - 基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base|\ - 信用|拜访|登录|开始唤醒|visit|login|startup|\ - 公招|招募|公開(募集|求人)|recruit|\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)GUI(?:`|))))[\\s\\S]*$)" -"module: infrast": - - '(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base)' - - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)infrast(?:`|))))[\\s\\S]*$)" -"module: others": - - '(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|信用|拜访|登录|开始唤醒|visit|login|startup)' - - "(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)others(?:`|))))[\\s\\S]*$)" -"module: recruit": - - '(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|公招|招募|公開(募集|求人)|recruit)' - - "(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|^(?![\\s\\S]*(?:\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)recruit(?:`|))))[\\s\\S]*$)" -"module: roguelike": - - '(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|肉(鸽|鴿)|集成战略|rogue|ローグ)' - - "(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)roguelike(?:`|))))[\\s\\S]*$)" -"release": - - '(?:[Aa]dd (?:`|)release(?:`|)|Release v(?:\d)+\.(?:\d)+\.(?:\d)+)' - - "(?:[Aa]dd (?:`|)release(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)release(?:`|))))[\\s\\S]*$)" -"ambiguous": - # 不符合上面任何一个的分类并且(如果是PR)不符合 commitizen - - '(?:[Aa]dd (?:`|)ambiguous(?:`|))' - - "(?:[Aa]dd (?:`|)ambiguous(?:`|)|^(?![\\s\\S]*(?:\ - feat|chore|perf|style|refactor|fix|doc|\ - 自动编队|作业|作業|copilot|\ - 刷图|刷.{0,6}材料|关卡选择|战斗|作战|戰鬥|戦闘|fight|battle|\ - 图形化界面|闪退|gui|GUI|インターフェース|\ - 基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base|\ - 信用|拜访|登录|开始唤醒|visit|login|startup|\ - 公招|招募|公開(募集|求人)|recruit|\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ - Release v(?:\\d)+\\.(?:\\d)+\\.(?:\\d)+|\ - [Rr]emove (?:[Aa]ll labels|(?:`|)ambiguous(?:`|))))[\\s\\S]*$)" -"translation required": - # 不要使用日文发 issue - - "(?:[Aa]dd (?:`|)translation required(?:`|)|([\\u3040-\\u30ff]|[㍿㍐]))" - - "(?:[Aa]dd (?:`|)translation required(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)translation required(?:`|))))[\\s\\S]*$)" -"Client: JP": - - '(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|日(文|语|本|)服|YoStarJP)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: JP(?:`|))))[\\s\\S]*$)" -"Client: EN": - - '(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|英(文|语|)服|国际服|美服|YoStarEN)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: EN(?:`|))))[\\s\\S]*$)" -"Client: KR": - - '(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|韩(文|语|国|)服|YoStarKR)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: KR(?:`|))))[\\s\\S]*$)" -"Client: ZH_TW": - - '(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|繁中服|台(湾|灣|)服|繁体中文服|(龙|龍)成|天下网游|txwy)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: ZH_TW(?:`|))))[\\s\\S]*$)" -"MAA Team": - - '(?:[Aa]dd (?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|))' - - "(?:[Aa]dd (?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|))))[\\s\\S]*$)" +labels: + # 可以强制加上一个 label + # 可以强制去掉一个 label + # Add 的优先级比 Remove 高 + - name: "module: copilot" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot)' + - "(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)copilot(?:`|))))[\\s\\S]*$)" + - name: "module: fight" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle)' + - "(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|^(?![\\s\\S]*(?:\ + 自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot|\ + 肉(鸽|鴿)|集成战略|rogue|ローグ|\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)fight(?:`|))))[\\s\\S]*$)" + - name: "module: GUI" + regexes: + # 其它模块都匹配不上的时候再尝试匹配GUI + # 因为可能有人说“公招界面”“肉鸽崩溃”“基建闪退”等等 + - '(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|图形化界面|闪退|gui|GUI|インターフェース)' + - "(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|^(?![\\s\\S]*(?:\ + 自动编队|作业|作業|copilot|\ + 刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle|\ + 基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base|\ + 信用|拜访|登录|开始唤醒|visit|login|startup|\ + 公招|招募|公開(募集|求人)|recruit|\ + 肉(鸽|鴿)|集成战略|rogue|ローグ|\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)GUI(?:`|))))[\\s\\S]*$)" + - name: "module: infrast" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base)' + - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)infrast(?:`|))))[\\s\\S]*$)" + - name: "module: others" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|信用|拜访|登录|开始唤醒|visit|login|startup)' + - "(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)others(?:`|))))[\\s\\S]*$)" + - name: "module: recruit" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|公招|招募|公開(募集|求人)|recruit)' + - "(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|^(?![\\s\\S]*(?:\ + 肉(鸽|鴿)|集成战略|rogue|ローグ|\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)recruit(?:`|))))[\\s\\S]*$)" + - name: "module: roguelike" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|肉(鸽|鴿)|集成战略|rogue|ローグ)' + - "(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)roguelike(?:`|))))[\\s\\S]*$)" + - name: "release" + regexes: + - '(?:[Aa]dd (?:`|)release(?:`|)|Release v(?:\d)+\.(?:\d)+\.(?:\d)+)' + - "(?:[Aa]dd (?:`|)release(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)release(?:`|))))[\\s\\S]*$)" + - name: "ambiguous" + regexes: + # 不符合上面任何一个的分类并且(如果是PR)不符合 commitizen + - '(?:[Aa]dd (?:`|)ambiguous(?:`|))' + - "(?:[Aa]dd (?:`|)ambiguous(?:`|)|^(?![\\s\\S]*(?:\ + feat|chore|perf|style|refactor|fix|doc|\ + 自动编队|作业|作業|copilot|\ + 刷图|刷.{0,6}材料|关卡选择|战斗|作战|戰鬥|戦闘|fight|battle|\ + 图形化界面|闪退|gui|GUI|インターフェース|\ + 基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base|\ + 信用|拜访|登录|开始唤醒|visit|login|startup|\ + 公招|招募|公開(募集|求人)|recruit|\ + 肉(鸽|鴿)|集成战略|rogue|ローグ|\ + Release v(?:\\d)+\\.(?:\\d)+\\.(?:\\d)+|\ + [Rr]emove (?:[Aa]ll labels|(?:`|)ambiguous(?:`|))))[\\s\\S]*$)" + - name: "translation required" + regexes: + # 不要使用日文发 issue + - "(?:[Aa]dd (?:`|)translation required(?:`|)|([\\u3040-\\u30ff]|[㍿㍐]))" + - "(?:[Aa]dd (?:`|)translation required(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)translation required(?:`|))))[\\s\\S]*$)" + - name: "Client: JP" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|日(文|语|本|)服|YoStarJP)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: JP(?:`|))))[\\s\\S]*$)" + - name: "Client: EN" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|英(文|语|)服|国际服|美服|YoStarEN)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: EN(?:`|))))[\\s\\S]*$)" + - name: "Client: KR" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|韩(文|语|国|)服|YoStarKR)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: KR(?:`|))))[\\s\\S]*$)" + - name: "Client: ZH_TW" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|繁中服|台(湾|灣|)服|繁体中文服|(龙|龍)成|天下网游|txwy)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: ZH_TW(?:`|))))[\\s\\S]*$)" + - name: "MAA Team" + regexes: + - '(?:[Aa]dd (?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|))' + - "(?:[Aa]dd (?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|))))[\\s\\S]*$)" +comments: + - name: Log upload failed + regexes: + - '\[Uploading asst(?:.bak| - 副本|).(?:zip|log)…\]\(\)' + content: + "你的日志没有上传成功,请重新上传。\n\n\ + Your log did not upload successfully, please re-upload it." + - name: Upload failed + regexes: Uploading + content: + "你有一些文件没有上传成功,请重新上传。\n\n\ + You have some files that did not upload successfully, please re-upload them." + disabled-if: + - "Log upload failed" \ No newline at end of file diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml index 3b5abc2d69..b1f4430e78 100644 --- a/.github/workflows/labeler.yml +++ b/.github/workflows/labeler.yml @@ -1,18 +1,15 @@ -name: "Labeler" +name: "Issue Checker" on: issues: types: [opened, edited] - pull_request: - types: [opened, edited] jobs: triage: runs-on: ubuntu-latest steps: - - uses: github/issue-labeler@v2.5 + - uses: zzyyyl/issue-checker@v1.1 with: repo-token: "${{ secrets.GITHUB_TOKEN }}" configuration-path: .github/labeler.yml not-before: 2022-08-05T00:00:00Z - enable-versioned-regex: 0 include-title: 1 From d910942e3c91fffdb8f3761985d50b7644f0eb48 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Mon, 8 Aug 2022 10:19:23 +0800 Subject: [PATCH 02/13] =?UTF-8?q?chore:=20=E7=BB=99=20issue-checker=20?= =?UTF-8?q?=E5=8A=A0=E4=B8=AA=E6=9D=83=E9=99=90=EF=BC=8C=E5=B9=B6=E4=B8=94?= =?UTF-8?q?=E5=A4=84=E7=90=86=20pr?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/labeler.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml index b1f4430e78..1eaa21f3c3 100644 --- a/.github/workflows/labeler.yml +++ b/.github/workflows/labeler.yml @@ -2,6 +2,12 @@ name: "Issue Checker" on: issues: types: [opened, edited] + pull_request: + types: [opened, edited] + +permissions: + issues: write + pull-requests: write jobs: triage: From 9e19ce8da7353ce664a047233a67df65a535a0fc Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Mon, 8 Aug 2022 14:29:21 +0800 Subject: [PATCH 03/13] =?UTF-8?q?chore:=20=E6=9B=B4=E6=96=B0=20issue-check?= =?UTF-8?q?er?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/{labeler.yml => issue-checker.yml} | 65 ++++++++++--------- .../{labeler.yml => issue-checker.yml} | 4 +- 2 files changed, 36 insertions(+), 33 deletions(-) rename .github/{labeler.yml => issue-checker.yml} (78%) rename .github/workflows/{labeler.yml => issue-checker.yml} (78%) diff --git a/.github/labeler.yml b/.github/issue-checker.yml similarity index 78% rename from .github/labeler.yml rename to .github/issue-checker.yml index 9694280b4c..1cc26836f8 100644 --- a/.github/labeler.yml +++ b/.github/issue-checker.yml @@ -7,26 +7,19 @@ labels: - '(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot)' - "(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|^(?![\\s\\S]*(?:\ [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)copilot(?:`|))))[\\s\\S]*$)" + - name: "module: roguelike" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|肉(鸽|鴿)|集成战略|rogue|ローグ)' + - "(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)roguelike(?:`|))))[\\s\\S]*$)" - name: "module: fight" regexes: - '(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle)' - "(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|^(?![\\s\\S]*(?:\ - 自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot|\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)fight(?:`|))))[\\s\\S]*$)" - - name: "module: GUI" - regexes: - # 其它模块都匹配不上的时候再尝试匹配GUI - # 因为可能有人说“公招界面”“肉鸽崩溃”“基建闪退”等等 - - '(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|图形化界面|闪退|gui|GUI|インターフェース)' - - "(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|^(?![\\s\\S]*(?:\ - 自动编队|作业|作業|copilot|\ - 刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle|\ - 基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base|\ - 信用|拜访|登录|开始唤醒|visit|login|startup|\ - 公招|招募|公開(募集|求人)|recruit|\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)GUI(?:`|))))[\\s\\S]*$)" + disabled-if: + - "module: copilot" + - "module: roguelike" - name: "module: infrast" regexes: - '(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base)' @@ -41,36 +34,46 @@ labels: regexes: - '(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|公招|招募|公開(募集|求人)|recruit)' - "(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|^(?![\\s\\S]*(?:\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)recruit(?:`|))))[\\s\\S]*$)" - - name: "module: roguelike" + disabled-if: + - "module: roguelike" + - name: "module: GUI" + # 其它模块都匹配不上的时候再尝试匹配GUI + # 因为可能有人说“公招界面”“肉鸽崩溃”“基建闪退”等等 regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|肉(鸽|鴿)|集成战略|rogue|ローグ)' - - "(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)roguelike(?:`|))))[\\s\\S]*$)" + - '(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|图形化界面|闪退|gui|GUI|インターフェース)' + - "(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)GUI(?:`|))))[\\s\\S]*$)" + disabled-if: + - "module: copilot" + - "module: fight" + - "module: infrast" + - "module: recruit" + - "module: roguelike" + - "module: others" - name: "release" regexes: - '(?:[Aa]dd (?:`|)release(?:`|)|Release v(?:\d)+\.(?:\d)+\.(?:\d)+)' - "(?:[Aa]dd (?:`|)release(?:`|)|^(?![\\s\\S]*(?:\ [Rr]emove (?:[Aa]ll labels|(?:`|)release(?:`|))))[\\s\\S]*$)" - name: "ambiguous" + # 不符合上面任何一个的分类并且(如果是PR)不符合 commitizen regexes: - # 不符合上面任何一个的分类并且(如果是PR)不符合 commitizen - - '(?:[Aa]dd (?:`|)ambiguous(?:`|))' - "(?:[Aa]dd (?:`|)ambiguous(?:`|)|^(?![\\s\\S]*(?:\ feat|chore|perf|style|refactor|fix|doc|\ - 自动编队|作业|作業|copilot|\ - 刷图|刷.{0,6}材料|关卡选择|战斗|作战|戰鬥|戦闘|fight|battle|\ - 图形化界面|闪退|gui|GUI|インターフェース|\ - 基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base|\ - 信用|拜访|登录|开始唤醒|visit|login|startup|\ - 公招|招募|公開(募集|求人)|recruit|\ - 肉(鸽|鴿)|集成战略|rogue|ローグ|\ - Release v(?:\\d)+\\.(?:\\d)+\\.(?:\\d)+|\ [Rr]emove (?:[Aa]ll labels|(?:`|)ambiguous(?:`|))))[\\s\\S]*$)" + disabled-if: + - "module: copilot" + - "module: fight" + - "module: GUI" + - "module: infrast" + - "module: others" + - "module: recruit" + - "module: roguelike" + - "release" - name: "translation required" + # 不要使用日文发 issue regexes: - # 不要使用日文发 issue - "(?:[Aa]dd (?:`|)translation required(?:`|)|([\\u3040-\\u30ff]|[㍿㍐]))" - "(?:[Aa]dd (?:`|)translation required(?:`|)|^(?![\\s\\S]*(?:\ [Rr]emove (?:[Aa]ll labels|(?:`|)translation required(?:`|))))[\\s\\S]*$)" diff --git a/.github/workflows/labeler.yml b/.github/workflows/issue-checker.yml similarity index 78% rename from .github/workflows/labeler.yml rename to .github/workflows/issue-checker.yml index 1eaa21f3c3..b2db802aad 100644 --- a/.github/workflows/labeler.yml +++ b/.github/workflows/issue-checker.yml @@ -13,9 +13,9 @@ jobs: triage: runs-on: ubuntu-latest steps: - - uses: zzyyyl/issue-checker@v1.1 + - uses: zzyyyl/issue-checker@v1.2 with: repo-token: "${{ secrets.GITHUB_TOKEN }}" - configuration-path: .github/labeler.yml + configuration-path: .github/issue-checker.yml not-before: 2022-08-05T00:00:00Z include-title: 1 From 909a55263f48c55196f066bc1b01faa0ddcac7e0 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Mon, 8 Aug 2022 14:28:54 +0800 Subject: [PATCH 04/13] =?UTF-8?q?chore:=20=E5=86=8D=E5=8A=A0=E4=B8=AA?= =?UTF-8?q?=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/issue-checker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/issue-checker.yml b/.github/workflows/issue-checker.yml index b2db802aad..2d38bb740d 100644 --- a/.github/workflows/issue-checker.yml +++ b/.github/workflows/issue-checker.yml @@ -6,6 +6,7 @@ on: types: [opened, edited] permissions: + contents: read issues: write pull-requests: write From 38e6cb9a395795a6dd4277c8017347fc113db691 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Mon, 8 Aug 2022 15:38:43 +0800 Subject: [PATCH 05/13] =?UTF-8?q?chore:=20=E6=B5=8B=E8=AF=95=20`author=5Fa?= =?UTF-8?q?ssociation`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/issue-checker.yml | 6 ++---- .github/workflows/issue-checker.yml | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/issue-checker.yml b/.github/issue-checker.yml index 1cc26836f8..a60852daf6 100644 --- a/.github/issue-checker.yml +++ b/.github/issue-checker.yml @@ -98,10 +98,8 @@ labels: - "(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|^(?![\\s\\S]*(?:\ [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: ZH_TW(?:`|))))[\\s\\S]*$)" - name: "MAA Team" - regexes: - - '(?:[Aa]dd (?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|))' - - "(?:[Aa]dd (?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:MAA|maa)(?: |)[Tt]eam(?:`|))))[\\s\\S]*$)" + author_association: + - "MEMBER" comments: - name: Log upload failed regexes: diff --git a/.github/workflows/issue-checker.yml b/.github/workflows/issue-checker.yml index 2d38bb740d..a086a1208c 100644 --- a/.github/workflows/issue-checker.yml +++ b/.github/workflows/issue-checker.yml @@ -14,7 +14,7 @@ jobs: triage: runs-on: ubuntu-latest steps: - - uses: zzyyyl/issue-checker@v1.2 + - uses: zzyyyl/issue-checker@v1.3 with: repo-token: "${{ secrets.GITHUB_TOKEN }}" configuration-path: .github/issue-checker.yml From 2891270925d575e00037621642d94bd3efe25b9c Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Mon, 8 Aug 2022 16:44:07 +0800 Subject: [PATCH 06/13] =?UTF-8?q?chore:=20=E4=BF=AE=E5=A4=8D=20issue-check?= =?UTF-8?q?er=20=E6=B2=A1=E6=9C=89=E7=BB=99=20PR=20=E6=89=93=E6=A0=87?= =?UTF-8?q?=E7=AD=BE=E6=9D=83=E9=99=90=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/issue-checker.yml | 2 +- .github/workflows/issue-checker.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/issue-checker.yml b/.github/issue-checker.yml index a60852daf6..c95a084662 100644 --- a/.github/issue-checker.yml +++ b/.github/issue-checker.yml @@ -103,7 +103,7 @@ labels: comments: - name: Log upload failed regexes: - - '\[Uploading asst(?:.bak| - 副本|).(?:zip|log)…\]\(\)' + - '\[Uploading asst(?:.bak|)(?: - 副本|).(?:zip|log)…\]\(\)' content: "你的日志没有上传成功,请重新上传。\n\n\ Your log did not upload successfully, please re-upload it." diff --git a/.github/workflows/issue-checker.yml b/.github/workflows/issue-checker.yml index a086a1208c..c94a5241b3 100644 --- a/.github/workflows/issue-checker.yml +++ b/.github/workflows/issue-checker.yml @@ -2,7 +2,7 @@ name: "Issue Checker" on: issues: types: [opened, edited] - pull_request: + pull_request_target: types: [opened, edited] permissions: From 5ea51dc58b0bc10a25a38b40e45591447ae109a2 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Mon, 8 Aug 2022 16:58:29 +0800 Subject: [PATCH 07/13] =?UTF-8?q?chore:=20=E4=BF=AE=E6=94=B9=E4=B8=80?= =?UTF-8?q?=E4=BA=9B=E5=85=B3=E9=94=AE=E8=AF=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `base` 也太容易误判了( --- .github/issue-checker.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/issue-checker.yml b/.github/issue-checker.yml index c95a084662..a068a962cb 100644 --- a/.github/issue-checker.yml +++ b/.github/issue-checker.yml @@ -22,7 +22,8 @@ labels: - "module: roguelike" - name: "module: infrast" regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|基建|贸易站|制造站|控制中枢|会客室|基地|infrast|base)' + - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|\ + 基建|贸易站|制造站|发电站|加工站|会客室|训练室|办公室|控制中枢|宿舍|基地|infrast|dorm)" - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|^(?![\\s\\S]*(?:\ [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)infrast(?:`|))))[\\s\\S]*$)" - name: "module: others" From 55606c0aff4ddd41ba6d050bfe3165e4fb5c6950 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Tue, 9 Aug 2022 13:24:15 +0800 Subject: [PATCH 08/13] =?UTF-8?q?chore:=20=E6=9B=B4=E6=96=B0=20zzyyyl/issu?= =?UTF-8?q?e-checker,=20=E5=A2=9E=E5=8A=A0=E5=A4=84=E7=90=86=20issue=5Fcom?= =?UTF-8?q?ment=20=E7=9A=84=20`fixed`=20=E5=92=8C=20`duplicate`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/issue-checker.yml | 272 ++++++++++++++++------------ .github/workflows/issue-checker.yml | 4 +- 2 files changed, 160 insertions(+), 116 deletions(-) diff --git a/.github/issue-checker.yml b/.github/issue-checker.yml index a068a962cb..dd3409ec89 100644 --- a/.github/issue-checker.yml +++ b/.github/issue-checker.yml @@ -1,117 +1,159 @@ +default-mode: + pull_request_target: [add, remove] + issues: [add, remove] + issue_comment: [add] labels: - # 可以强制加上一个 label - # 可以强制去掉一个 label - # Add 的优先级比 Remove 高 - - name: "module: copilot" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot)' - - "(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)copilot(?:`|))))[\\s\\S]*$)" - - name: "module: roguelike" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|肉(鸽|鴿)|集成战略|rogue|ローグ)' - - "(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)roguelike(?:`|))))[\\s\\S]*$)" - - name: "module: fight" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle)' - - "(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)fight(?:`|))))[\\s\\S]*$)" - disabled-if: - - "module: copilot" - - "module: roguelike" - - name: "module: infrast" - regexes: - - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|\ - 基建|贸易站|制造站|发电站|加工站|会客室|训练室|办公室|控制中枢|宿舍|基地|infrast|dorm)" - - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)infrast(?:`|))))[\\s\\S]*$)" - - name: "module: others" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|信用|拜访|登录|开始唤醒|visit|login|startup)' - - "(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)others(?:`|))))[\\s\\S]*$)" - - name: "module: recruit" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|公招|招募|公開(募集|求人)|recruit)' - - "(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)recruit(?:`|))))[\\s\\S]*$)" - disabled-if: - - "module: roguelike" - - name: "module: GUI" - # 其它模块都匹配不上的时候再尝试匹配GUI - # 因为可能有人说“公招界面”“肉鸽崩溃”“基建闪退”等等 - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|图形化界面|闪退|gui|GUI|インターフェース)' - - "(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)GUI(?:`|))))[\\s\\S]*$)" - disabled-if: - - "module: copilot" - - "module: fight" - - "module: infrast" - - "module: recruit" - - "module: roguelike" - - "module: others" - - name: "release" - regexes: - - '(?:[Aa]dd (?:`|)release(?:`|)|Release v(?:\d)+\.(?:\d)+\.(?:\d)+)' - - "(?:[Aa]dd (?:`|)release(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)release(?:`|))))[\\s\\S]*$)" - - name: "ambiguous" - # 不符合上面任何一个的分类并且(如果是PR)不符合 commitizen - regexes: - - "(?:[Aa]dd (?:`|)ambiguous(?:`|)|^(?![\\s\\S]*(?:\ - feat|chore|perf|style|refactor|fix|doc|\ - [Rr]emove (?:[Aa]ll labels|(?:`|)ambiguous(?:`|))))[\\s\\S]*$)" - disabled-if: - - "module: copilot" - - "module: fight" - - "module: GUI" - - "module: infrast" - - "module: others" - - "module: recruit" - - "module: roguelike" - - "release" - - name: "translation required" - # 不要使用日文发 issue - regexes: - - "(?:[Aa]dd (?:`|)translation required(?:`|)|([\\u3040-\\u30ff]|[㍿㍐]))" - - "(?:[Aa]dd (?:`|)translation required(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)translation required(?:`|))))[\\s\\S]*$)" - - name: "Client: JP" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|日(文|语|本|)服|YoStarJP)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: JP(?:`|))))[\\s\\S]*$)" - - name: "Client: EN" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|英(文|语|)服|国际服|美服|YoStarEN)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: EN(?:`|))))[\\s\\S]*$)" - - name: "Client: KR" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|韩(文|语|国|)服|YoStarKR)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: KR(?:`|))))[\\s\\S]*$)" - - name: "Client: ZH_TW" - regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|繁中服|台(湾|灣|)服|繁体中文服|(龙|龍)成|天下网游|txwy)' - - "(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|^(?![\\s\\S]*(?:\ - [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: ZH_TW(?:`|))))[\\s\\S]*$)" - - name: "MAA Team" - author_association: - - "MEMBER" +# 可以强制加上一个 label +# 可以强制去掉一个 label +# Add 的优先级比 Remove 高 +- name: "module: copilot" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|自动(作战|战斗|编队)|作业|自動(戰|戦)(鬥|闘)|作業|copilot)' + - "(?:[Aa]dd (?:`|)(?:module: |)copilot(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)copilot(?:`|))))[\\s\\S]*$)" +- name: "module: roguelike" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|肉(鸽|鴿)|集成战略|rogue|ローグ)' + - "(?:[Aa]dd (?:`|)(?:module: |)roguelike(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)roguelike(?:`|))))[\\s\\S]*$)" +- name: "module: fight" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle)' + - "(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)fight(?:`|))))[\\s\\S]*$)" + disabled-if: + - "module: copilot" + - "module: roguelike" +- name: "module: infrast" + regexes: + - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|\ + 基建|贸易站|制造站|发电站|加工站|会客室|训练室|办公室|控制中枢|宿舍|基地|infrast|dorm)" + - "(?:[Aa]dd (?:`|)(?:module: |)infrast(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)infrast(?:`|))))[\\s\\S]*$)" +- name: "module: others" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|信用|拜访|登录|开始唤醒|visit|login|startup)' + - "(?:[Aa]dd (?:`|)(?:module: |)others(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)others(?:`|))))[\\s\\S]*$)" +- name: "module: recruit" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|公招|招募|公開(募集|求人)|recruit)' + - "(?:[Aa]dd (?:`|)(?:module: |)recruit(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)recruit(?:`|))))[\\s\\S]*$)" + disabled-if: + - "module: roguelike" +- name: "module: GUI" + # 其它模块都匹配不上的时候再尝试匹配GUI + # 因为可能有人说“公招界面”“肉鸽崩溃”“基建闪退”等等 + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|图形化界面|闪退|gui|GUI|インターフェース)' + - "(?:[Aa]dd (?:`|)(?:module: |)GUI(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)GUI(?:`|))))[\\s\\S]*$)" + disabled-if: + - "module: copilot" + - "module: fight" + - "module: infrast" + - "module: recruit" + - "module: roguelike" + - "module: others" +- name: "release" + regexes: + - '(?:[Aa]dd (?:`|)release(?:`|)|Release v(?:\d)+\.(?:\d)+\.(?:\d)+)' + - "(?:[Aa]dd (?:`|)release(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)release(?:`|))))[\\s\\S]*$)" + mode: + pull_request_target: [add, remove] +- name: "ambiguous" + # 不符合上面任何一个的分类并且(如果是PR)不符合 commitizen + regexes: + - "(?:[Aa]dd (?:`|)ambiguous(?:`|)|^(?![\\s\\S]*(?:\ + feat|chore|perf|style|refactor|fix|doc|\ + [Rr]emove (?:[Aa]ll labels|(?:`|)ambiguous(?:`|))))[\\s\\S]*$)" + mode: + pull_request_target: [add, remove] + issues: [add, remove] + issue_comment: [remove] + disabled-if: + - "module: copilot" + - "module: fight" + - "module: GUI" + - "module: infrast" + - "module: others" + - "module: recruit" + - "module: roguelike" + - "release" +- name: "translation required" + # 不要使用日文发 issue + regexes: + - "(?:[Aa]dd (?:`|)translation required(?:`|)|([\\u3040-\\u30ff]|[㍿㍐]))" + - "(?:[Aa]dd (?:`|)translation required(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)translation required(?:`|))))[\\s\\S]*$)" + mode: + pull_request_target: [add, remove] + issues: [add, remove] +- name: "Client: JP" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|日(文|语|本|)服|YoStarJP)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: JP(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: JP(?:`|))))[\\s\\S]*$)" +- name: "Client: EN" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|英(文|语|)服|国际服|美服|YoStarEN)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: EN(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: EN(?:`|))))[\\s\\S]*$)" +- name: "Client: KR" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|韩(文|语|国|)服|YoStarKR)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: KR(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: KR(?:`|))))[\\s\\S]*$)" +- name: "Client: ZH_TW" + regexes: + - '(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|繁中服|台(湾|灣|)服|繁体中文服|(龙|龍)成|天下网游|txwy)' + - "(?:[Aa]dd (?:`|)(?:module: |)Client: ZH_TW(?:`|)|^(?![\\s\\S]*(?:\ + [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)Client: ZH_TW(?:`|))))[\\s\\S]*$)" +- name: "MAA Team" + mode: + pull_request_target: [add] + issues: [add] + author_association: + - "MEMBER" +- name: "fixed" + regexes: + - "(?:(?:`v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|)`|\ + v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|)\\s+)|\ + \\[(?:`v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|)`|\ + v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|))\\]\\(\\S*\\))\ + \\s*fixed|(?:[Ff]ixed by\\s*\ + (?:`v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|)`|\\s+\ + v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|))|\ + \\[(?:`v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|)`|\ + v\\d+\\.\\d+\\.\\d+(?:-(?:alpha|beta)\\.\\d+|\\.\\d+|))\\]\\(\\S*\\))" + mode: + issue_comment: [add] +- name: "duplicate" + regexes: + "[Dd]uplicate of\\s*\\[?`?#\\d+" + mode: + issue_comment: [add] comments: - - name: Log upload failed - regexes: - - '\[Uploading asst(?:.bak|)(?: - 副本|).(?:zip|log)…\]\(\)' - content: - "你的日志没有上传成功,请重新上传。\n\n\ - Your log did not upload successfully, please re-upload it." - - name: Upload failed - regexes: Uploading - content: - "你有一些文件没有上传成功,请重新上传。\n\n\ - You have some files that did not upload successfully, please re-upload them." - disabled-if: - - "Log upload failed" \ No newline at end of file +- name: Log upload failed + regexes: + - '\[Uploading asst(?:.bak|)(?: - 副本|).(?:zip|log)…\]\(\)' + content: + "你的日志没有上传成功,请重新上传。\n\n\ + Your log did not upload successfully, please re-upload it." + mode: + pull_request_target: [add] + issues: [add] + issue_comment: [add] +- name: Upload failed + regexes: Uploading + content: + "你有一些文件没有上传成功,请重新上传。\n\n\ + You have some files that did not upload successfully, please re-upload them." + mode: + pull_request_target: [add] + issues: [add] + issue_comment: [add] + disabled-if: + - "Log upload failed" diff --git a/.github/workflows/issue-checker.yml b/.github/workflows/issue-checker.yml index c94a5241b3..c5179fffb3 100644 --- a/.github/workflows/issue-checker.yml +++ b/.github/workflows/issue-checker.yml @@ -4,6 +4,8 @@ on: types: [opened, edited] pull_request_target: types: [opened, edited] + issue_comment: + types: [created, edited] permissions: contents: read @@ -14,7 +16,7 @@ jobs: triage: runs-on: ubuntu-latest steps: - - uses: zzyyyl/issue-checker@v1.3 + - uses: zzyyyl/issue-checker@v1.4 with: repo-token: "${{ secrets.GITHUB_TOKEN }}" configuration-path: .github/issue-checker.yml From 2314305385ad68a3acc9306879a4a413144a7e53 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Tue, 9 Aug 2022 14:55:21 +0800 Subject: [PATCH 09/13] =?UTF-8?q?chore:=20=E4=BD=BF=E7=94=A8=E9=9A=90?= =?UTF-8?q?=E8=97=8F=E5=8A=9F=E8=83=BD=20push?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit close #1492 --- .github/workflows/issue-checker.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/issue-checker.yml b/.github/workflows/issue-checker.yml index c5179fffb3..5c527d8348 100644 --- a/.github/workflows/issue-checker.yml +++ b/.github/workflows/issue-checker.yml @@ -6,6 +6,7 @@ on: types: [opened, edited] issue_comment: types: [created, edited] + push: permissions: contents: read @@ -16,7 +17,7 @@ jobs: triage: runs-on: ubuntu-latest steps: - - uses: zzyyyl/issue-checker@v1.4 + - uses: zzyyyl/issue-checker@v1.5 with: repo-token: "${{ secrets.GITHUB_TOKEN }}" configuration-path: .github/issue-checker.yml From ba2b3fca3a10cceac29a0bff18e2a17a2d76864c Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Tue, 9 Aug 2022 15:30:31 +0800 Subject: [PATCH 10/13] =?UTF-8?q?chore:=20=E5=A2=9E=E5=8A=A0=20issue-check?= =?UTF-8?q?er=20`module:=20fight`=20=E5=85=B3=E9=94=AE=E8=AF=8D=20`?= =?UTF-8?q?=E5=89=BF=E7=81=AD`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/issue-checker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/issue-checker.yml b/.github/issue-checker.yml index dd3409ec89..2de511c086 100644 --- a/.github/issue-checker.yml +++ b/.github/issue-checker.yml @@ -18,7 +18,7 @@ labels: [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)roguelike(?:`|))))[\\s\\S]*$)" - name: "module: fight" regexes: - - '(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|刷图|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle)' + - '(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|刷图|剿灭|刷.{0,6}材料|关卡选择|战斗|作战|(戰|戦)(鬥|闘)|fight|battle)' - "(?:[Aa]dd (?:`|)(?:module: |)fight(?:`|)|^(?![\\s\\S]*(?:\ [Rr]emove (?:[Aa]ll labels|(?:`|)(?:module: |)fight(?:`|))))[\\s\\S]*$)" disabled-if: From ce47ae41ac04d0f535097e97e8e1a05699507e72 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Wed, 10 Aug 2022 14:24:17 +0800 Subject: [PATCH 11/13] chore: Update issue template --- .github/ISSUE_TEMPLATE/-----bug-report-.yaml | 2 +- .../ISSUE_TEMPLATE/-----bug-report-en-.yaml | 74 +++++++++++++++++++ .../ISSUE_TEMPLATE/-----feature-request-.yaml | 2 +- .../-----feature-request-en-.yaml | 23 ++++++ .github/ISSUE_TEMPLATE/---others-.md | 6 +- .github/ISSUE_TEMPLATE/---others-en-.md | 10 +++ 6 files changed, 112 insertions(+), 5 deletions(-) create mode 100644 .github/ISSUE_TEMPLATE/-----bug-report-en-.yaml create mode 100644 .github/ISSUE_TEMPLATE/-----feature-request-en-.yaml create mode 100644 .github/ISSUE_TEMPLATE/---others-en-.md diff --git a/.github/ISSUE_TEMPLATE/-----bug-report-.yaml b/.github/ISSUE_TEMPLATE/-----bug-report-.yaml index 64a469923b..af469206c6 100644 --- a/.github/ISSUE_TEMPLATE/-----bug-report-.yaml +++ b/.github/ISSUE_TEMPLATE/-----bug-report-.yaml @@ -1,4 +1,4 @@ -name: 问题反馈(Bug report) +name: 问题反馈 description: 识别错误、操作异常、连接错误等 labels: ['bug'] body: diff --git a/.github/ISSUE_TEMPLATE/-----bug-report-en-.yaml b/.github/ISSUE_TEMPLATE/-----bug-report-en-.yaml new file mode 100644 index 0000000000..4bd3c89547 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/-----bug-report-en-.yaml @@ -0,0 +1,74 @@ +name: Bug Report +description: >- + Recognition errors, operation abnormalities, + connection errors, etc. +labels: ['bug'] +body: + - type: checkboxes + id: checks + attributes: + label: Before raising the issue... + options: + - label: >- + I understand that Issues are for feedback and problem solving, + not trolling the comments section, and will provide as + much information as possible to help solve the problem. + required: true + - label: >- + I spent at least 5 minutes thinking and preparing + before raising the issue. + required: true + - label: >- + I have read the FAQ and the User Manual in the documentation + and believe that this is most likely a bug and not designed + to be so. + required: true + - label: >- + I have checked the latest beta update and there is no mention + of the bug being fixed. + required: true + - type: textarea + id: describe + attributes: + label: Description + description: Describe your problem in as much detail as possible + validations: + required: true + - type: textarea + id: logs + attributes: + label: Log files + description: >- + Upload the `asst.log` log file from the software directory and + indicate the approximate point in time when the problem occurred. + + Please drag and drop the full file in, not your own cuttings; + compress it before uploading if too large. + validations: + required: true + - type: textarea + id: screenshots + attributes: + label: Screenshots + description: >- + If available, add screenshots to help explain your problem, + including but not limited to screenshots of MAA software, + screenshots of game screens. + + If the problem is recognition related, please help by providing + the original image taken by the emulator's own screenshot tool + (or via adb). + validations: + required: false + - type: textarea + id: others + attributes: + label: Anthing else? + description: >- + Emulator used, operating system, related configuration, links, + reference material, etc. + + Anything that will give us more insight into the problem + you are having. + validations: + required: false diff --git a/.github/ISSUE_TEMPLATE/-----feature-request-.yaml b/.github/ISSUE_TEMPLATE/-----feature-request-.yaml index e7158589da..d7573041b3 100644 --- a/.github/ISSUE_TEMPLATE/-----feature-request-.yaml +++ b/.github/ISSUE_TEMPLATE/-----feature-request-.yaml @@ -1,4 +1,4 @@ -name: 需求建议(Feature request) +name: 需求建议 description: 新功能、建议等 labels: ['enhancement'] body: diff --git a/.github/ISSUE_TEMPLATE/-----feature-request-en-.yaml b/.github/ISSUE_TEMPLATE/-----feature-request-en-.yaml new file mode 100644 index 0000000000..9a2fc286da --- /dev/null +++ b/.github/ISSUE_TEMPLATE/-----feature-request-en-.yaml @@ -0,0 +1,23 @@ +name: Feature Request +description: New features, suggestions, etc. +labels: ['enhancement'] +body: + - type: textarea + id: describe + attributes: + label: The problems you have encountered? + validations: + required: false + - type: textarea + id: solution + attributes: + label: Any good ideas? + validations: + required: false + - type: textarea + id: additional + attributes: + label: Additional + description: Any other background, screen shots, etc. + validations: + required: false diff --git a/.github/ISSUE_TEMPLATE/---others-.md b/.github/ISSUE_TEMPLATE/---others-.md index 209760a952..1733ef5c62 100644 --- a/.github/ISSUE_TEMPLATE/---others-.md +++ b/.github/ISSUE_TEMPLATE/---others-.md @@ -1,8 +1,8 @@ --- -name: 其他(Others) -about: 其他议题 +name: 其他 +about: 提出问题,但不是报告错误或需求建议 title: '' -labels: '' +labels: 'question' assignees: '' --- diff --git a/.github/ISSUE_TEMPLATE/---others-en-.md b/.github/ISSUE_TEMPLATE/---others-en-.md new file mode 100644 index 0000000000..1bd75ae71e --- /dev/null +++ b/.github/ISSUE_TEMPLATE/---others-en-.md @@ -0,0 +1,10 @@ +--- +name: Others +about: Ask a question rather than a bug report or feature request. +title: '' +labels: 'question' +assignees: '' + +--- + + From 8e7471d1d5b61ff97bec1e2cd62ab20ec4e603e8 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Wed, 10 Aug 2022 14:36:08 +0800 Subject: [PATCH 12/13] chore: Update issue template MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 什么叫名字太短啊 kora --- .github/ISSUE_TEMPLATE/---others-.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/ISSUE_TEMPLATE/---others-.md b/.github/ISSUE_TEMPLATE/---others-.md index 1733ef5c62..aa2e922db8 100644 --- a/.github/ISSUE_TEMPLATE/---others-.md +++ b/.github/ISSUE_TEMPLATE/---others-.md @@ -1,5 +1,5 @@ --- -name: 其他 +name: 其他议题 about: 提出问题,但不是报告错误或需求建议 title: '' labels: 'question' From 5ad6f7847497cc81708be9294f7b4f6875066c83 Mon Sep 17 00:00:00 2001 From: zzyyyl Date: Wed, 10 Aug 2022 15:23:09 +0800 Subject: [PATCH 13/13] =?UTF-8?q?chore:=20=E5=A2=9E=E5=8A=A0=E4=B8=80?= =?UTF-8?q?=E4=BA=9B=20Issue=20=E6=A8=A1=E6=9D=BF=E7=9A=84=E6=8F=8F?= =?UTF-8?q?=E8=BF=B0=EF=BC=8C=E8=B0=83=E6=95=B4=E9=A1=BA=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../{-----bug-report-.yaml => cn-bug-report.yaml} | 2 +- .../{-----feature-request-.yaml => cn-feature-request.yaml} | 2 +- .github/ISSUE_TEMPLATE/{---others-.md => cn-others.md} | 2 +- .../{-----bug-report-en-.yaml => en-bug-report.yaml} | 2 +- .../{-----feature-request-en-.yaml => en-feature-request.yaml} | 2 +- .github/ISSUE_TEMPLATE/{---others-en-.md => en-others-.md} | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) rename .github/ISSUE_TEMPLATE/{-----bug-report-.yaml => cn-bug-report.yaml} (98%) rename .github/ISSUE_TEMPLATE/{-----feature-request-.yaml => cn-feature-request.yaml} (93%) rename .github/ISSUE_TEMPLATE/{---others-.md => cn-others.md} (75%) rename .github/ISSUE_TEMPLATE/{-----bug-report-en-.yaml => en-bug-report.yaml} (98%) rename .github/ISSUE_TEMPLATE/{-----feature-request-en-.yaml => en-feature-request.yaml} (93%) rename .github/ISSUE_TEMPLATE/{---others-en-.md => en-others-.md} (82%) diff --git a/.github/ISSUE_TEMPLATE/-----bug-report-.yaml b/.github/ISSUE_TEMPLATE/cn-bug-report.yaml similarity index 98% rename from .github/ISSUE_TEMPLATE/-----bug-report-.yaml rename to .github/ISSUE_TEMPLATE/cn-bug-report.yaml index af469206c6..a55210b1db 100644 --- a/.github/ISSUE_TEMPLATE/-----bug-report-.yaml +++ b/.github/ISSUE_TEMPLATE/cn-bug-report.yaml @@ -1,4 +1,4 @@ -name: 问题反馈 +name: 问题反馈(使用中文) description: 识别错误、操作异常、连接错误等 labels: ['bug'] body: diff --git a/.github/ISSUE_TEMPLATE/-----feature-request-.yaml b/.github/ISSUE_TEMPLATE/cn-feature-request.yaml similarity index 93% rename from .github/ISSUE_TEMPLATE/-----feature-request-.yaml rename to .github/ISSUE_TEMPLATE/cn-feature-request.yaml index d7573041b3..9411edb333 100644 --- a/.github/ISSUE_TEMPLATE/-----feature-request-.yaml +++ b/.github/ISSUE_TEMPLATE/cn-feature-request.yaml @@ -1,4 +1,4 @@ -name: 需求建议 +name: 需求建议(使用中文) description: 新功能、建议等 labels: ['enhancement'] body: diff --git a/.github/ISSUE_TEMPLATE/---others-.md b/.github/ISSUE_TEMPLATE/cn-others.md similarity index 75% rename from .github/ISSUE_TEMPLATE/---others-.md rename to .github/ISSUE_TEMPLATE/cn-others.md index aa2e922db8..3301c9276b 100644 --- a/.github/ISSUE_TEMPLATE/---others-.md +++ b/.github/ISSUE_TEMPLATE/cn-others.md @@ -1,5 +1,5 @@ --- -name: 其他议题 +name: 其他议题(使用中文) about: 提出问题,但不是报告错误或需求建议 title: '' labels: 'question' diff --git a/.github/ISSUE_TEMPLATE/-----bug-report-en-.yaml b/.github/ISSUE_TEMPLATE/en-bug-report.yaml similarity index 98% rename from .github/ISSUE_TEMPLATE/-----bug-report-en-.yaml rename to .github/ISSUE_TEMPLATE/en-bug-report.yaml index 4bd3c89547..91c8e160c5 100644 --- a/.github/ISSUE_TEMPLATE/-----bug-report-en-.yaml +++ b/.github/ISSUE_TEMPLATE/en-bug-report.yaml @@ -1,4 +1,4 @@ -name: Bug Report +name: Bug Report (in English) description: >- Recognition errors, operation abnormalities, connection errors, etc. diff --git a/.github/ISSUE_TEMPLATE/-----feature-request-en-.yaml b/.github/ISSUE_TEMPLATE/en-feature-request.yaml similarity index 93% rename from .github/ISSUE_TEMPLATE/-----feature-request-en-.yaml rename to .github/ISSUE_TEMPLATE/en-feature-request.yaml index 9a2fc286da..67bed8f56f 100644 --- a/.github/ISSUE_TEMPLATE/-----feature-request-en-.yaml +++ b/.github/ISSUE_TEMPLATE/en-feature-request.yaml @@ -1,4 +1,4 @@ -name: Feature Request +name: Feature Request (in English) description: New features, suggestions, etc. labels: ['enhancement'] body: diff --git a/.github/ISSUE_TEMPLATE/---others-en-.md b/.github/ISSUE_TEMPLATE/en-others-.md similarity index 82% rename from .github/ISSUE_TEMPLATE/---others-en-.md rename to .github/ISSUE_TEMPLATE/en-others-.md index 1bd75ae71e..68ad6356e4 100644 --- a/.github/ISSUE_TEMPLATE/---others-en-.md +++ b/.github/ISSUE_TEMPLATE/en-others-.md @@ -1,5 +1,5 @@ --- -name: Others +name: Others (in English) about: Ask a question rather than a bug report or feature request. title: '' labels: 'question'