mirror of
https://github.com/MaaAssistantArknights/MaaAssistantArknights.git
synced 2026-07-15 17:30:27 +08:00
chore: feature-request增加陷阱选项 改进en-bug-report标题 (#12917)
* chore: cn-feature-request * chore: en-feature-request * chore: 呃呃怎么写description里了 * ci: issue-checkbox-checker --------- Co-authored-by: 晓丶梦丶仁 <74444214+Daydreamer114@users.noreply.github.com>
This commit is contained in:
26
.github/workflows/issue-checkbox-checker.yml
vendored
26
.github/workflows/issue-checkbox-checker.yml
vendored
@@ -47,18 +47,28 @@ jobs:
|
||||
with:
|
||||
script: |
|
||||
const originalBody = context.payload.issue.body;
|
||||
const checkboxSectionRegex_cn = /([\s\S]*?)(### 问题描述\n\n)/;
|
||||
const checkboxSectionRegex_en = /([\s\S]*?)(### Description\n\n)/;
|
||||
|
||||
const foldedBody_cn = originalBody.replace(
|
||||
checkboxSectionRegex_cn,
|
||||
const checkboxSectionRegex_cn_bug = /([\s\S]*?)(### 问题描述\n\n)/;
|
||||
const checkboxSectionRegex_cn_feat = /([\s\S]*?)(### 说说你遇到的问题?\n\n)/;
|
||||
const checkboxSectionRegex_en_bug = /([\s\S]*?)(### Description\n\n)/;
|
||||
const checkboxSectionRegex_en_feat = /([\s\S]*?)(### The problems you have encountered?\n\n)/;
|
||||
|
||||
const foldedBody_cn_bug = originalBody.replace(
|
||||
checkboxSectionRegex_cn_bug,
|
||||
`<details><summary>Checkboxes</summary>\n\n$1\n\n</details>\n\n$2`
|
||||
);
|
||||
const foldedBody = foldedBody_cn.replace(
|
||||
checkboxSectionRegex_en,
|
||||
const foldedBody_cn_feat = foldedBody_cn_bug.replace(
|
||||
checkboxSectionRegex_cn_feat,
|
||||
`<details><summary>Checkboxes</summary>\n\n$1\n\n</details>\n\n$2`
|
||||
);
|
||||
|
||||
const foldedBody_en_bug = foldedBody_cn_feat.replace(
|
||||
checkboxSectionRegex_en_bug,
|
||||
`<details><summary>Checkboxes</summary>\n\n$1\n\n</details>\n\n$2`
|
||||
);
|
||||
const foldedBody = foldedBody_en_bug.replace(
|
||||
checkboxSectionRegex_en_feat,
|
||||
`<details><summary>Checkboxes</summary>\n\n$1\n\n</details>\n\n$2`
|
||||
);
|
||||
|
||||
await github.rest.issues.update({
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
|
||||
Reference in New Issue
Block a user