@bitmagic/cli 0.1.52-dev.1 → 0.1.52-dev.11

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.
Files changed (152) hide show
  1. package/README.md +217 -11
  2. package/dist/assets/add.d.ts +40 -0
  3. package/dist/assets/add.js +229 -0
  4. package/dist/assets/add.js.map +1 -0
  5. package/dist/assets/entry.d.ts +44 -0
  6. package/dist/assets/entry.js +71 -0
  7. package/dist/assets/entry.js.map +1 -0
  8. package/dist/assets/file-kind.d.ts +61 -0
  9. package/dist/assets/file-kind.js +195 -0
  10. package/dist/assets/file-kind.js.map +1 -0
  11. package/dist/assets/list.d.ts +27 -0
  12. package/dist/assets/list.js +50 -0
  13. package/dist/assets/list.js.map +1 -0
  14. package/dist/assets/remove.d.ts +50 -0
  15. package/dist/assets/remove.js +91 -0
  16. package/dist/assets/remove.js.map +1 -0
  17. package/dist/assets/voxelize-glb.d.ts +37 -0
  18. package/dist/assets/voxelize-glb.js +65 -0
  19. package/dist/assets/voxelize-glb.js.map +1 -0
  20. package/dist/assets/vxl-summary.d.ts +32 -0
  21. package/dist/assets/vxl-summary.js +118 -0
  22. package/dist/assets/vxl-summary.js.map +1 -0
  23. package/dist/bin.js +25 -0
  24. package/dist/bin.js.map +1 -1
  25. package/dist/cli.d.ts +12 -0
  26. package/dist/cli.js +15 -1
  27. package/dist/cli.js.map +1 -1
  28. package/dist/commands/assets.d.ts +56 -0
  29. package/dist/commands/assets.js +328 -0
  30. package/dist/commands/assets.js.map +1 -0
  31. package/dist/commands/cover.js +2 -3
  32. package/dist/commands/cover.js.map +1 -1
  33. package/dist/commands/forge.d.ts +2 -9
  34. package/dist/commands/forge.js +2 -13
  35. package/dist/commands/forge.js.map +1 -1
  36. package/dist/commands/generate.d.ts +41 -9
  37. package/dist/commands/generate.js +234 -54
  38. package/dist/commands/generate.js.map +1 -1
  39. package/dist/commands/judge.d.ts +7 -7
  40. package/dist/commands/judge.js +53 -25
  41. package/dist/commands/judge.js.map +1 -1
  42. package/dist/commands/levels.d.ts +33 -0
  43. package/dist/commands/levels.js +241 -0
  44. package/dist/commands/levels.js.map +1 -0
  45. package/dist/commands/number-flag.d.ts +7 -0
  46. package/dist/commands/number-flag.js +38 -0
  47. package/dist/commands/number-flag.js.map +1 -0
  48. package/dist/commands/publish.d.ts +6 -1
  49. package/dist/commands/publish.js +42 -15
  50. package/dist/commands/publish.js.map +1 -1
  51. package/dist/commands/run-deps.d.ts +27 -0
  52. package/dist/commands/run-deps.js +43 -0
  53. package/dist/commands/run-deps.js.map +1 -0
  54. package/dist/commands/verify.d.ts +4 -0
  55. package/dist/commands/verify.js +94 -51
  56. package/dist/commands/verify.js.map +1 -1
  57. package/dist/editor/journal.d.ts +48 -1
  58. package/dist/editor/journal.js +44 -0
  59. package/dist/editor/journal.js.map +1 -1
  60. package/dist/editor/previews.d.ts +6 -0
  61. package/dist/editor/previews.js +16 -0
  62. package/dist/editor/previews.js.map +1 -1
  63. package/dist/editor/server.js +228 -53
  64. package/dist/editor/server.js.map +1 -1
  65. package/dist/editor/shell-page.js +221 -116
  66. package/dist/editor/shell-page.js.map +1 -1
  67. package/dist/editor/voxel-save.d.ts +47 -0
  68. package/dist/editor/voxel-save.js +49 -0
  69. package/dist/editor/voxel-save.js.map +1 -0
  70. package/dist/errors.d.ts +10 -0
  71. package/dist/errors.js +16 -0
  72. package/dist/errors.js.map +1 -1
  73. package/dist/forge/apply-modifications.d.ts +18 -1
  74. package/dist/forge/apply-modifications.js +15 -32
  75. package/dist/forge/apply-modifications.js.map +1 -1
  76. package/dist/forge/browser-host.js +9 -4
  77. package/dist/forge/browser-host.js.map +1 -1
  78. package/dist/forge/voxelize-session.d.ts +61 -0
  79. package/dist/forge/voxelize-session.js +137 -0
  80. package/dist/forge/voxelize-session.js.map +1 -0
  81. package/dist/generate/model.d.ts +36 -0
  82. package/dist/generate/model.js +90 -0
  83. package/dist/generate/model.js.map +1 -0
  84. package/dist/generate/prop.d.ts +52 -4
  85. package/dist/generate/prop.js +169 -102
  86. package/dist/generate/prop.js.map +1 -1
  87. package/dist/generate/stream.d.ts +7 -0
  88. package/dist/generate/stream.js +2 -1
  89. package/dist/generate/stream.js.map +1 -1
  90. package/dist/generate/vehicle.js +5 -85
  91. package/dist/generate/vehicle.js.map +1 -1
  92. package/dist/http/signed-upload.d.ts +55 -0
  93. package/dist/http/signed-upload.js +168 -0
  94. package/dist/http/signed-upload.js.map +1 -0
  95. package/dist/judge/facts.js +72 -57
  96. package/dist/judge/facts.js.map +1 -1
  97. package/dist/judge/record.d.ts +3 -0
  98. package/dist/judge/record.js +3 -0
  99. package/dist/judge/record.js.map +1 -1
  100. package/dist/levels/registry.d.ts +88 -0
  101. package/dist/levels/registry.js +309 -0
  102. package/dist/levels/registry.js.map +1 -0
  103. package/dist/messages/check.d.ts +30 -0
  104. package/dist/messages/check.js +119 -0
  105. package/dist/messages/check.js.map +1 -0
  106. package/dist/messages/notice.d.ts +58 -0
  107. package/dist/messages/notice.js +54 -0
  108. package/dist/messages/notice.js.map +1 -0
  109. package/dist/messages/refresh.d.ts +19 -0
  110. package/dist/messages/refresh.js +42 -0
  111. package/dist/messages/refresh.js.map +1 -0
  112. package/dist/project/jobs.d.ts +1 -1
  113. package/dist/project/jobs.js.map +1 -1
  114. package/dist/project/platform-declaration.d.ts +51 -0
  115. package/dist/project/platform-declaration.js +81 -0
  116. package/dist/project/platform-declaration.js.map +1 -0
  117. package/dist/publish/client.d.ts +13 -0
  118. package/dist/publish/client.js +13 -34
  119. package/dist/publish/client.js.map +1 -1
  120. package/dist/publish/platform.d.ts +42 -0
  121. package/dist/publish/platform.js +58 -0
  122. package/dist/publish/platform.js.map +1 -0
  123. package/dist/scaffold/project-files.js +124 -22
  124. package/dist/scaffold/project-files.js.map +1 -1
  125. package/dist/verify/artifacts.d.ts +19 -0
  126. package/dist/verify/artifacts.js +34 -0
  127. package/dist/verify/artifacts.js.map +1 -0
  128. package/dist/verify/browser.d.ts +10 -0
  129. package/dist/verify/browser.js +79 -9
  130. package/dist/verify/browser.js.map +1 -1
  131. package/dist/verify/classify.d.ts +37 -1
  132. package/dist/verify/classify.js +66 -2
  133. package/dist/verify/classify.js.map +1 -1
  134. package/dist/verify/device.d.ts +43 -0
  135. package/dist/verify/device.js +59 -0
  136. package/dist/verify/device.js.map +1 -0
  137. package/dist/verify/iterate.d.ts +21 -2
  138. package/dist/verify/iterate.js +43 -36
  139. package/dist/verify/iterate.js.map +1 -1
  140. package/dist/verify/mobile-parity.d.ts +42 -0
  141. package/dist/verify/mobile-parity.js +84 -0
  142. package/dist/verify/mobile-parity.js.map +1 -0
  143. package/dist/verify/platform.d.ts +47 -0
  144. package/dist/verify/platform.js +89 -0
  145. package/dist/verify/platform.js.map +1 -0
  146. package/dist/verify/result.d.ts +90 -6
  147. package/dist/verify/result.js +89 -10
  148. package/dist/verify/result.js.map +1 -1
  149. package/dist/verify/url.d.ts +9 -1
  150. package/dist/verify/url.js +10 -2
  151. package/dist/verify/url.js.map +1 -1
  152. package/package.json +4 -4
@@ -0,0 +1,58 @@
1
+ import type { EnvironmentName } from '../config/environments.js';
2
+ /**
3
+ * The unread-messages nudge.
4
+ *
5
+ * Bitmagic broadcasts reach web creators through the portal's notification bell. A CLI-lane
6
+ * creator may never open the portal at all, so a command prints a one-line pointer instead —
7
+ * the same shape as the update nudge next door, and for the same reason: a hint worth giving,
8
+ * never worth failing or slowing a command over.
9
+ *
10
+ * The CLI never CONSUMES a message. Reading is an act, and the read receipt is what tells an
11
+ * admin whether a broadcast actually landed — a terminal glancing at a count is not that.
12
+ */
13
+ /** What is remembered between runs, so no command pays for the network. */
14
+ export interface UnreadMessagesCache {
15
+ /**
16
+ * Which environment the count is about.
17
+ *
18
+ * Credentials are per environment and a creator can hold a prod and a dev login at once, so
19
+ * an answer about one says nothing about the other. Mirrors `UpdateCheckCache.tag`, including
20
+ * the consequence: a cache for the other environment reads as absent and is refreshed.
21
+ */
22
+ environment: EnvironmentName;
23
+ /** The count, or null when the last check could not reach the server (a back-off marker). */
24
+ unread: number | null;
25
+ /** Where to read them — the server hands this over; see check.ts. */
26
+ inboxUrl: string | null;
27
+ /** Epoch ms of that check. */
28
+ checkedAt: number;
29
+ }
30
+ /**
31
+ * How stale a count may be before it is refreshed.
32
+ *
33
+ * An hour, matching the release line's update check. Broadcasts are rare and never urgent to
34
+ * the minute, and the cost of being wrong is one extra line of stderr.
35
+ */
36
+ export declare const MESSAGES_CHECK_INTERVAL_MS: number;
37
+ /**
38
+ * How old a cached count may be and still be PRINTED.
39
+ *
40
+ * Separate from the refresh interval, and the thing that stops a laptop that has been offline
41
+ * for a fortnight nagging every single command about a message read in a browser on day one.
42
+ * Past this, the nudge goes quiet until a check succeeds again.
43
+ */
44
+ export declare const MESSAGES_NOTICE_MAX_AGE_MS: number;
45
+ /** Whether the cached answer should be refreshed in the background. */
46
+ export declare function isMessagesCacheStale(cache: UnreadMessagesCache | null, now: number): boolean;
47
+ /**
48
+ * The line to print, or null to stay quiet.
49
+ *
50
+ * Quiet for: no cache at all (a first-ever run pays one silent command, exactly as the update
51
+ * notice does), a failed check (`unread: null` — an unreachable server is not evidence of
52
+ * anything), nothing unread, no inbox URL to point at, and an answer past its max age.
53
+ *
54
+ * The wording is deliberately soft. The count can be up to an interval stale and the CLI cannot
55
+ * know whether the message was read in a browser five minutes ago, so it reports rather than
56
+ * instructs.
57
+ */
58
+ export declare function unreadMessagesNotice(cache: UnreadMessagesCache | null, now: number): string | null;
@@ -0,0 +1,54 @@
1
+ /**
2
+ * How stale a count may be before it is refreshed.
3
+ *
4
+ * An hour, matching the release line's update check. Broadcasts are rare and never urgent to
5
+ * the minute, and the cost of being wrong is one extra line of stderr.
6
+ */
7
+ export const MESSAGES_CHECK_INTERVAL_MS = 60 * 60 * 1000;
8
+ /**
9
+ * How old a cached count may be and still be PRINTED.
10
+ *
11
+ * Separate from the refresh interval, and the thing that stops a laptop that has been offline
12
+ * for a fortnight nagging every single command about a message read in a browser on day one.
13
+ * Past this, the nudge goes quiet until a check succeeds again.
14
+ */
15
+ export const MESSAGES_NOTICE_MAX_AGE_MS = 24 * 60 * 60 * 1000;
16
+ /** Whether the cached answer should be refreshed in the background. */
17
+ export function isMessagesCacheStale(cache, now) {
18
+ if (cache === null)
19
+ return true;
20
+ // A clock that moved backwards (a resumed VM, a corrected clock) would otherwise pin the
21
+ // cache as fresh forever — the same guard the update cache carries.
22
+ if (cache.checkedAt > now)
23
+ return true;
24
+ return now - cache.checkedAt >= MESSAGES_CHECK_INTERVAL_MS;
25
+ }
26
+ /**
27
+ * The line to print, or null to stay quiet.
28
+ *
29
+ * Quiet for: no cache at all (a first-ever run pays one silent command, exactly as the update
30
+ * notice does), a failed check (`unread: null` — an unreachable server is not evidence of
31
+ * anything), nothing unread, no inbox URL to point at, and an answer past its max age.
32
+ *
33
+ * The wording is deliberately soft. The count can be up to an interval stale and the CLI cannot
34
+ * know whether the message was read in a browser five minutes ago, so it reports rather than
35
+ * instructs.
36
+ */
37
+ export function unreadMessagesNotice(cache, now) {
38
+ if (cache === null || cache.unread === null || cache.inboxUrl === null)
39
+ return null;
40
+ if (!Number.isFinite(cache.unread) || cache.unread <= 0)
41
+ return null;
42
+ if (cache.checkedAt > now)
43
+ return null;
44
+ if (now - cache.checkedAt >= MESSAGES_NOTICE_MAX_AGE_MS)
45
+ return null;
46
+ const n = Math.floor(cache.unread);
47
+ // Capped for the same reason the bell's badge is: a number that high means something else is
48
+ // wrong, and the exact figure helps nobody.
49
+ const shown = n > 99 ? '99+' : String(n);
50
+ return n === 1
51
+ ? `You have 1 unread message from Bitmagic. Read it at ${cache.inboxUrl}`
52
+ : `You have ${shown} unread messages from Bitmagic. Read them at ${cache.inboxUrl}`;
53
+ }
54
+ //# sourceMappingURL=notice.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"notice.js","sourceRoot":"","sources":["../../src/messages/notice.ts"],"names":[],"mappings":"AAkCA;;;;;GAKG;AACH,MAAM,CAAC,MAAM,0BA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AC,CAAC,YAAY,KAAK,gDAAgD,KAAK,CAAC,QAAQ,EAAE,CAAC;AACxF,CAAC"}
@@ -0,0 +1,19 @@
1
+ /**
2
+ * Refresh the cached unread count after a command has done its work.
3
+ *
4
+ * Deliberately here and NOT in bin.ts, where the printing lives. bin.ts runs before citty has
5
+ * parsed argv, so it has no resolved environment and no token; by the time a command finishes,
6
+ * CommandContext has both — the same reasoning that puts the telemetry beacon here.
7
+ *
8
+ * Three properties this placement buys, all of them required:
9
+ * - never fires for a logged-out creator: getAccessToken throws before any network happens,
10
+ * and nothing is written, because no check took place to back off from.
11
+ * - never slows a command down: the count is for the NEXT run, the fetch is bounded at two
12
+ * seconds, and the print side is a pure file read.
13
+ * - never speaks for the wrong environment: the count is cached against the one that was
14
+ * actually resolved for this command, flags included.
15
+ *
16
+ * This is NOT telemetry — it is the creator's own inbox — so it is deliberately not gated on
17
+ * DO_NOT_TRACK. It reports nothing about the user; it asks a question on their behalf.
18
+ */
19
+ export declare function refreshUnreadMessages(): Promise<void>;
@@ -0,0 +1,42 @@
1
+ import { resolveAuth0ClientId } from '../config/environments.js';
2
+ import { getAccessToken } from '../auth/session.js';
3
+ import { currentCommand } from '../telemetry/command-context.js';
4
+ import { refreshUnreadMessagesInBackground } from './check.js';
5
+ /**
6
+ * Refresh the cached unread count after a command has done its work.
7
+ *
8
+ * Deliberately here and NOT in bin.ts, where the printing lives. bin.ts runs before citty has
9
+ * parsed argv, so it has no resolved environment and no token; by the time a command finishes,
10
+ * CommandContext has both — the same reasoning that puts the telemetry beacon here.
11
+ *
12
+ * Three properties this placement buys, all of them required:
13
+ * - never fires for a logged-out creator: getAccessToken throws before any network happens,
14
+ * and nothing is written, because no check took place to back off from.
15
+ * - never slows a command down: the count is for the NEXT run, the fetch is bounded at two
16
+ * seconds, and the print side is a pure file read.
17
+ * - never speaks for the wrong environment: the count is cached against the one that was
18
+ * actually resolved for this command, flags included.
19
+ *
20
+ * This is NOT telemetry — it is the creator's own inbox — so it is deliberately not gated on
21
+ * DO_NOT_TRACK. It reports nothing about the user; it asks a question on their behalf.
22
+ */
23
+ export async function refreshUnreadMessages() {
24
+ try {
25
+ const command = currentCommand();
26
+ if (command === null)
27
+ return;
28
+ const environment = command.environment;
29
+ if (environment === null)
30
+ return;
31
+ const clientId = resolveAuth0ClientId(environment, process.env);
32
+ const token = await getAccessToken(environment, clientId, {
33
+ fetch: globalThis.fetch,
34
+ sleep: (ms) => new Promise((resolve) => setTimeout(resolve, ms)),
35
+ });
36
+ await refreshUnreadMessagesInBackground(environment.name, environment.apiUrl, token);
37
+ }
38
+ catch {
39
+ // Logged out, offline, or anything else: the nudge simply stays as it was.
40
+ }
41
+ }
42
+ //# sourceMappingURL=refresh.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"refresh.js","sourceRoot":"","sources":["../../src/messages/refresh.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,iCAAiC,EAAE,MAAM,YAAY,CAAC;AAE/D;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,KAAK,UAAU,qBAAqB;IACzC,IAAI,CAAC;QACH,MAAM,OAAO,GAAG,cAAc,EAAE,CAAC;QACjC,IAAI,OAAO,KAAK,IAAI;YAAE,OAAO;QAC7B,MAAM,WAAW,GAAG,OAAO,CAAC,WAAW,CAAC;QACxC,IAAI,WAAW,KAAK,IAAI;YAAE,OAAO;QAEjC,MAAM,QAAQ,GAAG,oBAAoB,CAAC,WAAW,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC;QAChE,MAAM,KAAK,GAAG,MAAM,cAAc,CAAC,WAAW,EAAE,QAAQ,EAAE;YACxD,KAAK,EAAE,UAAU,CAAC,KAAK;YACvB,KAAK,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC;SACvE,CAAC,CAAC;QAEH,MAAM,iCAAiC,CAAC,WAAW,CAAC,IAAI,EAAE,WAAW,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;IACvF,CAAC;IAAC,MAAM,CAAC;QACP,2EAA2E;IAC7E,CAAC;AACH,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import type { ForgeProgressSnapshot } from '../forge/progress.js';
2
2
  import type { ForgeLayoutMap } from '@bitmagic/world-forger/pipeline/index.js';
3
3
  /** Which command is running. Shown as-is in the dev view, so these are creator-facing words. */
4
- export type JobKind = 'skybox' | 'sound' | 'image' | 'character' | 'animation' | 'prop' | 'vehicle' | 'forge' | 'cover' | 'hq' | 'judge';
4
+ export type JobKind = 'skybox' | 'background' | 'block-type' | 'sound' | 'image' | 'character' | 'animation' | 'prop' | 'vehicle' | 'forge' | 'cover' | 'hq' | 'judge' | 'upload' | 'model';
5
5
  export interface JobRecord {
6
6
  jobId: string;
7
7
  kind: JobKind;
@@ -1 +1 @@
1
- {"version":3,"file":"jobs.js","sourceRoot":"","sources":["../../src/project/jobs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+CG;AACH,OAAO,KAAK,EAAE,MAAM,IAAI,CAAC;AACzB,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AA6ChE,MAAM,CAAC,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;AAEvD,4EAA4E;AAC5E,MAAM,oBAAoB,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;AAEjD,MAAM,UAAU,WAAW,CAAC,IAAY;IACtC,OAAO,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iG;IACjG,eAAe,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;AAC/B,CAAC;AAED,oFAAoF;AACpF,MAAM,UAAU,OAAO,CAAC,IAAY,EAAE,KAAa,EAAE,KAAa;IAChE,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,WAAW,CAAC,EAAE,CAAC,YAAY,CAAC,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC;QAC7E,IAAI,QAAQ,KAAK,IAAI;YAAE,OAAO;QAC9B,WAAW,CAAC,IAAI,EAAE,EAAE,GAAG,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,SAAS,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC;IACnG,CAAC;IAAC,MAAM,CAAC;QACP,8EAA8E;IAChF,CAAC;AACH,CAAC"}
@@ -0,0 +1,51 @@
1
+ /**
2
+ * What a project's work copy DECLARES about the platform it is for: `primaryPlatform` at the top
3
+ * level of `src/work/game.json`, and `worldProfileData.mobileOrientation`.
4
+ *
5
+ * One reader, because two commands now act on the same two fields and must never disagree about
6
+ * them. `bitmagic publish` syncs them to the catalogue (`publish/platform.ts`), and `bitmagic
7
+ * verify` / `bitmagic judge` use them to decide which platform to BOOT and whether a mobile
8
+ * parity gap is a warning or a failure. A second copy of this parse would drift the day one of
9
+ * those files moves.
10
+ *
11
+ * This module reports what the files SAY and nothing about what to do with it: a value that is
12
+ * present but unusable lands in `rejected` rather than in a sentence, because "leaving the stored
13
+ * platform alone" and "verifying on the desktop viewport instead" are different consequences of
14
+ * the same bad value and only the caller knows which one applies.
15
+ *
16
+ * Best effort throughout: a missing, unreadable or malformed file means "the project declares
17
+ * nothing", never an error. A declaration must not be able to fail a command whose real work
18
+ * succeeded.
19
+ */
20
+ export type PrimaryPlatform = 'desktop' | 'mobile';
21
+ export type MobileOrientation = 'portrait' | 'landscape';
22
+ export interface PlatformDeclaration {
23
+ /**
24
+ * `undefined` means the project declares nothing, which is NOT the same as declaring
25
+ * 'desktop': publish's catalogue columns are sticky, so "says nothing" must leave the stored
26
+ * value alone while "says desktop" must overwrite it. Verify treats both as desktop, but it
27
+ * has to be able to tell them apart to explain WHY it picked a platform.
28
+ */
29
+ primaryPlatform?: PrimaryPlatform;
30
+ mobileOrientation?: MobileOrientation;
31
+ /** Whether either work-copy file could be read at all. */
32
+ workCopyReadable: boolean;
33
+ /** Values that were present but not one of the accepted ones, verbatim, for the caller's message. */
34
+ rejected: {
35
+ primaryPlatform?: unknown;
36
+ mobileOrientation?: unknown;
37
+ };
38
+ }
39
+ /**
40
+ * Parse the platform declaration out of `src/work/`.
41
+ *
42
+ * `mobileOrientation` resolves world.json first, game.json second, matching the web lane's own
43
+ * resolution (`game-storage-backend.ts`'s `getListingFieldsSync`). Note this is the OPPOSITE
44
+ * order to `readFaviconOverride` in publish/favicon.ts, which reads game.json first — the
45
+ * favicon override's home is game.json, the orientation's is world.json, and neither order is a
46
+ * house style.
47
+ *
48
+ * The legacy `mainPlatform` spelling is NOT honoured: it predates the CLI lane entirely, so no
49
+ * project this reads can carry it.
50
+ */
51
+ export declare function readPlatformDeclaration(root: string): PlatformDeclaration;
@@ -0,0 +1,81 @@
1
+ /**
2
+ * What a project's work copy DECLARES about the platform it is for: `primaryPlatform` at the top
3
+ * level of `src/work/game.json`, and `worldProfileData.mobileOrientation`.
4
+ *
5
+ * One reader, because two commands now act on the same two fields and must never disagree about
6
+ * them. `bitmagic publish` syncs them to the catalogue (`publish/platform.ts`), and `bitmagic
7
+ * verify` / `bitmagic judge` use them to decide which platform to BOOT and whether a mobile
8
+ * parity gap is a warning or a failure. A second copy of this parse would drift the day one of
9
+ * those files moves.
10
+ *
11
+ * This module reports what the files SAY and nothing about what to do with it: a value that is
12
+ * present but unusable lands in `rejected` rather than in a sentence, because "leaving the stored
13
+ * platform alone" and "verifying on the desktop viewport instead" are different consequences of
14
+ * the same bad value and only the caller knows which one applies.
15
+ *
16
+ * Best effort throughout: a missing, unreadable or malformed file means "the project declares
17
+ * nothing", never an error. A declaration must not be able to fail a command whose real work
18
+ * succeeded.
19
+ */
20
+ import * as fs from 'node:fs';
21
+ import * as path from 'node:path';
22
+ import { aliasSourceDir } from '../scaffold/aliases.js';
23
+ /**
24
+ * Parse the platform declaration out of `src/work/`.
25
+ *
26
+ * `mobileOrientation` resolves world.json first, game.json second, matching the web lane's own
27
+ * resolution (`game-storage-backend.ts`'s `getListingFieldsSync`). Note this is the OPPOSITE
28
+ * order to `readFaviconOverride` in publish/favicon.ts, which reads game.json first — the
29
+ * favicon override's home is game.json, the orientation's is world.json, and neither order is a
30
+ * house style.
31
+ *
32
+ * The legacy `mainPlatform` spelling is NOT honoured: it predates the CLI lane entirely, so no
33
+ * project this reads can carry it.
34
+ */
35
+ export function readPlatformDeclaration(root) {
36
+ const workDir = path.join(root, aliasSourceDir('work'));
37
+ const game = readJsonObject(path.join(workDir, 'game.json'));
38
+ const world = readJsonObject(path.join(workDir, 'world.json'));
39
+ const declaration = {
40
+ workCopyReadable: game !== null || world !== null,
41
+ rejected: {},
42
+ };
43
+ const declared = game?.primaryPlatform;
44
+ if (declared === 'desktop' || declared === 'mobile') {
45
+ declaration.primaryPlatform = declared;
46
+ }
47
+ else if (declared !== undefined) {
48
+ declaration.rejected.primaryPlatform = declared;
49
+ }
50
+ const orientation = worldProfileValue(world, 'mobileOrientation')
51
+ ?? worldProfileValue(game, 'mobileOrientation');
52
+ if (orientation === 'portrait' || orientation === 'landscape') {
53
+ declaration.mobileOrientation = orientation;
54
+ }
55
+ else if (orientation !== undefined) {
56
+ declaration.rejected.mobileOrientation = orientation;
57
+ }
58
+ return declaration;
59
+ }
60
+ /** Parse one work-copy JSON file, or null when it is missing, unreadable or not an object. */
61
+ function readJsonObject(filePath) {
62
+ let parsed;
63
+ try {
64
+ if (!fs.existsSync(filePath))
65
+ return null;
66
+ parsed = JSON.parse(fs.readFileSync(filePath, 'utf-8'));
67
+ }
68
+ catch {
69
+ return null;
70
+ }
71
+ return typeof parsed === 'object' && parsed !== null && !Array.isArray(parsed)
72
+ ? parsed
73
+ : null;
74
+ }
75
+ function worldProfileValue(source, key) {
76
+ const profile = source?.worldProfileData;
77
+ if (typeof profile !== 'object' || profile === null || Array.isArray(profile))
78
+ return undefined;
79
+ return profile[key];
80
+ }
81
+ //# sourceMappingURL=platform-declaration.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform-declaration.js","sourceRoot":"","sources":["../../src/project/platform-declaration.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,MAAM,SAAS,CAAC;AAC9B,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAuBxD;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,uBAAuB,CAAC,IAAY;IAClD,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,IAAI,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC,CAAC;IAC7D,MAAM,KAAK,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,YAAY,CAAC,CAAC,CAAC;IAE/D,MAAM,WAAW,GAAwB;QACvC,gBAAgB,EAAE,IAAI,KAAK,IAAI,IAAI,KAAK,KAAK,IAAI;QACjD,QAAQ,EAAE,EAAE;KACb,CAAC;IAEF,MAAM,QAAQ,GAAG,IAAI,EAAE,eAAe,CAAC;IACvC,IAAI,QAAQ,KAAK,SAAS,IAAI,QAAQ,KAAK,QAAQ,EAAE,CAAC;QACpD,WAAW,CAAC,eAAe,GAAG,QAAQ,CAAC;IACzC,CAAC;SAAM,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;QAClC,WAAW,CAAC,QAAQ,CA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6 +119,19 @@ export interface CompletePublishRequest {
119
119
  * routinely different copies of the shared code — see SOURCE_INDEX_ALGO.
120
120
  */
121
121
  fingerprintAlgo?: string;
122
+ /**
123
+ * The catalog's platform indicators, synced from the project's own work copy — see
124
+ * `publish/platform.ts` for where each one is read and why an absent key is not the same
125
+ * message as `'desktop'` / `null`.
126
+ *
127
+ * Optional in the same forward-compatible sense as the source-archive fields above: both are
128
+ * sticky columns server-side, so a CLI that sends neither leaves whatever is stored alone, and
129
+ * a server that has not deployed this yet simply ignores two unknown body keys. Neither
130
+ * direction of the skew can fail a publish.
131
+ */
132
+ primaryPlatform?: 'desktop' | 'mobile';
133
+ /** `null` clears the stored orientation — the project no longer declares one. */
134
+ mobileOrientation?: 'portrait' | 'landscape' | null;
122
135
  }
123
136
  /** Per-check outcome from the server's source audit. Advisory: none of it changes the exit code. */
124
137
  export interface SourceCheckResult {
@@ -1,14 +1,24 @@
1
1
  /**
2
2
  * The HTTP client for `bitmagic publish`: the two authorizing calls to api-server
3
3
  * (`publish/begin`, `publish/complete`), the thumbnail's signed-upload lane
4
- * (`uploads/signed-url`, the same route `forge/upload-proxy.ts` bridges for the browser), and the
5
- * two raw PUTs against the signed GCS URLs those calls mint.
4
+ * (`uploads/signed-url`, the same route `forge/upload-proxy.ts` bridges for the browser and
5
+ * `bitmagic assets add` uploads through), and the raw PUTs against the signed GCS URLs those calls
6
+ * mint — which go through `http/signed-upload.ts`, pinned to this lane's exit code.
6
7
  *
7
8
  * `publishExitCode` is the one status→exit-code mapping every call above shares, so `publish.ts`
8
9
  * never has to duplicate the 401/403/409 distinctions per call site.
9
10
  */
10
11
  import { CliError } from '../errors.js';
11
12
  import { apiServerHeaders } from '../telemetry/request-headers.js';
13
+ import { putSignedUrl as putSignedUrlShared, putSignedUpload } from '../http/signed-upload.js';
14
+ /**
15
+ * The publish lane's exit code for a failed PUT is 6 (README "Exit codes": upload or finalize
16
+ * failed, usually transient), so every raw PUT here goes through the shared helper with it pinned.
17
+ */
18
+ const PUBLISH_UPLOAD_EXIT_CODE = 6;
19
+ function putSignedUrl(url, body, headers, deps) {
20
+ return putSignedUrlShared(url, body, headers, deps, { exitCode: PUBLISH_UPLOAD_EXIT_CODE });
21
+ }
12
22
  function isRecord(value) {
13
23
  return typeof value === 'object' && value !== null && !Array.isArray(value);
14
24
  }
@@ -95,34 +105,6 @@ async function postJson(url, accessToken, body, deps) {
95
105
  const message = stringField(parsedError.error) ?? `api-server returned HTTP ${response.status} for ${url}.`;
96
106
  throw new CliError(message, publishExitCode(response.status, { code }));
97
107
  }
98
- /**
99
- * Raw PUT of already-prepared bytes to a GCS V4 signed URL.
100
- *
101
- * `headers` must match exactly what the URL's signature bound (Cache-Control, and — for the
102
- * thumbnail lane — Content-Encoding when the server chose to gzip). A mismatch is a 403 from GCS,
103
- * not a stale-cache symptom; see cli-publish.ts's and cli-uploads.ts's own doc comments for why.
104
- */
105
- async function putSignedUrl(url, body, headers, deps) {
106
- let response;
107
- try {
108
- // `@types/node`'s ambient `Uint8Array` (generic over `ArrayBufferLike` since TS 5.7) does not
109
- // structurally match this project's `BodyInit` (this tsconfig's `"DOM"` lib pulls in lib.dom's
110
- // own copy, which `@types/node`'s conditional global-augmentation defers to whenever DOM
111
- // globals are present — see node_modules/@types/node/web-globals/fetch.d.ts). Deriving the
112
- // body type from `Parameters<typeof fetch>[1]` instead of naming `BodyInit` was tried and hits
113
- // the identical mismatch, because it resolves to the same lib.dom type in THIS project. Both a
114
- // `string` and a `Uint8Array` are valid `fetch` bodies at runtime regardless.
115
- response = await deps.fetch(url, { method: 'PUT', headers, body: body });
116
- }
117
- catch (error) {
118
- const message = error instanceof Error ? error.message : String(error);
119
- throw new CliError(`Could not upload to storage: ${message}`, 6);
120
- }
121
- if (!response.ok) {
122
- const text = await response.text().catch(() => '');
123
- throw new CliError(`Upload to storage failed: HTTP ${response.status}${text ? ` — ${text.slice(0, 200)}` : ''}`, 6);
124
- }
125
- }
126
108
  export async function beginPublish(environment, accessToken, body, deps) {
127
109
  return postJson(`${environment.apiUrl}/api/cli/v1/publish/begin`, accessToken, body, deps);
128
110
  }
@@ -160,9 +142,6 @@ export async function requestThumbnailUploadUrl(environment, accessToken, body,
160
142
  * the server — not this lane — decides both.
161
143
  */
162
144
  export async function putThumbnail(signed, bytes, contentType, deps) {
163
- const headers = { 'Content-Type': contentType, 'Cache-Control': signed.cacheControl };
164
- if (signed.contentEncoding)
165
- headers['Content-Encoding'] = signed.contentEncoding;
166
- await putSignedUrl(signed.signedUrl, bytes, headers, deps);
145
+ await putSignedUpload(signed, bytes, contentType, deps, { exitCode: PUBLISH_UPLOAD_EXIT_CODE });
167
146
  }
168
147
  //# sourceMappingURL=client.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"client.js","sourceRoot":"","sources":["../../src/publish/client.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAExC,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAWnE,SAAS,QAAQ,CAAC,KAAc;IAC9B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AAC9E,CAAC;AAED,SAAS,WAAW,CAAC,KAAc;IACjC,OAAO,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC;AACvD,CAAC;AAED,KAAK,UAAU,YAAY,CAAC,QAAuB;IACjD,IAAI,CAAC;QACH,MAAM,MAAM,GAAY,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;QAC9C,OAAO,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;IACxC,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,EAAE,CAAC;IACZ,CAAC;AACH,CAAC;AAED;;;;;;GAMG;AACH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,SAAS,EACT,IAAI,EACJ,EAAE,cAAc,EAAE,2BAA2B,EAAE,eAAe,EAAE,YAAY,EAAE,EAC9E,IAAI,CACL,CAAC;AACJ,CAAC;AAoBD,MAAM,CAAC,KAAK,UAAU,yBAAyB,CAC7C,WAAwB,EACxB,WAAmB,EACnB,IAA4B,EAC5B,IAAa;IAEb,OAAO,QAAQ,CACb,GAAG,WAAW,CAAC,MAAM,gCAAgC,EACrD,WAAW,EACX,IAAI,EACJ,IAAI,CACL,CAAC;AACJ,CAAC;AAED;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,YAAY,CAChC,MAA0B,EAC1B,KAAiB,EACjB,WAAmB,EACnB,IAAa;IAEb,MAAM,eAAe,CAAC,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,IAAI,EAAE,EAAE,QAAQ,EAAE,wBAAwB,EAAE,CAAC,CAAC;AAClG,CAAC"}
@@ -0,0 +1,42 @@
1
+ /** The two platform indicator columns, in the shape `publish/complete` accepts them. */
2
+ export interface PlatformIndicators {
3
+ primaryPlatform?: 'desktop' | 'mobile';
4
+ /** `null` is meaningful: the project declares no orientation, so the stored one is cleared. */
5
+ mobileOrientation?: 'portrait' | 'landscape' | null;
6
+ }
7
+ export interface PlatformIndicatorsResult {
8
+ /** Spread straight into the `publish/complete` body. An absent key means "preserve". */
9
+ fields: PlatformIndicators;
10
+ /** Creator-facing lines: what was read, or why something in the project files was ignored. */
11
+ notes: string[];
12
+ }
13
+ /**
14
+ * The platform indicators a publish syncs from the project's own work copy: which platform the
15
+ * game is FOR (`primaryPlatform`, top level of game.json) and, for a phone game that only makes
16
+ * sense one way up, `worldProfileData.mobileOrientation`.
17
+ *
18
+ * The parse itself lives in `project/platform-declaration.ts`, shared with `bitmagic verify`,
19
+ * which boots the platform the same two fields declare. What stays HERE is the wire semantics,
20
+ * which are publish's alone.
21
+ *
22
+ * The project files are the source of truth, exactly as they are in the web lane — the columns
23
+ * are "indicators synced from game.json at publish, like `genre`" (migration 048). So a value
24
+ * changed anywhere else is reverted by the creator's next publish, and the way to make a game
25
+ * mobile is to edit `src/work/game.json`.
26
+ *
27
+ * Two asymmetries that are deliberate:
28
+ *
29
+ * - An ABSENT or unrecognised `primaryPlatform` omits the key rather than defaulting to
30
+ * 'desktop'. Both columns are sticky at the `upsertGame` layer (an absent key preserves the
31
+ * stored value), so "the project says nothing" and "the project says desktop" must not
32
+ * collapse into the same wire message.
33
+ * - A readable work copy that declares no orientation sends an explicit `null`, which CLEARS
34
+ * the column. That is what makes deleting the field from world.json take effect; omitting
35
+ * the key instead would make an orientation impossible to remove from here. Only a work copy
36
+ * neither of whose files can be read omits the key.
37
+ *
38
+ * Best effort throughout, like `readFaviconOverride`: a missing, unreadable or malformed file
39
+ * means "the project declares nothing", never an error. A catalog indicator must not be able to
40
+ * fail a publish whose bundle is already uploaded.
41
+ */
42
+ export declare function readPlatformIndicators(root: string): PlatformIndicatorsResult;
@@ -0,0 +1,58 @@
1
+ import { readPlatformDeclaration } from '../project/platform-declaration.js';
2
+ /**
3
+ * The platform indicators a publish syncs from the project's own work copy: which platform the
4
+ * game is FOR (`primaryPlatform`, top level of game.json) and, for a phone game that only makes
5
+ * sense one way up, `worldProfileData.mobileOrientation`.
6
+ *
7
+ * The parse itself lives in `project/platform-declaration.ts`, shared with `bitmagic verify`,
8
+ * which boots the platform the same two fields declare. What stays HERE is the wire semantics,
9
+ * which are publish's alone.
10
+ *
11
+ * The project files are the source of truth, exactly as they are in the web lane — the columns
12
+ * are "indicators synced from game.json at publish, like `genre`" (migration 048). So a value
13
+ * changed anywhere else is reverted by the creator's next publish, and the way to make a game
14
+ * mobile is to edit `src/work/game.json`.
15
+ *
16
+ * Two asymmetries that are deliberate:
17
+ *
18
+ * - An ABSENT or unrecognised `primaryPlatform` omits the key rather than defaulting to
19
+ * 'desktop'. Both columns are sticky at the `upsertGame` layer (an absent key preserves the
20
+ * stored value), so "the project says nothing" and "the project says desktop" must not
21
+ * collapse into the same wire message.
22
+ * - A readable work copy that declares no orientation sends an explicit `null`, which CLEARS
23
+ * the column. That is what makes deleting the field from world.json take effect; omitting
24
+ * the key instead would make an orientation impossible to remove from here. Only a work copy
25
+ * neither of whose files can be read omits the key.
26
+ *
27
+ * Best effort throughout, like `readFaviconOverride`: a missing, unreadable or malformed file
28
+ * means "the project declares nothing", never an error. A catalog indicator must not be able to
29
+ * fail a publish whose bundle is already uploaded.
30
+ */
31
+ export function readPlatformIndicators(root) {
32
+ const declaration = readPlatformDeclaration(root);
33
+ const fields = {};
34
+ const notes = [];
35
+ if (declaration.primaryPlatform !== undefined) {
36
+ fields.primaryPlatform = declaration.primaryPlatform;
37
+ }
38
+ if (declaration.workCopyReadable) {
39
+ // Explicit null when the work copy is readable but declares nothing — see the doc comment.
40
+ fields.mobileOrientation = declaration.mobileOrientation ?? null;
41
+ }
42
+ const { rejected } = declaration;
43
+ if ('primaryPlatform' in rejected) {
44
+ notes.push(`game.json primaryPlatform ${JSON.stringify(rejected.primaryPlatform)} is not "desktop" `
45
+ + 'or "mobile" — leaving the stored platform alone.');
46
+ }
47
+ if ('mobileOrientation' in rejected) {
48
+ notes.push(`worldProfileData.mobileOrientation ${JSON.stringify(rejected.mobileOrientation)} is not `
49
+ + '"portrait" or "landscape" — publishing with no orientation lock.');
50
+ }
51
+ if (fields.primaryPlatform === 'mobile') {
52
+ notes.push(fields.mobileOrientation
53
+ ? `Cataloged as a mobile game, locked to ${fields.mobileOrientation}.`
54
+ : 'Cataloged as a mobile game.');
55
+ }
56
+ return { fields, notes };
57
+ }
58
+ //# sourceMappingURL=platform.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform.js","sourceRoot":"","sources":["../../src/publish/platform.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,oCAAoC,CAAC;AAgB7E;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,MAAM,UAAU,sBAAsB,CAAC,IAAY;IACjD,MAAM,WAAW,GAAG,uB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