mirror of
https://github.com/adminlove520/AI-Account-Toolkit.git
synced 2026-05-16 09:26:46 +08:00
fix: 改用 pull_request 事件并恢复 paths 过滤
This commit is contained in:
15
.github/workflows/pr-review.yml
vendored
15
.github/workflows/pr-review.yml
vendored
@@ -4,8 +4,17 @@
|
||||
name: PR Review
|
||||
|
||||
on:
|
||||
pull_request_target:
|
||||
pull_request:
|
||||
types: [opened, synchronize, reopened]
|
||||
paths:
|
||||
- '**.py'
|
||||
- '**.md'
|
||||
- 'README.md'
|
||||
- 'requirements.txt'
|
||||
- 'pyproject.toml'
|
||||
- 'setup.cfg'
|
||||
- '.github/workflows/**'
|
||||
- '.github/scripts/**'
|
||||
workflow_dispatch:
|
||||
|
||||
# 限制并发,避免同一 PR 多次触发时重复评论
|
||||
@@ -241,7 +250,7 @@ jobs:
|
||||
uses: actions/checkout@v5
|
||||
|
||||
- name: 🏷️ 添加标签
|
||||
if: github.event_name == 'pull_request_target'
|
||||
if: github.event_name == 'pull_request'
|
||||
uses: actions/github-script@v8
|
||||
with:
|
||||
script: |
|
||||
@@ -312,7 +321,7 @@ jobs:
|
||||
name: 💬 审查报告
|
||||
runs-on: ubuntu-latest
|
||||
needs: [security-check, auto-check, ai-review]
|
||||
if: always() && github.event_name == 'pull_request_target' && needs.security-check.outputs.safe_to_run == 'true'
|
||||
if: always() && github.event_name == 'pull_request' && needs.security-check.outputs.safe_to_run == 'true'
|
||||
|
||||
steps:
|
||||
- name: 📥 检出代码
|
||||
|
||||
Reference in New Issue
Block a user