@paradigma-inc/flywheel 0.1.146 → 0.1.148
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/package.json +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/commands/help-metadata.js +14 -13
- package/src/runtime/vendor/flywheel-cli-dist/commands/help-metadata.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/commands/help.js +19 -12
- package/src/runtime/vendor/flywheel-cli-dist/commands/help.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/commands/registry/repository.js +4 -3
- package/src/runtime/vendor/flywheel-cli-dist/commands/registry/repository.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/commands/repository-output.js +34 -0
- package/src/runtime/vendor/flywheel-cli-dist/commands/repository-output.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/http/client.js +1 -0
- package/src/runtime/vendor/flywheel-cli-dist/http/client.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/invariants.js +24 -8
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/invariants.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/models/operation-identity.js +22 -0
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/models/operation-identity.js.map +1 -0
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/rebase/context.js +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/rebase/context.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/rebase/pull.js +2 -5
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/rebase/pull.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/rebase/replay.js +55 -62
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/rebase/replay.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/service/commit.js +7 -4
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/service/commit.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/service/revert.js +8 -11
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/service/revert.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/service/writes.js +9 -183
- package/src/runtime/vendor/flywheel-cli-dist/local/domain/service/writes.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/runtime/operations/history.js +18 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/runtime/operations/history.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/runtime/operations/projections.js +3 -3
- package/src/runtime/vendor/flywheel-cli-dist/local/runtime/operations/projections.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/runtime/snapshot-diff.js +183 -0
- package/src/runtime/vendor/flywheel-cli-dist/local/runtime/snapshot-diff.js.map +1 -0
- package/src/runtime/vendor/flywheel-cli-dist/local/store/apply.js +2 -3
- package/src/runtime/vendor/flywheel-cli-dist/local/store/apply.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/contract.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/history-validation.js +21 -14
- package/src/runtime/vendor/flywheel-cli-dist/local/store/history-validation.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/latest-values.js +170 -8
- package/src/runtime/vendor/flywheel-cli-dist/local/store/latest-values.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/pending.js +58 -100
- package/src/runtime/vendor/flywheel-cli-dist/local/store/pending.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/apply.js +52 -15
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/apply.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/artifacts.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/context.js +2 -0
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/context.js.map +1 -0
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/nodes.js +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/nodes.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/relations.js +3 -5
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/relations.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/projection/tags.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/sqlite/store.js +30 -28
- package/src/runtime/vendor/flywheel-cli-dist/local/store/sqlite/store.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/sync-commits.js +12 -70
- package/src/runtime/vendor/flywheel-cli-dist/local/store/sync-commits.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/local/store/sync.js +5 -11
- package/src/runtime/vendor/flywheel-cli-dist/local/store/sync.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/main.js +99 -180
- package/src/runtime/vendor/flywheel-cli-dist/main.js.map +1 -1
- package/src/runtime/vendor/flywheel-cli-dist/runtime-auth.js +112 -0
- package/src/runtime/vendor/flywheel-cli-dist/runtime-auth.js.map +1 -0
- package/src/runtime/vendor/manifest.json +9 -1
- package/src/unified-cli.mjs +189 -193
package/src/unified-cli.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { runCli as runSetupCli } from "./cli.mjs";
|
|
2
2
|
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
helpExtrasArg,
|
|
4
|
+
loadPackageVersion,
|
|
5
|
+
usageExtrasArg,
|
|
6
|
+
usageVersionArg,
|
|
7
7
|
} from "./public-command-metadata.mjs";
|
|
8
8
|
import { runRuntimeCli } from "./runtime/delegate.mjs";
|
|
9
9
|
import { RUNTIME_ALIASES } from "./runtime/vendor/flywheel-cli-dist/commands/aliases.js";
|
|
@@ -12,52 +12,52 @@ import { runUpdateCommand } from "./update/command.mjs";
|
|
|
12
12
|
import { runCommandWithDeferredUpdateWarning } from "./update/warning.mjs";
|
|
13
13
|
|
|
14
14
|
const ALIAS_RESERVED_COMMANDS = new Set([
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
15
|
+
"setup",
|
|
16
|
+
"update",
|
|
17
|
+
"uninstall",
|
|
18
|
+
"completion",
|
|
19
|
+
"help",
|
|
20
|
+
"--help",
|
|
21
|
+
"-h",
|
|
22
|
+
"--usage",
|
|
23
|
+
"--usage-spec",
|
|
24
24
|
]);
|
|
25
25
|
const VERSION_REQUEST_TOKENS = new Set(["--version", "-v", "version"]);
|
|
26
26
|
const USAGE_REQUEST_TOKENS = new Set(["--usage", "--usage-spec"]);
|
|
27
27
|
const COMPLETION_HELP_SUBCOMMANDS = new Set(["install", "uninstall"]);
|
|
28
28
|
|
|
29
29
|
function renderAliasesHelp() {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
30
|
+
const lines = Object.entries(RUNTIME_ALIASES).map(
|
|
31
|
+
([aliasCommand, canonicalCommand]) =>
|
|
32
|
+
` ${aliasCommand} → ${canonicalCommand}`,
|
|
33
|
+
);
|
|
34
|
+
process.stdout.write(`${lines.join("\n")}\n`);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
-
function
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
37
|
+
function stripHelpOptionTokens(argv) {
|
|
38
|
+
const out = [];
|
|
39
|
+
for (let i = 0; i < argv.length; i += 1) {
|
|
40
|
+
const token = argv[i];
|
|
41
|
+
if (token.startsWith("--format=") || token.startsWith("--env=")) continue;
|
|
42
|
+
if (token === "--format" || token === "--env") {
|
|
43
|
+
i += 1;
|
|
44
|
+
continue;
|
|
45
|
+
}
|
|
46
|
+
out.push(token);
|
|
47
|
+
}
|
|
48
|
+
return out;
|
|
49
49
|
}
|
|
50
50
|
|
|
51
51
|
function isVersionRequest(argv) {
|
|
52
|
-
|
|
52
|
+
return argv.length === 1 && VERSION_REQUEST_TOKENS.has(argv[0]);
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
/**
|
|
56
56
|
* Detect a top-level help invocation.
|
|
57
57
|
*
|
|
58
58
|
* The first token must be `help`, `--help`, or `-h` (or argv must be empty).
|
|
59
|
-
* Format tokens may follow — `flywheel help --
|
|
60
|
-
* `flywheel --help --format=json` are help invocations — but
|
|
59
|
+
* Format and environment tokens may follow — `flywheel help --env=research`
|
|
60
|
+
* and `flywheel --help --format=json` are help invocations — but options
|
|
61
61
|
* are never a help signal on their own. Misordered inputs like
|
|
62
62
|
* `flywheel --format=json help` fall through to the dispatcher, which
|
|
63
63
|
* surfaces `unknown command: --format=json` with a non-zero exit and keeps
|
|
@@ -68,189 +68,185 @@ function isVersionRequest(argv) {
|
|
|
68
68
|
* runtime ignores the trailing positional and emits top-level help.
|
|
69
69
|
*/
|
|
70
70
|
function isCombinedHelpRequest(argv) {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
71
|
+
if (argv.length === 0) return true;
|
|
72
|
+
if (argv[0] === "--help" || argv[0] === "-h") return true;
|
|
73
|
+
if (argv[0] !== "help") return false;
|
|
74
|
+
const remainder = stripHelpOptionTokens(argv.slice(1));
|
|
75
|
+
return remainder.length === 0;
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
function setupHelpArgvFor(target, subcommand) {
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
79
|
+
if (target === "setup" || target === "uninstall") {
|
|
80
|
+
return [target, "--help"];
|
|
81
|
+
}
|
|
82
82
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
}
|
|
87
|
-
return ["completion", "--help"];
|
|
83
|
+
if (target === "completion") {
|
|
84
|
+
if (COMPLETION_HELP_SUBCOMMANDS.has(subcommand)) {
|
|
85
|
+
return ["completion", subcommand, "--help"];
|
|
88
86
|
}
|
|
87
|
+
return ["completion", "--help"];
|
|
88
|
+
}
|
|
89
89
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
}
|
|
90
|
+
for (const nestedSubcommand of COMPLETION_HELP_SUBCOMMANDS) {
|
|
91
|
+
if (target === `completion ${nestedSubcommand}`) {
|
|
92
|
+
return ["completion", nestedSubcommand, "--help"];
|
|
94
93
|
}
|
|
94
|
+
}
|
|
95
95
|
|
|
96
|
-
|
|
96
|
+
return null;
|
|
97
97
|
}
|
|
98
98
|
|
|
99
99
|
async function routeExplicitHelp(argv, { runSetup, runRuntime }) {
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
process.exitCode = exitCode;
|
|
122
|
-
return;
|
|
123
|
-
}
|
|
124
|
-
const resolvedArgv =
|
|
125
|
-
typeof target === "string" &&
|
|
126
|
-
Object.prototype.hasOwnProperty.call(RUNTIME_ALIASES, target)
|
|
127
|
-
? ["help", RUNTIME_ALIASES[target], ...argv.slice(2)]
|
|
128
|
-
: argv;
|
|
129
|
-
const exitCode = await runRuntime(resolvedArgv);
|
|
100
|
+
const [, target, subcommand] = argv;
|
|
101
|
+
if (target === "--aliases" || target === "-a") {
|
|
102
|
+
renderAliasesHelp();
|
|
103
|
+
return;
|
|
104
|
+
}
|
|
105
|
+
const setupHelpArgv = setupHelpArgvFor(target, subcommand);
|
|
106
|
+
if (setupHelpArgv) {
|
|
107
|
+
process.exitCode = await runSetup(["node", "flywheel", ...setupHelpArgv], {
|
|
108
|
+
exitOverride: true,
|
|
109
|
+
});
|
|
110
|
+
return;
|
|
111
|
+
}
|
|
112
|
+
if (target === "update") {
|
|
113
|
+
process.exitCode = await runUpdateCommand(["--help"]);
|
|
114
|
+
return;
|
|
115
|
+
}
|
|
116
|
+
if (target === undefined) {
|
|
117
|
+
// Defensive: `isCombinedHelpRequest` normally catches this path first,
|
|
118
|
+
// but keep the fallback so any accidental routing still surfaces the
|
|
119
|
+
// grouped help + extras instead of a blank runtime call.
|
|
120
|
+
const exitCode = await runRuntime(["help", helpExtrasArg()]);
|
|
130
121
|
process.exitCode = exitCode;
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
const resolvedArgv =
|
|
125
|
+
typeof target === "string" &&
|
|
126
|
+
Object.prototype.hasOwnProperty.call(RUNTIME_ALIASES, target)
|
|
127
|
+
? ["help", RUNTIME_ALIASES[target], ...argv.slice(2)]
|
|
128
|
+
: argv;
|
|
129
|
+
const exitCode = await runRuntime(resolvedArgv);
|
|
130
|
+
process.exitCode = exitCode;
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
async function runWithDeferredUpdateWarning(argv, runCommand) {
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
134
|
+
const exitCode = await runCommandWithDeferredUpdateWarning({
|
|
135
|
+
argv,
|
|
136
|
+
currentVersion: await loadPackageVersion(),
|
|
137
|
+
runCommand,
|
|
138
|
+
});
|
|
139
|
+
if (Number.isInteger(exitCode)) {
|
|
140
|
+
process.exitCode = exitCode;
|
|
141
|
+
}
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
export async function runUnifiedCli(
|
|
145
|
-
|
|
146
|
-
|
|
145
|
+
argv = process.argv.slice(2),
|
|
146
|
+
dependencies = {},
|
|
147
147
|
) {
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
if (isVersionRequest(argv)) {
|
|
160
|
-
process.stdout.write(`${await loadPackageVersion()}\n`);
|
|
161
|
-
process.exitCode = 0;
|
|
162
|
-
return;
|
|
163
|
-
}
|
|
148
|
+
if (!Array.isArray(argv)) {
|
|
149
|
+
throw new Error("runUnifiedCli expects an argv array.");
|
|
150
|
+
}
|
|
151
|
+
const runSetup = dependencies.runSetupCli ?? runSetupCli;
|
|
152
|
+
const runtimeDependencies = dependencies.runtimeDependencies ?? {};
|
|
153
|
+
const runRuntime = (runtimeArgv) =>
|
|
154
|
+
(dependencies.runRuntimeCli ?? runRuntimeCli)(
|
|
155
|
+
runtimeArgv,
|
|
156
|
+
runtimeDependencies,
|
|
157
|
+
);
|
|
164
158
|
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
usageExtrasArg(),
|
|
171
|
-
usageVersionArg(publicPackageVersion),
|
|
172
|
-
]);
|
|
173
|
-
});
|
|
174
|
-
return;
|
|
175
|
-
}
|
|
159
|
+
if (isVersionRequest(argv)) {
|
|
160
|
+
process.stdout.write(`${await loadPackageVersion()}\n`);
|
|
161
|
+
process.exitCode = 0;
|
|
162
|
+
return;
|
|
163
|
+
}
|
|
176
164
|
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
165
|
+
if (argv.length === 1 && USAGE_REQUEST_TOKENS.has(argv[0])) {
|
|
166
|
+
await runWithDeferredUpdateWarning(argv, async () => {
|
|
167
|
+
const publicPackageVersion = await loadPackageVersion();
|
|
168
|
+
return await runRuntime([
|
|
169
|
+
argv[0],
|
|
170
|
+
usageExtrasArg(),
|
|
171
|
+
usageVersionArg(publicPackageVersion),
|
|
172
|
+
]);
|
|
173
|
+
});
|
|
174
|
+
return;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
if (isCombinedHelpRequest(argv)) {
|
|
178
|
+
// Preserve output validation and the selected credential/server profile.
|
|
179
|
+
// Put internal extras before user flags so a missing flag value cannot
|
|
180
|
+
// consume and expose the internal payload in an error.
|
|
181
|
+
const helpArgs = [];
|
|
182
|
+
for (let i = 0; i < argv.length; i += 1) {
|
|
183
|
+
const token = argv[i];
|
|
184
|
+
if (token.startsWith("--format=") || token.startsWith("--env=")) {
|
|
185
|
+
helpArgs.push(token);
|
|
186
|
+
} else if (token === "--format" || token === "--env") {
|
|
187
|
+
helpArgs.push(token);
|
|
188
|
+
if (i + 1 < argv.length) {
|
|
189
|
+
helpArgs.push(argv[i + 1]);
|
|
190
|
+
i += 1;
|
|
197
191
|
}
|
|
198
|
-
|
|
199
|
-
await runWithDeferredUpdateWarning(
|
|
200
|
-
argv,
|
|
201
|
-
async () => await runRuntime(passthrough),
|
|
202
|
-
);
|
|
203
|
-
return;
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
if (
|
|
207
|
-
argv.length > 0 &&
|
|
208
|
-
!ALIAS_RESERVED_COMMANDS.has(argv[0]) &&
|
|
209
|
-
Object.prototype.hasOwnProperty.call(RUNTIME_ALIASES, argv[0])
|
|
210
|
-
) {
|
|
211
|
-
argv = [RUNTIME_ALIASES[argv[0]], ...argv.slice(1)];
|
|
192
|
+
}
|
|
212
193
|
}
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
});
|
|
237
|
-
});
|
|
238
|
-
return;
|
|
239
|
-
}
|
|
240
|
-
|
|
241
|
-
if (
|
|
242
|
-
command.includes(":") ||
|
|
243
|
-
Object.prototype.hasOwnProperty.call(RETIRED_COMMAND_NAMES, command)
|
|
244
|
-
) {
|
|
245
|
-
await runWithDeferredUpdateWarning(
|
|
246
|
-
argv,
|
|
247
|
-
async () => await runRuntime(argv),
|
|
248
|
-
);
|
|
249
|
-
return;
|
|
250
|
-
}
|
|
251
|
-
|
|
194
|
+
const passthrough = ["help", helpExtrasArg(), ...helpArgs];
|
|
195
|
+
await runWithDeferredUpdateWarning(
|
|
196
|
+
argv,
|
|
197
|
+
async () => await runRuntime(passthrough),
|
|
198
|
+
);
|
|
199
|
+
return;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
if (
|
|
203
|
+
argv.length > 0 &&
|
|
204
|
+
!ALIAS_RESERVED_COMMANDS.has(argv[0]) &&
|
|
205
|
+
Object.prototype.hasOwnProperty.call(RUNTIME_ALIASES, argv[0])
|
|
206
|
+
) {
|
|
207
|
+
argv = [RUNTIME_ALIASES[argv[0]], ...argv.slice(1)];
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
const [command] = argv;
|
|
211
|
+
if (command === "update") {
|
|
212
|
+
process.exitCode = await runUpdateCommand(argv.slice(1));
|
|
213
|
+
return;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
if (command === "help") {
|
|
252
217
|
await runWithDeferredUpdateWarning(argv, async () => {
|
|
253
|
-
|
|
254
|
-
|
|
218
|
+
await routeExplicitHelp(argv, { runSetup, runRuntime });
|
|
219
|
+
return process.exitCode ?? 0;
|
|
255
220
|
});
|
|
221
|
+
return;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
if (
|
|
225
|
+
command === "setup" ||
|
|
226
|
+
command === "uninstall" ||
|
|
227
|
+
command === "completion"
|
|
228
|
+
) {
|
|
229
|
+
await runWithDeferredUpdateWarning(argv, async () => {
|
|
230
|
+
return await runSetup(["node", "flywheel", ...argv], {
|
|
231
|
+
exitOverride: true,
|
|
232
|
+
});
|
|
233
|
+
});
|
|
234
|
+
return;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
if (
|
|
238
|
+
command.includes(":") ||
|
|
239
|
+
Object.prototype.hasOwnProperty.call(RETIRED_COMMAND_NAMES, command)
|
|
240
|
+
) {
|
|
241
|
+
await runWithDeferredUpdateWarning(
|
|
242
|
+
argv,
|
|
243
|
+
async () => await runRuntime(argv),
|
|
244
|
+
);
|
|
245
|
+
return;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
await runWithDeferredUpdateWarning(argv, async () => {
|
|
249
|
+
process.stderr.write(`unknown command: ${command}\n`);
|
|
250
|
+
return 1;
|
|
251
|
+
});
|
|
256
252
|
}
|