Skip to content

Commit 5e9bb5a

Browse files
authored
fix deepseek (#3449)
1 parent c068501 commit 5e9bb5a

1 file changed

Lines changed: 6 additions & 35 deletions

File tree

‎.github/workflows/deepseek_view.yml‎

Lines changed: 6 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -2,48 +2,19 @@ name: Deepseek Code Review
22
on:
33
pull_request_target:
44
types:
5-
- opened # Triggers when a PR is opened
6-
issue_comment:
7-
types:
8-
- created
5+
- opened # Triggers when a PR is opened
96

7+
# fix: GraphQL: Resource not accessible by integration (addComment) error
108
permissions:
11-
contents: read
129
pull-requests: write
1310

1411
jobs:
1512
setup-deepseek-review:
16-
if: |
17-
github.event_name == 'pull_request_target' ||
18-
(
19-
github.event_name == 'issue_comment' &&
20-
github.event.issue.pull_request &&
21-
startsWith(github.event.comment.body, '/review')
22-
)
13+
timeout-minutes: 30
2314
runs-on: ubuntu-latest
2415
name: Code Review
2516
steps:
26-
- name: Checkout deepseek-review scripts
27-
uses: actions/checkout@v4
28-
with:
29-
repository: hustcer/deepseek-review
30-
path: .tmp/deepseek-review
31-
32-
- name: Setup Nu
33-
uses: hustcer/setup-nu@v3.23
34-
with:
35-
version: 0.112.2
36-
3717
- name: DeepSeek Code Review
38-
shell: nu {0}
39-
env:
40-
REVIEW_PR_NUMBER: ${{ github.event.pull_request.number || github.event.issue.number }}
41-
REVIEW_REPO: ${{ github.repository }}
42-
REVIEW_TOKEN: ${{ secrets.DEEPSEEK_CHAT_TOKEN }}
43-
REVIEW_GITHUB_TOKEN: ${{ github.token }}
44-
REVIEW_MODEL: deepseek-v4-flash
45-
run: |
46-
const NU_LIB_DIRS = [ '${{ github.workspace }}/.tmp/deepseek-review/nu' ]
47-
use review.nu *
48-
49-
deepseek-review $env.REVIEW_TOKEN --model $env.REVIEW_MODEL --repo $env.REVIEW_REPO --pr-number $env.REVIEW_PR_NUMBER --gh-token $env.REVIEW_GITHUB_TOKEN
18+
uses: hustcer/deepseek-review@v1
19+
with:
20+
chat-token: ${{ secrets.DEEPSEEK_CHAT_TOKEN }}

0 commit comments

Comments
 (0)