@hypersoniclabs/helix-cli 0.1.24-helix3.450 → 0.1.24-helix3.451
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/earlyAccessNotice.d.ts +9 -0
- package/dist/earlyAccessNotice.js +63 -0
- package/dist/earlyAccessNotice.js.map +1 -0
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/plugins/beamng-vehicle/bin/__pycache__/beamng_abs.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/beamng_audio.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/beamng_engine.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/beamng_expression.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/beamng_jbeam.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/beamng_materials.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/beamng_stock_events.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/fmod_studio.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/fsb5.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/sim_audio.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/sim_audio_ac.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/sim_audio_beamng.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/sim_audio_fixtures.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/test_beamng_engine.cpython-312.pyc +0 -0
- package/plugins/beamng-vehicle/bin/__pycache__/test_sim_audio.cpython-312.pyc +0 -0
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/** The notice line for a command path such as ["vehicle", "validate"], or null when there is none. */
|
|
2
|
+
export declare function earlyAccessNoticeFor(commandPath: readonly string[]): string | null;
|
|
3
|
+
/** Print the notice for this command at most once per process. Never throws. */
|
|
4
|
+
export declare function printEarlyAccessNotice(commandPath: readonly string[], env?: NodeJS.ProcessEnv): void;
|
|
5
|
+
/** The names from the root command's direct child down to the executing command. */
|
|
6
|
+
export declare function commandPathOf(command: {
|
|
7
|
+
name(): string;
|
|
8
|
+
parent: unknown;
|
|
9
|
+
}): string[];
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.earlyAccessNoticeFor = earlyAccessNoticeFor;
|
|
4
|
+
exports.printEarlyAccessNotice = printEarlyAccessNotice;
|
|
5
|
+
exports.commandPathOf = commandPathOf;
|
|
6
|
+
// The "Early access" notice for creation commands whose kind is not yet stable.
|
|
7
|
+
//
|
|
8
|
+
// The kind -> stability map and the disclaimer wording live in @hypersoniclabs/helix-manifest
|
|
9
|
+
// (creation-stability) so the MCP, this CLI and the website agree. This file only decides which
|
|
10
|
+
// command is which kind and prints the line once per run.
|
|
11
|
+
//
|
|
12
|
+
// It goes to STDERR, always: `--json` output on stdout stays one parseable document. Set
|
|
13
|
+
// HELIX_NO_EARLY_ACCESS_NOTICE=1 to silence it (scripts, and wrappers that already tell the user).
|
|
14
|
+
const helix_manifest_1 = require("@hypersoniclabs/helix-manifest");
|
|
15
|
+
/** Command path -> creation kind. Longest prefix wins; a path with no match prints nothing. */
|
|
16
|
+
const COMMAND_KINDS = [
|
|
17
|
+
['vehicle addon', 'vehicle-addon'],
|
|
18
|
+
['vehicle', 'vehicle'],
|
|
19
|
+
['device', 'device'],
|
|
20
|
+
['pack', 'locomotion-pack'],
|
|
21
|
+
// Interactive item definitions are weapons and emotes today; neither kind is stable yet.
|
|
22
|
+
['item-def', 'Weapon and emote'],
|
|
23
|
+
];
|
|
24
|
+
/** The notice line for a command path such as ["vehicle", "validate"], or null when there is none. */
|
|
25
|
+
function earlyAccessNoticeFor(commandPath) {
|
|
26
|
+
const joined = commandPath.join(' ');
|
|
27
|
+
let best = null;
|
|
28
|
+
for (const entry of COMMAND_KINDS) {
|
|
29
|
+
const [prefix] = entry;
|
|
30
|
+
if ((joined === prefix || joined.startsWith(`${prefix} `)) && (!best || prefix.length > best[0].length))
|
|
31
|
+
best = entry;
|
|
32
|
+
}
|
|
33
|
+
if (!best)
|
|
34
|
+
return null;
|
|
35
|
+
return (0, helix_manifest_1.isEarlyAccessCreationKind)(best[1]) ? (0, helix_manifest_1.earlyAccessDisclaimer)(best[1]) : null;
|
|
36
|
+
}
|
|
37
|
+
let printed = false;
|
|
38
|
+
/** Print the notice for this command at most once per process. Never throws. */
|
|
39
|
+
function printEarlyAccessNotice(commandPath, env = process.env) {
|
|
40
|
+
if (printed || env.HELIX_NO_EARLY_ACCESS_NOTICE === '1')
|
|
41
|
+
return;
|
|
42
|
+
const notice = earlyAccessNoticeFor(commandPath);
|
|
43
|
+
if (!notice)
|
|
44
|
+
return;
|
|
45
|
+
printed = true;
|
|
46
|
+
try {
|
|
47
|
+
process.stderr.write(`${notice}\n`);
|
|
48
|
+
}
|
|
49
|
+
catch {
|
|
50
|
+
/* a closed stderr must never fail the command */
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
/** The names from the root command's direct child down to the executing command. */
|
|
54
|
+
function commandPathOf(command) {
|
|
55
|
+
const names = [];
|
|
56
|
+
let current = command;
|
|
57
|
+
while (current && current.parent) {
|
|
58
|
+
names.unshift(current.name());
|
|
59
|
+
current = current.parent;
|
|
60
|
+
}
|
|
61
|
+
return names;
|
|
62
|
+
}
|
|
63
|
+
//# sourceMappingURL=earlyAccessNotice.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"earlyAccessNotice.js","sourceRoot":"","sources":["../src/earlyAccessNotice.ts"],"names":[],"mappings":";;AAqBA,oDASC;AAKD,wDAUC;AAGD,sC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,GAAG,CAAC,4BAA4B,KAAK,GAAG;QAAE,OAAO;IAChE,MAAM,MAAM,GAAG,oBAAoB,CAAC,WAAW,CAAC,CAAC;IACjD,IAAI,CAAC,MAAM;QAAE,OAAO;IACpB,OAAO,GAAG,IAAI,CAAC;IACf,IAAI,CAAC;QACH,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,MAAM,IAAI,CAAC,CAAC;IACtC,CAAC;IAAC,MAAM,CAAC;QACP,iDAAiD;IACnD,CAAC;AACH,CAAC;AAED,oFAAoF;AACpF,SAAgB,aAAa,CAAC,OAA4C;IACxE,MAAM,KAAK,GAAa,EAAE,CAAC;IAC3B,IAAI,OAAO,GAA+C,OAAO,CAAC;IAClE,OAAO,OAAO,IAAK,OAA+B,CAAC,MAAM,EAAE,CAAC;QAC1D,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC;QAC9B,OAAO,GAAI,OAAkE,CAAC,MAAM,CAAC;IACvF,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -74,6 +74,7 @@ const browserLogin_1 = require("./browserLogin");
|
|
|
74
74
|
const unreal_1 = require("./unreal");
|
|
75
75
|
const unrealPublish_1 = require("./unrealPublish");
|
|
76
76
|
const device_1 = require("./device");
|
|
77
|
+
const earlyAccessNotice_1 = require("./earlyAccessNotice");
|
|
77
78
|
const types_1 = require("./bridge/types");
|
|
78
79
|
const cliAuthority_1 = require("./continuum/cliAuthority");
|
|
79
80
|
const adminPackagePinCommand_1 = require("./continuum/adminPackagePinCommand");
|
|
@@ -85,6 +86,10 @@ program
|
|
|
85
86
|
.name('helix')
|
|
86
87
|
.description('HELIX creator CLI — scaffold, validate, and publish Instant Worlds')
|
|
87
88
|
.version((0, lib_1.cliVersion)());
|
|
89
|
+
// Early-access kinds (device, vehicle, add-on, ...) say so once per run, on stderr, before the work starts.
|
|
90
|
+
program.hook('preAction', (_thisCommand, actionCommand) => {
|
|
91
|
+
(0, earlyAccessNotice_1.printEarlyAccessNotice)((0, earlyAccessNotice_1.commandPathOf)(actionCommand));
|
|
92
|
+
});
|
|
88
93
|
function fail(message) {
|
|
89
94
|
// Synchronous: stderr is an ASYNC pipe on macOS, so console.error + process.exit cut a long refusal at ~512 bytes
|
|
90
95
|
// whenever the output was piped — exactly how an agent or CI reads it — losing the next command it names.
|