-
Notifications
You must be signed in to change notification settings - Fork 6
ci: add Kimi Code Review Action #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| name: Kimi Code Review | ||
|
|
||
| on: | ||
| pull_request: | ||
| types: [opened, synchronize] | ||
|
|
||
| permissions: | ||
| contents: read | ||
| pull-requests: write | ||
| checks: write | ||
|
|
||
| jobs: | ||
| review: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - uses: howardpen9/kimi-code-reviewer@v1 | ||
|
Check notice on line 17 in .github/workflows/kimi-review.yml
|
||
| with: | ||
| kimi_api_key: ${{ secrets.MOONSHOT_API_KEY }} | ||
| language: zh-TW | ||
| fail_on: never | ||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -3,11 +3,17 @@ | |||||
| import * as os from 'os' | ||||||
| import * as fs from 'fs' | ||||||
|
|
||||||
| /** Configuration for running a Kimi CLI session */ | ||||||
| export interface KimiRunConfig { | ||||||
| /** The analysis prompt to send to Kimi */ | ||||||
| prompt: string | ||||||
| /** Absolute path to the codebase root directory */ | ||||||
| workDir?: string | ||||||
| /** Resume a specific session by ID */ | ||||||
| sessionId?: string | ||||||
| /** Enable thinking mode for deeper analysis */ | ||||||
| thinking?: boolean | ||||||
| /** Timeout in milliseconds (default: 600000) */ | ||||||
|
Check warning on line 16 in src/kimi-runner.ts
|
||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🟡 [warning] JSDoc default value mismatch The JSDoc comment states the default timeout is 600000ms (10 minutes), but the actual default value in the Current code ( const { prompt, workDir, sessionId, thinking, timeoutMs = 300_000 } = configSuggested fix: Update the JSDoc to match the actual default value, or vice versa. Suggested fix:
Suggested change
|
||||||
| timeoutMs?: number | ||||||
| } | ||||||
|
|
||||||
|
|
||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔵 [suggestion] Pin third-party action to specific SHA
Using a mutable version tag (
@v1) for third-party actions introduces supply chain security risks. If the action's repository is compromised, malicious code could automatically execute in your workflow withpull-requests: writeandchecks: writepermissions.Recommendation: Pin to a specific commit SHA and use Dependabot or Renovate to update it:
Suggested fix: