@vm0/cli 4.17.0 → 4.18.0
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/index.js +13 -15
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -13255,9 +13255,9 @@ var createImageRequestSchema = external_exports.object({
|
|
|
13255
13255
|
/^[a-zA-Z0-9][a-zA-Z0-9-]{1,62}[a-zA-Z0-9]$/,
|
|
13256
13256
|
"alias must be 3-64 characters, alphanumeric and hyphens, start/end with alphanumeric"
|
|
13257
13257
|
).refine(
|
|
13258
|
-
(val) => !val.startsWith("vm0-"),
|
|
13258
|
+
(val) => !val.toLowerCase().startsWith("vm0-"),
|
|
13259
13259
|
'alias cannot start with "vm0-" (reserved for system templates)'
|
|
13260
|
-
),
|
|
13260
|
+
).transform((s) => s.toLowerCase()),
|
|
13261
13261
|
deleteExisting: external_exports.boolean().optional()
|
|
13262
13262
|
});
|
|
13263
13263
|
var createImageResponseSchema = external_exports.object({
|
|
@@ -13487,10 +13487,10 @@ function getLegacySystemTemplateWarning(legacyFormat) {
|
|
|
13487
13487
|
return void 0;
|
|
13488
13488
|
}
|
|
13489
13489
|
if (legacyFormat === "vm0-claude-code") {
|
|
13490
|
-
return `Warning: "${legacyFormat}" format is deprecated. Use "
|
|
13490
|
+
return `Warning: "${legacyFormat}" format is deprecated. Use "vm0/claude-code" instead.`;
|
|
13491
13491
|
}
|
|
13492
13492
|
if (legacyFormat === "vm0-claude-code-dev") {
|
|
13493
|
-
return `Warning: "${legacyFormat}" format is deprecated. Use "
|
|
13493
|
+
return `Warning: "${legacyFormat}" format is deprecated. Use "vm0/claude-code:dev" instead.`;
|
|
13494
13494
|
}
|
|
13495
13495
|
if (legacyFormat.startsWith("vm0-github-cli")) {
|
|
13496
13496
|
return `Warning: "${legacyFormat}" is deprecated and will be removed. No replacement available.`;
|
|
@@ -16294,7 +16294,7 @@ async function generateEnvPlaceholders(missingVars, envFilePath) {
|
|
|
16294
16294
|
}
|
|
16295
16295
|
}
|
|
16296
16296
|
var cookCommand = new Command13().name("cook").description("One-click agent preparation and execution from vm0.yaml").argument("[prompt]", "Prompt for the agent").action(async (prompt) => {
|
|
16297
|
-
const shouldExit = await checkAndUpgrade("4.
|
|
16297
|
+
const shouldExit = await checkAndUpgrade("4.18.0", prompt);
|
|
16298
16298
|
if (shouldExit) {
|
|
16299
16299
|
process.exit(0);
|
|
16300
16300
|
}
|
|
@@ -16509,7 +16509,7 @@ var buildCommand = new Command14().name("build").description("Build a custom ima
|
|
|
16509
16509
|
try {
|
|
16510
16510
|
const scope = await apiClient.getScope();
|
|
16511
16511
|
const dockerfile = await readFile6(file2, "utf8");
|
|
16512
|
-
console.log(chalk16.blue(`Building image:
|
|
16512
|
+
console.log(chalk16.blue(`Building image: ${scope.slug}/${name}`));
|
|
16513
16513
|
console.log();
|
|
16514
16514
|
const buildInfo = await apiClient.createImage({
|
|
16515
16515
|
dockerfile,
|
|
@@ -16545,9 +16545,7 @@ var buildCommand = new Command14().name("build").description("Build a custom ima
|
|
|
16545
16545
|
if (status === "ready") {
|
|
16546
16546
|
const shortVersion = formatVersionIdForDisplay(versionId);
|
|
16547
16547
|
console.log(
|
|
16548
|
-
chalk16.green(
|
|
16549
|
-
`\u2713 Image built: @${scope.slug}/${name}:${shortVersion}`
|
|
16550
|
-
)
|
|
16548
|
+
chalk16.green(`\u2713 Image built: ${scope.slug}/${name}:${shortVersion}`)
|
|
16551
16549
|
);
|
|
16552
16550
|
} else {
|
|
16553
16551
|
console.error(chalk16.red(`\u2717 Build failed`));
|
|
@@ -17074,7 +17072,7 @@ var statusCommand3 = new Command20().name("status").description("View current sc
|
|
|
17074
17072
|
try {
|
|
17075
17073
|
const scope = await apiClient.getScope();
|
|
17076
17074
|
console.log(chalk21.cyan("Scope Information:"));
|
|
17077
|
-
console.log(` Slug: ${chalk21.green(
|
|
17075
|
+
console.log(` Slug: ${chalk21.green(scope.slug)}`);
|
|
17078
17076
|
console.log(` Type: ${scope.type}`);
|
|
17079
17077
|
if (scope.displayName) {
|
|
17080
17078
|
console.log(` Display Name: ${scope.displayName}`);
|
|
@@ -17119,7 +17117,7 @@ var setCommand = new Command21().name("set").description("Set your scope slug").
|
|
|
17119
17117
|
if (existingScope) {
|
|
17120
17118
|
if (!options.force) {
|
|
17121
17119
|
console.error(
|
|
17122
|
-
chalk22.yellow(`You already have a scope:
|
|
17120
|
+
chalk22.yellow(`You already have a scope: ${existingScope.slug}`)
|
|
17123
17121
|
);
|
|
17124
17122
|
console.error();
|
|
17125
17123
|
console.error("To change your scope, use --force:");
|
|
@@ -17133,17 +17131,17 @@ var setCommand = new Command21().name("set").description("Set your scope slug").
|
|
|
17133
17131
|
process.exit(1);
|
|
17134
17132
|
}
|
|
17135
17133
|
scope = await apiClient.updateScope({ slug, force: true });
|
|
17136
|
-
console.log(chalk22.green(`\u2713 Scope updated to
|
|
17134
|
+
console.log(chalk22.green(`\u2713 Scope updated to ${scope.slug}`));
|
|
17137
17135
|
} else {
|
|
17138
17136
|
scope = await apiClient.createScope({
|
|
17139
17137
|
slug,
|
|
17140
17138
|
displayName: options.displayName
|
|
17141
17139
|
});
|
|
17142
|
-
console.log(chalk22.green(`\u2713 Scope created:
|
|
17140
|
+
console.log(chalk22.green(`\u2713 Scope created: ${scope.slug}`));
|
|
17143
17141
|
}
|
|
17144
17142
|
console.log();
|
|
17145
17143
|
console.log("Your images will now be namespaced as:");
|
|
17146
|
-
console.log(chalk22.cyan(`
|
|
17144
|
+
console.log(chalk22.cyan(` ${scope.slug}/<image-name>`));
|
|
17147
17145
|
} catch (error43) {
|
|
17148
17146
|
if (error43 instanceof Error) {
|
|
17149
17147
|
if (error43.message.includes("Not authenticated")) {
|
|
@@ -17180,7 +17178,7 @@ var scopeCommand = new Command22().name("scope").description("Manage your scope
|
|
|
17180
17178
|
|
|
17181
17179
|
// src/index.ts
|
|
17182
17180
|
var program = new Command23();
|
|
17183
|
-
program.name("vm0").description("VM0 CLI - A modern build tool").version("4.
|
|
17181
|
+
program.name("vm0").description("VM0 CLI - A modern build tool").version("4.18.0");
|
|
17184
17182
|
program.command("info").description("Display environment information").action(async () => {
|
|
17185
17183
|
console.log(chalk23.cyan("System Information:"));
|
|
17186
17184
|
console.log(`Node Version: ${process.version}`);
|