@vm0/cli 5.0.2 → 5.1.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.
Files changed (2) hide show
  1. package/index.js +21 -15
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -12339,7 +12339,9 @@ var storedExecutionContextSchema = external_exports.object({
12339
12339
  encryptedSecrets: external_exports.string().nullable(),
12340
12340
  // AES-256-GCM encrypted secrets
12341
12341
  cliAgentType: external_exports.string(),
12342
- experimentalFirewall: experimentalFirewallSchema.optional()
12342
+ experimentalFirewall: experimentalFirewallSchema.optional(),
12343
+ postCreateCommand: external_exports.string().nullable().optional()
12344
+ // Lifecycle hook
12343
12345
  });
12344
12346
  var executionContextSchema = external_exports.object({
12345
12347
  runId: external_exports.string().uuid(),
@@ -12357,7 +12359,9 @@ var executionContextSchema = external_exports.object({
12357
12359
  secretValues: external_exports.array(external_exports.string()).nullable(),
12358
12360
  cliAgentType: external_exports.string(),
12359
12361
  // Experimental firewall configuration
12360
- experimentalFirewall: experimentalFirewallSchema.optional()
12362
+ experimentalFirewall: experimentalFirewallSchema.optional(),
12363
+ // Lifecycle hook - command to run after working dir creation
12364
+ postCreateCommand: external_exports.string().nullable().optional()
12361
12365
  });
12362
12366
  var runnersJobClaimContract = c.router({
12363
12367
  claim: {
@@ -15175,17 +15179,19 @@ function validateAgentCompose(config2) {
15175
15179
  error: "Missing agent.image (required when provider is not auto-configured)"
15176
15180
  };
15177
15181
  }
15178
- if (agent.working_dir !== void 0 && typeof agent.working_dir !== "string") {
15179
- return {
15180
- valid: false,
15181
- error: "agent.working_dir must be a string if provided"
15182
- };
15183
- }
15184
- if (!agent.working_dir && !providerIsSupported) {
15185
- return {
15186
- valid: false,
15187
- error: "Missing agent.working_dir (required when provider is not auto-configured)"
15188
- };
15182
+ if (agent.postCreateCommand !== void 0) {
15183
+ if (typeof agent.postCreateCommand !== "string") {
15184
+ return {
15185
+ valid: false,
15186
+ error: "agent.postCreateCommand must be a string"
15187
+ };
15188
+ }
15189
+ if (agent.postCreateCommand.length === 0) {
15190
+ return {
15191
+ valid: false,
15192
+ error: "agent.postCreateCommand cannot be empty"
15193
+ };
15194
+ }
15189
15195
  }
15190
15196
  if (agent.instructions !== void 0) {
15191
15197
  if (typeof agent.instructions !== "string") {
@@ -18588,7 +18594,7 @@ async function autoPullArtifact(runOutput, artifactDir) {
18588
18594
  }
18589
18595
  var cookCmd = new Command17().name("cook").description("One-click agent preparation and execution from vm0.yaml");
18590
18596
  cookCmd.argument("[prompt]", "Prompt for the agent").option("-y, --yes", "Skip confirmation prompts").action(async (prompt, options) => {
18591
- const shouldExit = await checkAndUpgrade("5.0.2", prompt);
18597
+ const shouldExit = await checkAndUpgrade("5.1.0", prompt);
18592
18598
  if (shouldExit) {
18593
18599
  process.exit(0);
18594
18600
  }
@@ -20151,7 +20157,7 @@ var setupGithubCommand = new Command26().name("setup-github").description("Initi
20151
20157
 
20152
20158
  // src/index.ts
20153
20159
  var program = new Command27();
20154
- program.name("vm0").description("VM0 CLI - A modern build tool").version("5.0.2");
20160
+ program.name("vm0").description("VM0 CLI - A modern build tool").version("5.1.0");
20155
20161
  program.command("info").description("Display environment information").action(async () => {
20156
20162
  console.log(chalk29.bold("System Information:"));
20157
20163
  console.log(`Node Version: ${process.version}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vm0/cli",
3
- "version": "5.0.2",
3
+ "version": "5.1.0",
4
4
  "description": "CLI application",
5
5
  "repository": {
6
6
  "type": "git",