@prisma/cli 3.0.0-alpha.6 → 3.0.0-alpha.7

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.
@@ -1,5 +1,5 @@
1
- import path from "node:path";
2
1
  import { mkdir, readFile, writeFile } from "node:fs/promises";
2
+ import path from "node:path";
3
3
  //#region src/adapters/local-state.ts
4
4
  const DEFAULT_STATE = {
5
5
  auth: null,
@@ -60,19 +60,27 @@ function createRunCommand(runtime) {
60
60
  }
61
61
  function createDeployCommand(runtime) {
62
62
  const command = attachCommandDescriptor(configureRuntimeCommand(new Command("deploy"), runtime), "app.deploy");
63
- command.addOption(new Option("--app <name>", "App name")).addOption(new Option("--project <id-or-name>", "Project id or name")).addOption(new Option("--entry <path>", "Entrypoint path for Bun or auto deploys")).addOption(new Option("--build-type <type>", "Deploy build type").choices([...PREVIEW_BUILD_TYPES]).default("auto")).addOption(new Option("--http-port <port>", "HTTP port override for the deployed app")).addOption(new Option("--env <name=value>", "Environment variable").argParser(collectRepeatableValues));
63
+ command.addOption(new Option("--app <name>", "App name")).addOption(new Option("--project <id-or-name>", "Project id or name")).addOption(new Option("--branch <name>", "Branch name")).addOption(new Option("--framework <name>", "Framework to deploy").choices([
64
+ "nextjs",
65
+ "hono",
66
+ "tanstack-start"
67
+ ])).addOption(new Option("--entry <path>", "Entrypoint path for Bun or auto deploys")).addOption(new Option("--build-type <type>", "Legacy deploy build type").choices([...PREVIEW_BUILD_TYPES]).default("auto").hideHelp()).addOption(new Option("--http-port <port>", "HTTP port override for the deployed app")).addOption(new Option("--env <name=value>", "Environment variable").argParser(collectRepeatableValues));
64
68
  addGlobalFlags(command);
65
69
  command.action(async (options) => {
66
70
  const appName = options.app;
67
71
  const entry = options.entry;
68
72
  const buildType = options.buildType;
73
+ const branchName = options.branch;
74
+ const framework = options.framework;
69
75
  const httpPort = options.httpPort;
70
76
  const envAssignments = options.env;
71
77
  const projectRef = options.project;
72
78
  await runCommand(runtime, "app.deploy", options, (context) => runAppDeploy(context, appName, {
73
79
  projectRef,
80
+ branchName,
74
81
  entrypoint: entry,
75
82
  buildType,
83
+ framework,
76
84
  httpPort,
77
85
  envAssignments
78
86
  }), {