[BUG]: AI疑难解答在关服状态不能用 #53
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Auto Close Beta Issues | |
| on: | |
| issues: | |
| types: [opened, edited, reopened] | |
| permissions: | |
| issues: write | |
| jobs: | |
| close_beta_issue: | |
| if: ${{ github.event.issue.state == 'open' && github.event.issue.body && contains(github.event.issue.body, 'beta.simpfun.cn') }} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Comment and close issue | |
| uses: actions/github-script@v7 | |
| with: | |
| script: | | |
| const body = "请看#39\n\n> 检查最新版本\n> 公测版(https://beta.simpfun.cn/ )不接受问题反馈,如在公测版遇到问题请在开发版(https://sfe.x.ahne.cn/ )成功复现后再进行反馈。"; | |
| await github.rest.issues.createComment({ | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| issue_number: context.issue.number, | |
| body, | |
| }); | |
| await github.rest.issues.update({ | |
| owner: context.repo.owner, | |
| repo: context.repo.repo, | |
| issue_number: context.issue.number, | |
| state: 'closed', | |
| state_reason: 'not_planned', | |
| }); |