@shopify/create-app 3.65.3 → 3.66.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.
- package/dist/chunk-2RSJVBMF.js +5625 -0
- package/dist/{chunk-Z65QJ5D7.js → chunk-4DRC2PSU.js} +17 -30
- package/dist/chunk-4OD45DDO.js +31508 -0
- package/dist/chunk-522OB3EU.js +45 -0
- package/dist/{chunk-S57LLFKK.js → chunk-5U24TEX5.js} +5434 -10324
- package/dist/{chunk-GJPZCXGT.js → chunk-6A7MXLVB.js} +159 -405
- package/dist/{chunk-FUPW7TWB.js → chunk-7ZCQLP5Y.js} +3 -3
- package/dist/{chunk-5LBEKXRW.js → chunk-FIJKOZJF.js} +19 -55
- package/dist/{chunk-2JG3TU4D.js → chunk-FT6PCF6E.js} +2441 -5551
- package/dist/chunk-GIUM5DCQ.js +2144 -0
- package/dist/chunk-HIAKHDLR.js +54 -0
- package/dist/chunk-LLSRDN3T.js +15352 -0
- package/dist/chunk-LTDD2GRL.js +111 -0
- package/dist/{chunk-56H6ULTJ.js → chunk-NGBYQF44.js} +9 -9
- package/dist/chunk-NLC7NBUB.js +80 -0
- package/dist/{chunk-FMKVOTQK.js → chunk-O5K4AU7Q.js} +18 -34
- package/dist/chunk-OMDEA7TV.js +10615 -0
- package/dist/chunk-PNN7RS7Y.js +105 -0
- package/dist/{chunk-ZPL24Y2D.js → chunk-POZ5MGPT.js} +13 -18
- package/dist/chunk-T7T35H4F.js +108 -0
- package/dist/chunk-UBB7JKND.js +55 -0
- package/dist/chunk-VSLR7ET4.js +3034 -0
- package/dist/{chunk-SAO7C4LP.js → chunk-VZVGAREJ.js} +46821 -101962
- package/dist/{chunk-C34SFNV7.js → chunk-WBQF4CSV.js} +12 -22
- package/dist/chunk-XVNW332R.js +524 -0
- package/dist/{chunk-AB7PVDZA.js → chunk-Y4ECGRAF.js} +13 -23
- package/dist/chunk-ZAUZQLNO.js +3774 -0
- package/dist/chunk-ZULFH3SL.js +1847 -0
- package/dist/commands/init.d.ts +0 -1
- package/dist/commands/init.js +27 -27
- package/dist/commands/init.test.js +51 -70
- package/dist/{constants-24TFXZKQ.js → constants-WG7I7G3O.js} +5 -5
- package/dist/custom-oclif-loader-JKRJZ56E.js +47 -0
- package/dist/del-NW5KFKFP.js +1820 -0
- package/dist/devtools-UBOREV57.js +2572 -0
- package/dist/error-handler-26SLAJTC.js +35 -0
- package/dist/hooks/postrun.js +35 -42
- package/dist/hooks/prerun.js +58 -36
- package/dist/index.js +7 -7
- package/dist/lib-3K5QYF3J.js +9 -0
- package/dist/{local-IEMPZHFX.js → local-H6TW5MNX.js} +13 -13
- package/dist/magic-string.es-3RXPUXZF.js +843 -0
- package/dist/multipart-parser-QKUAJJP5.js +193 -0
- package/dist/{node-package-manager-LYYU5SQZ.js → node-package-manager-QAUN6HGS.js} +16 -14
- package/dist/open-MZGVNFZO.js +197 -0
- package/dist/out-KDGAD475.js +6 -0
- package/dist/{path-CFPIDSWV.js → path-L375JOQ2.js} +4 -4
- package/dist/prompts/init.js +13 -13
- package/dist/prompts/init.test.js +42 -59
- package/dist/services/init.js +20 -20
- package/dist/services/init.test.js +5 -5
- package/dist/system-ZI2HKAKO.js +26 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/{ui-SSXOUA2N.js → ui-727JEZUX.js} +13 -13
- package/dist/utils/template/cleanup.js +13 -13
- package/dist/utils/template/cleanup.test.js +18 -30
- package/dist/utils/template/npm.js +15 -15
- package/dist/utils/template/npm.test.js +48 -87
- package/oclif.manifest.json +1 -1
- package/package.json +3 -4
- package/dist/chunk-3G24M6S4.js +0 -3185
- package/dist/chunk-44DJDCJW.js +0 -7843
- package/dist/chunk-B3EA2BEZ.js +0 -22131
- package/dist/chunk-DL3MKXVR.js +0 -4754
- package/dist/chunk-EJ67NGP2.js +0 -105
- package/dist/chunk-G4XEYGTB.js +0 -63
- package/dist/chunk-IKO7JBOJ.js +0 -14788
- package/dist/chunk-LSCXQWNO.js +0 -822
- package/dist/chunk-M2VKB6RG.js +0 -146
- package/dist/chunk-MCED27CG.js +0 -5626
- package/dist/chunk-NSNRZPBN.js +0 -145
- package/dist/chunk-P5J3HFWZ.js +0 -44962
- package/dist/chunk-RAQ4Z7GU.js +0 -2477
- package/dist/chunk-SWNRLCC6.js +0 -61
- package/dist/chunk-T5LLJYYS.js +0 -195
- package/dist/chunk-YC4FLMDD.js +0 -74
- package/dist/custom-oclif-loader-B7KCOFFE.js +0 -83
- package/dist/del-ZCPTGWOA.js +0 -2847
- package/dist/devtools-5N4JAP3R.js +0 -3588
- package/dist/error-handler-6K3LQUFG.js +0 -35
- package/dist/lib-CTSCLPNV.js +0 -9
- package/dist/magic-string.es-ATGURXGQ.js +0 -1353
- package/dist/multipart-parser-KYOHF24X.js +0 -360
- package/dist/open-JRS7RW22.js +0 -291
- package/dist/out-OKI3G7I5.js +0 -6
- package/dist/system-23HIJRP3.js +0 -26
package/dist/chunk-SWNRLCC6.js
DELETED
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
init_cjs_shims
|
|
3
|
-
} from "./chunk-ZPL24Y2D.js";
|
|
4
|
-
|
|
5
|
-
// ../../node_modules/.pnpm/yocto-queue@1.0.0/node_modules/yocto-queue/index.js
|
|
6
|
-
init_cjs_shims();
|
|
7
|
-
var Node = class {
|
|
8
|
-
value;
|
|
9
|
-
next;
|
|
10
|
-
constructor(value) {
|
|
11
|
-
this.value = value;
|
|
12
|
-
}
|
|
13
|
-
};
|
|
14
|
-
var Queue = class {
|
|
15
|
-
#head;
|
|
16
|
-
#tail;
|
|
17
|
-
#size;
|
|
18
|
-
constructor() {
|
|
19
|
-
this.clear();
|
|
20
|
-
}
|
|
21
|
-
enqueue(value) {
|
|
22
|
-
const node = new Node(value);
|
|
23
|
-
if (this.#head) {
|
|
24
|
-
this.#tail.next = node;
|
|
25
|
-
this.#tail = node;
|
|
26
|
-
} else {
|
|
27
|
-
this.#head = node;
|
|
28
|
-
this.#tail = node;
|
|
29
|
-
}
|
|
30
|
-
this.#size++;
|
|
31
|
-
}
|
|
32
|
-
dequeue() {
|
|
33
|
-
const current = this.#head;
|
|
34
|
-
if (!current) {
|
|
35
|
-
return;
|
|
36
|
-
}
|
|
37
|
-
this.#head = this.#head.next;
|
|
38
|
-
this.#size--;
|
|
39
|
-
return current.value;
|
|
40
|
-
}
|
|
41
|
-
clear() {
|
|
42
|
-
this.#head = void 0;
|
|
43
|
-
this.#tail = void 0;
|
|
44
|
-
this.#size = 0;
|
|
45
|
-
}
|
|
46
|
-
get size() {
|
|
47
|
-
return this.#size;
|
|
48
|
-
}
|
|
49
|
-
*[Symbol.iterator]() {
|
|
50
|
-
let current = this.#head;
|
|
51
|
-
while (current) {
|
|
52
|
-
yield current.value;
|
|
53
|
-
current = current.next;
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
export {
|
|
59
|
-
Queue
|
|
60
|
-
};
|
|
61
|
-
//# sourceMappingURL=chunk-SWNRLCC6.js.map
|
package/dist/chunk-T5LLJYYS.js
DELETED
|
@@ -1,195 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
init_cjs_shims
|
|
3
|
-
} from "./chunk-ZPL24Y2D.js";
|
|
4
|
-
|
|
5
|
-
// ../../node_modules/.pnpm/pathe@1.1.1/node_modules/pathe/dist/shared/pathe.92c04245.mjs
|
|
6
|
-
init_cjs_shims();
|
|
7
|
-
function normalizeWindowsPath(input = "") {
|
|
8
|
-
if (!input || !input.includes("\\")) {
|
|
9
|
-
return input;
|
|
10
|
-
}
|
|
11
|
-
return input.replace(/\\/g, "/");
|
|
12
|
-
}
|
|
13
|
-
var _UNC_REGEX = /^[/\\]{2}/;
|
|
14
|
-
var _IS_ABSOLUTE_RE = /^[/\\](?![/\\])|^[/\\]{2}(?!\.)|^[A-Za-z]:[/\\]/;
|
|
15
|
-
var _DRIVE_LETTER_RE = /^[A-Za-z]:$/;
|
|
16
|
-
var normalize = function(path2) {
|
|
17
|
-
if (path2.length === 0) {
|
|
18
|
-
return ".";
|
|
19
|
-
}
|
|
20
|
-
path2 = normalizeWindowsPath(path2);
|
|
21
|
-
const isUNCPath = path2.match(_UNC_REGEX);
|
|
22
|
-
const isPathAbsolute = isAbsolute(path2);
|
|
23
|
-
const trailingSeparator = path2[path2.length - 1] === "/";
|
|
24
|
-
path2 = normalizeString(path2, !isPathAbsolute);
|
|
25
|
-
if (path2.length === 0) {
|
|
26
|
-
if (isPathAbsolute) {
|
|
27
|
-
return "/";
|
|
28
|
-
}
|
|
29
|
-
return trailingSeparator ? "./" : ".";
|
|
30
|
-
}
|
|
31
|
-
if (trailingSeparator) {
|
|
32
|
-
path2 += "/";
|
|
33
|
-
}
|
|
34
|
-
if (_DRIVE_LETTER_RE.test(path2)) {
|
|
35
|
-
path2 += "/";
|
|
36
|
-
}
|
|
37
|
-
if (isUNCPath) {
|
|
38
|
-
if (!isPathAbsolute) {
|
|
39
|
-
return `//./${path2}`;
|
|
40
|
-
}
|
|
41
|
-
return `//${path2}`;
|
|
42
|
-
}
|
|
43
|
-
return isPathAbsolute && !isAbsolute(path2) ? `/${path2}` : path2;
|
|
44
|
-
};
|
|
45
|
-
var join = function(...arguments_) {
|
|
46
|
-
if (arguments_.length === 0) {
|
|
47
|
-
return ".";
|
|
48
|
-
}
|
|
49
|
-
let joined;
|
|
50
|
-
for (const argument of arguments_) {
|
|
51
|
-
if (argument && argument.length > 0) {
|
|
52
|
-
if (joined === void 0) {
|
|
53
|
-
joined = argument;
|
|
54
|
-
} else {
|
|
55
|
-
joined += `/${argument}`;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
if (joined === void 0) {
|
|
60
|
-
return ".";
|
|
61
|
-
}
|
|
62
|
-
return normalize(joined.replace(/\/\/+/g, "/"));
|
|
63
|
-
};
|
|
64
|
-
function cwd() {
|
|
65
|
-
if (typeof process !== "undefined") {
|
|
66
|
-
return process.cwd().replace(/\\/g, "/");
|
|
67
|
-
}
|
|
68
|
-
return "/";
|
|
69
|
-
}
|
|
70
|
-
var resolve = function(...arguments_) {
|
|
71
|
-
arguments_ = arguments_.map((argument) => normalizeWindowsPath(argument));
|
|
72
|
-
let resolvedPath = "";
|
|
73
|
-
let resolvedAbsolute = false;
|
|
74
|
-
for (let index = arguments_.length - 1; index >= -1 && !resolvedAbsolute; index--) {
|
|
75
|
-
const path2 = index >= 0 ? arguments_[index] : cwd();
|
|
76
|
-
if (!path2 || path2.length === 0) {
|
|
77
|
-
continue;
|
|
78
|
-
}
|
|
79
|
-
resolvedPath = `${path2}/${resolvedPath}`;
|
|
80
|
-
resolvedAbsolute = isAbsolute(path2);
|
|
81
|
-
}
|
|
82
|
-
resolvedPath = normalizeString(resolvedPath, !resolvedAbsolute);
|
|
83
|
-
if (resolvedAbsolute && !isAbsolute(resolvedPath)) {
|
|
84
|
-
return `/${resolvedPath}`;
|
|
85
|
-
}
|
|
86
|
-
return resolvedPath.length > 0 ? resolvedPath : ".";
|
|
87
|
-
};
|
|
88
|
-
function normalizeString(path2, allowAboveRoot) {
|
|
89
|
-
let res = "";
|
|
90
|
-
let lastSegmentLength = 0;
|
|
91
|
-
let lastSlash = -1;
|
|
92
|
-
let dots = 0;
|
|
93
|
-
let char = null;
|
|
94
|
-
for (let index = 0; index <= path2.length; ++index) {
|
|
95
|
-
if (index < path2.length) {
|
|
96
|
-
char = path2[index];
|
|
97
|
-
} else if (char === "/") {
|
|
98
|
-
break;
|
|
99
|
-
} else {
|
|
100
|
-
char = "/";
|
|
101
|
-
}
|
|
102
|
-
if (char === "/") {
|
|
103
|
-
if (lastSlash === index - 1 || dots === 1)
|
|
104
|
-
;
|
|
105
|
-
else if (dots === 2) {
|
|
106
|
-
if (res.length < 2 || lastSegmentLength !== 2 || res[res.length - 1] !== "." || res[res.length - 2] !== ".") {
|
|
107
|
-
if (res.length > 2) {
|
|
108
|
-
const lastSlashIndex = res.lastIndexOf("/");
|
|
109
|
-
if (lastSlashIndex === -1) {
|
|
110
|
-
res = "";
|
|
111
|
-
lastSegmentLength = 0;
|
|
112
|
-
} else {
|
|
113
|
-
res = res.slice(0, lastSlashIndex);
|
|
114
|
-
lastSegmentLength = res.length - 1 - res.lastIndexOf("/");
|
|
115
|
-
}
|
|
116
|
-
lastSlash = index;
|
|
117
|
-
dots = 0;
|
|
118
|
-
continue;
|
|
119
|
-
} else if (res.length > 0) {
|
|
120
|
-
res = "";
|
|
121
|
-
lastSegmentLength = 0;
|
|
122
|
-
lastSlash = index;
|
|
123
|
-
dots = 0;
|
|
124
|
-
continue;
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
if (allowAboveRoot) {
|
|
128
|
-
res += res.length > 0 ? "/.." : "..";
|
|
129
|
-
lastSegmentLength = 2;
|
|
130
|
-
}
|
|
131
|
-
} else {
|
|
132
|
-
if (res.length > 0) {
|
|
133
|
-
res += `/${path2.slice(lastSlash + 1, index)}`;
|
|
134
|
-
} else {
|
|
135
|
-
res = path2.slice(lastSlash + 1, index);
|
|
136
|
-
}
|
|
137
|
-
lastSegmentLength = index - lastSlash - 1;
|
|
138
|
-
}
|
|
139
|
-
lastSlash = index;
|
|
140
|
-
dots = 0;
|
|
141
|
-
} else if (char === "." && dots !== -1) {
|
|
142
|
-
++dots;
|
|
143
|
-
} else {
|
|
144
|
-
dots = -1;
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
return res;
|
|
148
|
-
}
|
|
149
|
-
var isAbsolute = function(p) {
|
|
150
|
-
return _IS_ABSOLUTE_RE.test(p);
|
|
151
|
-
};
|
|
152
|
-
var _EXTNAME_RE = /.(\.[^./]+)$/;
|
|
153
|
-
var extname = function(p) {
|
|
154
|
-
const match = _EXTNAME_RE.exec(normalizeWindowsPath(p));
|
|
155
|
-
return match && match[1] || "";
|
|
156
|
-
};
|
|
157
|
-
var relative = function(from, to) {
|
|
158
|
-
const _from = resolve(from).split("/");
|
|
159
|
-
const _to = resolve(to).split("/");
|
|
160
|
-
const _fromCopy = [..._from];
|
|
161
|
-
for (const segment of _fromCopy) {
|
|
162
|
-
if (_to[0] !== segment) {
|
|
163
|
-
break;
|
|
164
|
-
}
|
|
165
|
-
_from.shift();
|
|
166
|
-
_to.shift();
|
|
167
|
-
}
|
|
168
|
-
return [..._from.map(() => ".."), ..._to].join("/");
|
|
169
|
-
};
|
|
170
|
-
var dirname = function(p) {
|
|
171
|
-
const segments = normalizeWindowsPath(p).replace(/\/$/, "").split("/").slice(0, -1);
|
|
172
|
-
if (segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0])) {
|
|
173
|
-
segments[0] += "/";
|
|
174
|
-
}
|
|
175
|
-
return segments.join("/") || (isAbsolute(p) ? "/" : ".");
|
|
176
|
-
};
|
|
177
|
-
var basename = function(p, extension) {
|
|
178
|
-
const lastSegment = normalizeWindowsPath(p).split("/").pop();
|
|
179
|
-
return extension && lastSegment.endsWith(extension) ? lastSegment.slice(0, -extension.length) : lastSegment;
|
|
180
|
-
};
|
|
181
|
-
|
|
182
|
-
// ../../node_modules/.pnpm/pathe@1.1.1/node_modules/pathe/dist/index.mjs
|
|
183
|
-
init_cjs_shims();
|
|
184
|
-
|
|
185
|
-
export {
|
|
186
|
-
normalize,
|
|
187
|
-
join,
|
|
188
|
-
resolve,
|
|
189
|
-
isAbsolute,
|
|
190
|
-
extname,
|
|
191
|
-
relative,
|
|
192
|
-
dirname,
|
|
193
|
-
basename
|
|
194
|
-
};
|
|
195
|
-
//# sourceMappingURL=chunk-T5LLJYYS.js.map
|
package/dist/chunk-YC4FLMDD.js
DELETED
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
__commonJS,
|
|
3
|
-
__require,
|
|
4
|
-
init_cjs_shims
|
|
5
|
-
} from "./chunk-ZPL24Y2D.js";
|
|
6
|
-
|
|
7
|
-
// ../../node_modules/.pnpm/is-docker@2.2.1/node_modules/is-docker/index.js
|
|
8
|
-
var require_is_docker = __commonJS({
|
|
9
|
-
"../../node_modules/.pnpm/is-docker@2.2.1/node_modules/is-docker/index.js"(exports, module) {
|
|
10
|
-
"use strict";
|
|
11
|
-
init_cjs_shims();
|
|
12
|
-
var fs = __require("fs");
|
|
13
|
-
var isDocker;
|
|
14
|
-
function hasDockerEnv() {
|
|
15
|
-
try {
|
|
16
|
-
fs.statSync("/.dockerenv");
|
|
17
|
-
return true;
|
|
18
|
-
} catch (_) {
|
|
19
|
-
return false;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
function hasDockerCGroup() {
|
|
23
|
-
try {
|
|
24
|
-
return fs.readFileSync("/proc/self/cgroup", "utf8").includes("docker");
|
|
25
|
-
} catch (_) {
|
|
26
|
-
return false;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
module.exports = () => {
|
|
30
|
-
if (isDocker === void 0) {
|
|
31
|
-
isDocker = hasDockerEnv() || hasDockerCGroup();
|
|
32
|
-
}
|
|
33
|
-
return isDocker;
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
|
-
});
|
|
37
|
-
|
|
38
|
-
// ../../node_modules/.pnpm/is-wsl@2.2.0/node_modules/is-wsl/index.js
|
|
39
|
-
var require_is_wsl = __commonJS({
|
|
40
|
-
"../../node_modules/.pnpm/is-wsl@2.2.0/node_modules/is-wsl/index.js"(exports, module) {
|
|
41
|
-
"use strict";
|
|
42
|
-
init_cjs_shims();
|
|
43
|
-
var os = __require("os");
|
|
44
|
-
var fs = __require("fs");
|
|
45
|
-
var isDocker = require_is_docker();
|
|
46
|
-
var isWsl = () => {
|
|
47
|
-
if (process.platform !== "linux") {
|
|
48
|
-
return false;
|
|
49
|
-
}
|
|
50
|
-
if (os.release().toLowerCase().includes("microsoft")) {
|
|
51
|
-
if (isDocker()) {
|
|
52
|
-
return false;
|
|
53
|
-
}
|
|
54
|
-
return true;
|
|
55
|
-
}
|
|
56
|
-
try {
|
|
57
|
-
return fs.readFileSync("/proc/version", "utf8").toLowerCase().includes("microsoft") ? !isDocker() : false;
|
|
58
|
-
} catch (_) {
|
|
59
|
-
return false;
|
|
60
|
-
}
|
|
61
|
-
};
|
|
62
|
-
if (process.env.__IS_WSL_TEST__) {
|
|
63
|
-
module.exports = isWsl;
|
|
64
|
-
} else {
|
|
65
|
-
module.exports = isWsl();
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
});
|
|
69
|
-
|
|
70
|
-
export {
|
|
71
|
-
require_is_docker,
|
|
72
|
-
require_is_wsl
|
|
73
|
-
};
|
|
74
|
-
//# sourceMappingURL=chunk-YC4FLMDD.js.map
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
execaSync,
|
|
3
|
-
fileExistsSync
|
|
4
|
-
} from "./chunk-P5J3HFWZ.js";
|
|
5
|
-
import "./chunk-LSCXQWNO.js";
|
|
6
|
-
import "./chunk-5LBEKXRW.js";
|
|
7
|
-
import {
|
|
8
|
-
cwd,
|
|
9
|
-
joinPath,
|
|
10
|
-
sniffForPath
|
|
11
|
-
} from "./chunk-Z65QJ5D7.js";
|
|
12
|
-
import "./chunk-M2VKB6RG.js";
|
|
13
|
-
import {
|
|
14
|
-
require_lib
|
|
15
|
-
} from "./chunk-SAO7C4LP.js";
|
|
16
|
-
import "./chunk-GJPZCXGT.js";
|
|
17
|
-
import "./chunk-MCED27CG.js";
|
|
18
|
-
import "./chunk-YC4FLMDD.js";
|
|
19
|
-
import "./chunk-SWNRLCC6.js";
|
|
20
|
-
import "./chunk-T5LLJYYS.js";
|
|
21
|
-
import {
|
|
22
|
-
__toESM,
|
|
23
|
-
init_cjs_shims
|
|
24
|
-
} from "./chunk-ZPL24Y2D.js";
|
|
25
|
-
|
|
26
|
-
// ../cli-kit/src/public/node/custom-oclif-loader.ts
|
|
27
|
-
init_cjs_shims();
|
|
28
|
-
var import_core = __toESM(require_lib(), 1);
|
|
29
|
-
var ShopifyConfig = class extends import_core.Config {
|
|
30
|
-
constructor(options) {
|
|
31
|
-
const currentPath = cwd();
|
|
32
|
-
let path = sniffForPath() ?? currentPath;
|
|
33
|
-
const currentPathMightBeHydrogenMonorepo = /(shopify|hydrogen)\/hydrogen/i.test(currentPath);
|
|
34
|
-
const ignoreHydrogenMonorepo = process.env.IGNORE_HYDROGEN_MONOREPO;
|
|
35
|
-
if (currentPathMightBeHydrogenMonorepo && !ignoreHydrogenMonorepo) {
|
|
36
|
-
path = execaSync("npm", ["prefix"]).stdout.trim();
|
|
37
|
-
}
|
|
38
|
-
if (fileExistsSync(joinPath(`${path}`, "package.json"))) {
|
|
39
|
-
options.pluginAdditions = {
|
|
40
|
-
core: ["@shopify/cli-hydrogen"],
|
|
41
|
-
path
|
|
42
|
-
};
|
|
43
|
-
}
|
|
44
|
-
super(options);
|
|
45
|
-
this["determinePriority"] = this.customPriority;
|
|
46
|
-
}
|
|
47
|
-
customPriority(commands) {
|
|
48
|
-
const oclifPlugins = this.pjson.oclif?.plugins ?? [];
|
|
49
|
-
const commandPlugins = commands.sort((aCommand, bCommand) => {
|
|
50
|
-
const pluginAliasA = aCommand.pluginAlias ?? "A-Cannot-Find-This";
|
|
51
|
-
const pluginAliasB = bCommand.pluginAlias ?? "B-Cannot-Find-This";
|
|
52
|
-
const aIndex = oclifPlugins.indexOf(pluginAliasA);
|
|
53
|
-
const bIndex = oclifPlugins.indexOf(pluginAliasB);
|
|
54
|
-
if (aCommand.pluginType === "core" && bCommand.pluginAlias === "@shopify/cli-hydrogen") {
|
|
55
|
-
return 1;
|
|
56
|
-
}
|
|
57
|
-
if (aCommand.pluginAlias === "@shopify/cli-hydrogen" && bCommand.pluginType === "core") {
|
|
58
|
-
return -1;
|
|
59
|
-
}
|
|
60
|
-
if (aCommand.pluginType === "core" && bCommand.pluginType === "core") {
|
|
61
|
-
return aIndex - bIndex;
|
|
62
|
-
}
|
|
63
|
-
if (bCommand.pluginType === "core" && aCommand.pluginType !== "core") {
|
|
64
|
-
return 1;
|
|
65
|
-
}
|
|
66
|
-
if (aCommand.pluginType === "core" && bCommand.pluginType !== "core") {
|
|
67
|
-
return -1;
|
|
68
|
-
}
|
|
69
|
-
if (aCommand.pluginType === "jit" && bCommand.pluginType !== "jit") {
|
|
70
|
-
return 1;
|
|
71
|
-
}
|
|
72
|
-
if (bCommand.pluginType === "jit" && aCommand.pluginType !== "jit") {
|
|
73
|
-
return -1;
|
|
74
|
-
}
|
|
75
|
-
return 0;
|
|
76
|
-
});
|
|
77
|
-
return commandPlugins[0];
|
|
78
|
-
}
|
|
79
|
-
};
|
|
80
|
-
export {
|
|
81
|
-
ShopifyConfig
|
|
82
|
-
};
|
|
83
|
-
//# sourceMappingURL=custom-oclif-loader-B7KCOFFE.js.map
|