@decantr/cli 1.8.0 → 1.10.0
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 +22 -1
- package/dist/bin.js +1 -1
- package/dist/{chunk-Y45MCRGI.js → chunk-FLZVSNB5.js} +19 -3
- package/dist/{chunk-DONMNPS7.js → chunk-K5KCZSEI.js} +141 -2
- package/dist/content-health-QQHBR6XG.js +1057 -0
- package/dist/{health-VSL4MROO.js → health-SIKAOE2Z.js} +7 -3
- package/dist/index.js +1 -1
- package/dist/{studio-BCTWKXFH.js → studio-EQSSNA6D.js} +1 -1
- package/package.json +5 -4
- package/src/templates/DECANTR.md.template +2 -1
- package/src/templates/decantr-health.workflow.yml.template +62 -0
|
@@ -5,8 +5,10 @@ import {
|
|
|
5
5
|
formatProjectHealthMarkdown,
|
|
6
6
|
formatProjectHealthText,
|
|
7
7
|
parseHealthArgs,
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
renderProjectHealthCiWorkflow,
|
|
9
|
+
shouldFailHealth,
|
|
10
|
+
writeProjectHealthCiWorkflow
|
|
11
|
+
} from "./chunk-K5KCZSEI.js";
|
|
10
12
|
import "./chunk-RSDCWAHD.js";
|
|
11
13
|
import "./chunk-DI2PLOJ6.js";
|
|
12
14
|
export {
|
|
@@ -16,5 +18,7 @@ export {
|
|
|
16
18
|
formatProjectHealthMarkdown,
|
|
17
19
|
formatProjectHealthText,
|
|
18
20
|
parseHealthArgs,
|
|
19
|
-
|
|
21
|
+
renderProjectHealthCiWorkflow,
|
|
22
|
+
shouldFailHealth,
|
|
23
|
+
writeProjectHealthCiWorkflow
|
|
20
24
|
};
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@decantr/cli",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.10.0",
|
|
4
4
|
"description": "Decantr CLI - scaffold, audit, inspect Project Health, and maintain Decantr projects from the terminal",
|
|
5
5
|
"author": "Decantr AI",
|
|
6
6
|
"license": "MIT",
|
|
@@ -30,11 +30,12 @@
|
|
|
30
30
|
"access": "public"
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
|
+
"ajv": "^8.18.0",
|
|
33
34
|
"@decantr/core": "1.0.6",
|
|
34
35
|
"@decantr/essence-spec": "1.0.7",
|
|
35
|
-
"@decantr/
|
|
36
|
-
"@decantr/
|
|
37
|
-
"@decantr/
|
|
36
|
+
"@decantr/registry": "1.1.0",
|
|
37
|
+
"@decantr/telemetry": "0.1.2",
|
|
38
|
+
"@decantr/verifier": "1.1.0"
|
|
38
39
|
},
|
|
39
40
|
"scripts": {
|
|
40
41
|
"build": "tsup",
|
|
@@ -115,7 +115,7 @@ Read `.decantr/context/page-{name}-pack.md` for the most local compiled route co
|
|
|
115
115
|
### Validation
|
|
116
116
|
|
|
117
117
|
Run `decantr check` to detect drift violations while editing and `decantr audit` to audit the whole project contract after implementation.
|
|
118
|
-
Run `decantr health` for the broader Project Health view before handoff, pull requests, or CI. Use `decantr health --prompt <finding-id>` to generate a scoped remediation prompt for a specific issue, and `decantr studio` to inspect local drift, routes, findings, remediation, CI, and pack state in a localhost dashboard.
|
|
118
|
+
Run `decantr health` for the broader Project Health view before handoff, pull requests, or CI. Use `decantr health init-ci` to install the default GitHub Actions health gate, `decantr health --prompt <finding-id>` to generate a scoped remediation prompt for a specific issue, and `decantr studio` to inspect local drift, routes, findings, remediation, CI, and pack state in a localhost dashboard.
|
|
119
119
|
Declared command palettes and hotkeys must be implemented, not merely acknowledged.
|
|
120
120
|
|
|
121
121
|
### Quick Commands
|
|
@@ -123,6 +123,7 @@ Declared command palettes and hotkeys must be implemented, not merely acknowledg
|
|
|
123
123
|
```bash
|
|
124
124
|
decantr status # Project status overview
|
|
125
125
|
decantr health # Local contract health report
|
|
126
|
+
decantr health init-ci # Install GitHub Actions health gate
|
|
126
127
|
decantr studio # Local health dashboard
|
|
127
128
|
decantr check # Detect drift violations
|
|
128
129
|
decantr get pattern X # Fetch a pattern spec from registry
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
name: Decantr Project Health
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
workflow_dispatch:
|
|
6
|
+
push:
|
|
7
|
+
branches:
|
|
8
|
+
- main
|
|
9
|
+
|
|
10
|
+
permissions:
|
|
11
|
+
contents: read
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
health:
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v6
|
|
18
|
+
|
|
19
|
+
- uses: actions/setup-node@v6
|
|
20
|
+
with:
|
|
21
|
+
node-version: '22'
|
|
22
|
+
|
|
23
|
+
- name: Install dependencies
|
|
24
|
+
shell: bash
|
|
25
|
+
run: |
|
|
26
|
+
if [ -f pnpm-lock.yaml ]; then
|
|
27
|
+
corepack enable
|
|
28
|
+
pnpm install --frozen-lockfile
|
|
29
|
+
elif [ -f package-lock.json ]; then
|
|
30
|
+
npm ci
|
|
31
|
+
elif [ -f yarn.lock ]; then
|
|
32
|
+
corepack enable
|
|
33
|
+
yarn install --frozen-lockfile
|
|
34
|
+
elif [ -f package.json ]; then
|
|
35
|
+
npm install
|
|
36
|
+
else
|
|
37
|
+
echo "No package manifest found; skipping dependency install."
|
|
38
|
+
fi
|
|
39
|
+
|
|
40
|
+
- name: Generate Decantr health JSON
|
|
41
|
+
run: npx --yes {{CLI_PACKAGE}} health --json --output {{JSON_PATH}}
|
|
42
|
+
|
|
43
|
+
- name: Audit Decantr health
|
|
44
|
+
run: npx --yes {{CLI_PACKAGE}} health --ci --fail-on {{FAIL_ON}} --markdown --output {{REPORT_PATH}}
|
|
45
|
+
|
|
46
|
+
- name: Publish health summary
|
|
47
|
+
if: always()
|
|
48
|
+
shell: bash
|
|
49
|
+
run: |
|
|
50
|
+
if [ -f {{REPORT_PATH}} ]; then
|
|
51
|
+
cat {{REPORT_PATH}} >> "$GITHUB_STEP_SUMMARY"
|
|
52
|
+
fi
|
|
53
|
+
|
|
54
|
+
- name: Upload health artifacts
|
|
55
|
+
if: always()
|
|
56
|
+
uses: actions/upload-artifact@v6
|
|
57
|
+
with:
|
|
58
|
+
name: decantr-project-health
|
|
59
|
+
path: |
|
|
60
|
+
{{JSON_PATH}}
|
|
61
|
+
{{REPORT_PATH}}
|
|
62
|
+
if-no-files-found: ignore
|