@shopify/cli 2.0.13 → 3.0.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,44 @@
1
1
  # @shopify/cli
2
2
 
3
+ ## 3.0.1
4
+
5
+ ### Patch Changes
6
+
7
+ - b911cfa2: Add editions command
8
+ - 2044f14c: Update Ngrok plugin dependency to 0.2.6 (error improvements)
9
+ - Updated dependencies [c01cd9a5]
10
+ - Updated dependencies [9d324502]
11
+ - @shopify/cli-kit@3.0.1
12
+
13
+ ## 3.0.0
14
+
15
+ ### Major Changes
16
+
17
+ - Bump to 3.0.0
18
+
19
+ ### Patch Changes
20
+
21
+ - Updated dependencies
22
+ - @shopify/cli-kit@3.0.0
23
+
24
+ ## 2.0.15
25
+
26
+ ### Patch Changes
27
+
28
+ - Updated dependencies [19e343ea]
29
+ - Updated dependencies [eaf69a92]
30
+ - Updated dependencies [5ed34580]
31
+ - @shopify/cli-kit@2.0.15
32
+
33
+ ## 2.0.14
34
+
35
+ ### Patch Changes
36
+
37
+ - Updated dependencies [87e51326]
38
+ - Updated dependencies [87e51326]
39
+ - Updated dependencies [b10ddafc]
40
+ - @shopify/cli-kit@2.0.14
41
+
3
42
  ## 2.0.13
4
43
 
5
44
  ### Patch Changes
@@ -0,0 +1,104 @@
1
+ import { Command } from '@oclif/core';
2
+ import { output, ui } from '@shopify/cli-kit';
3
+
4
+ const subcommands = {
5
+ bfs: () => {
6
+ output.info(unindent(`
7
+ - Built for Shopify: Build great commerce apps that look and perform like they\u2019re part of Shopify
8
+ - Shopify Functions: New ways to extend Shopify: Build custom discounts, shipping, and payments
9
+ - Checkout Extensibility: Apps for checkout are here: Powerful customizations that work with Shop Pay
10
+ `));
11
+ output.info(`
12
+
13
+ `);
14
+ output.info(output.content`${output.token.yellow("Read more here: https://shopify.com/editions/dev#chapter-1")}`);
15
+ },
16
+ devtools: () => {
17
+ output.info(unindent(`
18
+ - Developer Experience: Simplified updates to write and distribute an app
19
+ - Embedded App Improvements: Offer a truly seamless app experience
20
+ - Data Protection: Future-proof the apps you build
21
+ `));
22
+ output.info(`
23
+
24
+ `);
25
+ output.info(output.content`${output.token.yellow("Read more here: https://shopify.com/editions/dev#chapter-2")}`);
26
+ },
27
+ hydrogen: () => {
28
+ output.info(unindent(`
29
+ - Hydrogen + Oxygen: The Shopify stack for headless commerce
30
+ - Pixels: Intelligent interactions\u2014powered by secure data
31
+ - Marketplace Kit: Add commerce to any platform
32
+ `));
33
+ output.info(`
34
+
35
+ `);
36
+ output.info(output.content`${output.token.yellow("Read more here: https://shopify.com/editions/dev#chapter-3")}`);
37
+ }
38
+ };
39
+ class Editions extends Command {
40
+ async run() {
41
+ output.info(output.content`${output.token.green(unindent(`
42
+ _____ __ _ ____ ______ ___ __ _
43
+ / ___// /_ ____ ____ (_) __/_ __ / ____/___/ (_) /_(_)___ ____ _____
44
+ \\__ \\/ __ \\/ __ \\/ __ \\/ / /_/ / / / / __/ / __ / / __/ / __ \\/ __ \\/ ___/
45
+ ___/ / / / / /_/ / /_/ / / __/ /_/ / / /___/ /_/ / / /_/ / /_/ / / / (__ )
46
+ /____/_/ /_/\\____/ .___/_/_/ \\__, / /_____/\\__,_/_/\\__/_/\\____/_/ /_/____/
47
+ /_/ /____/
48
+ ____ __ ___ __
49
+ / __ \\___ _ __ / |/ /___ ____/ /__
50
+ / / / / _ \\ | / / / /|_/ / __ \\/ __ / _ \\
51
+ / /_/ / __/ |/ / / / / / /_/ / /_/ / __/
52
+ /_____/\\___/|___/ /_/ /_/\\____/\\__,_/\\___/
53
+ `))}`);
54
+ output.info(unindent(`
55
+
56
+
57
+ Welcome to Dev Mode for the Summer 2022 Edition
58
+ https://shopify.com/editions/dev
59
+
60
+
61
+ `));
62
+ const answer = await ui.prompt([
63
+ {
64
+ name: "editionschoice",
65
+ type: "select",
66
+ message: "What are you looking to solve?",
67
+ choices: [
68
+ {
69
+ value: "bfs",
70
+ name: "NEW WAYS TO BUILD GREAT APPS"
71
+ },
72
+ {
73
+ value: "devtools",
74
+ name: "IMPROVED DEV TOOLS"
75
+ },
76
+ {
77
+ value: "hydrogen",
78
+ name: "NEXT LEVEL STOREFRONT BUILDING"
79
+ }
80
+ ]
81
+ }
82
+ ]);
83
+ await subcommands[answer.editionschoice]?.();
84
+ output.info(`
85
+
86
+
87
+ `);
88
+ }
89
+ }
90
+ Editions.description = "Shopify editions";
91
+ Editions.hidden = true;
92
+ function unindent(value) {
93
+ const lines = value.split("\n");
94
+ if (lines[0].trim() === "")
95
+ lines.shift();
96
+ if (lines.at(-1)?.trim() === "")
97
+ lines.pop();
98
+ const nonEmptyLines = lines.filter((line) => line.trim().length > 0);
99
+ const numSpacesToCut = Math.min(...nonEmptyLines.map((line) => (/^[\s]*[^\s]/.exec(line)?.[0].length || 1) - 1));
100
+ return lines.map((line) => line.slice(numSpacesToCut)).join("\n");
101
+ }
102
+
103
+ export { Editions as default };
104
+ //# sourceMappingURL=editions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"editions.js","sources":["../../src/cli/commands/editions.ts"],"sourcesContent":["import {Command} from '@oclif/core'\nimport {output, ui} from '@shopify/cli-kit'\n\ntype Choice = 'bfs' | 'hydrogen' | 'devtools'\n\nconst subcommands: {[key in Choice]: () => void | Promise<void>} = {\n bfs: () => {\n output.info(\n unindent(`\n - Built for Shopify: Build great commerce apps that look and perform like they’re part of Shopify\n - Shopify Functions: New ways to extend Shopify: Build custom discounts, shipping, and payments\n - Checkout Extensibility: Apps for checkout are here: Powerful customizations that work with Shop Pay\n `),\n )\n output.info(`\\n\\n`)\n output.info(output.content`${output.token.yellow('Read more here: https://shopify.com/editions/dev#chapter-1')}`)\n },\n devtools: () => {\n output.info(\n unindent(`\n - Developer Experience: Simplified updates to write and distribute an app\n - Embedded App Improvements: Offer a truly seamless app experience\n - Data Protection: Future-proof the apps you build\n `),\n )\n output.info(`\\n\\n`)\n output.info(output.content`${output.token.yellow('Read more here: https://shopify.com/editions/dev#chapter-2')}`)\n },\n hydrogen: () => {\n output.info(\n unindent(`\n - Hydrogen + Oxygen: The Shopify stack for headless commerce\n - Pixels: Intelligent interactions—powered by secure data\n - Marketplace Kit: Add commerce to any platform\n `),\n )\n output.info(`\\n\\n`)\n output.info(output.content`${output.token.yellow('Read more here: https://shopify.com/editions/dev#chapter-3')}`)\n },\n}\nexport default class Editions extends Command {\n static description = 'Shopify editions'\n static hidden = true\n\n async run(): Promise<void> {\n output.info(\n output.content`${output.token.green(\n unindent(`\n _____ __ _ ____ ______ ___ __ _\n / ___// /_ ____ ____ (_) __/_ __ / ____/___/ (_) /_(_)___ ____ _____\n \\\\__ \\\\/ __ \\\\/ __ \\\\/ __ \\\\/ / /_/ / / / / __/ / __ / / __/ / __ \\\\/ __ \\\\/ ___/\n ___/ / / / / /_/ / /_/ / / __/ /_/ / / /___/ /_/ / / /_/ / /_/ / / / (__ )\n /____/_/ /_/\\\\____/ .___/_/_/ \\\\__, / /_____/\\\\__,_/_/\\\\__/_/\\\\____/_/ /_/____/\n /_/ /____/\n ____ __ ___ __\n / __ \\\\___ _ __ / |/ /___ ____/ /__\n / / / / _ \\\\ | / / / /|_/ / __ \\\\/ __ / _ \\\\\n / /_/ / __/ |/ / / / / / /_/ / /_/ / __/\n /_____/\\\\___/|___/ /_/ /_/\\\\____/\\\\__,_/\\\\___/\n `),\n )}`,\n )\n\n output.info(\n unindent(`\n\n\n Welcome to Dev Mode for the Summer 2022 Edition\n https://shopify.com/editions/dev\n\n\n `),\n )\n\n const answer: {editionschoice: Choice} = await ui.prompt([\n {\n name: 'editionschoice',\n type: 'select',\n message: 'What are you looking to solve?',\n choices: [\n {\n value: 'bfs',\n name: 'NEW WAYS TO BUILD GREAT APPS',\n },\n {\n value: 'devtools',\n name: 'IMPROVED DEV TOOLS',\n },\n {\n value: 'hydrogen',\n name: 'NEXT LEVEL STOREFRONT BUILDING',\n },\n ],\n },\n ])\n\n await subcommands[answer.editionschoice]?.()\n output.info(`\\n\\n\\n`)\n }\n}\n\nfunction unindent(value: string): string {\n const lines = value.split('\\n')\n // Remove empty lines at start and end\n if (lines[0].trim() === '') lines.shift()\n if (lines.at(-1)?.trim() === '') lines.pop()\n const nonEmptyLines = lines.filter((line) => line.trim().length > 0)\n const numSpacesToCut = Math.min(...nonEmptyLines.map((line) => (/^[\\s]*[^\\s]/.exec(line)?.[0].length || 1) - 1))\n return lines.map((line) => line.slice(numSpacesToCut)).join('\\n')\n}\n"],"names":[],"mappings":";;;AAKA,MAAM,WAA6D,GAAA;AAAA,EACjE,KAAK,MAAM;AACT,IAAA,MAAA,CAAO,KACL,QAAS,CAAA,CAAA;AAAA;AAAA;AAAA;AAAA,MAAA,CAIR,CACH,CAAA,CAAA;AACA,IAAA,MAAA,CAAO,IAAK,CAAA,CAAA;AAAA;AAAA,CAAM,CAAA,CAAA;AAClB,IAAA,MAAA,CAAO,KAAK,MAAO,CAAA,OAAA,CAAA,EAAU,OAAO,KAAM,CAAA,MAAA,CAAO,4DAA4D,CAAG,CAAA,CAAA,CAAA,CAAA;AAAA,GAClH;AAAA,EACA,UAAU,MAAM;AACd,IAAA,MAAA,CAAO,KACL,QAAS,CAAA,CAAA;AAAA;AAAA;AAAA;AAAA,MAAA,CAIR,CACH,CAAA,CAAA;AACA,IAAA,MAAA,CAAO,IAAK,CAAA,CAAA;AAAA;AAAA,CAAM,CAAA,CAAA;AAClB,IAAA,MAAA,CAAO,KAAK,MAAO,CAAA,OAAA,CAAA,EAAU,OAAO,KAAM,CAAA,MAAA,CAAO,4DAA4D,CAAG,CAAA,CAAA,CAAA,CAAA;AAAA,GAClH;AAAA,EACA,UAAU,MAAM;AACd,IAAA,MAAA,CAAO,KACL,QAAS,CAAA,CAAA;AAAA;AAAA;AAAA;AAAA,MAAA,CAIR,CACH,CAAA,CAAA;AACA,IAAA,MAAA,CAAO,IAAK,CAAA,CAAA;AAAA;AAAA,CAAM,CAAA,CAAA;AAClB,IAAA,MAAA,CAAO,K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AAA,IAAA,CAAA;AA2DlB,SAAA,QAAA,CAAkB,KAAuB,EAAA;AACvC,EAAM,MAAA,KAAA,GAAQ,KAAM,CAAA,KAAA,CAAM,IAAI,CAAA,CAAA;AAE9B,EAAI,IAAA,KAAA,CAAM,CAAG,CAAA,CAAA,IAAA,EAAW,KAAA,EAAA;AAAI,IAAA,KAAA,CAAM,KAAM,EAAA,CAAA;AACxC,EAAA,IAAI,KAAM,CAAA,EAAA,CAAG,CAAE,CAAA,CAAA,EAAG,MAAW,KAAA,EAAA;AAAI,IAAA,KAAA,CAAM,GAAI,EAAA,CAAA;AAC3C,EAAM,MAAA,aAAA,GAAgB,MAAM,MAAO,CAAA,CAAC,SAAS,IAAK,CAAA,IAAA,EAAO,CAAA,MAAA,GAAS,CAAC,CAAA,CAAA;AACnE,EAAA,MAAM,iBAAiB,IAAK,CAAA,GAAA,CAAI,GAAG,aAAA,CAAc,IAAI,CAAC,IAAA,KAAU,CAAc,aAAA,CAAA,IAAA,CAAK,IAAI,CAAI,GAAA,CAAA,CAAA,CAAG,MAAU,IAAA,CAAA,IAAK,CAAC,CAAC,CAAA,CAAA;AAC/G,EAAO,OAAA,KAAA,CAAM,GAAI,CAAA,CAAC,IAAS,KAAA,IAAA,CAAK,MAAM,cAAc,CAAC,CAAE,CAAA,IAAA,CAAK,IAAI,CAAA,CAAA;AAClE;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shopify/cli",
3
- "version": "2.0.13",
3
+ "version": "3.0.1",
4
4
  "private": false,
5
5
  "description": "A CLI tool to build for the Shopify platform",
6
6
  "type": "module",
@@ -51,8 +51,8 @@
51
51
  "@oclif/core": "1.7.0",
52
52
  "@oclif/plugin-help": "^5.1.12",
53
53
  "@oclif/plugin-plugins": "^2.1.0",
54
- "@shopify/cli-kit": "2.0.13",
55
- "@shopify/plugin-ngrok": "^0.2.4"
54
+ "@shopify/cli-kit": "3.0.1",
55
+ "@shopify/plugin-ngrok": "^0.2.6"
56
56
  },
57
57
  "devDependencies": {
58
58
  "vitest": "0.10.0"