@shopify/create-app 4.9.4 → 5.0.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/{analytics-7RLRFLCQ.js → analytics-NVXLO3J4.js} +19 -18
- package/dist/analytics-WSNO62UE.js +41 -0
- package/dist/{chunk-75IKCZVA.js → chunk-3S4LYDKB.js} +7 -7
- package/dist/{chunk-L6MEGCFP.js → chunk-77MCGVDL.js} +2 -2
- package/dist/{chunk-C3P3BBJI.js → chunk-C7SNAAK3.js} +3 -2
- package/dist/{chunk-NN45GPHA.js → chunk-CXCQOKSC.js} +5 -5
- package/dist/{chunk-7EY7VZVX.js → chunk-D7A5DYKK.js} +10 -4
- package/dist/{chunk-RRQPXOTA.js → chunk-DIOGWWS3.js} +2 -2
- package/dist/{json-error-XFVCG7UX.js → chunk-DIYGDUU2.js} +9 -39
- package/dist/{chunk-PUN2NAT5.js → chunk-DKAJC4S3.js} +104 -1407
- package/dist/{chunk-A33KVF5C.js → chunk-E4XG6SVI.js} +1 -1
- package/dist/{chunk-TLGD6UXP.js → chunk-F5VM2BG4.js} +202 -79
- package/dist/chunk-GLO2DI4E.js +3036 -0
- package/dist/{chunk-ATS65VTD.js → chunk-J53FSF5Q.js} +3 -3
- package/dist/{chunk-IIDLK3B2.js → chunk-J6OB5R2E.js} +2 -2
- package/dist/{chunk-57VCTLOQ.js → chunk-JZFZ3JYG.js} +7 -2
- package/dist/{chunk-6BEAY6DV.js → chunk-L6U3W2XC.js} +8 -9
- package/dist/{chunk-52LPDF46.js → chunk-LQDG3VBX.js} +15 -12
- package/dist/{chunk-IG7O7GU7.js → chunk-MRUYZVYJ.js} +5 -3
- package/dist/{chunk-TJDRI2KO.js → chunk-S3XZMGTD.js} +13 -13
- package/dist/{chunk-IYZRNCTE.js → chunk-TES7JZAA.js} +13 -11
- package/dist/chunk-UJ5OJF5L.js +47 -0
- package/dist/{chunk-DXHBESFY.js → chunk-VHVI7YNQ.js} +43 -4
- package/dist/{chunk-QLLL4VIM.js → chunk-VKOB4EDC.js} +17 -3040
- package/dist/{chunk-VDSENONW.js → chunk-XP6ZAZM3.js} +7 -7
- package/dist/{chunk-53A2QBFH.js → chunk-YCTA633Q.js} +16 -16
- package/dist/{chunk-EJEHENXO.js → chunk-YYP4UTTA.js} +1 -2
- package/dist/{chunk-MNUDC2IF.js → chunk-ZNGF52JY.js} +2 -2
- package/dist/command-event-context-I6WEUQYW.js +12 -0
- package/dist/{command-json-schema-LA7ZVL4O.js → command-json-schema-NFKBCUYJ.js} +15 -12
- package/dist/{conf-store-NRFTTQPX.js → conf-store-F5RVQXAB.js} +9 -8
- package/dist/{custom-oclif-loader-WGQ253VO.js → custom-oclif-loader-JCV5BKJY.js} +10 -9
- package/dist/{deprecations-WHQU454D.js → deprecations-D6NF6OMP.js} +15 -14
- package/dist/{environment-5XBFWY2A.js → environment-3MKMYTQQ.js} +4 -4
- package/dist/environments-RFS64LOU.js +33 -0
- package/dist/{error-handler-MENPWWOI.js → error-handler-JY4HXOW5.js} +19 -18
- package/dist/{fs-SDWO6JOY.js → fs-7KG7OY2Z.js} +7 -6
- package/dist/hooks/postrun.js +8 -7
- package/dist/hooks/prerun.js +6 -6
- package/dist/index.js +11718 -8172
- package/dist/{is-global-JQIYTGBN.js → is-global-3E5IDVMO.js} +7 -6
- package/dist/json-error-NQH2L57S.js +48 -0
- package/dist/{lib-NYDMHWZM.js → lib-7M7VJIRB.js} +2 -2
- package/dist/{local-G2BSQFFH.js → local-ZKE22RLD.js} +5 -5
- package/dist/{metadata-XWHS3SDJ.js → metadata-EACJ44OR.js} +6 -6
- package/dist/{node-package-manager-QET5FYFY.js → node-package-manager-NFYSJBUI.js} +17 -16
- package/dist/{notifications-system-TAHUXXGQ.js → notifications-system-ZDDGD7AS.js} +20 -19
- package/dist/{os-JHHBXO2N.js → os-VAWLBHBF.js} +8 -7
- package/dist/{output-2B3LJAUM.js → output-MFN7MN4X.js} +7 -6
- package/dist/{path-RDYZ7Q5T.js → path-NBWFOGJ4.js} +2 -2
- package/dist/{prettier-BNZDRHR4.js → prettier-XM547TFN.js} +2 -2
- package/dist/{system-EHWOZQCE.js → system-SDCJN2UD.js} +15 -14
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/{ui-ZXHKYLCS.js → ui-HZTN2YF4.js} +15 -14
- package/dist/upgrade-NSRTWSK6.js +295 -0
- package/dist/version-5LTDAJ3Z.js +37 -0
- package/dist/{version-IJ2X574N.js → version-XXTHXVKK.js} +2 -2
- package/oclif.manifest.json +11 -1
- package/package.json +3 -3
- package/dist/analytics-WZ4U5RJZ.js +0 -40
- package/dist/environments-II3QYMU3.js +0 -32
- package/dist/upgrade-H2IEKPCC.js +0 -218
- package/dist/version-QY5L7H5O.js +0 -36
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isUnitTest
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-CXCQOKSC.js";
|
|
4
4
|
import {
|
|
5
5
|
init_cjs_shims
|
|
6
6
|
} from "./chunk-3XNI6LP4.js";
|
|
@@ -32,7 +32,7 @@ function createRuntimeMetadataContainer(defaultPublicMetadata = {}) {
|
|
|
32
32
|
try {
|
|
33
33
|
await getAndSet();
|
|
34
34
|
} catch (error) {
|
|
35
|
-
let { sendErrorToBugsnag } = await import("./error-handler-
|
|
35
|
+
let { sendErrorToBugsnag } = await import("./error-handler-JY4HXOW5.js");
|
|
36
36
|
await sendErrorToBugsnag(error, "unexpected_error");
|
|
37
37
|
}
|
|
38
38
|
}, durationStack = [];
|
|
@@ -75,4 +75,4 @@ export {
|
|
|
75
75
|
addSensitiveMetadata,
|
|
76
76
|
runWithTimer
|
|
77
77
|
};
|
|
78
|
-
//# sourceMappingURL=chunk-
|
|
78
|
+
//# sourceMappingURL=chunk-J53FSF5Q.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
captureOutput,
|
|
3
3
|
require_lib
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-DKAJC4S3.js";
|
|
5
5
|
import {
|
|
6
6
|
require_semver
|
|
7
7
|
} from "./chunk-OQ3KXXGH.js";
|
|
@@ -52,4 +52,4 @@ export {
|
|
|
52
52
|
isPreReleaseVersion,
|
|
53
53
|
isMajorVersionChange
|
|
54
54
|
};
|
|
55
|
-
//# sourceMappingURL=chunk-
|
|
55
|
+
//# sourceMappingURL=chunk-J6OB5R2E.js.map
|
|
@@ -108,6 +108,7 @@ var basename = function(p, extension) {
|
|
|
108
108
|
|
|
109
109
|
// ../cli-kit/dist/public/node/path.js
|
|
110
110
|
import { fileURLToPath } from "url";
|
|
111
|
+
import { relative as nativeRelative, isAbsolute as nativeIsAbsolute, sep as nativeSeparator } from "node:path";
|
|
111
112
|
function joinPath(...paths) {
|
|
112
113
|
return join(...paths);
|
|
113
114
|
}
|
|
@@ -145,7 +146,11 @@ function relativizePath(path2, dir = cwd2()) {
|
|
|
145
146
|
let result = commonParentDirectory(path2, dir), relativePath2 = relative(dir, path2), relativeComponents = relativePath2.split("/").filter((component) => component === "..").length;
|
|
146
147
|
return result === "/" || relativePath2 === "" || relativeComponents > 2 ? path2 : relativePath2;
|
|
147
148
|
}
|
|
148
|
-
function isSubpath(mainPath, subpath) {
|
|
149
|
+
function isSubpath(mainPath, subpath, options = { native: !1 }) {
|
|
150
|
+
if (options.native) {
|
|
151
|
+
let relativePath3 = nativeRelative(mainPath, subpath);
|
|
152
|
+
return relativePath3 !== ".." && !relativePath3.startsWith(`..${nativeSeparator}`) && !nativeIsAbsolute(relativePath3);
|
|
153
|
+
}
|
|
149
154
|
let relativePath2 = relative(mainPath, subpath);
|
|
150
155
|
return !relativePath2.startsWith("..") && !isAbsolutePath(relativePath2);
|
|
151
156
|
}
|
|
@@ -197,4 +202,4 @@ export {
|
|
|
197
202
|
sniffForJson,
|
|
198
203
|
sanitizeRelativePath
|
|
199
204
|
};
|
|
200
|
-
//# sourceMappingURL=chunk-
|
|
205
|
+
//# sourceMappingURL=chunk-JZFZ3JYG.js.map
|
|
@@ -3,13 +3,13 @@ import {
|
|
|
3
3
|
flushStdout,
|
|
4
4
|
stringifyMessage,
|
|
5
5
|
tokenItemToString
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-VKOB4EDC.js";
|
|
7
7
|
import {
|
|
8
8
|
require_lib
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-YYP4UTTA.js";
|
|
10
10
|
import {
|
|
11
11
|
normalizePath
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-JZFZ3JYG.js";
|
|
13
13
|
import {
|
|
14
14
|
__toESM,
|
|
15
15
|
init_cjs_shims
|
|
@@ -114,12 +114,12 @@ async function handler(error) {
|
|
|
114
114
|
let maybeError = error;
|
|
115
115
|
fatal = new BugError(maybeError?.message ?? "Unknown error"), maybeError?.stack && (fatal.stack = maybeError?.stack);
|
|
116
116
|
}
|
|
117
|
-
let { jsonOutputEnabled } = await import("./environment-
|
|
118
|
-
if (jsonOutputEnabled()) {
|
|
119
|
-
let { renderFatalErrorAsJson } = await import("./json-error-
|
|
117
|
+
let { jsonOutputEnabled } = await import("./environment-3MKMYTQQ.js"), { commandEventOutputMode } = await import("./command-event-context-I6WEUQYW.js");
|
|
118
|
+
if (jsonOutputEnabled() || commandEventOutputMode() === "json") {
|
|
119
|
+
let { renderFatalErrorAsJson } = await import("./json-error-NQH2L57S.js");
|
|
120
120
|
return renderFatalErrorAsJson(fatal), await flushStdout(), error;
|
|
121
121
|
}
|
|
122
|
-
let { renderFatalError } = await import("./ui-
|
|
122
|
+
let { renderFatalError } = await import("./ui-HZTN2YF4.js");
|
|
123
123
|
return renderFatalError(fatal), Promise.resolve(error);
|
|
124
124
|
}
|
|
125
125
|
function errorMapper(error) {
|
|
@@ -184,7 +184,6 @@ export {
|
|
|
184
184
|
graphQLErrorCodes,
|
|
185
185
|
isRateLimitCode,
|
|
186
186
|
isPermissionCode,
|
|
187
|
-
hasRateLimitCode,
|
|
188
187
|
isGatewayErrorStatus,
|
|
189
188
|
FatalErrorType,
|
|
190
189
|
CancelExecution,
|
|
@@ -198,4 +197,4 @@ export {
|
|
|
198
197
|
shouldReportErrorAsUnexpected,
|
|
199
198
|
cleanSingleStackTracePath
|
|
200
199
|
};
|
|
201
|
-
//# sourceMappingURL=chunk-
|
|
200
|
+
//# sourceMappingURL=chunk-L6U3W2XC.js.map
|
|
@@ -1,26 +1,28 @@
|
|
|
1
1
|
import {
|
|
2
2
|
jsonOutputEnabled
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-VHVI7YNQ.js";
|
|
4
4
|
import {
|
|
5
5
|
defineJsonOutputSchema
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-77MCGVDL.js";
|
|
7
7
|
import {
|
|
8
8
|
collectLog,
|
|
9
|
-
commandDiagnosticEventSchema,
|
|
10
|
-
commandEventOutputMode,
|
|
11
|
-
commandEventSchema,
|
|
12
|
-
commandProgressEventSchema,
|
|
13
9
|
consoleWarn,
|
|
14
10
|
output,
|
|
15
11
|
outputDebug,
|
|
16
12
|
outputInfo,
|
|
17
13
|
outputWarn,
|
|
18
|
-
outputWhereAppropriate
|
|
19
|
-
|
|
20
|
-
} from "./chunk-QLLL4VIM.js";
|
|
14
|
+
outputWhereAppropriate
|
|
15
|
+
} from "./chunk-VKOB4EDC.js";
|
|
21
16
|
import {
|
|
22
17
|
isUnitTest
|
|
23
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-CXCQOKSC.js";
|
|
19
|
+
import {
|
|
20
|
+
commandDiagnosticEventSchema,
|
|
21
|
+
commandEventOutputMode,
|
|
22
|
+
commandEventSchema,
|
|
23
|
+
commandProgressEventSchema,
|
|
24
|
+
runWithCommandEvents
|
|
25
|
+
} from "./chunk-GLO2DI4E.js";
|
|
24
26
|
import {
|
|
25
27
|
init_cjs_shims
|
|
26
28
|
} from "./chunk-3XNI6LP4.js";
|
|
@@ -81,6 +83,7 @@ function renderCommandEventAsJson(event) {
|
|
|
81
83
|
|
|
82
84
|
export {
|
|
83
85
|
runWithCommandEventsForCommand,
|
|
84
|
-
commandEventOutputSchema
|
|
86
|
+
commandEventOutputSchema,
|
|
87
|
+
renderCommandEventAsJson
|
|
85
88
|
};
|
|
86
|
-
//# sourceMappingURL=chunk-
|
|
89
|
+
//# sourceMappingURL=chunk-LQDG3VBX.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
defineJsonOutputSchema
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-77MCGVDL.js";
|
|
4
4
|
import {
|
|
5
5
|
external_exports
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-GLO2DI4E.js";
|
|
7
7
|
import {
|
|
8
8
|
init_cjs_shims
|
|
9
9
|
} from "./chunk-3XNI6LP4.js";
|
|
@@ -45,6 +45,8 @@ var JsonErrorCustomSectionSchema = external_exports.object({
|
|
|
45
45
|
});
|
|
46
46
|
|
|
47
47
|
export {
|
|
48
|
+
JsonAbortErrorSchema,
|
|
49
|
+
JsonErrorSchema,
|
|
48
50
|
jsonErrorOutputSchema
|
|
49
51
|
};
|
|
50
|
-
//# sourceMappingURL=chunk-
|
|
52
|
+
//# sourceMappingURL=chunk-MRUYZVYJ.js.map
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
AbortError,
|
|
6
6
|
BugError
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-L6U3W2XC.js";
|
|
8
8
|
import {
|
|
9
9
|
fileExistsSync,
|
|
10
10
|
fileHasWritePermissions,
|
|
@@ -12,21 +12,21 @@ import {
|
|
|
12
12
|
outputContent,
|
|
13
13
|
outputDebug,
|
|
14
14
|
unixFileIsOwnedByCurrentUser
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-VKOB4EDC.js";
|
|
16
16
|
import {
|
|
17
17
|
isUnitTest
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-CXCQOKSC.js";
|
|
19
19
|
import {
|
|
20
20
|
envPaths,
|
|
21
21
|
environmentVariables
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-C7SNAAK3.js";
|
|
23
23
|
import {
|
|
24
24
|
require_semver
|
|
25
25
|
} from "./chunk-OQ3KXXGH.js";
|
|
26
26
|
import {
|
|
27
27
|
dirname,
|
|
28
28
|
resolvePath
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-JZFZ3JYG.js";
|
|
30
30
|
import {
|
|
31
31
|
__commonJS,
|
|
32
32
|
__toESM,
|
|
@@ -5488,26 +5488,26 @@ init_cjs_shims();
|
|
|
5488
5488
|
init_cjs_shims();
|
|
5489
5489
|
import path from "node:path";
|
|
5490
5490
|
|
|
5491
|
-
// ../../node_modules/.pnpm/when-exit@2.1.
|
|
5491
|
+
// ../../node_modules/.pnpm/when-exit@2.1.5_patch_hash=dd8a5ad3c180e5b767f6050ad69222568dd4f0111de3769c24841d0caa8f26f7/node_modules/when-exit/dist/node/index.js
|
|
5492
5492
|
init_cjs_shims();
|
|
5493
5493
|
|
|
5494
|
-
// ../../node_modules/.pnpm/when-exit@2.1.
|
|
5494
|
+
// ../../node_modules/.pnpm/when-exit@2.1.5_patch_hash=dd8a5ad3c180e5b767f6050ad69222568dd4f0111de3769c24841d0caa8f26f7/node_modules/when-exit/dist/node/interceptor.js
|
|
5495
5495
|
init_cjs_shims();
|
|
5496
5496
|
import process5 from "node:process";
|
|
5497
5497
|
|
|
5498
|
-
// ../../node_modules/.pnpm/when-exit@2.1.
|
|
5498
|
+
// ../../node_modules/.pnpm/when-exit@2.1.5_patch_hash=dd8a5ad3c180e5b767f6050ad69222568dd4f0111de3769c24841d0caa8f26f7/node_modules/when-exit/dist/node/constants.js
|
|
5499
5499
|
init_cjs_shims();
|
|
5500
5500
|
import process4 from "node:process";
|
|
5501
5501
|
var IS_LINUX = process4.platform === "linux", IS_WINDOWS = process4.platform === "win32";
|
|
5502
5502
|
|
|
5503
|
-
// ../../node_modules/.pnpm/when-exit@2.1.
|
|
5503
|
+
// ../../node_modules/.pnpm/when-exit@2.1.5_patch_hash=dd8a5ad3c180e5b767f6050ad69222568dd4f0111de3769c24841d0caa8f26f7/node_modules/when-exit/dist/node/signals.js
|
|
5504
5504
|
init_cjs_shims();
|
|
5505
5505
|
var Signals = ["SIGHUP", "SIGINT", "SIGTERM"];
|
|
5506
5506
|
IS_WINDOWS || Signals.push("SIGALRM", "SIGABRT", "SIGVTALRM", "SIGXCPU", "SIGXFSZ", "SIGUSR2", "SIGTRAP", "SIGSYS", "SIGQUIT", "SIGIOT");
|
|
5507
5507
|
IS_LINUX && Signals.push("SIGIO", "SIGPOLL", "SIGPWR", "SIGSTKFLT");
|
|
5508
5508
|
var signals_default = Signals;
|
|
5509
5509
|
|
|
5510
|
-
// ../../node_modules/.pnpm/when-exit@2.1.
|
|
5510
|
+
// ../../node_modules/.pnpm/when-exit@2.1.5_patch_hash=dd8a5ad3c180e5b767f6050ad69222568dd4f0111de3769c24841d0caa8f26f7/node_modules/when-exit/dist/node/interceptor.js
|
|
5511
5511
|
var Interceptor = class {
|
|
5512
5512
|
/* CONSTRUCTOR */
|
|
5513
5513
|
constructor() {
|
|
@@ -5516,7 +5516,7 @@ var Interceptor = class {
|
|
|
5516
5516
|
this.exited = !0;
|
|
5517
5517
|
for (let callback of this.callbacks)
|
|
5518
5518
|
callback();
|
|
5519
|
-
signal && (IS_WINDOWS && signal !== "SIGINT" && signal !== "SIGTERM" && signal !== "SIGKILL" ? process5.kill(process5.pid, "SIGTERM") : process5.kill(process5.pid, signal));
|
|
5519
|
+
signal && process5.listenerCount(signal) === 0 && (IS_WINDOWS && signal !== "SIGINT" && signal !== "SIGTERM" && signal !== "SIGKILL" ? process5.kill(process5.pid, "SIGTERM") : process5.kill(process5.pid, signal));
|
|
5520
5520
|
}
|
|
5521
5521
|
}, this.hook = () => {
|
|
5522
5522
|
process5.once("exit", () => this.exit());
|
|
@@ -5531,7 +5531,7 @@ var Interceptor = class {
|
|
|
5531
5531
|
}
|
|
5532
5532
|
}, interceptor_default = new Interceptor();
|
|
5533
5533
|
|
|
5534
|
-
// ../../node_modules/.pnpm/when-exit@2.1.
|
|
5534
|
+
// ../../node_modules/.pnpm/when-exit@2.1.5_patch_hash=dd8a5ad3c180e5b767f6050ad69222568dd4f0111de3769c24841d0caa8f26f7/node_modules/when-exit/dist/node/index.js
|
|
5535
5535
|
var whenExit = interceptor_default.register, node_default = whenExit;
|
|
5536
5536
|
|
|
5537
5537
|
// ../../node_modules/.pnpm/atomically@2.1.1/node_modules/atomically/dist/utils/temp.js
|
|
@@ -6139,4 +6139,4 @@ export {
|
|
|
6139
6139
|
getCachedPartnerAccountStatus,
|
|
6140
6140
|
setCachedPartnerAccountStatus
|
|
6141
6141
|
};
|
|
6142
|
-
//# sourceMappingURL=chunk-
|
|
6142
|
+
//# sourceMappingURL=chunk-S3XZMGTD.js.map
|
|
@@ -1,32 +1,34 @@
|
|
|
1
1
|
import {
|
|
2
2
|
fetch
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-F5VM2BG4.js";
|
|
4
4
|
import {
|
|
5
5
|
versionSatisfies
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-3S4LYDKB.js";
|
|
7
7
|
import {
|
|
8
8
|
CLI_KIT_VERSION
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-ZNGF52JY.js";
|
|
10
10
|
import {
|
|
11
11
|
cacheRetrieve,
|
|
12
12
|
cacheStore
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-S3XZMGTD.js";
|
|
14
14
|
import {
|
|
15
15
|
exec,
|
|
16
16
|
renderError,
|
|
17
17
|
renderInfo,
|
|
18
18
|
renderWarning
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-DKAJC4S3.js";
|
|
20
20
|
import {
|
|
21
21
|
jsonOutputEnabled
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-VHVI7YNQ.js";
|
|
23
23
|
import {
|
|
24
24
|
AbortSilentError
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-L6U3W2XC.js";
|
|
26
26
|
import {
|
|
27
|
-
external_exports,
|
|
28
27
|
outputDebug
|
|
29
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-VKOB4EDC.js";
|
|
29
|
+
import {
|
|
30
|
+
external_exports
|
|
31
|
+
} from "./chunk-GLO2DI4E.js";
|
|
30
32
|
import {
|
|
31
33
|
isTruthy
|
|
32
34
|
} from "./chunk-HNIAZN6U.js";
|
|
@@ -111,7 +113,7 @@ async function showNotificationsIfNeeded(currentSurfaces, environment = process.
|
|
|
111
113
|
throw new AbortSilentError();
|
|
112
114
|
let errorMessage = `Error showing notifications: ${error.message}`;
|
|
113
115
|
outputDebug(errorMessage);
|
|
114
|
-
let { sendErrorToBugsnag } = await import("./error-handler-
|
|
116
|
+
let { sendErrorToBugsnag } = await import("./error-handler-JY4HXOW5.js");
|
|
115
117
|
await sendErrorToBugsnag(errorMessage, "unexpected_error");
|
|
116
118
|
}
|
|
117
119
|
}
|
|
@@ -225,4 +227,4 @@ export {
|
|
|
225
227
|
filterNotifications,
|
|
226
228
|
stringifyFilters
|
|
227
229
|
};
|
|
228
|
-
//# sourceMappingURL=chunk-
|
|
230
|
+
//# sourceMappingURL=chunk-TES7JZAA.js.map
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import {
|
|
2
|
+
exec
|
|
3
|
+
} from "./chunk-DKAJC4S3.js";
|
|
4
|
+
import {
|
|
5
|
+
outputInfo
|
|
6
|
+
} from "./chunk-VKOB4EDC.js";
|
|
7
|
+
import {
|
|
8
|
+
commandEventOutputMode
|
|
9
|
+
} from "./chunk-GLO2DI4E.js";
|
|
10
|
+
import {
|
|
11
|
+
init_cjs_shims
|
|
12
|
+
} from "./chunk-3XNI6LP4.js";
|
|
13
|
+
|
|
14
|
+
// ../cli-kit/dist/public/node/upgrade/output.js
|
|
15
|
+
init_cjs_shims();
|
|
16
|
+
import { Writable } from "node:stream";
|
|
17
|
+
import { StringDecoder } from "node:string_decoder";
|
|
18
|
+
function upgradeOutputStreams() {
|
|
19
|
+
return commandEventOutputMode() !== "json" ? { stdout: process.stdout, stderr: process.stderr } : { stdout: diagnosticStream(), stderr: diagnosticStream() };
|
|
20
|
+
}
|
|
21
|
+
function diagnosticStream() {
|
|
22
|
+
let decoder = new StringDecoder("utf8");
|
|
23
|
+
return new Writable({
|
|
24
|
+
write(chunk, _encoding, callback) {
|
|
25
|
+
let message = decoder.write(chunk);
|
|
26
|
+
message && outputInfo(message), callback();
|
|
27
|
+
},
|
|
28
|
+
final(callback) {
|
|
29
|
+
let message = decoder.end();
|
|
30
|
+
message && outputInfo(message), callback();
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
async function execUpgradeCommand(command, args) {
|
|
35
|
+
let streams = upgradeOutputStreams();
|
|
36
|
+
try {
|
|
37
|
+
await exec(command, args, streams.stdout === process.stdout ? { stdio: "inherit" } : { stdin: "inherit", ...streams });
|
|
38
|
+
} finally {
|
|
39
|
+
streams.stdout !== process.stdout && streams.stdout.end(), streams.stderr !== process.stderr && streams.stderr.end();
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export {
|
|
44
|
+
upgradeOutputStreams,
|
|
45
|
+
execUpgradeCommand
|
|
46
|
+
};
|
|
47
|
+
//# sourceMappingURL=chunk-UJ5OJF5L.js.map
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
environmentVariables,
|
|
3
3
|
systemEnvironmentVariables
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-C7SNAAK3.js";
|
|
5
5
|
import {
|
|
6
6
|
isTruthy
|
|
7
7
|
} from "./chunk-HNIAZN6U.js";
|
|
8
8
|
import {
|
|
9
9
|
sniffForJson
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-JZFZ3JYG.js";
|
|
11
11
|
import {
|
|
12
12
|
init_cjs_shims
|
|
13
13
|
} from "./chunk-3XNI6LP4.js";
|
|
@@ -34,13 +34,48 @@ function nonRandomUUID(subject) {
|
|
|
34
34
|
return crypto.createHash("sha1").update(Buffer.from("6ba7b810-9dad-11d1-80b4-00c04fd430c8".replace(/-/g, ""), "hex")).update(subject).digest().toString("hex").replace(/(.{8})(.{4})(.{4})(.{4})(.{12})/, "$1-$2-$3-$4-$5");
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
+
// ../cli-kit/dist/private/node/session/automation-token.js
|
|
38
|
+
init_cjs_shims();
|
|
39
|
+
var SERVICE_ACCOUNT_TOKEN = environmentVariables.serviceAccountToken, APP_TOKEN = environmentVariables.appAutomationToken, PARTNERS_TOKEN = environmentVariables.partnersToken;
|
|
40
|
+
function automationTokenVariable(env = process.env) {
|
|
41
|
+
return [SERVICE_ACCOUNT_TOKEN, APP_TOKEN, PARTNERS_TOKEN].find((name) => env[name] !== void 0);
|
|
42
|
+
}
|
|
43
|
+
function automationTokenAuthMethod(env = process.env) {
|
|
44
|
+
return automationTokenVariable(env) === SERVICE_ACCOUNT_TOKEN ? "service_account_token" : "partners_token";
|
|
45
|
+
}
|
|
46
|
+
function deprecatedAutomationTokenVariable(env = process.env) {
|
|
47
|
+
if (automationTokenVariablesProblem(env))
|
|
48
|
+
return;
|
|
49
|
+
let variable = automationTokenVariable(env);
|
|
50
|
+
return variable === APP_TOKEN || variable === PARTNERS_TOKEN ? variable : void 0;
|
|
51
|
+
}
|
|
52
|
+
function automationTokenVariablesProblem(env = process.env) {
|
|
53
|
+
if (env[SERVICE_ACCOUNT_TOKEN] !== void 0) {
|
|
54
|
+
let conflictingVariables = [APP_TOKEN, PARTNERS_TOKEN].filter((name) => env[name] !== void 0);
|
|
55
|
+
if (conflictingVariables.length > 0)
|
|
56
|
+
return {
|
|
57
|
+
message: `${SERVICE_ACCOUNT_TOKEN} can't be set together with ${conflictingVariables.join(" or ")}.`,
|
|
58
|
+
tryMessage: `Unset ${conflictingVariables.join(" and ")}, or unset ${SERVICE_ACCOUNT_TOKEN}.`
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
let variable = automationTokenVariable(env);
|
|
62
|
+
if (variable && env[variable] === "")
|
|
63
|
+
return {
|
|
64
|
+
message: `${variable} is set but empty.`,
|
|
65
|
+
tryMessage: "Set it to an automation token, or unset it to log in with your Shopify account."
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
|
|
37
69
|
// ../cli-kit/dist/public/node/environment.js
|
|
38
70
|
function getEnvironmentVariables() {
|
|
39
71
|
return process.env;
|
|
40
72
|
}
|
|
41
73
|
function getAppAutomationToken() {
|
|
42
74
|
let env = getEnvironmentVariables();
|
|
43
|
-
|
|
75
|
+
if (automationTokenVariablesProblem(env))
|
|
76
|
+
return;
|
|
77
|
+
let variable = automationTokenVariable(env);
|
|
78
|
+
return variable ? env[variable] : void 0;
|
|
44
79
|
}
|
|
45
80
|
function getOrganization() {
|
|
46
81
|
return getEnvironmentVariables()[environmentVariables.organization];
|
|
@@ -77,6 +112,10 @@ export {
|
|
|
77
112
|
fileHash,
|
|
78
113
|
randomUUID,
|
|
79
114
|
nonRandomUUID,
|
|
115
|
+
automationTokenVariable,
|
|
116
|
+
automationTokenAuthMethod,
|
|
117
|
+
deprecatedAutomationTokenVariable,
|
|
118
|
+
automationTokenVariablesProblem,
|
|
80
119
|
getEnvironmentVariables,
|
|
81
120
|
getAppAutomationToken,
|
|
82
121
|
getOrganization,
|
|
@@ -86,4 +125,4 @@ export {
|
|
|
86
125
|
skipNetworkLevelRetry,
|
|
87
126
|
maxRequestTimeForNetworkCallsMs
|
|
88
127
|
};
|
|
89
|
-
//# sourceMappingURL=chunk-
|
|
128
|
+
//# sourceMappingURL=chunk-VHVI7YNQ.js.map
|