2023-12-16 17:41:35 +08:00
|
|
|
|
name: Issue Labeled
|
|
|
|
|
|
|
|
|
|
on:
|
|
|
|
|
issues:
|
|
|
|
|
types: [labeled]
|
|
|
|
|
|
|
|
|
|
permissions:
|
|
|
|
|
contents: read
|
|
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
|
issue-labeled:
|
|
|
|
|
permissions:
|
|
|
|
|
issues: write
|
|
|
|
|
pull-requests: write
|
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
steps:
|
2023-12-18 11:16:20 +08:00
|
|
|
|
- name: content template
|
|
|
|
|
id: template
|
|
|
|
|
run: |
|
2023-12-20 11:32:42 +08:00
|
|
|
|
contribute="详见:🍀 [Layui Issue 贡献指南](https://github.com/layui/layui/blob/main/CONTRIBUTING.md)"
|
|
|
|
|
echo "CONTRIBUTING=$contribute" >> $GITHUB_OUTPUT
|
2023-12-18 11:16:20 +08:00
|
|
|
|
|
2023-12-16 17:41:35 +08:00
|
|
|
|
- name: help wanted
|
|
|
|
|
if: github.event.label.name == 'help wanted'
|
|
|
|
|
uses: actions-cool/issues-helper@v3
|
|
|
|
|
with:
|
|
|
|
|
actions: 'create-comment'
|
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
body: |
|
2023-12-18 11:16:20 +08:00
|
|
|
|
@${{ github.event.issue.user.login }} 你好 👋。
|
|
|
|
|
我们赞成为该议题寻求社区帮助,欢迎创建 [Pull Request](https://github.com/layui/layui/pulls) 来协助实现,若变更内容涉及到 API 新增和改动,除了提交核心代码外,还需包含:文档、测试用例等相关文件,以便我们更好地进行 Review。期待您的贡献!
|
|
|
|
|
> ${{ steps.template.outputs.CONTRIBUTING }}
|
2023-12-16 17:41:35 +08:00
|
|
|
|
|
|
|
|
|
- name: invalid
|
|
|
|
|
if: github.event.label.name == 'invalid'
|
|
|
|
|
uses: actions-cool/issues-helper@v3
|
|
|
|
|
with:
|
|
|
|
|
actions: 'create-comment,close-issue'
|
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
body: |
|
2023-12-18 11:16:20 +08:00
|
|
|
|
@${{ github.event.issue.user.login }} 你好,为了提升沟通效率,我们对 Issue 制定了严格的要求,你的 Issue 因不符合规定而被自动关闭。
|
2023-12-26 22:58:03 +08:00
|
|
|
|
建议你在下次创建 Issue 时,遵循相应规范和社区行为准则。谢谢。
|
2023-12-18 11:16:20 +08:00
|
|
|
|
> ${{ steps.template.outputs.CONTRIBUTING }}
|
2023-12-16 17:41:35 +08:00
|
|
|
|
|
|
|
|
|
- name: need reproduce
|
|
|
|
|
if: github.event.label.name == 'need reproduce'
|
|
|
|
|
uses: actions-cool/issues-helper@v3
|
|
|
|
|
with:
|
|
|
|
|
actions: 'create-comment'
|
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
body: |
|
2023-12-26 22:58:03 +08:00
|
|
|
|
@${{ github.event.issue.user.login }} 你好,请提供一个最小化的重现,以便我们为你协助排查问题。良好的重现应当包括但不仅限于:
|
2023-12-16 17:41:35 +08:00
|
|
|
|
- 产生问题的详细步骤
|
|
|
|
|
- 与问题相关的完整代码
|
|
|
|
|
- 在线 Demo (推荐通过 [stackblitz](https://stackblitz.com/) 或 [codepen](https://codepen.io/) 创建)
|
2023-12-18 11:16:20 +08:00
|
|
|
|
> ${{ steps.template.outputs.CONTRIBUTING }}
|
|
|
|
|
> 延伸:👉 [为什么要提供最小化重现?](https://antfu.me/posts/why-reproductions-are-required-zh)
|
2023-12-16 17:41:35 +08:00
|
|
|
|
|
|
|
|
|
- name: discussion
|
|
|
|
|
if: github.event.label.name == 'discussion'
|
|
|
|
|
uses: actions-cool/issues-helper@v3
|
|
|
|
|
with:
|
|
|
|
|
actions: 'create-comment,close-issue'
|
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
body: |
|
2023-12-26 22:58:03 +08:00
|
|
|
|
@${{ github.event.issue.user.login }} 你好,Issue 只接受「Bug 报告」和「功能请求」,而你的议题涉及到如何使用、功能疑惑或其他业务相关的问题,这并不适合作为 Issue 讨论。建议你通过以下方式寻求解决方案:
|
2023-12-16 17:41:35 +08:00
|
|
|
|
- 仔细查阅 Layui 官方文档:https://layui.dev
|
2023-12-18 11:16:20 +08:00
|
|
|
|
- 通过其他技术社区搜索相关资料、或充分利用当前主流的人工智能大模型
|
2023-12-16 17:41:35 +08:00
|
|
|
|
- [Discussions](https://github.com/layui/layui/discussions)
|
2023-12-18 11:16:20 +08:00
|
|
|
|
> ${{ steps.template.outputs.CONTRIBUTING }}
|
2023-12-16 17:41:35 +08:00
|
|
|
|
|
|
|
|
|
- name: unrelated
|
|
|
|
|
if: github.event.label.name == 'unrelated'
|
|
|
|
|
uses: actions-cool/issues-helper@v3
|
|
|
|
|
with:
|
|
|
|
|
actions: 'create-comment,close-issue'
|
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
body: |
|
2023-12-26 22:58:03 +08:00
|
|
|
|
@${{ github.event.issue.user.login }} 你提出的问题与 Layui 可能不存在相关联。建议通过以下方式寻求解决方案:
|
2023-12-18 11:16:20 +08:00
|
|
|
|
- 通过其他技术社区搜索相关资料、或充分利用当前主流的人工智能大模型
|
2023-12-16 17:41:35 +08:00
|
|
|
|
- [Discussions](https://github.com/layui/layui/discussions)
|
2023-12-18 11:16:20 +08:00
|
|
|
|
> ${{ steps.template.outputs.CONTRIBUTING }}
|