From abe40c58a5d251abdfb2bc04b2a7d302ddf08e47 Mon Sep 17 00:00:00 2001 From: Zhan Rongrui Date: Sun, 4 Oct 2026 00:37:00 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20ci:=20align=20shared=20tooling?= =?UTF-8?q?=20and=20site=20validation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/policy-pr.yml | 4 ++-- README.md | 16 ++++++++-------- apps/root/package.json | 2 +- apps/slides/package.json | 2 +- prek.toml | 4 ++-- 5 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/policy-pr.yml b/.github/workflows/policy-pr.yml index 15aba69..4dfd274 100644 --- a/.github/workflows/policy-pr.yml +++ b/.github/workflows/policy-pr.yml @@ -27,12 +27,12 @@ jobs: - name: Check PR title if: github.event.pull_request.user.login != 'renovate[bot]' - uses: zendev-lab/zendev/actions/validate-title@v0.4.0 + uses: zendev-lab/zendev/actions/validate-title@7d8bcbf6134f62b7c7eaadb763f9a0d434717c44 # Shared message validation with: text: ${{ github.event.pull_request.title }} - name: Check PR body - uses: zendev-lab/zendev/actions/validate-body@v0.4.0 + uses: zendev-lab/zendev/actions/validate-body@7d8bcbf6134f62b7c7eaadb763f9a0d434717c44 # Shared Markdown scanner with: body: ${{ github.event.pull_request.body }} template: .github/pull_request_template.md diff --git a/README.md b/README.md index f2f1936..1acfc41 100644 --- a/README.md +++ b/README.md @@ -8,13 +8,13 @@ 仓库根: -| 命令 | 说明 | -| :--------------- | :------------------------------- | -| `vp install` | 安装依赖 | -| `vp run dev` | 各 app 开发服务(过滤 `apps/*`) | -| `vp run build` | 全部应用生产构建 → `apps/*/dist` | -| `vp run preview` | 预览构建结果 | -| `vp check` | 格式 + lint + 类型 | +| 命令 | 说明 | +| :--------------- | :-------------------------------------------- | +| `vp install` | 安装依赖 | +| `vp run dev` | 各 app 开发服务(过滤 `apps/*`) | +| `vp run build` | 全部应用 Astro 检查与生产构建 → `apps/*/dist` | +| `vp run preview` | 预览构建结果 | +| `vp check` | 格式 + lint + 类型 | 另有 `vp fmt`、`vp lint`、`vp test`(见 AGENTS)。Pre-commit、[prek](https://github.com/j178/prek):`vp install` 会跑 `prepare` 写入钩子;首次克隆可再执行 `prek install-hooks`。 @@ -55,7 +55,7 @@ hosting/ → 静态资源子模块(见下) 串联示例:`vp run build:cf:root && vp run deploy:cf:root`。 -发布需 `wrangler login` 或环境变量 **`CLOUDFLARE_API_TOKEN`**(及按需 **`CLOUDFLARE_ACCOUNT_ID`**)。干净环境:`corepack enable && pnpm install --frozen-lockfile`。 +发布需 `wrangler login` 或环境变量 **`CLOUDFLARE_API_TOKEN`**(及按需 **`CLOUDFLARE_ACCOUNT_ID`**)。干净环境:`vp install --frozen-lockfile`。 ### 旧域名跳转 diff --git a/apps/root/package.json b/apps/root/package.json index 0da67a3..710f09e 100644 --- a/apps/root/package.json +++ b/apps/root/package.json @@ -4,7 +4,7 @@ "type": "module", "scripts": { "dev": "astro dev", - "build": "astro build", + "build": "astro check && astro build", "preview": "astro preview", "astro": "astro", "format": "vp fmt . --write", diff --git a/apps/slides/package.json b/apps/slides/package.json index b0b388a..1ccb9be 100644 --- a/apps/slides/package.json +++ b/apps/slides/package.json @@ -4,7 +4,7 @@ "type": "module", "scripts": { "dev": "astro dev", - "build": "astro build", + "build": "astro check && astro build", "preview": "astro preview", "astro": "astro", "format": "vp fmt . --write", diff --git a/prek.toml b/prek.toml index a938a01..ff1fc0a 100644 --- a/prek.toml +++ b/prek.toml @@ -37,8 +37,8 @@ hooks = [{ id = "typos", args = ["--force-exclude"] }] [[repos]] repo = "https://github.com/zendev-lab/zendev" -rev = "v0.2.0" -hooks = [{ id = "zendev-commit-msg" }] +rev = "7d8bcbf6134f62b7c7eaadb763f9a0d434717c44" +hooks = [{ id = "zendev-message-check" }] [[repos]] repo = "local"