@insforge/cli 0.1.68 → 0.1.69

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/index.js CHANGED
@@ -1416,8 +1416,8 @@ function registerBranchListCommand(branch) {
1416
1416
  import { writeFileSync as writeFileSync2 } from "fs";
1417
1417
  import * as clack5 from "@clack/prompts";
1418
1418
  function registerBranchMergeCommand(branch) {
1419
- branch.command("merge <name>").description("Merge a branch back to its parent project").option("--dry-run", "Compute the diff and print rendered SQL; do not apply").option("-y, --yes", "Skip confirmation prompt").option("--save-sql <path>", "Write rendered SQL preview to a file").action(async (name, opts, cmd) => {
1420
- const { json, apiUrl } = getRootOpts(cmd);
1419
+ branch.command("merge <name>").description("Merge a branch back to its parent project").option("--dry-run", "Compute the diff and print rendered SQL; do not apply").option("--save-sql <path>", "Write rendered SQL preview to a file").action(async (name, opts, cmd) => {
1420
+ const { json, apiUrl, yes } = getRootOpts(cmd);
1421
1421
  try {
1422
1422
  await requireAuth(apiUrl);
1423
1423
  const project = getProjectConfig();
@@ -1469,7 +1469,7 @@ function registerBranchMergeCommand(branch) {
1469
1469
  }
1470
1470
  return;
1471
1471
  }
1472
- if (!opts.yes && !json) {
1472
+ if (!yes && !json) {
1473
1473
  const parentLabel = project.branched_from?.project_name ?? project.project_name;
1474
1474
  const confirmed = await clack5.confirm({
1475
1475
  message: `Apply this merge to parent project '${parentLabel}'?`
@@ -1523,8 +1523,8 @@ import * as clack6 from "@clack/prompts";
1523
1523
  var POLL_INTERVAL_MS2 = 3e3;
1524
1524
  var POLL_TIMEOUT_MS2 = 5 * 60 * 1e3;
1525
1525
  function registerBranchResetCommand(branch) {
1526
- branch.command("reset <name>").description("Reset a branch's database back to T0 (the parent snapshot at branch creation)").option("-y, --yes", "Skip confirmation").action(async (name, opts, cmd) => {
1527
- const { json, apiUrl } = getRootOpts(cmd);
1526
+ branch.command("reset <name>").description("Reset a branch's database back to T0 (the parent snapshot at branch creation)").action(async (name, _opts, cmd) => {
1527
+ const { json, apiUrl, yes } = getRootOpts(cmd);
1528
1528
  try {
1529
1529
  await requireAuth(apiUrl);
1530
1530
  const project = getProjectConfig();
@@ -1539,7 +1539,7 @@ function registerBranchResetCommand(branch) {
1539
1539
  );
1540
1540
  }
1541
1541
  const entryState = target.branch_state;
1542
- if (!opts.yes && !json) {
1542
+ if (!yes && !json) {
1543
1543
  const confirmed = await clack6.confirm({
1544
1544
  message: `Reset branch '${name}' back to T0? This wipes all schema/data/policy/function/migration changes made on the branch since creation.` + (entryState === "merged" ? " (Branch is currently merged \u2014 reset will reopen it for further work.)" : "")
1545
1545
  });
@@ -1601,8 +1601,8 @@ async function pollUntilReady2(branchId, apiUrl, showProgress, startingState) {
1601
1601
  // src/commands/branch/delete.ts
1602
1602
  import * as clack7 from "@clack/prompts";
1603
1603
  function registerBranchDeleteCommand(branch) {
1604
- branch.command("delete <name>").description("Delete a branch").option("-y, --yes", "Skip confirmation").action(async (name, opts, cmd) => {
1605
- const { json, apiUrl } = getRootOpts(cmd);
1604
+ branch.command("delete <name>").description("Delete a branch").action(async (name, _opts, cmd) => {
1605
+ const { json, apiUrl, yes } = getRootOpts(cmd);
1606
1606
  try {
1607
1607
  await requireAuth(apiUrl);
1608
1608
  const project = getProjectConfig();
@@ -1611,7 +1611,7 @@ function registerBranchDeleteCommand(branch) {
1611
1611
  const branches = await listBranchesApi(parentId, apiUrl);
1612
1612
  const target = branches.find((b) => b.name === name);
1613
1613
  if (!target) throw new CLIError(`Branch '${name}' not found.`);
1614
- if (!opts.yes && !json) {
1614
+ if (!yes && !json) {
1615
1615
  const confirmed = await clack7.confirm({
1616
1616
  message: `Delete branch '${name}'? This terminates its EC2 instance.`
1617
1617
  });
@@ -6829,7 +6829,7 @@ function registerDiagnoseCommands(diagnoseCmd2) {
6829
6829
  const s = !json ? clack14.spinner() : null;
6830
6830
  s?.start("Collecting diagnostic data...");
6831
6831
  const data2 = await collectDiagnosticData(projectId, ossMode, apiUrl);
6832
- const cliVersion = "0.1.68";
6832
+ const cliVersion = "0.1.69";
6833
6833
  s?.stop("Data collected");
6834
6834
  if (!json) {
6835
6835
  console.log(`