@dreamboard-games/cli 0.1.30-alpha.31 → 0.1.30-alpha.33
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 +8 -8
- package/dist/agent-verifier/agent-workspace-verifier.mjs +109 -13
- package/dist/agent-verifier/agent-workspace-verifier.mjs.map +1 -1
- package/dist/agent-verifier/{chunk-NBRUEJUK.mjs → chunk-OQ6OGY5D.mjs} +3 -3
- package/dist/agent-verifier/{chunk-NBRUEJUK.mjs.map → chunk-OQ6OGY5D.mjs.map} +1 -1
- package/dist/agent-verifier/{materialize-workspace-MAGKDMK5.mjs → materialize-workspace-3ECF4EYD.mjs} +2 -2
- package/dist/agent-verifier/{static-scaffold-CLRRWXON.mjs → static-scaffold-XZ4FS4RR.mjs} +2 -2
- package/dist/authoring-compatibility-internal.js +1 -1
- package/dist/{chunk-YNJVKC2T.js → chunk-BN5UBK47.js} +3 -3
- package/dist/{chunk-YNJVKC2T.js.map → chunk-BN5UBK47.js.map} +1 -1
- package/dist/{chunk-X244CUU4.js → chunk-E67GR2SL.js} +111 -14
- package/dist/chunk-E67GR2SL.js.map +1 -0
- package/dist/index.js +23 -20
- package/dist/index.js.map +1 -1
- package/dist/internal.js +2 -2
- package/package.json +1 -1
- package/release/authoring-release-set.json +2 -2
- package/skills/dreamboard/SKILL.md +3 -3
- package/skills/dreamboard/references/building-your-first-game.md +1 -1
- package/skills/dreamboard/references/cli.md +20 -19
- package/skills/dreamboard/references/quickstart.md +3 -3
- package/dist/chunk-X244CUU4.js.map +0 -1
- /package/dist/agent-verifier/{materialize-workspace-MAGKDMK5.mjs.map → materialize-workspace-3ECF4EYD.mjs.map} +0 -0
- /package/dist/agent-verifier/{static-scaffold-CLRRWXON.mjs.map → static-scaffold-XZ4FS4RR.mjs.map} +0 -0
package/dist/index.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
|
+
CAN_SELECT_ENVIRONMENT,
|
|
3
4
|
CONFIG_FLAG_ARGS,
|
|
4
5
|
IS_PUBLISHED_BUILD,
|
|
5
6
|
LOCAL_REGISTRY_URL,
|
|
@@ -46,7 +47,7 @@ import {
|
|
|
46
47
|
titleFromSlug,
|
|
47
48
|
toDreamboardApiError,
|
|
48
49
|
waitForCompiledResultJobSdk
|
|
49
|
-
} from "./chunk-
|
|
50
|
+
} from "./chunk-E67GR2SL.js";
|
|
50
51
|
import {
|
|
51
52
|
applyWorkspaceCodegen,
|
|
52
53
|
collectLocalFiles,
|
|
@@ -80,7 +81,7 @@ import {
|
|
|
80
81
|
updateProjectLocalMaintainerRegistry,
|
|
81
82
|
updateProjectState,
|
|
82
83
|
writeSnapshot
|
|
83
|
-
} from "./chunk-
|
|
84
|
+
} from "./chunk-BN5UBK47.js";
|
|
84
85
|
import {
|
|
85
86
|
getActiveCredentialBackendName,
|
|
86
87
|
getGlobalAuthPath,
|
|
@@ -2154,13 +2155,13 @@ async function runAuthAction(rawArgs) {
|
|
|
2154
2155
|
await runGitCredentialHelper();
|
|
2155
2156
|
return;
|
|
2156
2157
|
}
|
|
2157
|
-
if (IS_PUBLISHED_BUILD && !PUBLISHED_AUTH_ACTIONS.has(action)) {
|
|
2158
|
+
if (IS_PUBLISHED_BUILD && !PUBLISHED_AUTH_ACTIONS.has(action) && !(CAN_SELECT_ENVIRONMENT && action === "env")) {
|
|
2158
2159
|
throw new Error(
|
|
2159
2160
|
"The published Dreamboard CLI supports auth login, logout, and status."
|
|
2160
2161
|
);
|
|
2161
2162
|
}
|
|
2162
2163
|
if (action === "env") {
|
|
2163
|
-
if (
|
|
2164
|
+
if (!CAN_SELECT_ENVIRONMENT) {
|
|
2164
2165
|
throw new Error(
|
|
2165
2166
|
"The published Dreamboard CLI is production-only and does not support switching environments."
|
|
2166
2167
|
);
|
|
@@ -2214,7 +2215,7 @@ async function runAuthAction(rawArgs) {
|
|
|
2214
2215
|
}
|
|
2215
2216
|
if (action === "login") {
|
|
2216
2217
|
const shouldPrintJwt = !IS_PUBLISHED_BUILD && parsedArgs.jwt === true;
|
|
2217
|
-
const environment =
|
|
2218
|
+
const environment = !CAN_SELECT_ENVIRONMENT ? PUBLISHED_ENVIRONMENT : parsedArgs.env || globalConfig.environment || (IS_PUBLISHED_BUILD ? PUBLISHED_ENVIRONMENT : "staging");
|
|
2218
2219
|
const storedSession = await getStoredSession();
|
|
2219
2220
|
const resolvedConfig = resolveConfig(
|
|
2220
2221
|
globalConfig,
|
|
@@ -2295,7 +2296,7 @@ async function runAuthAction(rawArgs) {
|
|
|
2295
2296
|
void 0,
|
|
2296
2297
|
storedSession
|
|
2297
2298
|
);
|
|
2298
|
-
const environment =
|
|
2299
|
+
const environment = resolvedConfig.environment;
|
|
2299
2300
|
const status = await createUserSessionManager(resolvedConfig).inspectSession();
|
|
2300
2301
|
const backendName = await getActiveCredentialBackendName();
|
|
2301
2302
|
consola.log(`Environment: ${environment}`);
|
|
@@ -2358,16 +2359,18 @@ var auth_default = defineCommand({
|
|
|
2358
2359
|
name: "login",
|
|
2359
2360
|
description: "Open browser login and store a refreshable session",
|
|
2360
2361
|
action: "login",
|
|
2361
|
-
args:
|
|
2362
|
+
args: CAN_SELECT_ENVIRONMENT ? {
|
|
2362
2363
|
env: {
|
|
2363
2364
|
type: "string",
|
|
2364
2365
|
description: "Environment: local | staging | prod"
|
|
2365
2366
|
},
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2367
|
+
...IS_PUBLISHED_BUILD ? {} : {
|
|
2368
|
+
jwt: {
|
|
2369
|
+
type: "boolean",
|
|
2370
|
+
description: "Print auth token JSON to stdout"
|
|
2371
|
+
}
|
|
2369
2372
|
}
|
|
2370
|
-
}
|
|
2373
|
+
} : {}
|
|
2371
2374
|
}),
|
|
2372
2375
|
logout: defineAuthActionCommand({
|
|
2373
2376
|
name: "logout",
|
|
@@ -2378,12 +2381,12 @@ var auth_default = defineCommand({
|
|
|
2378
2381
|
name: "status",
|
|
2379
2382
|
description: "Show stored Dreamboard session status",
|
|
2380
2383
|
action: "status",
|
|
2381
|
-
args:
|
|
2384
|
+
args: CAN_SELECT_ENVIRONMENT ? {
|
|
2382
2385
|
env: {
|
|
2383
2386
|
type: "string",
|
|
2384
2387
|
description: "Environment: local | staging | prod"
|
|
2385
2388
|
}
|
|
2386
|
-
}
|
|
2389
|
+
} : {}
|
|
2387
2390
|
}),
|
|
2388
2391
|
"git-credential": defineAuthActionCommand({
|
|
2389
2392
|
name: "git-credential",
|
|
@@ -4110,11 +4113,7 @@ var dev_default = defineCommand({
|
|
|
4110
4113
|
},
|
|
4111
4114
|
async run({ args }) {
|
|
4112
4115
|
const parsedArgs = parseDevCommandArgs(args);
|
|
4113
|
-
const { projectRoot, projectConfig, config } = await resolveProjectContext(
|
|
4114
|
-
parsedArgs,
|
|
4115
|
-
{ requireAuth: false }
|
|
4116
|
-
);
|
|
4117
|
-
await configureClient(config);
|
|
4116
|
+
const { projectRoot, projectConfig, config } = await resolveProjectContext(parsedArgs);
|
|
4118
4117
|
const remoteProject = await resolveRemoteProject({
|
|
4119
4118
|
projectRoot,
|
|
4120
4119
|
projectConfig,
|
|
@@ -4122,10 +4121,14 @@ var dev_default = defineCommand({
|
|
|
4122
4121
|
});
|
|
4123
4122
|
const effectiveProjectConfig = remoteProject.projectConfig;
|
|
4124
4123
|
const effectiveAuthToken = resolveLocalHarnessAccessToken(config) ?? (await createUserSessionManager(config).resolveApiToken())?.token ?? config.authToken;
|
|
4124
|
+
const authenticatedConfig = {
|
|
4125
|
+
...config,
|
|
4126
|
+
authToken: effectiveAuthToken
|
|
4127
|
+
};
|
|
4125
4128
|
const devCompile = await ensureDevCompiledResult({
|
|
4126
4129
|
projectRoot,
|
|
4127
4130
|
projectConfig: effectiveProjectConfig,
|
|
4128
|
-
config,
|
|
4131
|
+
config: authenticatedConfig,
|
|
4129
4132
|
env: parsedArgs.env ?? "local",
|
|
4130
4133
|
debug: parsedArgs.debug
|
|
4131
4134
|
});
|
|
@@ -4248,7 +4251,7 @@ var dev_default = defineCommand({
|
|
|
4248
4251
|
}
|
|
4249
4252
|
}
|
|
4250
4253
|
},
|
|
4251
|
-
createCliDevHostPlatform(
|
|
4254
|
+
createCliDevHostPlatform(authenticatedConfig)
|
|
4252
4255
|
);
|
|
4253
4256
|
clearPreflightOutput();
|
|
4254
4257
|
console.log(
|