🔨 chore: update github workflow (#8808)
Some checks failed
Release CI / Release (push) Has been cancelled
Test CI / test (push) Has been cancelled
Upstream Sync / Sync latest commits from upstream repo (push) Has been cancelled

* Update docker/build-push-action action to v6

* update

* fix workflow

* fix workflow

* fix workflow

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
Arvin Xu
2025-08-20 02:40:25 +08:00
committed by GitHub
parent f36f6f7724
commit 1ee6724168
7 changed files with 5 additions and 103 deletions

View File

@@ -1,78 +0,0 @@
name: Claude Code Review
on:
pull_request:
types: [opened, synchronize]
# Optional: Only run on specific file changes
# paths:
# - "src/**/*.ts"
# - "src/**/*.tsx"
# - "src/**/*.js"
# - "src/**/*.jsx"
jobs:
claude-review:
# Optional: Filter by PR author
# if: |
# github.event.pull_request.user.login == 'external-contributor' ||
# github.event.pull_request.user.login == 'new-developer' ||
# github.event.pull_request.author_association == 'FIRST_TIME_CONTRIBUTOR'
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
issues: read
id-token: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Run Claude Code Review
id: claude-review
uses: anthropics/claude-code-action@beta
with:
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
# Optional: Specify model (defaults to Claude Sonnet 4, uncomment for Claude Opus 4)
model: 'claude-opus-4-1-20250805'
allowed_bots: 'bot'
# Direct prompt for automated review (no @claude mention needed)
direct_prompt: |
Please review this pull request and provide feedback on:
- Code quality and best practices
- Potential bugs or issues
- Performance considerations
- Security concerns
- Test coverage
Be constructive and helpful in your feedback.
# Optional: Use sticky comments to make Claude reuse the same comment on subsequent pushes to the same PR
# use_sticky_comment: true
# Optional: Customize review based on file types
# direct_prompt: |
# Review this PR focusing on:
# - For TypeScript files: Type safety and proper interface usage
# - For API endpoints: Security, input validation, and error handling
# - For React components: Performance, accessibility, and best practices
# - For tests: Coverage, edge cases, and test quality
# Optional: Different prompts for different authors
# direct_prompt: |
# ${{ github.event.pull_request.author_association == 'FIRST_TIME_CONTRIBUTOR' &&
# 'Welcome! Please review this PR from a first-time contributor. Be encouraging and provide detailed explanations for any suggestions.' ||
# 'Please provide a thorough code review focusing on our coding standards and best practices.' }}
# Optional: Add specific tools for running tests or linting
allowed_tools: 'Bash(bun run:*),Bash(pnpm run:*),Bash(npm run:*),Bash(npx vitest:*),Bash(rg:*),Bash(find:*),Bash(sed:*),Bash(grep:*),Bash(awk:*),Bash(wc:*),Bash(xargs:*)'
# Optional: Skip review for certain conditions
# if: |
# !contains(github.event.pull_request.title, '[skip-review]') &&
# !contains(github.event.pull_request.title, '[WIP]')

View File

@@ -80,7 +80,7 @@ jobs:
- name: Build and export
id: build
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
platforms: ${{ matrix.platform }}
context: .

View File

@@ -80,7 +80,7 @@ jobs:
- name: Build and export
id: build
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
platforms: ${{ matrix.platform }}
context: .

View File

@@ -80,7 +80,7 @@ jobs:
- name: Build and export
id: build
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
platforms: ${{ matrix.platform }}
context: .

View File

@@ -11,7 +11,7 @@ jobs:
services:
postgres:
image: pgvector/pgvector:pg16
image: pgvector/pgvector:pg17
env:
POSTGRES_PASSWORD: postgres
options: >-

View File

@@ -1,19 +0,0 @@
name: Wiki Sync
on:
workflow_dispatch:
push:
paths:
- 'docs/wiki/**'
branches:
- main
jobs:
update-wiki:
runs-on: ubuntu-latest
name: Wiki sync
steps:
- uses: OrlovM/Wiki-Action@v1
with:
path: 'docs/wiki'
token: ${{ secrets.GH_TOKEN }}

View File

@@ -358,8 +358,7 @@ export const processMultiProviderModelList = async (
let providerLocalConfig: any[] | null = null;
if (providerid) {
try {
const modulePath = `@/config/aiModels/${providerid}`;
const moduleImport = await import(modulePath);
const moduleImport = await import(`@/config/aiModels/${providerid}`);
providerLocalConfig = moduleImport.default;
} catch {
// 如果配置文件不存在或导入失败,保持为 null