@catladder/cli 0.0.0-main-8f6ef5d1 → 0.0.0-main-884209c8
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/bundles/catenv/index.js +32 -11
- package/dist/bundles/cli/index.js +32 -11
- package/dist/pipeline/src/pipeline/yarn/yarnUtils.js +12 -11
- package/dist/pipeline/src/pipeline/yarn/yarnUtils.js.map +1 -1
- package/dist/pipeline/src/utils/jsonParse.d.ts +1 -0
- package/dist/pipeline/src/utils/jsonParse.js +13 -0
- package/dist/pipeline/src/utils/jsonParse.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -9280,6 +9280,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
|
9280
9280
|
exports.getWorkspaceDependencies = exports.getWorkspaces = exports.getYarnVersion = void 0;
|
|
9281
9281
|
var child_process_promise_1 = __nccwpck_require__(5763);
|
|
9282
9282
|
var memoizee_1 = __importDefault(__nccwpck_require__(5839));
|
|
9283
|
+
var jsonParse_1 = __nccwpck_require__(6046);
|
|
9283
9284
|
var execOrFail = function (cmd, onFail) { return __awaiter(void 0, void 0, void 0, function () {
|
|
9284
9285
|
var e_1;
|
|
9285
9286
|
return __generator(this, function (_a) {
|
|
@@ -9306,29 +9307,29 @@ exports.getYarnVersion = (0, memoizee_1.default)(function () { return __awaiter(
|
|
|
9306
9307
|
}); }, { promise: true });
|
|
9307
9308
|
// export for mocking
|
|
9308
9309
|
exports.getWorkspaces = (0, memoizee_1.default)(function (isClassic) { return __awaiter(void 0, void 0, void 0, function () {
|
|
9309
|
-
var _a, _b, _c, _d, _e, _f, _g
|
|
9310
|
-
var
|
|
9311
|
-
return __generator(this, function (
|
|
9312
|
-
switch (
|
|
9310
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
9311
|
+
var _h, _j;
|
|
9312
|
+
return __generator(this, function (_k) {
|
|
9313
|
+
switch (_k.label) {
|
|
9313
9314
|
case 0:
|
|
9314
9315
|
if (!isClassic) return [3 /*break*/, 2];
|
|
9315
9316
|
_c = (_b = Object).values;
|
|
9316
|
-
|
|
9317
|
-
|
|
9317
|
+
_d = jsonParse_1.jsonParseOrThrow;
|
|
9318
|
+
_e = jsonParse_1.jsonParseOrThrow;
|
|
9318
9319
|
return [4 /*yield*/, execOrFail("yarn workspaces --json info", "{}")];
|
|
9319
9320
|
case 1:
|
|
9320
|
-
_a = _c.apply(_b, [
|
|
9321
|
+
_a = _c.apply(_b, [_d.apply(void 0, [(_j = (_h = _e.apply(void 0, [_k.sent()])) === null || _h === void 0 ? void 0 : _h.data) !== null && _j !== void 0 ? _j : "{}"])]);
|
|
9321
9322
|
return [3 /*break*/, 4];
|
|
9322
9323
|
case 2:
|
|
9323
|
-
|
|
9324
|
-
|
|
9324
|
+
_f = jsonParse_1.jsonParseOrThrow;
|
|
9325
|
+
_g = "[".concat;
|
|
9325
9326
|
return [4 /*yield*/, execOrFail("yarn workspaces list --json --verbose", "")];
|
|
9326
9327
|
case 3:
|
|
9327
|
-
_a =
|
|
9328
|
+
_a = _f.apply(void 0, [_g.apply("[", [(_k.sent())
|
|
9328
9329
|
.trim()
|
|
9329
9330
|
.split("\n")
|
|
9330
9331
|
.join(","), "]"])]);
|
|
9331
|
-
|
|
9332
|
+
_k.label = 4;
|
|
9332
9333
|
case 4: return [2 /*return*/, _a];
|
|
9333
9334
|
}
|
|
9334
9335
|
});
|
|
@@ -9716,6 +9717,26 @@ exports.mergeWithMergingArrays = mergeWithMergingArrays;
|
|
|
9716
9717
|
|
|
9717
9718
|
/***/ }),
|
|
9718
9719
|
|
|
9720
|
+
/***/ 6046:
|
|
9721
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
9722
|
+
|
|
9723
|
+
"use strict";
|
|
9724
|
+
|
|
9725
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
9726
|
+
exports.jsonParseOrThrow = void 0;
|
|
9727
|
+
var jsonParseOrThrow = function (str) {
|
|
9728
|
+
try {
|
|
9729
|
+
return JSON.parse(str);
|
|
9730
|
+
}
|
|
9731
|
+
catch (e) {
|
|
9732
|
+
throw new Error("could not parse json: ".concat(str));
|
|
9733
|
+
}
|
|
9734
|
+
};
|
|
9735
|
+
exports.jsonParseOrThrow = jsonParseOrThrow;
|
|
9736
|
+
//# sourceMappingURL=jsonParse.js.map
|
|
9737
|
+
|
|
9738
|
+
/***/ }),
|
|
9739
|
+
|
|
9719
9740
|
/***/ 1073:
|
|
9720
9741
|
/***/ (function(__unused_webpack_module, exports) {
|
|
9721
9742
|
|
|
@@ -16761,6 +16761,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
|
16761
16761
|
exports.getWorkspaceDependencies = exports.getWorkspaces = exports.getYarnVersion = void 0;
|
|
16762
16762
|
var child_process_promise_1 = __nccwpck_require__(75763);
|
|
16763
16763
|
var memoizee_1 = __importDefault(__nccwpck_require__(85839));
|
|
16764
|
+
var jsonParse_1 = __nccwpck_require__(46046);
|
|
16764
16765
|
var execOrFail = function (cmd, onFail) { return __awaiter(void 0, void 0, void 0, function () {
|
|
16765
16766
|
var e_1;
|
|
16766
16767
|
return __generator(this, function (_a) {
|
|
@@ -16787,29 +16788,29 @@ exports.getYarnVersion = (0, memoizee_1.default)(function () { return __awaiter(
|
|
|
16787
16788
|
}); }, { promise: true });
|
|
16788
16789
|
// export for mocking
|
|
16789
16790
|
exports.getWorkspaces = (0, memoizee_1.default)(function (isClassic) { return __awaiter(void 0, void 0, void 0, function () {
|
|
16790
|
-
var _a, _b, _c, _d, _e, _f, _g
|
|
16791
|
-
var
|
|
16792
|
-
return __generator(this, function (
|
|
16793
|
-
switch (
|
|
16791
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
16792
|
+
var _h, _j;
|
|
16793
|
+
return __generator(this, function (_k) {
|
|
16794
|
+
switch (_k.label) {
|
|
16794
16795
|
case 0:
|
|
16795
16796
|
if (!isClassic) return [3 /*break*/, 2];
|
|
16796
16797
|
_c = (_b = Object).values;
|
|
16797
|
-
|
|
16798
|
-
|
|
16798
|
+
_d = jsonParse_1.jsonParseOrThrow;
|
|
16799
|
+
_e = jsonParse_1.jsonParseOrThrow;
|
|
16799
16800
|
return [4 /*yield*/, execOrFail("yarn workspaces --json info", "{}")];
|
|
16800
16801
|
case 1:
|
|
16801
|
-
_a = _c.apply(_b, [
|
|
16802
|
+
_a = _c.apply(_b, [_d.apply(void 0, [(_j = (_h = _e.apply(void 0, [_k.sent()])) === null || _h === void 0 ? void 0 : _h.data) !== null && _j !== void 0 ? _j : "{}"])]);
|
|
16802
16803
|
return [3 /*break*/, 4];
|
|
16803
16804
|
case 2:
|
|
16804
|
-
|
|
16805
|
-
|
|
16805
|
+
_f = jsonParse_1.jsonParseOrThrow;
|
|
16806
|
+
_g = "[".concat;
|
|
16806
16807
|
return [4 /*yield*/, execOrFail("yarn workspaces list --json --verbose", "")];
|
|
16807
16808
|
case 3:
|
|
16808
|
-
_a =
|
|
16809
|
+
_a = _f.apply(void 0, [_g.apply("[", [(_k.sent())
|
|
16809
16810
|
.trim()
|
|
16810
16811
|
.split("\n")
|
|
16811
16812
|
.join(","), "]"])]);
|
|
16812
|
-
|
|
16813
|
+
_k.label = 4;
|
|
16813
16814
|
case 4: return [2 /*return*/, _a];
|
|
16814
16815
|
}
|
|
16815
16816
|
});
|
|
@@ -17197,6 +17198,26 @@ exports.mergeWithMergingArrays = mergeWithMergingArrays;
|
|
|
17197
17198
|
|
|
17198
17199
|
/***/ }),
|
|
17199
17200
|
|
|
17201
|
+
/***/ 46046:
|
|
17202
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
17203
|
+
|
|
17204
|
+
"use strict";
|
|
17205
|
+
|
|
17206
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
17207
|
+
exports.jsonParseOrThrow = void 0;
|
|
17208
|
+
var jsonParseOrThrow = function (str) {
|
|
17209
|
+
try {
|
|
17210
|
+
return JSON.parse(str);
|
|
17211
|
+
}
|
|
17212
|
+
catch (e) {
|
|
17213
|
+
throw new Error("could not parse json: ".concat(str));
|
|
17214
|
+
}
|
|
17215
|
+
};
|
|
17216
|
+
exports.jsonParseOrThrow = jsonParseOrThrow;
|
|
17217
|
+
//# sourceMappingURL=jsonParse.js.map
|
|
17218
|
+
|
|
17219
|
+
/***/ }),
|
|
17220
|
+
|
|
17200
17221
|
/***/ 61073:
|
|
17201
17222
|
/***/ (function(__unused_webpack_module, exports) {
|
|
17202
17223
|
|
|
@@ -67,6 +67,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
67
67
|
exports.getWorkspaceDependencies = exports.getWorkspaces = exports.getYarnVersion = void 0;
|
|
68
68
|
var child_process_promise_1 = require("child-process-promise");
|
|
69
69
|
var memoizee_1 = __importDefault(require("memoizee"));
|
|
70
|
+
var jsonParse_1 = require("../../utils/jsonParse");
|
|
70
71
|
var execOrFail = function (cmd, onFail) { return __awaiter(void 0, void 0, void 0, function () {
|
|
71
72
|
var e_1;
|
|
72
73
|
return __generator(this, function (_a) {
|
|
@@ -93,29 +94,29 @@ exports.getYarnVersion = (0, memoizee_1.default)(function () { return __awaiter(
|
|
|
93
94
|
}); }, { promise: true });
|
|
94
95
|
// export for mocking
|
|
95
96
|
exports.getWorkspaces = (0, memoizee_1.default)(function (isClassic) { return __awaiter(void 0, void 0, void 0, function () {
|
|
96
|
-
var _a, _b, _c, _d, _e, _f, _g
|
|
97
|
-
var
|
|
98
|
-
return __generator(this, function (
|
|
99
|
-
switch (
|
|
97
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
98
|
+
var _h, _j;
|
|
99
|
+
return __generator(this, function (_k) {
|
|
100
|
+
switch (_k.label) {
|
|
100
101
|
case 0:
|
|
101
102
|
if (!isClassic) return [3 /*break*/, 2];
|
|
102
103
|
_c = (_b = Object).values;
|
|
103
|
-
|
|
104
|
-
|
|
104
|
+
_d = jsonParse_1.jsonParseOrThrow;
|
|
105
|
+
_e = jsonParse_1.jsonParseOrThrow;
|
|
105
106
|
return [4 /*yield*/, execOrFail("yarn workspaces --json info", "{}")];
|
|
106
107
|
case 1:
|
|
107
|
-
_a = _c.apply(_b, [
|
|
108
|
+
_a = _c.apply(_b, [_d.apply(void 0, [(_j = (_h = _e.apply(void 0, [_k.sent()])) === null || _h === void 0 ? void 0 : _h.data) !== null && _j !== void 0 ? _j : "{}"])]);
|
|
108
109
|
return [3 /*break*/, 4];
|
|
109
110
|
case 2:
|
|
110
|
-
|
|
111
|
-
|
|
111
|
+
_f = jsonParse_1.jsonParseOrThrow;
|
|
112
|
+
_g = "[".concat;
|
|
112
113
|
return [4 /*yield*/, execOrFail("yarn workspaces list --json --verbose", "")];
|
|
113
114
|
case 3:
|
|
114
|
-
_a =
|
|
115
|
+
_a = _f.apply(void 0, [_g.apply("[", [(_k.sent())
|
|
115
116
|
.trim()
|
|
116
117
|
.split("\n")
|
|
117
118
|
.join(","), "]"])]);
|
|
118
|
-
|
|
119
|
+
_k.label = 4;
|
|
119
120
|
case 4: return [2 /*return*/, _a];
|
|
120
121
|
}
|
|
121
122
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"yarnUtils.js","sourceRoot":"","sources":["../../../../../../pipeline/src/pipeline/yarn/yarnUtils.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+DAA6C;AAC7C,sDAAgC;
|
|
1
|
+
{"version":3,"file":"yarnUtils.js","sourceRoot":"","sources":["../../../../../../pipeline/src/pipeline/yarn/yarnUtils.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+DAA6C;AAC7C,sDAAgC;AAEhC,mDAAyD;AAEzD,IAAM,UAAU,GAAG,UAAO,GAAW,EAAE,MAAc;;;;;;gBAE1C,qBAAM,IAAA,4BA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AAE,CAAC,+BAA+B,UACjE,OAAO,CAAC,UAAC,QAAQ;YAChB,gCAAgC;YAEhC,IAAM,cAAc,GAAG,aAAa,CAAC,IAAI,CACvC,UAAC,CAAC,IAAK,OAAA,CAAC,CAAC,QAAQ,KAAK,QAAQ,EAAvB,CAAuB,CAC/B,CAAC;YAEF,IAAI,cAAc,EAAE,CAAC;gBACnB,8CACK,IAAA,gCAAwB,EAAC,cAAc,EAAE,aAAa,CAAC;oBAC1D,cAAc,CAAC,QAAQ;0BACvB;YACJ,CAAC;YACD,OAAO,EAAE,CAAC;QACZ,CAAC,CAAC;aACD,MAAM,CAAC,OAAO,CAAc;QACjC,CAAC,CAAC,EAAE,CAAC;AACT,CAAC,CAAC;AAvBW,QAAA,wBAAwB,4BAuBnC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const jsonParseOrThrow: (str: string) => any;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.jsonParseOrThrow = void 0;
|
|
4
|
+
var jsonParseOrThrow = function (str) {
|
|
5
|
+
try {
|
|
6
|
+
return JSON.parse(str);
|
|
7
|
+
}
|
|
8
|
+
catch (e) {
|
|
9
|
+
throw new Error("could not parse json: ".concat(str));
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
exports.jsonParseOrThrow = jsonParseOrThrow;
|
|
13
|
+
//# sourceMappingURL=jsonParse.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsonParse.js","sourceRoot":"","sources":["../../../../../pipeline/src/utils/jsonParse.ts"],"names":[],"mappings":";;;AAAO,IAAM,gBAAgB,GAAG,UAAC,GAAW;IAC1C,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IACzB,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACX,MAAM,IAAI,KAAK,CAAC,gCAAyB,GAAG,CAAE,CAAC,CAAC;IAClD,CAAC;AACH,CAAC,CAAC;AANW,QAAA,gBAAgB,oBAM3B"}
|