@elvis1513/auto-coding-skill 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +47 -34
- package/cli/assets/skill/SKILL.md +19 -20
- package/cli/assets/skill/data/templates/ENGINEERING.md +62 -38
- package/cli/assets/skill/data/templates/docs/deployment/deploy-runbook.md +1 -1
- package/cli/assets/skill/data/templates/docs/reviews/_TEMPLATE-REVIEW.md +1 -1
- package/cli/assets/skill/data/templates/docs/tasks/summaries/_TEMPLATE-TASK-SUMMARY.md +1 -1
- package/cli/assets/skill/data/templates/docs/tasks/taskbook.md +1 -1
- package/cli/assets/skill/scripts/ap.py +18 -14
- package/cli/assets/skill/scripts/core.py +3 -4
- package/cli/src/index.js +1 -1
- package/package.json +1 -1
- package/cli/assets/skill/data/templates/docs/project/project-config.md +0 -45
package/README.md
CHANGED
|
@@ -23,13 +23,10 @@ npm install -g git+https://github.com/elvis1513/auto-coding-skill.git
|
|
|
23
23
|
|
|
24
24
|
```bash
|
|
25
25
|
autocoding init --ai codex
|
|
26
|
-
# or
|
|
27
|
-
autocoding init --ai claude
|
|
28
|
-
# or both
|
|
29
|
-
autocoding init --ai all
|
|
26
|
+
# or claude / all
|
|
30
27
|
```
|
|
31
28
|
|
|
32
|
-
2. Initialize docs
|
|
29
|
+
2. Initialize docs and local scripts:
|
|
33
30
|
|
|
34
31
|
```bash
|
|
35
32
|
python3 .codex/skills/auto-coding-skill/scripts/ap.py --repo . install
|
|
@@ -37,22 +34,13 @@ python3 .codex/skills/auto-coding-skill/scripts/ap.py --repo . install
|
|
|
37
34
|
python3 .claude/skills/auto-coding-skill/scripts/ap.py --repo . install
|
|
38
35
|
```
|
|
39
36
|
|
|
40
|
-
3. Fill one
|
|
37
|
+
3. Fill only one file manually:
|
|
41
38
|
|
|
42
|
-
- `
|
|
39
|
+
- `ENGINEERING.md` frontmatter
|
|
43
40
|
|
|
44
|
-
This
|
|
45
|
-
- build/test/lint/typecheck/smoke/regression commands
|
|
46
|
-
- deployment info (ip/user/password/service/path/health)
|
|
47
|
-
- docs paths
|
|
41
|
+
This frontmatter is the only manual config source (commands + deployment + docs paths).
|
|
48
42
|
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
```bash
|
|
52
|
-
pip install pyyaml requests
|
|
53
|
-
```
|
|
54
|
-
|
|
55
|
-
4. Let AI execute workflow by docs constraints:
|
|
43
|
+
4. Start AI development by constraints:
|
|
56
44
|
|
|
57
45
|
- `ENGINEERING.md`
|
|
58
46
|
- `docs/tasks/taskbook.md`
|
|
@@ -64,38 +52,63 @@ pip install pyyaml requests
|
|
|
64
52
|
|
|
65
53
|
## AGENTS.md Constraint Example
|
|
66
54
|
|
|
67
|
-
Add this in project `AGENTS.md`:
|
|
68
|
-
|
|
69
55
|
```md
|
|
70
56
|
## Mandatory Skill
|
|
71
|
-
- Always use `auto-coding-skill` for
|
|
57
|
+
- Always use `auto-coding-skill` for implementation tasks.
|
|
72
58
|
- Before any code change, read and obey:
|
|
73
59
|
1) ENGINEERING.md
|
|
74
|
-
2) docs/
|
|
75
|
-
|
|
76
|
-
-
|
|
77
|
-
- If any required doc is missing, create/update docs first, then code.
|
|
60
|
+
2) docs/tasks/taskbook.md
|
|
61
|
+
- Execute gates using `python3 scripts/autopipeline/ap.py`.
|
|
62
|
+
- If required docs are missing, create/update docs first, then code.
|
|
78
63
|
```
|
|
79
64
|
|
|
80
65
|
## Commands
|
|
81
66
|
|
|
82
67
|
```bash
|
|
83
|
-
|
|
84
|
-
python3
|
|
85
|
-
python3
|
|
86
|
-
python3
|
|
87
|
-
python3
|
|
88
|
-
python3
|
|
89
|
-
python3
|
|
68
|
+
pip install pyyaml requests
|
|
69
|
+
python3 scripts/autopipeline/ap.py run build
|
|
70
|
+
python3 scripts/autopipeline/ap.py run test
|
|
71
|
+
python3 scripts/autopipeline/ap.py run lint
|
|
72
|
+
python3 scripts/autopipeline/ap.py verify-api-docs
|
|
73
|
+
python3 scripts/autopipeline/ap.py check-matrix
|
|
74
|
+
python3 scripts/autopipeline/ap.py gen-summary T0001-1
|
|
75
|
+
python3 scripts/autopipeline/ap.py commit-push T0001-1 --msg "T0001-1: <summary>" --require-matrix
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
## Release New Version
|
|
79
|
+
|
|
80
|
+
1. Bump version (cannot republish an existing version):
|
|
81
|
+
|
|
82
|
+
```bash
|
|
83
|
+
npm version patch
|
|
84
|
+
# or: npm version minor
|
|
85
|
+
# or: npm version major
|
|
90
86
|
```
|
|
91
87
|
|
|
92
|
-
|
|
88
|
+
2. Login and pre-check:
|
|
93
89
|
|
|
94
90
|
```bash
|
|
95
91
|
npm login
|
|
96
92
|
npm whoami
|
|
97
93
|
npm run release:check
|
|
98
|
-
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
3. Publish:
|
|
97
|
+
|
|
98
|
+
```bash
|
|
99
|
+
npm publish --access public --otp <6-digit-otp>
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
4. Verify release:
|
|
103
|
+
|
|
104
|
+
```bash
|
|
105
|
+
npm view @elvis1513/auto-coding-skill version
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
5. Update installed clients:
|
|
109
|
+
|
|
110
|
+
```bash
|
|
111
|
+
npm install -g @elvis1513/auto-coding-skill@latest
|
|
99
112
|
```
|
|
100
113
|
|
|
101
114
|
## License
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: auto-coding-skill
|
|
3
|
-
description: Use for strict project engineering workflow in Claude/Codex.
|
|
3
|
+
description: Use for strict project engineering workflow in Claude/Codex. Initialize docs, fill ENGINEERING.md frontmatter once, then execute design->implement->gates->summary->commit/push.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Auto Coding Skill (Claude + Codex)
|
|
@@ -26,19 +26,19 @@ python3 .codex/skills/auto-coding-skill/scripts/ap.py --repo . install
|
|
|
26
26
|
# or .claude path
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
-
Install runtime deps:
|
|
29
|
+
3) Install runtime deps:
|
|
30
30
|
|
|
31
31
|
```bash
|
|
32
32
|
pip install pyyaml requests
|
|
33
33
|
```
|
|
34
34
|
|
|
35
|
-
## Single manual config
|
|
35
|
+
## Single manual config source
|
|
36
36
|
|
|
37
|
-
Fill only
|
|
37
|
+
Fill only:
|
|
38
38
|
|
|
39
|
-
- `
|
|
39
|
+
- `ENGINEERING.md` frontmatter
|
|
40
40
|
|
|
41
|
-
|
|
41
|
+
This contains all manual fields:
|
|
42
42
|
- `commands.*`
|
|
43
43
|
- `deployment.*`
|
|
44
44
|
- `docs.*`
|
|
@@ -48,22 +48,21 @@ Do not duplicate config in other md/yaml files.
|
|
|
48
48
|
## Execution order
|
|
49
49
|
|
|
50
50
|
1) `ENGINEERING.md`
|
|
51
|
-
2) `docs/
|
|
52
|
-
3) `docs/
|
|
53
|
-
4)
|
|
54
|
-
5)
|
|
55
|
-
6)
|
|
56
|
-
7)
|
|
57
|
-
8) commit/push
|
|
51
|
+
2) `docs/tasks/taskbook.md`
|
|
52
|
+
3) `docs/design/**`
|
|
53
|
+
4) implementation
|
|
54
|
+
5) run gates via `python3 scripts/autopipeline/ap.py`
|
|
55
|
+
6) update API docs + regression matrix + bug list + summary
|
|
56
|
+
7) commit/push
|
|
58
57
|
|
|
59
58
|
## Commands
|
|
60
59
|
|
|
61
60
|
```bash
|
|
62
|
-
python3
|
|
63
|
-
python3
|
|
64
|
-
python3
|
|
65
|
-
python3
|
|
66
|
-
python3
|
|
67
|
-
python3
|
|
68
|
-
python3
|
|
61
|
+
python3 scripts/autopipeline/ap.py run build
|
|
62
|
+
python3 scripts/autopipeline/ap.py run test
|
|
63
|
+
python3 scripts/autopipeline/ap.py run lint
|
|
64
|
+
python3 scripts/autopipeline/ap.py verify-api-docs
|
|
65
|
+
python3 scripts/autopipeline/ap.py check-matrix
|
|
66
|
+
python3 scripts/autopipeline/ap.py gen-summary T0001-1
|
|
67
|
+
python3 scripts/autopipeline/ap.py commit-push T0001-1 --msg "T0001-1: <summary>" --require-matrix
|
|
69
68
|
```
|
|
@@ -1,3 +1,42 @@
|
|
|
1
|
+
---
|
|
2
|
+
project:
|
|
3
|
+
name: ""
|
|
4
|
+
repo_root: "."
|
|
5
|
+
|
|
6
|
+
commands:
|
|
7
|
+
build: ""
|
|
8
|
+
test: ""
|
|
9
|
+
lint: ""
|
|
10
|
+
typecheck: ""
|
|
11
|
+
format: ""
|
|
12
|
+
smoke: ""
|
|
13
|
+
regression: ""
|
|
14
|
+
|
|
15
|
+
deployment:
|
|
16
|
+
host: ""
|
|
17
|
+
ssh_port: 22
|
|
18
|
+
username: ""
|
|
19
|
+
password: ""
|
|
20
|
+
service_name: ""
|
|
21
|
+
systemd_dir: "/usr/lib/systemd/system"
|
|
22
|
+
remote_app_root: ""
|
|
23
|
+
remote_jar_path: ""
|
|
24
|
+
remote_config_dir: ""
|
|
25
|
+
remote_bin_dir: ""
|
|
26
|
+
health_base_url: ""
|
|
27
|
+
health_path: ""
|
|
28
|
+
|
|
29
|
+
docs:
|
|
30
|
+
taskbook: "docs/tasks/taskbook.md"
|
|
31
|
+
design_dir: "docs/design"
|
|
32
|
+
review_dir: "docs/reviews"
|
|
33
|
+
api_doc: "docs/interfaces/api.md"
|
|
34
|
+
api_change_log: "docs/interfaces/api-change-log.md"
|
|
35
|
+
regression_matrix: "docs/testing/regression-matrix.md"
|
|
36
|
+
bug_list: "docs/bugs/bug-list.md"
|
|
37
|
+
summary_dir: "docs/tasks/summaries"
|
|
38
|
+
---
|
|
39
|
+
|
|
1
40
|
# ENGINEERING.md — AutoPipeline Gates (Source of Truth)
|
|
2
41
|
|
|
3
42
|
目标:把一次任务固化为不可跳过的流水线:
|
|
@@ -5,63 +44,48 @@
|
|
|
5
44
|
部署(systemd/jar) → 重启验证 → 按API Markdown全量回归 + 回归矩阵0fail →
|
|
6
45
|
记录Bug并新增自动化回归 → 任务总结落盘 → commit → push
|
|
7
46
|
|
|
8
|
-
|
|
47
|
+
规则:任一步骤失败或缺产物,禁止进入下一步;未 push 视为任务未完成,禁止开始下一个任务/子任务。
|
|
9
48
|
|
|
10
49
|
---
|
|
11
50
|
|
|
12
|
-
## 0.
|
|
13
|
-
## 0.1 项目配置(必须,单一入口)
|
|
51
|
+
## 0. 配置填写(必须)
|
|
14
52
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
- `commands.*`(build/test/lint/typecheck/smoke/regression)
|
|
18
|
-
- `deployment.*`(ip/用户名/密码/服务名/路径/健康检查等)
|
|
19
|
-
- `docs.*`(任务本、API文档、回归矩阵、Bug清单、总结目录等路径)
|
|
53
|
+
先填写本文件 frontmatter 中的所有空值(例如 ip/用户名/密码/服务名/路径/命令)。
|
|
54
|
+
禁止在其他 md/yaml 重复维护这些配置。
|
|
20
55
|
|
|
21
|
-
|
|
56
|
+
---
|
|
22
57
|
|
|
58
|
+
## 1. 权威输入与冲突裁决(优先级)
|
|
23
59
|
|
|
24
60
|
1) ENGINEERING.md(本文件)
|
|
25
|
-
2) docs/
|
|
26
|
-
3) docs/
|
|
27
|
-
4) docs/
|
|
28
|
-
5) docs/interfaces/api.md
|
|
29
|
-
6) docs/
|
|
30
|
-
7) docs/
|
|
31
|
-
8) docs/
|
|
32
|
-
9) docs/
|
|
33
|
-
10)
|
|
34
|
-
11) 代码实现(不得反向覆盖 1~10)
|
|
61
|
+
2) docs/tasks/taskbook.md
|
|
62
|
+
3) docs/design/**
|
|
63
|
+
4) docs/interfaces/api.md
|
|
64
|
+
5) docs/interfaces/api-change-log.md
|
|
65
|
+
6) docs/testing/regression-matrix.md(必须 0 FAIL)
|
|
66
|
+
7) docs/bugs/bug-list.md(长期积累,回归必测)
|
|
67
|
+
8) docs/tasks/summaries/**(每任务一份,强制产物)
|
|
68
|
+
9) docs/deployment/**
|
|
69
|
+
10) 代码实现(不得反向覆盖 1~9)
|
|
35
70
|
|
|
36
71
|
---
|
|
37
72
|
|
|
38
|
-
##
|
|
73
|
+
## 2. Gate 流水线(强制、不可跳过)
|
|
39
74
|
|
|
40
75
|
Gate-1 读任务:只从 taskbook 取范围与验收;缺信息先补 taskbook
|
|
41
|
-
Gate-1.5 配置确认:先补齐 `docs/project/project-config.md`;未补齐禁止进入实现
|
|
42
76
|
Gate-2 写DD:无DD禁止写代码;DD必须含 时序图/ER图/接口时序(Mermaid)
|
|
43
77
|
Gate-3 实现:严格按DD;接口变更必须同步 API Markdown
|
|
44
|
-
Gate-4 本地CI:必须通过(
|
|
78
|
+
Gate-4 本地CI:必须通过(commands.build / commands.test)
|
|
45
79
|
Gate-5 静态分析+Review:静态分析通过;docs/reviews/ 生成记录
|
|
46
80
|
Gate-6 文档:更新 api.md + 追加 api-change-log.md
|
|
47
|
-
Gate-7 部署:单机 systemd/jar
|
|
81
|
+
Gate-7 部署:单机 systemd/jar;service目录固定 /usr/lib/systemd/system;失败自动回滚
|
|
48
82
|
Gate-8 重启+健康:restart后必须健康检查通过
|
|
49
|
-
Gate-9 全量回归:按 API Markdown
|
|
50
|
-
Gate-10 任务总结:必须生成 docs/tasks/summaries/<TASK_ID>.md
|
|
51
|
-
Gate-11 完成:全门禁通过后必须 commit+push
|
|
52
|
-
|
|
53
|
-
---
|
|
54
|
-
|
|
55
|
-
## 2. 部署约束(来自你的固定要求)
|
|
56
|
-
|
|
57
|
-
- 允许 sshpass / 或 python 从 `docs/project/project-config.md` 读取 root 密码(非交互)
|
|
58
|
-
- systemd 目录固定:/usr/lib/systemd/system
|
|
59
|
-
- 只保留一个最新备份(*.bak / *.tgz.bak),失败自动回滚并重启服务
|
|
60
|
-
- 健康检查端点不固定:`docs/project/project-config.md` 的 deployment.health_* 字段配置
|
|
61
|
-
- 部署可更新项:app/config/、app/bin/、/usr/lib/systemd/system/*.service、jar
|
|
83
|
+
Gate-9 全量回归:按 API Markdown 全量回归;回归矩阵全量 PASS(0 fail);发现问题必须写 bug-list 并新增自动化回归用例
|
|
84
|
+
Gate-10 任务总结:必须生成 docs/tasks/summaries/<TASK_ID>.md
|
|
85
|
+
Gate-11 完成:全门禁通过后必须 commit+push
|
|
62
86
|
|
|
63
87
|
---
|
|
64
88
|
|
|
65
|
-
## 3. Repo
|
|
89
|
+
## 3. Repo 工具入口
|
|
66
90
|
|
|
67
|
-
统一用 `python3
|
|
91
|
+
统一用 `python3 scripts/autopipeline/ap.py <command>` 执行。
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Deploy Runbook(单机 systemd / jar)
|
|
2
2
|
|
|
3
|
-
部署参数统一读取:`
|
|
3
|
+
部署参数统一读取:`ENGINEERING.md` frontmatter
|
|
4
4
|
- deployment.host / deployment.ssh_port / deployment.username / deployment.password
|
|
5
5
|
- deployment.service_name / deployment.systemd_dir
|
|
6
6
|
- deployment.remote_app_root / deployment.remote_jar_path / deployment.remote_config_dir / deployment.remote_bin_dir
|
|
@@ -26,13 +26,13 @@ def cmd_install(args: argparse.Namespace) -> None:
|
|
|
26
26
|
if args.bridges:
|
|
27
27
|
copy_tree(templates / "bridges", repo)
|
|
28
28
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
copy_tree(Path(__file__).resolve(),
|
|
32
|
-
copy_tree(Path(__file__).resolve().parent / "core.py",
|
|
29
|
+
scripts_dir = repo / "scripts" / "autopipeline"
|
|
30
|
+
scripts_dir.mkdir(parents=True, exist_ok=True)
|
|
31
|
+
copy_tree(Path(__file__).resolve(), scripts_dir / "ap.py")
|
|
32
|
+
copy_tree(Path(__file__).resolve().parent / "core.py", scripts_dir / "core.py")
|
|
33
33
|
|
|
34
34
|
gi = repo / ".gitignore"
|
|
35
|
-
secret_line = "
|
|
35
|
+
secret_line = "ENGINEERING.md"
|
|
36
36
|
if gi.exists():
|
|
37
37
|
txt = gi.read_text(encoding="utf-8")
|
|
38
38
|
if secret_line not in txt:
|
|
@@ -41,11 +41,10 @@ def cmd_install(args: argparse.Namespace) -> None:
|
|
|
41
41
|
gi.write_text(secret_line + "\n", encoding="utf-8")
|
|
42
42
|
|
|
43
43
|
print(f"[install] OK: scaffold installed into {repo}")
|
|
44
|
-
print("[install] Next: edit
|
|
44
|
+
print("[install] Next: edit ENGINEERING.md frontmatter and fill all project/env fields")
|
|
45
45
|
|
|
46
46
|
|
|
47
|
-
def _infer_title(
|
|
48
|
-
taskbook = repo / "docs" / "tasks" / "taskbook.md"
|
|
47
|
+
def _infer_title(taskbook: Path, task_id: str) -> str:
|
|
49
48
|
if not taskbook.exists():
|
|
50
49
|
return "<Title>"
|
|
51
50
|
for line in taskbook.read_text(encoding="utf-8").splitlines():
|
|
@@ -62,16 +61,18 @@ def cmd_gen_summary(args: argparse.Namespace) -> None:
|
|
|
62
61
|
task_id = args.task_id
|
|
63
62
|
cfg = _load_cfg(repo)
|
|
64
63
|
docs_cfg = (cfg.get("docs") or {})
|
|
64
|
+
taskbook = Path(repo, str(docs_cfg.get("taskbook", "docs/tasks/taskbook.md")))
|
|
65
|
+
summary_dir = Path(repo, str(docs_cfg.get("summary_dir", "docs/tasks/summaries")))
|
|
65
66
|
api_change_log = str(docs_cfg.get("api_change_log", "docs/interfaces/api-change-log.md"))
|
|
66
67
|
regression_matrix = str(docs_cfg.get("regression_matrix", "docs/testing/regression-matrix.md"))
|
|
67
68
|
|
|
68
|
-
out_dir =
|
|
69
|
+
out_dir = summary_dir
|
|
69
70
|
out_dir.mkdir(parents=True, exist_ok=True)
|
|
70
71
|
out_file = out_dir / f"{task_id}.md"
|
|
71
72
|
if out_file.exists() and not args.force:
|
|
72
73
|
raise APError(f"Summary already exists: {out_file} (use --force to overwrite)")
|
|
73
74
|
|
|
74
|
-
title = _infer_title(
|
|
75
|
+
title = _infer_title(taskbook, task_id)
|
|
75
76
|
date = _dt.date.today().isoformat()
|
|
76
77
|
|
|
77
78
|
staged = run(["git", "diff", "--cached", "--name-only"], cwd=repo, check=False).stdout.strip()
|
|
@@ -163,7 +164,7 @@ def cmd_run(args: argparse.Namespace) -> None:
|
|
|
163
164
|
"""
|
|
164
165
|
Run a configured gate command:
|
|
165
166
|
build | test | lint | typecheck | format | smoke | regression
|
|
166
|
-
Commands are read from
|
|
167
|
+
Commands are read from ENGINEERING.md frontmatter.
|
|
167
168
|
"""
|
|
168
169
|
repo = Path(args.repo).resolve()
|
|
169
170
|
cfg = _load_cfg(repo)
|
|
@@ -172,7 +173,7 @@ def cmd_run(args: argparse.Namespace) -> None:
|
|
|
172
173
|
if name not in commands:
|
|
173
174
|
raise APError(
|
|
174
175
|
f"Command not configured: commands.{name}. "
|
|
175
|
-
"Edit
|
|
176
|
+
"Edit ENGINEERING.md frontmatter. "
|
|
176
177
|
f"Available: {', '.join(commands.keys()) or '(none)'}"
|
|
177
178
|
)
|
|
178
179
|
cmd = str(commands[name])
|
|
@@ -197,15 +198,18 @@ def cmd_verify_api_docs(args: argparse.Namespace) -> None:
|
|
|
197
198
|
def cmd_commit_push(args: argparse.Namespace) -> None:
|
|
198
199
|
repo = Path(args.repo).resolve()
|
|
199
200
|
ensure_git_repo(repo)
|
|
201
|
+
cfg = _load_cfg(repo)
|
|
202
|
+
docs_cfg = (cfg.get("docs") or {})
|
|
203
|
+
summary_dir = Path(repo, str(docs_cfg.get("summary_dir", "docs/tasks/summaries")))
|
|
200
204
|
|
|
201
205
|
task_id = args.task_id
|
|
202
206
|
msg = args.msg
|
|
203
207
|
|
|
204
|
-
summary =
|
|
208
|
+
summary = summary_dir / f"{task_id}.md"
|
|
205
209
|
if not summary.exists():
|
|
206
210
|
raise APError(
|
|
207
211
|
f"Task summary missing: {summary}\n"
|
|
208
|
-
f"Generate: python3
|
|
212
|
+
f"Generate: python3 scripts/autopipeline/ap.py gen-summary {task_id}"
|
|
209
213
|
)
|
|
210
214
|
|
|
211
215
|
if args.require_matrix:
|
|
@@ -97,15 +97,14 @@ def http_get_status(url: str, timeout_s: int = 5) -> int:
|
|
|
97
97
|
def find_config(repo: Path) -> Path:
|
|
98
98
|
"""Find single source project config file."""
|
|
99
99
|
candidates = [
|
|
100
|
-
repo / "
|
|
101
|
-
repo / "project-config.md",
|
|
100
|
+
repo / "ENGINEERING.md",
|
|
102
101
|
]
|
|
103
102
|
for c in candidates:
|
|
104
103
|
if c.exists():
|
|
105
104
|
return c
|
|
106
105
|
raise APError(
|
|
107
|
-
"Project config not found. Create
|
|
108
|
-
"and put
|
|
106
|
+
"Project config not found. Create ENGINEERING.md "
|
|
107
|
+
"and put commands + deployment fields in YAML frontmatter."
|
|
109
108
|
)
|
|
110
109
|
|
|
111
110
|
|
package/cli/src/index.js
CHANGED
|
@@ -64,7 +64,7 @@ function resolveTargetDir(ai, mode, destOverride){
|
|
|
64
64
|
|
|
65
65
|
function ensureGitignore(projectDir){
|
|
66
66
|
const gi = path.join(projectDir, ".gitignore");
|
|
67
|
-
const line = "
|
|
67
|
+
const line = "ENGINEERING.md";
|
|
68
68
|
if (!exists(gi)) {
|
|
69
69
|
fs.writeFileSync(gi, `${line}\n`, "utf-8");
|
|
70
70
|
return;
|
package/package.json
CHANGED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
project:
|
|
3
|
-
name: "fill-project-name"
|
|
4
|
-
repo_root: "."
|
|
5
|
-
|
|
6
|
-
commands:
|
|
7
|
-
build: "fill-build-command"
|
|
8
|
-
test: "fill-test-command"
|
|
9
|
-
lint: "fill-lint-command"
|
|
10
|
-
typecheck: "fill-typecheck-command"
|
|
11
|
-
format: "fill-format-command"
|
|
12
|
-
smoke: "fill-smoke-command"
|
|
13
|
-
regression: "fill-regression-command"
|
|
14
|
-
|
|
15
|
-
docs:
|
|
16
|
-
taskbook: "docs/tasks/taskbook.md"
|
|
17
|
-
design_dir: "docs/design"
|
|
18
|
-
review_dir: "docs/reviews"
|
|
19
|
-
api_doc: "docs/interfaces/api.md"
|
|
20
|
-
api_change_log: "docs/interfaces/api-change-log.md"
|
|
21
|
-
regression_matrix: "docs/testing/regression-matrix.md"
|
|
22
|
-
bug_list: "docs/bugs/bug-list.md"
|
|
23
|
-
summary_dir: "docs/tasks/summaries"
|
|
24
|
-
|
|
25
|
-
deployment:
|
|
26
|
-
host: "fill-ip-or-domain"
|
|
27
|
-
ssh_port: 22
|
|
28
|
-
username: "fill-username"
|
|
29
|
-
password: "fill-password"
|
|
30
|
-
service_name: "fill-service-name"
|
|
31
|
-
systemd_dir: "/usr/lib/systemd/system"
|
|
32
|
-
remote_app_root: "fill-remote-app-root"
|
|
33
|
-
remote_jar_path: "fill-remote-jar-path"
|
|
34
|
-
remote_config_dir: "fill-remote-config-dir"
|
|
35
|
-
remote_bin_dir: "fill-remote-bin-dir"
|
|
36
|
-
health_base_url: "fill-health-base-url"
|
|
37
|
-
health_path: "/health"
|
|
38
|
-
---
|
|
39
|
-
|
|
40
|
-
# Project Config(唯一人工维护入口)
|
|
41
|
-
|
|
42
|
-
规则:
|
|
43
|
-
1) 所有需要人工维护的项统一写在本文件 frontmatter。
|
|
44
|
-
2) 其他 docs 不再重复维护配置,统一引用本文件。
|
|
45
|
-
3) 开发前先补齐本文件,再启动任何 Gate。
|