@orkestrel/scaffold 0.0.127 → 0.0.128
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/dist/bin/main.js
CHANGED
|
@@ -10,7 +10,7 @@ import { readdirSync } from "node:fs";
|
|
|
10
10
|
import { parseArgs } from "node:util";
|
|
11
11
|
var package_default = {
|
|
12
12
|
name: "@orkestrel/scaffold",
|
|
13
|
-
version: "0.0.
|
|
13
|
+
version: "0.0.128",
|
|
14
14
|
description: "Scaffold workspaces with commands: new, audit, surface, repair, catalog, and overwrite.",
|
|
15
15
|
keywords: [
|
|
16
16
|
"audit",
|
|
@@ -78,7 +78,7 @@ Treat generated package identifiers, versions, layers, and dependency ranges as
|
|
|
78
78
|
| `@orkestrel/reason` | `0.0.17` | L2 | `@orkestrel/emitter` `^0.0.15`, `@orkestrel/contract` `^0.0.22` | |
|
|
79
79
|
| `@orkestrel/relation` | `0.0.20` | L3 | `@orkestrel/emitter` `^0.0.15`, `@orkestrel/contract` `^0.0.22`, `@orkestrel/database` `^0.0.22` | |
|
|
80
80
|
| `@orkestrel/router` | `0.0.20` | L2 | `@orkestrel/abort` `^0.0.16`, `@orkestrel/emitter` `^0.0.15`, `@orkestrel/contract` `^0.0.22` | |
|
|
81
|
-
| `@orkestrel/scaffold` | `0.0.
|
|
81
|
+
| `@orkestrel/scaffold` | `0.0.127` | L3 | `@orkestrel/console` `^0.0.19`, `@orkestrel/emitter` `^0.0.15`, `@orkestrel/process` `^0.0.18`, `@orkestrel/contract` `^0.0.22`, `@orkestrel/markdown` `^0.0.20`, `@orkestrel/template` `^0.0.13` | |
|
|
82
82
|
| `@orkestrel/sea` | `0.0.22` | L3 | `@orkestrel/emitter` `^0.0.15`, `@orkestrel/process` `^0.0.18`, `@orkestrel/contract` `^0.0.22` | |
|
|
83
83
|
| `@orkestrel/server` | `0.0.26` | L3 | `@orkestrel/abort` `^0.0.16`, `@orkestrel/codec` `^0.0.9`, `@orkestrel/router` `^0.0.20`, `@orkestrel/emitter` `^0.0.15`, `@orkestrel/timeout` `^0.0.16`, `@orkestrel/contract` `^0.0.22` | |
|
|
84
84
|
| `@orkestrel/sqlite` | `0.0.17` | L1 | `@orkestrel/contract` `^0.0.22` | |
|
package/dist/host/manifest.json
CHANGED
|
@@ -628,7 +628,7 @@
|
|
|
628
628
|
"storage": "claude/agents/orkestrel.md",
|
|
629
629
|
"destination": ".claude/agents/orkestrel.md",
|
|
630
630
|
"executable": false,
|
|
631
|
-
"digest": "
|
|
631
|
+
"digest": "a8c9dc23ba68618e2b09eb77c684a7e184ca9f31afe81588a9355b3c4f0e9091"
|
|
632
632
|
},
|
|
633
633
|
{
|
|
634
634
|
"storage": "claude/agents/planner.md",
|
|
@@ -1336,7 +1336,7 @@
|
|
|
1336
1336
|
"storage": "tests/config.test.ts",
|
|
1337
1337
|
"destination": "tests/config.test.ts",
|
|
1338
1338
|
"executable": false,
|
|
1339
|
-
"digest": "
|
|
1339
|
+
"digest": "bf15132fd375ab310ff11a010481d86796b8348fd03b9e4a2585415492707eec"
|
|
1340
1340
|
},
|
|
1341
1341
|
{
|
|
1342
1342
|
"storage": "tests/policy.test.ts",
|
|
@@ -1417,5 +1417,5 @@
|
|
|
1417
1417
|
"scripts"
|
|
1418
1418
|
],
|
|
1419
1419
|
"surface": [],
|
|
1420
|
-
"digest": "
|
|
1420
|
+
"digest": "8648e6666d97093faa375c67f4e668bd6f62a0b67aee232852500ff511af7fae"
|
|
1421
1421
|
}
|
|
@@ -1171,7 +1171,19 @@ describe('root configuration', () => {
|
|
|
1171
1171
|
})] },
|
|
1172
1172
|
}\n`,
|
|
1173
1173
|
)
|
|
1174
|
-
const journeys: object[]
|
|
1174
|
+
const journeys: Array<{ readonly application: string; readonly tests: readonly object[] }> = []
|
|
1175
|
+
// A face-only workspace declares no base application, so each declared application loads the
|
|
1176
|
+
// journey wrapper under its own Vite mode, and the default mode stands for the base entry.
|
|
1177
|
+
const occupied = [
|
|
1178
|
+
'browser',
|
|
1179
|
+
...collectFrameworks(POLICY_ROOT)
|
|
1180
|
+
.filter((face) => face.startsWith('app/'))
|
|
1181
|
+
.map((face) => face.slice(4)),
|
|
1182
|
+
].filter(
|
|
1183
|
+
(application) =>
|
|
1184
|
+
existsSync(resolve(POLICY_ROOT, 'app', application)) &&
|
|
1185
|
+
readdirSync(resolve(POLICY_ROOT, 'app', application)).includes('main.ts'),
|
|
1186
|
+
)
|
|
1175
1187
|
const targets = [
|
|
1176
1188
|
...required.map((wrapper) => ({ wrapper, directory: POLICY_ROOT })),
|
|
1177
1189
|
{ wrapper: journey, directory: planted.path },
|
|
@@ -1194,45 +1206,66 @@ describe('root configuration', () => {
|
|
|
1194
1206
|
if (axis === undefined || environment === undefined) {
|
|
1195
1207
|
throw new Error(`${wrapper} carries no target`)
|
|
1196
1208
|
}
|
|
1197
|
-
const loaded = await loadConfigFromFile(
|
|
1198
|
-
{ command: 'build', mode: 'test', isSsrBuild: false, isPreview: false },
|
|
1199
|
-
resolve(directory, wrapper),
|
|
1200
|
-
directory,
|
|
1201
|
-
'silent',
|
|
1202
|
-
)
|
|
1203
|
-
if (loaded === null) throw new Error(`${wrapper} did not load`)
|
|
1204
1209
|
if (environment === 'journey') {
|
|
1205
|
-
const
|
|
1206
|
-
if (
|
|
1207
|
-
throw new Error(`${wrapper}
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
if (
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
tests
|
|
1210
|
+
const applications = directory === planted.path ? ['browser'] : occupied
|
|
1211
|
+
if (applications.length === 0)
|
|
1212
|
+
throw new Error(`${wrapper} has no declared application to load`)
|
|
1213
|
+
for (const application of applications) {
|
|
1214
|
+
const mode = application === 'browser' ? 'test' : application
|
|
1215
|
+
const loaded = await loadConfigFromFile(
|
|
1216
|
+
{ command: 'build', mode, isSsrBuild: false, isPreview: false },
|
|
1217
|
+
resolve(directory, wrapper),
|
|
1218
|
+
directory,
|
|
1219
|
+
'silent',
|
|
1220
|
+
)
|
|
1221
|
+
if (loaded === null) throw new Error(`${wrapper} did not load`)
|
|
1222
|
+
const projects = loaded.config.test?.projects
|
|
1223
|
+
if (!Array.isArray(projects) || projects.length === 0) {
|
|
1224
|
+
throw new Error(`${wrapper} carries no journey projects`)
|
|
1225
|
+
}
|
|
1226
|
+
const tests: object[] = []
|
|
1227
|
+
for (const factory of projects) {
|
|
1228
|
+
if (typeof factory !== 'function')
|
|
1229
|
+
throw new Error(`${wrapper} carries no project factory`)
|
|
1230
|
+
const project: unknown = await Reflect.apply(factory, undefined, [
|
|
1231
|
+
{ command: 'serve', mode },
|
|
1232
|
+
])
|
|
1233
|
+
if (typeof project !== 'object' || project === null)
|
|
1234
|
+
throw new Error('A journey project is not a configuration')
|
|
1235
|
+
const test: unknown = Object.getOwnPropertyDescriptor(project, 'test')?.value
|
|
1236
|
+
if (typeof test !== 'object' || test === null)
|
|
1237
|
+
throw new Error('A journey project carries no test block')
|
|
1238
|
+
tests.push(test)
|
|
1239
|
+
}
|
|
1240
|
+
journeys.push({ application, tests })
|
|
1222
1241
|
}
|
|
1223
|
-
journeys.push(tests)
|
|
1224
1242
|
continue
|
|
1225
1243
|
}
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1244
|
+
// The showcase selects its application by Vite mode as the journey does.
|
|
1245
|
+
const modes =
|
|
1246
|
+
environment === 'showcase'
|
|
1247
|
+
? occupied.map((application) => (application === 'browser' ? 'test' : application))
|
|
1248
|
+
: ['test']
|
|
1249
|
+
if (modes.length === 0) throw new Error(`${wrapper} has no declared application to load`)
|
|
1250
|
+
for (const mode of modes) {
|
|
1251
|
+
const loaded = await loadConfigFromFile(
|
|
1252
|
+
{ command: 'build', mode, isSsrBuild: false, isPreview: false },
|
|
1253
|
+
resolve(directory, wrapper),
|
|
1254
|
+
directory,
|
|
1255
|
+
'silent',
|
|
1256
|
+
)
|
|
1257
|
+
if (loaded === null) throw new Error(`${wrapper} did not load`)
|
|
1258
|
+
const output = loaded.config.build?.outDir
|
|
1259
|
+
if (output === undefined) throw new Error(`${wrapper} carries no output`)
|
|
1260
|
+
const expected =
|
|
1261
|
+
environment === 'bin'
|
|
1262
|
+
? 'dist/bin'
|
|
1263
|
+
: environment === 'showcase'
|
|
1264
|
+
? 'showcase'
|
|
1265
|
+
: `dist/${axis}/${environment}`
|
|
1266
|
+
if (resolve(POLICY_ROOT, output) !== resolve(POLICY_ROOT, expected)) {
|
|
1267
|
+
throw new Error(`${wrapper} resolves to the wrong output`)
|
|
1268
|
+
}
|
|
1236
1269
|
}
|
|
1237
1270
|
continue
|
|
1238
1271
|
}
|
|
@@ -1279,10 +1312,10 @@ describe('root configuration', () => {
|
|
|
1279
1312
|
expect(() => expect(control).toStrictEqual(expectedTypes)).toThrow('expected')
|
|
1280
1313
|
}
|
|
1281
1314
|
}
|
|
1282
|
-
for (const tests of journeys) {
|
|
1315
|
+
for (const { application, tests } of journeys) {
|
|
1283
1316
|
const names = tests.map((test) => {
|
|
1284
1317
|
expect(Object.getOwnPropertyDescriptor(test, 'include')?.value).toStrictEqual([
|
|
1285
|
-
|
|
1318
|
+
`tests/app/${application}/integration.test.ts`,
|
|
1286
1319
|
])
|
|
1287
1320
|
expect(Object.getOwnPropertyDescriptor(test, 'exclude')?.value).toStrictEqual([])
|
|
1288
1321
|
expect(Object.getOwnPropertyDescriptor(test, 'setupFiles')?.value).toStrictEqual([
|
package/dist/src/core/index.cjs
CHANGED
|
@@ -4,7 +4,7 @@ let _orkestrel_template = require("@orkestrel/template");
|
|
|
4
4
|
let _orkestrel_emitter = require("@orkestrel/emitter");
|
|
5
5
|
var package_default = {
|
|
6
6
|
name: "@orkestrel/scaffold",
|
|
7
|
-
version: "0.0.
|
|
7
|
+
version: "0.0.128",
|
|
8
8
|
description: "Scaffold workspaces with commands: new, audit, surface, repair, catalog, and overwrite.",
|
|
9
9
|
keywords: [
|
|
10
10
|
"audit",
|
package/dist/src/core/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import { fillTemplate } from "@orkestrel/template";
|
|
|
3
3
|
import { Emitter } from "@orkestrel/emitter";
|
|
4
4
|
var package_default = {
|
|
5
5
|
name: "@orkestrel/scaffold",
|
|
6
|
-
version: "0.0.
|
|
6
|
+
version: "0.0.128",
|
|
7
7
|
description: "Scaffold workspaces with commands: new, audit, surface, repair, catalog, and overwrite.",
|
|
8
8
|
keywords: [
|
|
9
9
|
"audit",
|