@produck/agent-toolkit 0.2.0 → 0.3.3
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 +53 -9
- package/bin/agent-toolkit.mjs +76 -654
- package/bin/build-publish-assets.mjs +49 -0
- package/bin/command/enforce-node-baseline/help.txt +19 -0
- package/bin/command/enforce-node-baseline/index.mjs +155 -0
- package/{templates/help/main.txt → bin/command/main/help.txt} +7 -0
- package/bin/command/main/index.mjs +11 -0
- package/bin/command/preflight/help.txt +9 -0
- package/bin/command/preflight/index.mjs +147 -0
- package/bin/command/run-capture/index.mjs +100 -0
- package/bin/command/shared/args.mjs +45 -0
- package/bin/command/shared/text-resource.mjs +19 -0
- package/bin/command/summarize-log/index.mjs +64 -0
- package/bin/command/sync-coverage-script/help.txt +22 -0
- package/bin/command/sync-coverage-script/index.mjs +275 -0
- package/bin/command/sync-husky-hooks/help.txt +22 -0
- package/bin/command/sync-husky-hooks/index.mjs +267 -0
- package/bin/command/sync-instructions/index.mjs +272 -0
- package/bin/command/validate-commit-msg/help.txt +9 -0
- package/bin/command/validate-commit-msg/index.mjs +183 -0
- package/package.json +5 -3
- package/publish-assets/instructions/produck/00-produck-base.instructions.md +37 -39
- package/publish-assets/instructions/produck/10-produck-node.instructions.md +130 -26
- package/publish-assets/instructions/produck/15-produck-workspace.instructions.md +59 -27
- package/publish-assets/instructions/produck/20-produck-commit.instructions.md +24 -8
- package/publish-assets/instructions/produck/tooling-version-baseline.json +32 -0
- package/templates/help/preflight.txt +0 -3
- package/templates/help/validate-commit-msg.txt +0 -7
- /package/{templates/help/run-capture.txt → bin/command/run-capture/help.txt} +0 -0
- /package/{templates/help/summarize-log.txt → bin/command/summarize-log/help.txt} +0 -0
- /package/{templates/help/sync-instructions.txt → bin/command/sync-instructions/help.txt} +0 -0
- /package/{templates → bin/command/sync-instructions}/user-space-bootstrap.md +0 -0
package/README.md
CHANGED
|
@@ -4,42 +4,86 @@ Central CLI toolkit for organization-level AI execution workflows.
|
|
|
4
4
|
|
|
5
5
|
## Commands
|
|
6
6
|
|
|
7
|
+
- agent-toolkit enforce-node-baseline
|
|
7
8
|
- agent-toolkit preflight
|
|
8
9
|
- agent-toolkit run-capture
|
|
9
10
|
- agent-toolkit summarize-log
|
|
11
|
+
- agent-toolkit sync-coverage-script
|
|
12
|
+
- agent-toolkit sync-husky-hooks
|
|
10
13
|
- agent-toolkit validate-commit-msg
|
|
11
14
|
- agent-toolkit sync-instructions
|
|
12
15
|
|
|
13
16
|
## Examples
|
|
14
17
|
|
|
18
|
+
Run default mandatory baseline flow in downstream repository root:
|
|
19
|
+
|
|
20
|
+
```
|
|
21
|
+
npm exec -- agent-toolkit
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Equivalent explicit form:
|
|
25
|
+
|
|
26
|
+
```
|
|
27
|
+
npm exec -- agent-toolkit enforce-node-baseline --cwd .
|
|
28
|
+
```
|
|
29
|
+
|
|
15
30
|
Run preflight checks:
|
|
16
31
|
|
|
17
32
|
```
|
|
18
|
-
npm exec --
|
|
33
|
+
npm exec -- agent-toolkit preflight --cwd . --require package.json --ensure-dir logs
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Run one-shot mandatory baseline steps for downstream monorepo (1 -> 2 -> 3):
|
|
37
|
+
|
|
38
|
+
```
|
|
39
|
+
npm exec -- agent-toolkit enforce-node-baseline --cwd .
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Validate monorepo root workspace package.json baseline:
|
|
43
|
+
|
|
44
|
+
```
|
|
45
|
+
npm exec -- agent-toolkit preflight --cwd . --check-workspace-package-json package.json
|
|
19
46
|
```
|
|
20
47
|
|
|
21
48
|
Capture long output safely:
|
|
22
49
|
|
|
23
50
|
```
|
|
24
|
-
npm exec --
|
|
51
|
+
npm exec -- agent-toolkit run-capture --cwd . --cmd "npm run test" --out logs/test.log
|
|
25
52
|
```
|
|
26
53
|
|
|
27
54
|
Summarize captured output:
|
|
28
55
|
|
|
29
56
|
```
|
|
30
|
-
npm exec --
|
|
57
|
+
npm exec -- agent-toolkit summarize-log --file logs/test.log --match "FAIL|ERROR"
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Deploy organization coverage script and pinned local c8 devDependency to
|
|
61
|
+
workspace packages:
|
|
62
|
+
|
|
63
|
+
```
|
|
64
|
+
npm exec -- agent-toolkit sync-coverage-script --cwd .
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
Deploy organization local anti-drift husky hooks to repository root:
|
|
68
|
+
|
|
69
|
+
```
|
|
70
|
+
npm exec -- agent-toolkit sync-husky-hooks --cwd .
|
|
31
71
|
```
|
|
32
72
|
|
|
73
|
+
This command pins root local hook dependencies (`husky` and
|
|
74
|
+
`@produck/agent-toolkit`) and syncs `.husky/pre-commit` and
|
|
75
|
+
`.husky/commit-msg`.
|
|
76
|
+
|
|
33
77
|
Validate commit message format:
|
|
34
78
|
|
|
35
79
|
```
|
|
36
|
-
npm exec --
|
|
80
|
+
npm exec -- agent-toolkit validate-commit-msg --file .git/COMMIT_EDITMSG
|
|
37
81
|
```
|
|
38
82
|
|
|
39
83
|
Manual per-repository instruction distribution (write .github/instructions/produck/\*.instructions.md):
|
|
40
84
|
|
|
41
85
|
```
|
|
42
|
-
npm exec --
|
|
86
|
+
npm exec -- agent-toolkit sync-instructions --cwd .
|
|
43
87
|
```
|
|
44
88
|
|
|
45
89
|
Legacy repository bootstrap behavior:
|
|
@@ -52,13 +96,13 @@ Legacy repository bootstrap behavior:
|
|
|
52
96
|
Use organization source directory instead of built-in assets:
|
|
53
97
|
|
|
54
98
|
```
|
|
55
|
-
npm exec --
|
|
99
|
+
npm exec -- agent-toolkit sync-instructions --cwd . --source path/to/org/.github/distribution/produck --force --prune
|
|
56
100
|
```
|
|
57
101
|
|
|
58
|
-
Built-in
|
|
102
|
+
Built-in command-local resource locations (for review and updates):
|
|
59
103
|
|
|
60
|
-
- `
|
|
61
|
-
- `
|
|
104
|
+
- `bin/command/*/help.txt`
|
|
105
|
+
- `bin/command/sync-instructions/user-space-bootstrap.md`
|
|
62
106
|
|
|
63
107
|
Publish-time generated instruction assets:
|
|
64
108
|
|