@sanity/cli 5.12.0-next.8 → 5.12.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.
@@ -1717,7 +1717,7 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1717
1717
  token: token2,
1718
1718
  flags: {
1719
1719
  "project-id": flags["project-id"] ?? flags.projectId ?? flags.project,
1720
- "stack-id": flags["stack-id"] ?? flags.stackId ?? flags.stack,
1720
+ stack: flags["stack-id"] ?? flags.stackId ?? flags.stack,
1721
1721
  edit: flags.edit ?? flags.e,
1722
1722
  verbose: flags.verbose
1723
1723
  }
@@ -1739,6 +1739,7 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1739
1739
  const { initDeployedBlueprintConfig } = await import("@sanity/runtime-cli/cores"), { blueprintDeployCore } = await import("@sanity/runtime-cli/cores/blueprints"), cmdConfig = await initDeployedBlueprintConfig({
1740
1740
  bin: "sanity",
1741
1741
  log: utils$3.logger.Logger(output.print),
1742
+ stackOverride: flags.stack,
1742
1743
  token: token2
1743
1744
  });
1744
1745
  if (!cmdConfig.ok) throw new Error(cmdConfig.error);
@@ -1774,7 +1775,7 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1774
1775
  "no-wait": flags["no-wait"],
1775
1776
  force: flags.force ?? flags.f,
1776
1777
  "project-id": flags["project-id"] ?? flags.projectId ?? flags.project,
1777
- "stack-id": flags["stack-id"] ?? flags.stackId ?? flags.stack
1778
+ stack: flags["stack-id"] ?? flags.stackId ?? flags.stack
1778
1779
  }
1779
1780
  });
1780
1781
  if (!success) throw new Error(error2);
@@ -1816,12 +1817,13 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1816
1817
  const { initDeployedBlueprintConfig } = await import("@sanity/runtime-cli/cores"), { blueprintInfoCore } = await import("@sanity/runtime-cli/cores/blueprints"), cmdConfig = await initDeployedBlueprintConfig({
1817
1818
  bin: "sanity",
1818
1819
  log: utils$3.logger.Logger(output.print),
1820
+ stackOverride: flags.stack ?? flags.id,
1819
1821
  token: token2
1820
1822
  });
1821
1823
  if (!cmdConfig.ok) throw new Error(cmdConfig.error);
1822
1824
  const { success, error: error2 } = await blueprintInfoCore({
1823
1825
  ...cmdConfig.value,
1824
- flags
1826
+ flags: {}
1825
1827
  });
1826
1828
  if (!success) throw new Error(error2);
1827
1829
  }
@@ -1832,7 +1834,10 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1832
1834
  group: "blueprints",
1833
1835
  ...transformHelpText(runtimeCli.BlueprintsInitCommand, "sanity", "blueprints init"),
1834
1836
  async action(args, context) {
1835
- const { apiClient, cliConfig, output } = context, flags = { ...defaultFlags$8, ...args.extOptions }, [dir] = args.argsWithoutOptions, client2 = apiClient({
1837
+ const { apiClient, cliConfig, output } = context, flags = { ...defaultFlags$8, ...args.extOptions };
1838
+ if (flags.stack)
1839
+ throw new Error("--stack is not supported by init. Use --stack-id instead.");
1840
+ const [dir] = args.argsWithoutOptions, client2 = apiClient({
1836
1841
  requireUser: !0,
1837
1842
  requireProject: !1
1838
1843
  }), { token: token2 } = client2.config();
@@ -1844,7 +1849,6 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1844
1849
  "type",
1845
1850
  "stack-id",
1846
1851
  "stackId",
1847
- "stack",
1848
1852
  "stack-name",
1849
1853
  "name"
1850
1854
  ].find((key2) => flags[key2]);
@@ -1863,7 +1867,7 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1863
1867
  example: flags.example,
1864
1868
  "blueprint-type": flags["blueprint-type"] ?? flags.type,
1865
1869
  "project-id": flags["project-id"] ?? flags.projectId ?? flags.project,
1866
- "stack-id": flags["stack-id"] ?? flags.stackId ?? flags.stack,
1870
+ "stack-id": flags["stack-id"] ?? flags.stackId,
1867
1871
  "stack-name": flags["stack-name"] ?? flags.name,
1868
1872
  verbose: flags.verbose
1869
1873
  }
@@ -1885,6 +1889,7 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1885
1889
  const { initDeployedBlueprintConfig } = await import("@sanity/runtime-cli/cores"), { blueprintLogsCore } = await import("@sanity/runtime-cli/cores/blueprints"), cmdConfig = await initDeployedBlueprintConfig({
1886
1890
  bin: "sanity",
1887
1891
  log: utils$3.logger.Logger(output.print),
1892
+ stackOverride: flags.stack,
1888
1893
  token: token2
1889
1894
  });
1890
1895
  if (!cmdConfig.ok) throw new Error(cmdConfig.error);
@@ -1917,7 +1922,8 @@ const BlueprintsAddExampleUsed = telemetry.defineEvent({
1917
1922
  const { success, error: error2 } = await blueprintPlanCore({
1918
1923
  ...cmdConfig.value,
1919
1924
  flags: {
1920
- verbose: flags.verbose
1925
+ verbose: flags.verbose,
1926
+ stack: flags.stack
1921
1927
  }
1922
1928
  });
1923
1929
  if (!success) throw new Error(error2);