fix: update ui
This commit is contained in:
1 parent
b1613824ce
commit
8e263a1d76
9 files changed
+617
-400
No files matched your search
+5
-15
@@ -65,31 +65,21 @@ cd hxops
|
||||
|
||||
### 4.2 安装 Git Hooks(推荐,每人 clone 后执行一次)
|
||||
|
||||
仓库根目录的 `.githooks/` 会随代码拉取;**不会自动生效**,需在本机启用:
|
||||
完整说明见 **[Git Hooks 团队启用指南](./GIT_HOOKS.md)**(策略、安装步骤、验证、跳过方式、常见问题)。
|
||||
|
||||
| Hook | 时机 | 检查内容 |
|
||||
|------|------|----------|
|
||||
| `pre-commit` | `git commit` | 改 `models.py` 须同时提交 migration;暂存 `frontend/` 时跑 `vue-tsc` |
|
||||
| `pre-push` | `git push` | 本次推送含 `frontend/` 变更时跑 `npm run build`(与 Jenkins 部署一致) |
|
||||
|
||||
**Git Bash / WSL:**
|
||||
快速安装:
|
||||
|
||||
```bash
|
||||
chmod +x scripts/install_git_hooks.sh .githooks/pre-commit .githooks/pre-push
|
||||
# Git Bash / WSL
|
||||
./scripts/install_git_hooks.sh
|
||||
```
|
||||
|
||||
**PowerShell(仅启用钩子目录):**
|
||||
|
||||
```powershell
|
||||
# PowerShell
|
||||
git config core.hooksPath .githooks
|
||||
```
|
||||
|
||||
验证:`git config --get core.hooksPath` 应输出 `.githooks`。
|
||||
|
||||
前置:已执行 `cd frontend && npm install`。应急跳过前端检查:`$env:SKIP_FRONTEND_HOOKS="1"`(bash 为 `SKIP_FRONTEND_HOOKS=1`)。
|
||||
|
||||
Jenkins 在检测到 `frontend/` 变更时会再跑一遍同款构建(`scripts/ci_frontend_build.sh`),作为 Hook 被跳过时的兜底。
|
||||
验证:`git config --get core.hooksPath` → `.githooks`;前置:`cd frontend && npm install`。
|
||||
|
||||
### 4.3 常用 Git 操作示例
|
||||
|
||||
|
||||
Reference in new issue
Block a user