feat: 重组为标准 skill 包结构 + 修复 verify.sh bash 3.2 兼容
- 新增 .claude/skills/new-project/SKILL.md(标准 skill 格式) - install-skill.sh 安装时组装 SKILL.md + verify.sh,单一源无重复 - verify.sh 改用索引数组替代 declare -A,兼容 macOS bash 3.2 - log_pass/log_skip 显式 return 0,避免 set -e 下非 verbose 误退出 - README 改为 skill 优先;补全 copier.yml/scripts/template 入库
This commit is contained in:
+24
@@ -0,0 +1,24 @@
|
||||
version: 2
|
||||
updates:
|
||||
{%- if include_backend %}
|
||||
- package-ecosystem: pip
|
||||
directory: /backend
|
||||
schedule:
|
||||
interval: weekly
|
||||
{%- endif %}
|
||||
{%- if include_agent %}
|
||||
- package-ecosystem: pip
|
||||
directory: /agent
|
||||
schedule:
|
||||
interval: weekly
|
||||
{%- endif %}
|
||||
{%- if include_frontend %}
|
||||
- package-ecosystem: npm
|
||||
directory: /frontend
|
||||
schedule:
|
||||
interval: weekly
|
||||
{%- endif %}
|
||||
- package-ecosystem: github-actions
|
||||
directory: /
|
||||
schedule:
|
||||
interval: weekly
|
||||
+69
@@ -0,0 +1,69 @@
|
||||
name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
{%- if include_backend %}
|
||||
backend:
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: backend
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: astral-sh/setup-uv@v3
|
||||
with:
|
||||
python-version: "{{ python_version }}"
|
||||
- run: uv sync
|
||||
- run: uv run ruff check src
|
||||
- run: uv run ruff format --check src
|
||||
- run: uv run mypy src
|
||||
- run: uv run pip-audit
|
||||
{%- if database == 'sqlite' %}
|
||||
- run: uv run alembic upgrade head
|
||||
{%- endif %}
|
||||
- run: uv run pytest --cov=src --cov-fail-under=80
|
||||
{%- endif %}
|
||||
|
||||
{%- if include_agent %}
|
||||
agent:
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: agent
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: astral-sh/setup-uv@v3
|
||||
with:
|
||||
python-version: "{{ python_version }}"
|
||||
- run: uv sync
|
||||
- run: uv run ruff check src
|
||||
- run: uv run ruff format --check src
|
||||
- run: uv run mypy src
|
||||
- run: uv run pip-audit
|
||||
- run: uv run pytest --cov=src --cov-fail-under=80
|
||||
{%- endif %}
|
||||
|
||||
{%- if include_frontend %}
|
||||
frontend:
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: frontend
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: pnpm/action-setup@v4
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: {{ node_version }}
|
||||
cache: pnpm
|
||||
cache-dependency-path: frontend/pnpm-lock.yaml
|
||||
- run: pnpm install --frozen-lockfile
|
||||
- run: pnpm audit --audit-level high
|
||||
- run: pnpm lint
|
||||
- run: pnpm typecheck
|
||||
- run: pnpm test:run --coverage
|
||||
- run: pnpm build
|
||||
{%- endif %}
|
||||
Reference in New Issue
Block a user