@aikdna/kdna-studio-cli 0.7.0 → 0.8.1
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 +3 -3
- package/bin/kdna-studio.js +20 -2
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -56,7 +56,7 @@ kdna-studio export my_domain --format v1 --out dist/my_domain.kdna
|
|
|
56
56
|
Candidate promotion is scope-gated: only candidates with `status == accepted` and `scope_fit == true` are promoted to cards by default. Use `kdna-studio candidate override <project> <candidate-id>` only when a human intentionally overrides the scope gate.
|
|
57
57
|
|
|
58
58
|
The current Studio CLI export workflow uses approved cards as release evidence.
|
|
59
|
-
This is Studio project policy, not a Core
|
|
59
|
+
This is Studio project policy, not a KDNA Core v1 format-validity rule. Human
|
|
60
60
|
Lock and other provenance records are optional review evidence, not validity
|
|
61
61
|
requirements.
|
|
62
62
|
|
|
@@ -75,10 +75,10 @@ loading existing `.kdna` assets.
|
|
|
75
75
|
## Runtime Export Contract
|
|
76
76
|
|
|
77
77
|
`kdna-studio export --format v1` is the canonical runtime export path. It uses
|
|
78
|
-
`@aikdna/kdna-studio-core` to compile the Studio project into a Core
|
|
78
|
+
`@aikdna/kdna-studio-core` to compile the Studio project into a KDNA Core v1
|
|
79
79
|
runtime asset and then packs it with `@aikdna/kdna-core`.
|
|
80
80
|
|
|
81
|
-
A Core
|
|
81
|
+
A KDNA Core v1 runtime export contains only these top-level entries:
|
|
82
82
|
|
|
83
83
|
- `mimetype`
|
|
84
84
|
- `kdna.json`
|
package/bin/kdna-studio.js
CHANGED
|
@@ -63,7 +63,7 @@ Authoring:
|
|
|
63
63
|
kdna-studio card approve <project> <card-id|--all> --by <id> --statement <text> [--sign] [--passphrase <pass>]
|
|
64
64
|
kdna-studio card unlock <project> <card-id> --by <id> --statement <text>
|
|
65
65
|
kdna-studio compile <project> --out <dir>
|
|
66
|
-
kdna-studio export <project> --format v1 --out <file.kdna> [--allow-incomplete]
|
|
66
|
+
kdna-studio export <project> --format v1 --out <file.kdna> [--allow-incomplete] [--password <pw>|--password-stdin]
|
|
67
67
|
|
|
68
68
|
AI Authoring (requires LLM config: kdna-studio llm config):
|
|
69
69
|
kdna-studio distill <project> --ai # AI-driven candidate extraction from evidence
|
|
@@ -1415,6 +1415,7 @@ function exportProjectV1(project, name, outPath, opts = {}) {
|
|
|
1415
1415
|
created_at: manifestDefaults.created_at,
|
|
1416
1416
|
updated_at: manifestDefaults.updated_at,
|
|
1417
1417
|
access: project.release?.access || project.source_manifest?.access || 'public',
|
|
1418
|
+
password: opts.password || undefined,
|
|
1418
1419
|
});
|
|
1419
1420
|
writeFiles(v1Dir, runtimeAsset.files);
|
|
1420
1421
|
fs.mkdirSync(path.dirname(outPath), { recursive: true });
|
|
@@ -1605,7 +1606,24 @@ function cmdExport(args) {
|
|
|
1605
1606
|
if (!projectInput || !out) fail('Usage: kdna-studio export <project> --out <file.kdna> [--format v1] [--sign] [--allow-incomplete]');
|
|
1606
1607
|
if (option(args, '--format') === 'v1') {
|
|
1607
1608
|
const { project } = readProject(projectInput);
|
|
1608
|
-
|
|
1609
|
+
// BUG-11 (2026-06-27): previous logic required --password to be set
|
|
1610
|
+
// before --password-stdin would take effect. That meant callers using
|
|
1611
|
+
// `--password-stdin` alone (the recommended path) got `password = null`
|
|
1612
|
+
// and the export ran unencrypted. Resolve the two flags independently:
|
|
1613
|
+
// - --password-stdin → read password from stdin (preferred)
|
|
1614
|
+
// - --password <pw> → take password from the flag (insecure)
|
|
1615
|
+
// - --passphrase <pw> → legacy alias for --password
|
|
1616
|
+
// If both are given, --password-stdin wins (it is the explicit intent).
|
|
1617
|
+
// Use args.includes() for --password-stdin since it is a boolean flag
|
|
1618
|
+
// (option() rejects it for "missing value").
|
|
1619
|
+
const useStdin = args.includes('--password-stdin');
|
|
1620
|
+
const password = useStdin
|
|
1621
|
+
? fs.readFileSync(0, 'utf8').trim()
|
|
1622
|
+
: option(args, '--password') || option(args, '--passphrase');
|
|
1623
|
+
exportProjectV1(project, option(args, '--name') || project.name, path.resolve(out), {
|
|
1624
|
+
allowIncomplete: args.includes('--allow-incomplete'),
|
|
1625
|
+
password,
|
|
1626
|
+
});
|
|
1609
1627
|
return;
|
|
1610
1628
|
}
|
|
1611
1629
|
const { project, result } = compileProject(projectInput);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aikdna/kdna-studio-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.1",
|
|
4
4
|
"description": "Official KDNA Studio command-line authoring entry for creating, reviewing, compiling, and exporting .kdna judgment assets through the KDNA toolchain.",
|
|
5
5
|
"type": "commonjs",
|
|
6
6
|
"bin": {
|
|
@@ -39,12 +39,12 @@
|
|
|
39
39
|
"node": ">=18"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@aikdna/kdna-studio-core": "^1.
|
|
42
|
+
"@aikdna/kdna-studio-core": "^1.7.0",
|
|
43
43
|
"ajv": "^8.20.0",
|
|
44
44
|
"ajv-formats": "^3.0.1",
|
|
45
45
|
"cbor-x": "^1.6.4"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
|
-
"@aikdna/kdna-core": "^0.
|
|
48
|
+
"@aikdna/kdna-core": "^0.15.0"
|
|
49
49
|
}
|
|
50
50
|
}
|