@midscene/cli 0.30.10 → 1.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/es/index.mjs +172 -208
- package/dist/es/index.mjs.map +1 -1
- package/dist/lib/index.js +150 -186
- package/dist/lib/index.js.map +1 -1
- package/package.json +9 -9
package/dist/lib/index.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
/*! For license information please see index.js.LICENSE.txt */
|
|
2
2
|
var __webpack_modules__ = {
|
|
3
|
-
"../../node_modules/.pnpm/ansi-regex@5.0.1/node_modules/ansi-regex/index.js"
|
|
3
|
+
"../../node_modules/.pnpm/ansi-regex@5.0.1/node_modules/ansi-regex/index.js" (module) {
|
|
4
4
|
"use strict";
|
|
5
5
|
module.exports = ({ onlyFirst = false } = {})=>{
|
|
6
6
|
const pattern = "[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)|(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))";
|
|
7
7
|
return new RegExp(pattern, onlyFirst ? void 0 : 'g');
|
|
8
8
|
};
|
|
9
9
|
},
|
|
10
|
-
"../../node_modules/.pnpm/ansi-styles@4.3.0/node_modules/ansi-styles/index.js"
|
|
10
|
+
"../../node_modules/.pnpm/ansi-styles@4.3.0/node_modules/ansi-styles/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
11
11
|
"use strict";
|
|
12
12
|
module = __webpack_require__.nmd(module);
|
|
13
13
|
const wrapAnsi16 = (fn, offset)=>(...args)=>{
|
|
@@ -262,7 +262,7 @@ var __webpack_modules__ = {
|
|
|
262
262
|
get: assembleStyles
|
|
263
263
|
});
|
|
264
264
|
},
|
|
265
|
-
"../../node_modules/.pnpm/balanced-match@1.0.2/node_modules/balanced-match/index.js"
|
|
265
|
+
"../../node_modules/.pnpm/balanced-match@1.0.2/node_modules/balanced-match/index.js" (module) {
|
|
266
266
|
"use strict";
|
|
267
267
|
module.exports = balanced;
|
|
268
268
|
function balanced(a, b, str) {
|
|
@@ -320,7 +320,7 @@ var __webpack_modules__ = {
|
|
|
320
320
|
return result;
|
|
321
321
|
}
|
|
322
322
|
},
|
|
323
|
-
"../../node_modules/.pnpm/brace-expansion@2.0.1/node_modules/brace-expansion/index.js"
|
|
323
|
+
"../../node_modules/.pnpm/brace-expansion@2.0.1/node_modules/brace-expansion/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
324
324
|
var balanced = __webpack_require__("../../node_modules/.pnpm/balanced-match@1.0.2/node_modules/balanced-match/index.js");
|
|
325
325
|
module.exports = expandTop;
|
|
326
326
|
var escSlash = '\0SLASH' + Math.random() + '\0';
|
|
@@ -456,7 +456,7 @@ var __webpack_modules__ = {
|
|
|
456
456
|
return expansions;
|
|
457
457
|
}
|
|
458
458
|
},
|
|
459
|
-
"../../node_modules/.pnpm/chalk@4.1.2/node_modules/chalk/source/index.js"
|
|
459
|
+
"../../node_modules/.pnpm/chalk@4.1.2/node_modules/chalk/source/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
460
460
|
"use strict";
|
|
461
461
|
const ansiStyles = __webpack_require__("../../node_modules/.pnpm/ansi-styles@4.3.0/node_modules/ansi-styles/index.js");
|
|
462
462
|
const { stdout: stdoutColor, stderr: stderrColor } = __webpack_require__("../../node_modules/.pnpm/supports-color@7.2.0/node_modules/supports-color/index.js");
|
|
@@ -618,7 +618,7 @@ var __webpack_modules__ = {
|
|
|
618
618
|
chalk.stderr.supportsColor = stderrColor;
|
|
619
619
|
module.exports = chalk;
|
|
620
620
|
},
|
|
621
|
-
"../../node_modules/.pnpm/chalk@4.1.2/node_modules/chalk/source/templates.js"
|
|
621
|
+
"../../node_modules/.pnpm/chalk@4.1.2/node_modules/chalk/source/templates.js" (module) {
|
|
622
622
|
"use strict";
|
|
623
623
|
const TEMPLATE_REGEX = /(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi;
|
|
624
624
|
const STYLE_REGEX = /(?:^|\.)(\w+)(?:\(([^)]*)\))?/g;
|
|
@@ -741,7 +741,7 @@ var __webpack_modules__ = {
|
|
|
741
741
|
return chunks.join('');
|
|
742
742
|
};
|
|
743
743
|
},
|
|
744
|
-
"../../node_modules/.pnpm/chalk@4.1.2/node_modules/chalk/source/util.js"
|
|
744
|
+
"../../node_modules/.pnpm/chalk@4.1.2/node_modules/chalk/source/util.js" (module) {
|
|
745
745
|
"use strict";
|
|
746
746
|
const stringReplaceAll = (string, substring, replacer)=>{
|
|
747
747
|
let index = string.indexOf(substring);
|
|
@@ -774,7 +774,7 @@ var __webpack_modules__ = {
|
|
|
774
774
|
stringEncaseCRLFWithFirstIndex
|
|
775
775
|
};
|
|
776
776
|
},
|
|
777
|
-
"../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/conversions.js"
|
|
777
|
+
"../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/conversions.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
778
778
|
const cssKeywords = __webpack_require__("../../node_modules/.pnpm/color-name@1.1.4/node_modules/color-name/index.js");
|
|
779
779
|
const reverseKeywords = {};
|
|
780
780
|
for (const key of Object.keys(cssKeywords))reverseKeywords[cssKeywords[key]] = key;
|
|
@@ -1597,7 +1597,7 @@ var __webpack_modules__ = {
|
|
|
1597
1597
|
];
|
|
1598
1598
|
};
|
|
1599
1599
|
},
|
|
1600
|
-
"../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/index.js"
|
|
1600
|
+
"../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
1601
1601
|
const conversions = __webpack_require__("../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/conversions.js");
|
|
1602
1602
|
const route = __webpack_require__("../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/route.js");
|
|
1603
1603
|
const convert = {};
|
|
@@ -1642,7 +1642,7 @@ var __webpack_modules__ = {
|
|
|
1642
1642
|
});
|
|
1643
1643
|
module.exports = convert;
|
|
1644
1644
|
},
|
|
1645
|
-
"../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/route.js"
|
|
1645
|
+
"../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/route.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
1646
1646
|
const conversions = __webpack_require__("../../node_modules/.pnpm/color-convert@2.0.1/node_modules/color-convert/conversions.js");
|
|
1647
1647
|
function buildGraph() {
|
|
1648
1648
|
const graph = {};
|
|
@@ -1706,7 +1706,7 @@ var __webpack_modules__ = {
|
|
|
1706
1706
|
return conversion;
|
|
1707
1707
|
};
|
|
1708
1708
|
},
|
|
1709
|
-
"../../node_modules/.pnpm/color-name@1.1.4/node_modules/color-name/index.js"
|
|
1709
|
+
"../../node_modules/.pnpm/color-name@1.1.4/node_modules/color-name/index.js" (module) {
|
|
1710
1710
|
"use strict";
|
|
1711
1711
|
module.exports = {
|
|
1712
1712
|
aliceblue: [
|
|
@@ -2451,7 +2451,7 @@ var __webpack_modules__ = {
|
|
|
2451
2451
|
]
|
|
2452
2452
|
};
|
|
2453
2453
|
},
|
|
2454
|
-
"../../node_modules/.pnpm/dotenv@16.4.5/node_modules/dotenv/lib/main.js"
|
|
2454
|
+
"../../node_modules/.pnpm/dotenv@16.4.5/node_modules/dotenv/lib/main.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
2455
2455
|
const fs = __webpack_require__("fs");
|
|
2456
2456
|
const path = __webpack_require__("path");
|
|
2457
2457
|
const os = __webpack_require__("os");
|
|
@@ -2677,13 +2677,13 @@ var __webpack_modules__ = {
|
|
|
2677
2677
|
module.exports.populate = DotenvModule.populate;
|
|
2678
2678
|
module.exports = DotenvModule;
|
|
2679
2679
|
},
|
|
2680
|
-
"../../node_modules/.pnpm/emoji-regex@8.0.0/node_modules/emoji-regex/index.js"
|
|
2680
|
+
"../../node_modules/.pnpm/emoji-regex@8.0.0/node_modules/emoji-regex/index.js" (module) {
|
|
2681
2681
|
"use strict";
|
|
2682
2682
|
module.exports = function() {
|
|
2683
2683
|
return /\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB-\uDFFD])|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|(?:(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)\uFE0F|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\u200D[\u2640\u2642])|\uD83C\uDFF4\u200D\u2620)\uFE0F|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF4\uD83C\uDDF2|\uD83C\uDDF6\uD83C\uDDE6|[#\*0-9]\uFE0F\u20E3|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83D\uDC69(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270A-\u270D]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC70\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDCAA\uDD74\uDD7A\uDD90\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD36\uDDB5\uDDB6\uDDBB\uDDD2-\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5\uDEEB\uDEEC\uDEF4-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g;
|
|
2684
2684
|
};
|
|
2685
2685
|
},
|
|
2686
|
-
"../../node_modules/.pnpm/escalade@3.2.0/node_modules/escalade/sync/index.js"
|
|
2686
|
+
"../../node_modules/.pnpm/escalade@3.2.0/node_modules/escalade/sync/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
2687
2687
|
const { dirname, resolve } = __webpack_require__("path");
|
|
2688
2688
|
const { readdirSync, statSync } = __webpack_require__("fs");
|
|
2689
2689
|
module.exports = function(start, callback) {
|
|
@@ -2698,7 +2698,7 @@ var __webpack_modules__ = {
|
|
|
2698
2698
|
}
|
|
2699
2699
|
};
|
|
2700
2700
|
},
|
|
2701
|
-
"../../node_modules/.pnpm/get-caller-file@2.0.5/node_modules/get-caller-file/index.js"
|
|
2701
|
+
"../../node_modules/.pnpm/get-caller-file@2.0.5/node_modules/get-caller-file/index.js" (module) {
|
|
2702
2702
|
"use strict";
|
|
2703
2703
|
module.exports = function(position) {
|
|
2704
2704
|
if (void 0 === position) position = 2;
|
|
@@ -2712,7 +2712,7 @@ var __webpack_modules__ = {
|
|
|
2712
2712
|
if (null !== stack && 'object' == typeof stack) return stack[position] ? stack[position].getFileName() : void 0;
|
|
2713
2713
|
};
|
|
2714
2714
|
},
|
|
2715
|
-
"../../node_modules/.pnpm/has-flag@4.0.0/node_modules/has-flag/index.js"
|
|
2715
|
+
"../../node_modules/.pnpm/has-flag@4.0.0/node_modules/has-flag/index.js" (module) {
|
|
2716
2716
|
"use strict";
|
|
2717
2717
|
module.exports = (flag, argv = process.argv)=>{
|
|
2718
2718
|
const prefix = flag.startsWith('-') ? '' : 1 === flag.length ? '-' : '--';
|
|
@@ -2721,7 +2721,7 @@ var __webpack_modules__ = {
|
|
|
2721
2721
|
return -1 !== position && (-1 === terminatorPosition || position < terminatorPosition);
|
|
2722
2722
|
};
|
|
2723
2723
|
},
|
|
2724
|
-
"../../node_modules/.pnpm/is-fullwidth-code-point@3.0.0/node_modules/is-fullwidth-code-point/index.js"
|
|
2724
|
+
"../../node_modules/.pnpm/is-fullwidth-code-point@3.0.0/node_modules/is-fullwidth-code-point/index.js" (module) {
|
|
2725
2725
|
"use strict";
|
|
2726
2726
|
const isFullwidthCodePoint = (codePoint)=>{
|
|
2727
2727
|
if (Number.isNaN(codePoint)) return false;
|
|
@@ -2731,7 +2731,7 @@ var __webpack_modules__ = {
|
|
|
2731
2731
|
module.exports = isFullwidthCodePoint;
|
|
2732
2732
|
module.exports["default"] = isFullwidthCodePoint;
|
|
2733
2733
|
},
|
|
2734
|
-
"../../node_modules/.pnpm/require-directory@2.1.1/node_modules/require-directory/index.js"
|
|
2734
|
+
"../../node_modules/.pnpm/require-directory@2.1.1/node_modules/require-directory/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
2735
2735
|
"use strict";
|
|
2736
2736
|
var fs = __webpack_require__("fs"), join = __webpack_require__("path").join, resolve = __webpack_require__("path").resolve, dirname = __webpack_require__("path").dirname, defaultOptions = {
|
|
2737
2737
|
extensions: [
|
|
@@ -2775,7 +2775,7 @@ var __webpack_modules__ = {
|
|
|
2775
2775
|
module.exports = requireDirectory;
|
|
2776
2776
|
module.exports.defaults = defaultOptions;
|
|
2777
2777
|
},
|
|
2778
|
-
"../../node_modules/.pnpm/string-width@4.2.3/node_modules/string-width/index.js"
|
|
2778
|
+
"../../node_modules/.pnpm/string-width@4.2.3/node_modules/string-width/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
2779
2779
|
"use strict";
|
|
2780
2780
|
const stripAnsi = __webpack_require__("../../node_modules/.pnpm/strip-ansi@6.0.1/node_modules/strip-ansi/index.js");
|
|
2781
2781
|
const isFullwidthCodePoint = __webpack_require__("../../node_modules/.pnpm/is-fullwidth-code-point@3.0.0/node_modules/is-fullwidth-code-point/index.js");
|
|
@@ -2800,12 +2800,12 @@ var __webpack_modules__ = {
|
|
|
2800
2800
|
module.exports = stringWidth;
|
|
2801
2801
|
module.exports["default"] = stringWidth;
|
|
2802
2802
|
},
|
|
2803
|
-
"../../node_modules/.pnpm/strip-ansi@6.0.1/node_modules/strip-ansi/index.js"
|
|
2803
|
+
"../../node_modules/.pnpm/strip-ansi@6.0.1/node_modules/strip-ansi/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
2804
2804
|
"use strict";
|
|
2805
2805
|
const ansiRegex = __webpack_require__("../../node_modules/.pnpm/ansi-regex@5.0.1/node_modules/ansi-regex/index.js");
|
|
2806
2806
|
module.exports = (string)=>'string' == typeof string ? string.replace(ansiRegex(), '') : string;
|
|
2807
2807
|
},
|
|
2808
|
-
"../../node_modules/.pnpm/supports-color@7.2.0/node_modules/supports-color/index.js"
|
|
2808
|
+
"../../node_modules/.pnpm/supports-color@7.2.0/node_modules/supports-color/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
2809
2809
|
"use strict";
|
|
2810
2810
|
const os = __webpack_require__("os");
|
|
2811
2811
|
const tty = __webpack_require__("tty");
|
|
@@ -2873,7 +2873,7 @@ var __webpack_modules__ = {
|
|
|
2873
2873
|
stderr: translateLevel(supportsColor(true, tty.isatty(2)))
|
|
2874
2874
|
};
|
|
2875
2875
|
},
|
|
2876
|
-
"../../node_modules/.pnpm/wrap-ansi@7.0.0/node_modules/wrap-ansi/index.js"
|
|
2876
|
+
"../../node_modules/.pnpm/wrap-ansi@7.0.0/node_modules/wrap-ansi/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
2877
2877
|
"use strict";
|
|
2878
2878
|
const stringWidth = __webpack_require__("../../node_modules/.pnpm/string-width@4.2.3/node_modules/string-width/index.js");
|
|
2879
2879
|
const stripAnsi = __webpack_require__("../../node_modules/.pnpm/strip-ansi@6.0.1/node_modules/strip-ansi/index.js");
|
|
@@ -3007,7 +3007,7 @@ var __webpack_modules__ = {
|
|
|
3007
3007
|
};
|
|
3008
3008
|
module.exports = (string, columns, options)=>String(string).normalize().replace(/\r\n/g, '\n').split('\n').map((line)=>exec(line, columns, options)).join('\n');
|
|
3009
3009
|
},
|
|
3010
|
-
"./src/index.ts"
|
|
3010
|
+
"./src/index.ts" (__unused_rspack_module, __unused_rspack___webpack_exports__, __webpack_require__) {
|
|
3011
3011
|
"use strict";
|
|
3012
3012
|
const external_node_fs_namespaceObject = require("node:fs");
|
|
3013
3013
|
var external_node_fs_namespaceObject_0 = /*#__PURE__*/ __webpack_require__.t(external_node_fs_namespaceObject, 2);
|
|
@@ -3016,7 +3016,7 @@ var __webpack_modules__ = {
|
|
|
3016
3016
|
var main = __webpack_require__("../../node_modules/.pnpm/dotenv@16.4.5/node_modules/dotenv/lib/main.js");
|
|
3017
3017
|
var main_default = /*#__PURE__*/ __webpack_require__.n(main);
|
|
3018
3018
|
var package_namespaceObject = {
|
|
3019
|
-
|
|
3019
|
+
rE: "1.0.0"
|
|
3020
3020
|
};
|
|
3021
3021
|
const yaml_namespaceObject = require("@midscene/core/yaml");
|
|
3022
3022
|
const common_namespaceObject = require("@midscene/shared/common");
|
|
@@ -3160,35 +3160,45 @@ var __webpack_modules__ = {
|
|
|
3160
3160
|
resolve(server);
|
|
3161
3161
|
});
|
|
3162
3162
|
});
|
|
3163
|
+
function resolveTestId(cliTestId, yamlTestId, fileName) {
|
|
3164
|
+
return cliTestId ?? yamlTestId ?? fileName;
|
|
3165
|
+
}
|
|
3166
|
+
function buildAgentOptions(yamlAgent, preferenceTestId, fileName) {
|
|
3167
|
+
return {
|
|
3168
|
+
...yamlAgent || {},
|
|
3169
|
+
cache: (0, utils_namespaceObject.processCacheConfig)(yamlAgent?.cache, fileName),
|
|
3170
|
+
testId: preferenceTestId
|
|
3171
|
+
};
|
|
3172
|
+
}
|
|
3163
3173
|
async function createYamlPlayer(file, script, options) {
|
|
3164
3174
|
const yamlScript = script || (0, yaml_namespaceObject.parseYamlScript)((0, external_node_fs_namespaceObject.readFileSync)(file, 'utf-8'), file);
|
|
3175
|
+
const clonedYamlScript = structuredClone(yamlScript);
|
|
3165
3176
|
const fileName = (0, external_node_path_namespaceObject.basename)(file, (0, external_node_path_namespaceObject.extname)(file));
|
|
3166
3177
|
const preference = {
|
|
3167
|
-
headed:
|
|
3168
|
-
keepWindow:
|
|
3169
|
-
testId: fileName
|
|
3178
|
+
headed: options?.headed,
|
|
3179
|
+
keepWindow: options?.keepWindow,
|
|
3180
|
+
testId: resolveTestId(options?.testId, clonedYamlScript.agent?.testId, fileName)
|
|
3170
3181
|
};
|
|
3171
|
-
const player = new yaml_namespaceObject.ScriptPlayer(
|
|
3182
|
+
const player = new yaml_namespaceObject.ScriptPlayer(clonedYamlScript, async ()=>{
|
|
3172
3183
|
const freeFn = [];
|
|
3173
|
-
const webTarget =
|
|
3184
|
+
const webTarget = clonedYamlScript.web || clonedYamlScript.target;
|
|
3174
3185
|
const targetCount = [
|
|
3175
3186
|
void 0 !== webTarget,
|
|
3176
|
-
void 0 !==
|
|
3177
|
-
void 0 !==
|
|
3178
|
-
void 0 !==
|
|
3187
|
+
void 0 !== clonedYamlScript.android,
|
|
3188
|
+
void 0 !== clonedYamlScript.ios,
|
|
3189
|
+
void 0 !== clonedYamlScript.interface
|
|
3179
3190
|
].filter(Boolean).length;
|
|
3180
3191
|
if (targetCount > 1) {
|
|
3181
3192
|
const specifiedTargets = [
|
|
3182
3193
|
void 0 !== webTarget ? 'web' : null,
|
|
3183
|
-
void 0 !==
|
|
3184
|
-
void 0 !==
|
|
3185
|
-
void 0 !==
|
|
3194
|
+
void 0 !== clonedYamlScript.android ? 'android' : null,
|
|
3195
|
+
void 0 !== clonedYamlScript.ios ? 'ios' : null,
|
|
3196
|
+
void 0 !== clonedYamlScript.interface ? 'interface' : null
|
|
3186
3197
|
].filter(Boolean);
|
|
3187
3198
|
throw new Error(`Only one target type can be specified, but found multiple: ${specifiedTargets.join(', ')}. Please specify only one of: web, android, ios, or interface.`);
|
|
3188
3199
|
}
|
|
3189
3200
|
if (void 0 !== webTarget) {
|
|
3190
|
-
|
|
3191
|
-
if (void 0 !== yamlScript.target) console.warn("target is deprecated, please use web instead. See https://midscenejs.com/automate-with-scripts-in-yaml for more information. Sorry for the inconvenience.");
|
|
3201
|
+
if (void 0 !== clonedYamlScript.target) console.warn("target is deprecated, please use web instead. See https://midscenejs.com/automate-with-scripts-in-yaml for more information. Sorry for the inconvenience.");
|
|
3192
3202
|
let localServer;
|
|
3193
3203
|
let urlToVisit;
|
|
3194
3204
|
if (webTarget.serve) {
|
|
@@ -3197,17 +3207,16 @@ var __webpack_modules__ = {
|
|
|
3197
3207
|
const serverAddress = localServer.server.address();
|
|
3198
3208
|
freeFn.push({
|
|
3199
3209
|
name: 'local_server',
|
|
3200
|
-
fn: ()=>
|
|
3210
|
+
fn: ()=>localServer?.server.close()
|
|
3201
3211
|
});
|
|
3202
|
-
urlToVisit = webTarget.url.startsWith('/') ? `http://${
|
|
3212
|
+
urlToVisit = webTarget.url.startsWith('/') ? `http://${serverAddress?.address}:${serverAddress?.port}${webTarget.url}` : `http://${serverAddress?.address}:${serverAddress?.port}/${webTarget.url}`;
|
|
3203
3213
|
webTarget.url = urlToVisit;
|
|
3204
3214
|
}
|
|
3205
3215
|
if (!webTarget.bridgeMode) {
|
|
3206
|
-
var _yamlScript_agent1;
|
|
3207
3216
|
const { agent, freeFn: newFreeFn } = await (0, puppeteer_agent_launcher_namespaceObject.puppeteerAgentForTarget)(webTarget, {
|
|
3208
3217
|
...preference,
|
|
3209
|
-
|
|
3210
|
-
},
|
|
3218
|
+
...buildAgentOptions(clonedYamlScript.agent, preference.testId, fileName)
|
|
3219
|
+
}, options?.browser);
|
|
3211
3220
|
freeFn.push(...newFreeFn);
|
|
3212
3221
|
return {
|
|
3213
3222
|
agent,
|
|
@@ -3215,10 +3224,10 @@ var __webpack_modules__ = {
|
|
|
3215
3224
|
};
|
|
3216
3225
|
}
|
|
3217
3226
|
external_node_assert_default()('newTabWithUrl' === webTarget.bridgeMode || 'currentTab' === webTarget.bridgeMode, `bridgeMode config value must be either "newTabWithUrl" or "currentTab", but got ${webTarget.bridgeMode}`);
|
|
3218
|
-
if (webTarget.userAgent || webTarget.viewportWidth || webTarget.viewportHeight || webTarget.viewportScale || webTarget.waitForNetworkIdle || webTarget.cookie) console.warn('puppeteer options (userAgent, viewportWidth, viewportHeight, viewportScale, waitForNetworkIdle, cookie) are not supported in bridge mode. They will be ignored.');
|
|
3227
|
+
if (webTarget.userAgent || webTarget.viewportWidth || webTarget.viewportHeight || webTarget.viewportScale || webTarget.waitForNetworkIdle || webTarget.cookie || webTarget.chromeArgs) console.warn('puppeteer options (userAgent, viewportWidth, viewportHeight, viewportScale, waitForNetworkIdle, cookie, chromeArgs) are not supported in bridge mode. They will be ignored.');
|
|
3219
3228
|
const agent = new bridge_mode_namespaceObject.AgentOverChromeBridge({
|
|
3220
3229
|
closeNewTabsAfterDisconnect: webTarget.closeNewTabsAfterDisconnect,
|
|
3221
|
-
|
|
3230
|
+
...buildAgentOptions(clonedYamlScript.agent, preference.testId, fileName)
|
|
3222
3231
|
});
|
|
3223
3232
|
if ('newTabWithUrl' === webTarget.bridgeMode) await agent.connectNewTabWithUrl(webTarget.url);
|
|
3224
3233
|
else {
|
|
@@ -3234,13 +3243,13 @@ var __webpack_modules__ = {
|
|
|
3234
3243
|
freeFn
|
|
3235
3244
|
};
|
|
3236
3245
|
}
|
|
3237
|
-
if (void 0 !==
|
|
3238
|
-
|
|
3239
|
-
const
|
|
3240
|
-
|
|
3241
|
-
|
|
3246
|
+
if (void 0 !== clonedYamlScript.android) {
|
|
3247
|
+
const androidTarget = clonedYamlScript.android;
|
|
3248
|
+
const agent = await (0, android_namespaceObject.agentFromAdbDevice)(androidTarget?.deviceId, {
|
|
3249
|
+
...androidTarget,
|
|
3250
|
+
...buildAgentOptions(clonedYamlScript.agent, preference.testId, fileName)
|
|
3242
3251
|
});
|
|
3243
|
-
if (
|
|
3252
|
+
if (androidTarget?.launch) await agent.launch(androidTarget.launch);
|
|
3244
3253
|
freeFn.push({
|
|
3245
3254
|
name: 'destroy_android_agent',
|
|
3246
3255
|
fn: ()=>agent.destroy()
|
|
@@ -3250,13 +3259,13 @@ var __webpack_modules__ = {
|
|
|
3250
3259
|
freeFn
|
|
3251
3260
|
};
|
|
3252
3261
|
}
|
|
3253
|
-
if (void 0 !==
|
|
3254
|
-
const iosTarget =
|
|
3262
|
+
if (void 0 !== clonedYamlScript.ios) {
|
|
3263
|
+
const iosTarget = clonedYamlScript.ios;
|
|
3255
3264
|
const agent = await (0, ios_namespaceObject.agentFromWebDriverAgent)({
|
|
3256
|
-
|
|
3257
|
-
|
|
3265
|
+
...iosTarget,
|
|
3266
|
+
...buildAgentOptions(clonedYamlScript.agent, preference.testId, fileName)
|
|
3258
3267
|
});
|
|
3259
|
-
if (
|
|
3268
|
+
if (iosTarget?.launch) await agent.launch(iosTarget.launch);
|
|
3260
3269
|
freeFn.push({
|
|
3261
3270
|
name: 'destroy_ios_agent',
|
|
3262
3271
|
fn: ()=>agent.destroy()
|
|
@@ -3266,9 +3275,8 @@ var __webpack_modules__ = {
|
|
|
3266
3275
|
freeFn
|
|
3267
3276
|
};
|
|
3268
3277
|
}
|
|
3269
|
-
if (void 0 !==
|
|
3270
|
-
|
|
3271
|
-
const interfaceTarget = yamlScript.interface;
|
|
3278
|
+
if (void 0 !== clonedYamlScript.interface) {
|
|
3279
|
+
const interfaceTarget = clonedYamlScript.interface;
|
|
3272
3280
|
const moduleSpecifier = interfaceTarget.module;
|
|
3273
3281
|
let finalModuleSpecifier;
|
|
3274
3282
|
if (moduleSpecifier.startsWith('./') || moduleSpecifier.startsWith('../') || external_node_path_default().isAbsolute(moduleSpecifier)) {
|
|
@@ -3281,10 +3289,7 @@ var __webpack_modules__ = {
|
|
|
3281
3289
|
debug('DeviceClass', DeviceClass, 'with param', interfaceTarget.param);
|
|
3282
3290
|
const device = new DeviceClass(interfaceTarget.param || {});
|
|
3283
3291
|
debug('creating agent from device', device);
|
|
3284
|
-
const agent = (0, agent_namespaceObject.createAgent)(device,
|
|
3285
|
-
...yamlScript.agent,
|
|
3286
|
-
cache: (0, utils_namespaceObject.processCacheConfig)(null == (_yamlScript_agent3 = yamlScript.agent) ? void 0 : _yamlScript_agent3.cache, fileName)
|
|
3287
|
-
});
|
|
3292
|
+
const agent = (0, agent_namespaceObject.createAgent)(device, buildAgentOptions(clonedYamlScript.agent, preference.testId, fileName));
|
|
3288
3293
|
freeFn.push({
|
|
3289
3294
|
name: 'destroy_general_interface_agent',
|
|
3290
3295
|
fn: ()=>{
|
|
@@ -3306,26 +3311,25 @@ var __webpack_modules__ = {
|
|
|
3306
3311
|
const printer_indent = ' ';
|
|
3307
3312
|
const spinnerInterval = 80;
|
|
3308
3313
|
const spinnerFrames = [
|
|
3309
|
-
|
|
3310
|
-
|
|
3311
|
-
|
|
3312
|
-
|
|
3314
|
+
'◰',
|
|
3315
|
+
'◳',
|
|
3316
|
+
'◲',
|
|
3317
|
+
'◱'
|
|
3313
3318
|
];
|
|
3314
3319
|
const currentSpinningFrame = ()=>spinnerFrames[Math.floor(Date.now() / spinnerInterval) % spinnerFrames.length];
|
|
3315
3320
|
function indicatorForStatus(status) {
|
|
3316
|
-
if ('init' === status) return source_default().gray(
|
|
3321
|
+
if ('init' === status) return source_default().gray('◌');
|
|
3317
3322
|
if ('running' === status) return source_default().yellowBright(currentSpinningFrame());
|
|
3318
|
-
if ('done' === status) return source_default().green(
|
|
3319
|
-
if ('error' === status) return source_default().red(
|
|
3323
|
+
if ('done' === status) return source_default().green('✔︎');
|
|
3324
|
+
if ('error' === status) return source_default().red('✘');
|
|
3320
3325
|
}
|
|
3321
3326
|
const contextInfo = (context)=>{
|
|
3322
|
-
var _context_player_errorInSetup, _context_player_errorInSetup1;
|
|
3323
3327
|
const filePath = context.file;
|
|
3324
3328
|
const filePathToShow = (0, external_node_path_namespaceObject.relative)(process.cwd(), filePath);
|
|
3325
3329
|
const fileNameToPrint = `${source_default().gray(`${filePathToShow}`)}`;
|
|
3326
3330
|
const fileStatusText = indicatorForStatus(context.player.status);
|
|
3327
3331
|
const contextActionText = void 0 === context.player.currentTaskIndex && 'running' === context.player.status ? source_default().gray('(navigating)') : '';
|
|
3328
|
-
const errorText = context.player.errorInSetup ? `\n${printer_indent}${source_default().red('error:')} ${
|
|
3332
|
+
const errorText = context.player.errorInSetup ? `\n${printer_indent}${source_default().red('error:')} ${context.player.errorInSetup?.message}\n${printer_indent}${printer_indent}${context.player.errorInSetup?.stack}` : '';
|
|
3329
3333
|
const outputFile = context.player.output;
|
|
3330
3334
|
const outputText = outputFile && Object.keys(context.player.result || {}).length > 0 ? `\n${printer_indent}${source_default().gray(`output: ${outputFile}`)}` : '';
|
|
3331
3335
|
const reportFile = context.player.reportFile;
|
|
@@ -3343,7 +3347,6 @@ var __webpack_modules__ = {
|
|
|
3343
3347
|
};
|
|
3344
3348
|
};
|
|
3345
3349
|
const singleTaskInfo = (task)=>{
|
|
3346
|
-
var _task_error;
|
|
3347
3350
|
let stepText = '';
|
|
3348
3351
|
if ('init' === task.status) stepText = '';
|
|
3349
3352
|
else if ('running' === task.status || 'error' === task.status) if (void 0 === task.currentStep) stepText = source_default().gray('(navigating)');
|
|
@@ -3351,7 +3354,7 @@ var __webpack_modules__ = {
|
|
|
3351
3354
|
const actionText = '';
|
|
3352
3355
|
stepText = source_default().gray(`(task ${task.currentStep + 1}/${task.totalSteps}${actionText})`.trim());
|
|
3353
3356
|
} else stepText = source_default().gray('(unknown task)');
|
|
3354
|
-
const errorText = 'error' === task.status ? `\n${printer_indent}${source_default().gray('error:')}\n${printer_indent}${printer_indent}${
|
|
3357
|
+
const errorText = 'error' === task.status ? `\n${printer_indent}${source_default().gray('error:')}\n${printer_indent}${printer_indent}${task.error?.message}` : '';
|
|
3355
3358
|
const statusText = indicatorForStatus(task.status);
|
|
3356
3359
|
const mergedLine = `${statusText} ${task.name} ${stepText}${errorText}`;
|
|
3357
3360
|
return {
|
|
@@ -3654,7 +3657,7 @@ var __webpack_modules__ = {
|
|
|
3654
3657
|
}
|
|
3655
3658
|
current.message += next.message;
|
|
3656
3659
|
}
|
|
3657
|
-
if (current) this.render(
|
|
3660
|
+
if (current) this.render(current?.message, current?.type);
|
|
3658
3661
|
}
|
|
3659
3662
|
render(message, type = 'output') {
|
|
3660
3663
|
if (this.finished) {
|
|
@@ -3689,7 +3692,7 @@ var __webpack_modules__ = {
|
|
|
3689
3692
|
type,
|
|
3690
3693
|
message: chunk.toString()
|
|
3691
3694
|
});
|
|
3692
|
-
|
|
3695
|
+
callback?.();
|
|
3693
3696
|
};
|
|
3694
3697
|
return function() {
|
|
3695
3698
|
stream.write = original;
|
|
@@ -3782,7 +3785,7 @@ var __webpack_modules__ = {
|
|
|
3782
3785
|
};
|
|
3783
3786
|
delete clonedFileConfig.target;
|
|
3784
3787
|
}
|
|
3785
|
-
if (
|
|
3788
|
+
if (globalConfig?.target) {
|
|
3786
3789
|
globalConfig.web = {
|
|
3787
3790
|
...globalConfig.target,
|
|
3788
3791
|
...globalConfig.web
|
|
@@ -3848,7 +3851,7 @@ var __webpack_modules__ = {
|
|
|
3848
3851
|
};
|
|
3849
3852
|
await this.executeConcurrently(fileContextList, executeFile, executedResults, notExecutedContexts);
|
|
3850
3853
|
if (!isTTY) {
|
|
3851
|
-
console.log(
|
|
3854
|
+
console.log('\n📋 Execution Results:');
|
|
3852
3855
|
for (const context of executedResults)console.log(contextTaskListSummary(context.player.taskStatusList, context));
|
|
3853
3856
|
}
|
|
3854
3857
|
} finally{
|
|
@@ -3896,9 +3899,8 @@ var __webpack_modules__ = {
|
|
|
3896
3899
|
async processResults(executedContexts, notExecutedContexts) {
|
|
3897
3900
|
const results = [];
|
|
3898
3901
|
for (const context of executedContexts){
|
|
3899
|
-
var _player_taskStatusList, _player_errorInSetup;
|
|
3900
3902
|
const { file, player, duration } = context;
|
|
3901
|
-
const hasFailedTasks =
|
|
3903
|
+
const hasFailedTasks = player.taskStatusList?.some((task)=>'error' === task.status) ?? false;
|
|
3902
3904
|
const hasPlayerError = 'error' === player.status;
|
|
3903
3905
|
let success;
|
|
3904
3906
|
let resultType;
|
|
@@ -3924,7 +3926,7 @@ var __webpack_modules__ = {
|
|
|
3924
3926
|
report: reportFile,
|
|
3925
3927
|
duration,
|
|
3926
3928
|
resultType,
|
|
3927
|
-
error:
|
|
3929
|
+
error: player.errorInSetup?.message || (hasPlayerError ? 'Execution failed' : void 0) || (hasFailedTasks ? 'Some tasks failed' : void 0)
|
|
3928
3930
|
});
|
|
3929
3931
|
}
|
|
3930
3932
|
for (const context of notExecutedContexts)results.push({
|
|
@@ -3949,7 +3951,7 @@ var __webpack_modules__ = {
|
|
|
3949
3951
|
printExecutionPlan() {
|
|
3950
3952
|
console.log(' Scripts:');
|
|
3951
3953
|
for (const file of this.config.files)console.log(` - ${file}`);
|
|
3952
|
-
console.log(
|
|
3954
|
+
console.log('📋 Execution plan');
|
|
3953
3955
|
console.log(` Concurrency: ${this.config.concurrent}`);
|
|
3954
3956
|
console.log(` Keep window: ${this.config.keepWindow}`);
|
|
3955
3957
|
console.log(` Headed: ${this.config.headed}`);
|
|
@@ -4027,7 +4029,7 @@ var __webpack_modules__ = {
|
|
|
4027
4029
|
printExecutionSummary() {
|
|
4028
4030
|
const summary = this.getExecutionSummary();
|
|
4029
4031
|
const success = 0 === summary.failed && 0 === summary.partialFailed && 0 === summary.notExecuted;
|
|
4030
|
-
console.log(
|
|
4032
|
+
console.log('\n📊 Execution Summary:');
|
|
4031
4033
|
console.log(` Total files: ${summary.total}`);
|
|
4032
4034
|
console.log(` Successful: ${summary.successful}`);
|
|
4033
4035
|
console.log(` Failed: ${summary.failed}`);
|
|
@@ -4036,31 +4038,31 @@ var __webpack_modules__ = {
|
|
|
4036
4038
|
console.log(` Duration: ${(summary.totalDuration / 1000).toFixed(2)}s`);
|
|
4037
4039
|
console.log(` Summary: ${this.getSummaryAbsolutePath()}`);
|
|
4038
4040
|
if (summary.successful > 0) {
|
|
4039
|
-
console.log(
|
|
4041
|
+
console.log('\n✅ Successful files:');
|
|
4040
4042
|
this.getSuccessfulFiles().forEach((file)=>{
|
|
4041
4043
|
console.log(` ${file}`);
|
|
4042
4044
|
});
|
|
4043
4045
|
}
|
|
4044
4046
|
if (summary.failed > 0) {
|
|
4045
|
-
console.log(
|
|
4047
|
+
console.log('\n❌ Failed files');
|
|
4046
4048
|
this.getFailedFiles().forEach((file)=>{
|
|
4047
4049
|
console.log(` ${file}`);
|
|
4048
4050
|
});
|
|
4049
4051
|
}
|
|
4050
4052
|
if (summary.partialFailed > 0) {
|
|
4051
|
-
console.log(
|
|
4053
|
+
console.log('\n⚠️ Partial failed files (some tasks failed with continueOnError)');
|
|
4052
4054
|
this.getPartialFailedFiles().forEach((file)=>{
|
|
4053
4055
|
console.log(` ${file}`);
|
|
4054
4056
|
});
|
|
4055
4057
|
}
|
|
4056
4058
|
if (summary.notExecuted > 0) {
|
|
4057
|
-
console.log(
|
|
4059
|
+
console.log('\n⏸️ Not executed files');
|
|
4058
4060
|
this.getNotExecutedFiles().forEach((file)=>{
|
|
4059
4061
|
console.log(` ${file}`);
|
|
4060
4062
|
});
|
|
4061
4063
|
}
|
|
4062
|
-
if (success) console.log(
|
|
4063
|
-
else console.log(
|
|
4064
|
+
if (success) console.log('\n🎉 All files executed successfully!');
|
|
4065
|
+
else console.log('\n⚠️ Some files failed or were not executed.');
|
|
4064
4066
|
return success;
|
|
4065
4067
|
}
|
|
4066
4068
|
constructor(config){
|
|
@@ -11738,15 +11740,11 @@ var __webpack_modules__ = {
|
|
|
11738
11740
|
};
|
|
11739
11741
|
async function expandFilePatterns(patterns, basePath) {
|
|
11740
11742
|
const allFiles = [];
|
|
11741
|
-
const seenFiles = new Set();
|
|
11742
11743
|
for (const pattern of patterns)try {
|
|
11743
11744
|
const yamlFiles = await matchYamlFiles(pattern, {
|
|
11744
11745
|
cwd: basePath
|
|
11745
11746
|
});
|
|
11746
|
-
for (const file of yamlFiles)
|
|
11747
|
-
seenFiles.add(file);
|
|
11748
|
-
allFiles.push(file);
|
|
11749
|
-
}
|
|
11747
|
+
for (const file of yamlFiles)allFiles.push(file);
|
|
11750
11748
|
} catch (error) {
|
|
11751
11749
|
console.warn(`Warning: Failed to expand pattern "${pattern}":`, error);
|
|
11752
11750
|
}
|
|
@@ -11762,8 +11760,8 @@ var __webpack_modules__ = {
|
|
|
11762
11760
|
} catch (error) {
|
|
11763
11761
|
throw new Error(`Failed to parse config YAML: ${error}`);
|
|
11764
11762
|
}
|
|
11765
|
-
if (!
|
|
11766
|
-
const files = await expandFilePatterns(
|
|
11763
|
+
if (!configYaml?.files || !Array.isArray(configYaml?.files)) throw new Error('Config YAML must contain a "files" array');
|
|
11764
|
+
const files = await expandFilePatterns(configYaml?.files, basePath);
|
|
11767
11765
|
if (0 === files.length) throw new Error('No YAML files found matching the patterns in "files"');
|
|
11768
11766
|
const configFileName = (0, external_node_path_namespaceObject.basename)(configYamlPath, (0, external_node_path_namespaceObject.extname)(configYamlPath));
|
|
11769
11767
|
const timestamp = Date.now();
|
|
@@ -11793,23 +11791,23 @@ var __webpack_modules__ = {
|
|
|
11793
11791
|
ios: parsedConfig.ios,
|
|
11794
11792
|
target: parsedConfig.target
|
|
11795
11793
|
}, {
|
|
11796
|
-
web:
|
|
11797
|
-
android:
|
|
11798
|
-
ios:
|
|
11794
|
+
web: options?.web,
|
|
11795
|
+
android: options?.android,
|
|
11796
|
+
ios: options?.ios
|
|
11799
11797
|
});
|
|
11800
|
-
const keepWindow =
|
|
11801
|
-
const headed =
|
|
11798
|
+
const keepWindow = options?.keepWindow ?? parsedConfig.keepWindow;
|
|
11799
|
+
const headed = options?.headed ?? parsedConfig.headed;
|
|
11802
11800
|
const finalHeaded = keepWindow || headed;
|
|
11803
11801
|
return {
|
|
11804
11802
|
files: parsedConfig.files,
|
|
11805
|
-
concurrent:
|
|
11806
|
-
continueOnError:
|
|
11807
|
-
summary:
|
|
11808
|
-
shareBrowserContext:
|
|
11803
|
+
concurrent: options?.concurrent ?? parsedConfig.concurrent,
|
|
11804
|
+
continueOnError: options?.continueOnError ?? parsedConfig.continueOnError,
|
|
11805
|
+
summary: options?.summary ?? parsedConfig.summary,
|
|
11806
|
+
shareBrowserContext: options?.shareBrowserContext ?? parsedConfig.shareBrowserContext,
|
|
11809
11807
|
headed: finalHeaded,
|
|
11810
11808
|
keepWindow: keepWindow,
|
|
11811
|
-
dotenvOverride:
|
|
11812
|
-
dotenvDebug:
|
|
11809
|
+
dotenvOverride: options?.dotenvOverride ?? parsedConfig.dotenvOverride,
|
|
11810
|
+
dotenvDebug: options?.dotenvDebug ?? parsedConfig.dotenvDebug,
|
|
11813
11811
|
globalConfig
|
|
11814
11812
|
};
|
|
11815
11813
|
}
|
|
@@ -11838,8 +11836,16 @@ var __webpack_modules__ = {
|
|
|
11838
11836
|
};
|
|
11839
11837
|
}
|
|
11840
11838
|
const cli_utils_debug = (0, logger_namespaceObject.getDebug)('midscene:cli');
|
|
11839
|
+
function kebabToCamel(str) {
|
|
11840
|
+
return str.replace(/-([a-z])/g, (_, letter)=>letter.toUpperCase());
|
|
11841
|
+
}
|
|
11842
|
+
function camelToKebab(str) {
|
|
11843
|
+
return str.replace(/[A-Z]/g, (letter)=>`-${letter.toLowerCase()}`).replace(/^-/, '');
|
|
11844
|
+
}
|
|
11841
11845
|
const parseProcessArgs = async ()=>{
|
|
11842
|
-
const args = yargs(hideBin(process.argv)).
|
|
11846
|
+
const args = yargs(hideBin(process.argv)).parserConfiguration({
|
|
11847
|
+
'dot-notation': true
|
|
11848
|
+
}).usage(`Midscene.js helps you automate browser actions, assertions, and data extraction by AI.
|
|
11843
11849
|
Homepage: https://midscenejs.com
|
|
11844
11850
|
Github: https://github.com/web-infra-dev/midscene
|
|
11845
11851
|
|
|
@@ -11887,76 +11893,34 @@ Usage:
|
|
|
11887
11893
|
'dotenv-debug': {
|
|
11888
11894
|
type: 'boolean',
|
|
11889
11895
|
description: `Turn on logging to help debug why certain keys or values are not being set as you expect, default is ${config_factory_defaultConfig.dotenvDebug}`
|
|
11890
|
-
},
|
|
11891
|
-
'web.user-agent': {
|
|
11892
|
-
alias: 'web.userAgent',
|
|
11893
|
-
type: 'string',
|
|
11894
|
-
description: 'Override user agent for web environments.'
|
|
11895
|
-
},
|
|
11896
|
-
'web.viewport-width': {
|
|
11897
|
-
alias: 'web.viewportWidth',
|
|
11898
|
-
type: 'number',
|
|
11899
|
-
description: 'Override viewport width for web environments.'
|
|
11900
|
-
},
|
|
11901
|
-
'web.viewport-height': {
|
|
11902
|
-
alias: 'web.viewportHeight',
|
|
11903
|
-
type: 'number',
|
|
11904
|
-
description: 'Override viewport height for web environments.'
|
|
11905
|
-
},
|
|
11906
|
-
'android.device-id': {
|
|
11907
|
-
alias: 'android.deviceId',
|
|
11908
|
-
type: 'string',
|
|
11909
|
-
description: 'Override device ID for Android environments.'
|
|
11910
|
-
},
|
|
11911
|
-
'ios.device-id': {
|
|
11912
|
-
alias: 'ios.deviceId',
|
|
11913
|
-
type: 'string',
|
|
11914
|
-
description: 'Override device ID for iOS environments.'
|
|
11915
|
-
},
|
|
11916
|
-
'ios.wda-port': {
|
|
11917
|
-
alias: 'ios.wdaPort',
|
|
11918
|
-
type: 'number',
|
|
11919
|
-
description: 'Override WebDriverAgent port for iOS environments.'
|
|
11920
|
-
},
|
|
11921
|
-
'ios.wda-host': {
|
|
11922
|
-
alias: 'ios.wdaHost',
|
|
11923
|
-
type: 'string',
|
|
11924
|
-
description: 'Override WebDriverAgent host for iOS environments.'
|
|
11925
11896
|
}
|
|
11926
|
-
}).version('version', 'Show version number', "0.
|
|
11897
|
+
}).version('version', 'Show version number', "1.0.0").help().epilogue(`For complete list of configuration options, please visit:
|
|
11898
|
+
• Web options: https://midscenejs.com/automate-with-scripts-in-yaml#the-web-part
|
|
11899
|
+
• Android options: https://midscenejs.com/automate-with-scripts-in-yaml#the-android-part
|
|
11900
|
+
• iOS options: https://midscenejs.com/automate-with-scripts-in-yaml#the-ios-part
|
|
11901
|
+
|
|
11902
|
+
Examples:
|
|
11903
|
+
$0 script.yaml --web.user-agent "Custom Agent" --web.viewport-width 1920
|
|
11904
|
+
$0 script.yaml --android.device-id emulator-5554 --android.ime-strategy yadb-for-non-ascii
|
|
11905
|
+
$0 script.yaml --ios.wda-port 8100 --ios.auto-dismiss-keyboard`).wrap(yargs().terminalWidth());
|
|
11927
11906
|
const argv = await args.argv;
|
|
11928
11907
|
cli_utils_debug('argv', argv);
|
|
11929
11908
|
const transformedArgv = {
|
|
11930
11909
|
...argv
|
|
11931
11910
|
};
|
|
11932
|
-
|
|
11933
|
-
|
|
11934
|
-
|
|
11935
|
-
|
|
11936
|
-
|
|
11937
|
-
|
|
11938
|
-
|
|
11939
|
-
|
|
11940
|
-
|
|
11941
|
-
|
|
11942
|
-
|
|
11943
|
-
|
|
11944
|
-
if (argv
|
|
11945
|
-
transformedArgv.android = transformedArgv.android || {};
|
|
11946
|
-
transformedArgv.android.deviceId = argv['android.device-id'];
|
|
11947
|
-
}
|
|
11948
|
-
if (argv['ios.device-id']) {
|
|
11949
|
-
transformedArgv.ios = transformedArgv.ios || {};
|
|
11950
|
-
transformedArgv.ios.deviceId = argv['ios.device-id'];
|
|
11951
|
-
}
|
|
11952
|
-
if (argv['ios.wda-port']) {
|
|
11953
|
-
transformedArgv.ios = transformedArgv.ios || {};
|
|
11954
|
-
transformedArgv.ios.wdaPort = argv['ios.wda-port'];
|
|
11955
|
-
}
|
|
11956
|
-
if (argv['ios.wda-host']) {
|
|
11957
|
-
transformedArgv.ios = transformedArgv.ios || {};
|
|
11958
|
-
transformedArgv.ios.wdaHost = argv['ios.wda-host'];
|
|
11959
|
-
}
|
|
11911
|
+
const ensureBothFormats = (obj)=>{
|
|
11912
|
+
const result = {};
|
|
11913
|
+
Object.keys(obj).forEach((key)=>{
|
|
11914
|
+
const camelKey = kebabToCamel(key);
|
|
11915
|
+
const kebabKey = camelToKebab(key);
|
|
11916
|
+
result[kebabKey] = obj[key];
|
|
11917
|
+
result[camelKey] = obj[key];
|
|
11918
|
+
});
|
|
11919
|
+
return result;
|
|
11920
|
+
};
|
|
11921
|
+
if (argv.web && 'object' == typeof argv.web) transformedArgv.web = ensureBothFormats(argv.web);
|
|
11922
|
+
if (argv.android && 'object' == typeof argv.android) transformedArgv.android = ensureBothFormats(argv.android);
|
|
11923
|
+
if (argv.ios && 'object' == typeof argv.ios) transformedArgv.ios = ensureBothFormats(argv.ios);
|
|
11960
11924
|
return {
|
|
11961
11925
|
path: argv._[0],
|
|
11962
11926
|
files: argv.files,
|
|
@@ -11980,7 +11944,7 @@ Usage:
|
|
|
11980
11944
|
}
|
|
11981
11945
|
Promise.resolve((async ()=>{
|
|
11982
11946
|
const { options, path, files: cmdFiles } = await parseProcessArgs();
|
|
11983
|
-
const welcome = `\nWelcome to @midscene/cli v${package_namespaceObject.
|
|
11947
|
+
const welcome = `\nWelcome to @midscene/cli v${package_namespaceObject.rE}\n`;
|
|
11984
11948
|
console.log(welcome);
|
|
11985
11949
|
if (options.url) {
|
|
11986
11950
|
console.error("the cli mode is no longer supported, please use yaml file instead. See https://midscenejs.com/automate-with-scripts-in-yaml for more information. Sorry for the inconvenience.");
|
|
@@ -12048,35 +12012,35 @@ Usage:
|
|
|
12048
12012
|
process.exit(1);
|
|
12049
12013
|
}));
|
|
12050
12014
|
},
|
|
12051
|
-
assert
|
|
12015
|
+
assert (module) {
|
|
12052
12016
|
"use strict";
|
|
12053
12017
|
module.exports = require("assert");
|
|
12054
12018
|
},
|
|
12055
|
-
crypto
|
|
12019
|
+
crypto (module) {
|
|
12056
12020
|
"use strict";
|
|
12057
12021
|
module.exports = require("crypto");
|
|
12058
12022
|
},
|
|
12059
|
-
fs
|
|
12023
|
+
fs (module) {
|
|
12060
12024
|
"use strict";
|
|
12061
12025
|
module.exports = require("fs");
|
|
12062
12026
|
},
|
|
12063
|
-
os
|
|
12027
|
+
os (module) {
|
|
12064
12028
|
"use strict";
|
|
12065
12029
|
module.exports = require("os");
|
|
12066
12030
|
},
|
|
12067
|
-
path
|
|
12031
|
+
path (module) {
|
|
12068
12032
|
"use strict";
|
|
12069
12033
|
module.exports = require("path");
|
|
12070
12034
|
},
|
|
12071
|
-
tty
|
|
12035
|
+
tty (module) {
|
|
12072
12036
|
"use strict";
|
|
12073
12037
|
module.exports = require("tty");
|
|
12074
12038
|
},
|
|
12075
|
-
util
|
|
12039
|
+
util (module) {
|
|
12076
12040
|
"use strict";
|
|
12077
12041
|
module.exports = require("util");
|
|
12078
12042
|
},
|
|
12079
|
-
"../../node_modules/.pnpm/cliui@8.0.1/node_modules/cliui/build/index.cjs"
|
|
12043
|
+
"../../node_modules/.pnpm/cliui@8.0.1/node_modules/cliui/build/index.cjs" (module, __unused_rspack_exports, __webpack_require__) {
|
|
12080
12044
|
"use strict";
|
|
12081
12045
|
const align = {
|
|
12082
12046
|
right: alignRight,
|
|
@@ -12297,7 +12261,7 @@ Usage:
|
|
|
12297
12261
|
}
|
|
12298
12262
|
module.exports = ui;
|
|
12299
12263
|
},
|
|
12300
|
-
"../../node_modules/.pnpm/y18n@5.0.8/node_modules/y18n/build/index.cjs"
|
|
12264
|
+
"../../node_modules/.pnpm/y18n@5.0.8/node_modules/y18n/build/index.cjs" (module, __unused_rspack_exports, __webpack_require__) {
|
|
12301
12265
|
"use strict";
|
|
12302
12266
|
var fs = __webpack_require__("fs");
|
|
12303
12267
|
var util = __webpack_require__("util");
|
|
@@ -12455,7 +12419,7 @@ Usage:
|
|
|
12455
12419
|
const y18n = (opts)=>y18n$1(opts, nodePlatformShim);
|
|
12456
12420
|
module.exports = y18n;
|
|
12457
12421
|
},
|
|
12458
|
-
"../../node_modules/.pnpm/yargs-parser@21.1.1/node_modules/yargs-parser/build/index.cjs"
|
|
12422
|
+
"../../node_modules/.pnpm/yargs-parser@21.1.1/node_modules/yargs-parser/build/index.cjs" (module, __unused_rspack_exports, __webpack_require__) {
|
|
12459
12423
|
"use strict";
|
|
12460
12424
|
var util = __webpack_require__("util");
|
|
12461
12425
|
var path = __webpack_require__("path");
|
|
@@ -13264,7 +13228,7 @@ Usage:
|
|
|
13264
13228
|
yargsParser.looksLikeNumber = looksLikeNumber;
|
|
13265
13229
|
module.exports = yargsParser;
|
|
13266
13230
|
},
|
|
13267
|
-
"../../node_modules/.pnpm/yargs@17.7.2/node_modules/yargs/build/index.cjs"
|
|
13231
|
+
"../../node_modules/.pnpm/yargs@17.7.2/node_modules/yargs/build/index.cjs" (module, __unused_rspack_exports, __webpack_require__) {
|
|
13268
13232
|
"use strict";
|
|
13269
13233
|
var t1 = __webpack_require__("assert");
|
|
13270
13234
|
class e1 extends Error {
|
|
@@ -15349,7 +15313,7 @@ Usage:
|
|
|
15349
15313
|
};
|
|
15350
15314
|
module.exports = ue;
|
|
15351
15315
|
},
|
|
15352
|
-
"../../node_modules/.pnpm/dotenv@16.4.5/node_modules/dotenv/package.json"
|
|
15316
|
+
"../../node_modules/.pnpm/dotenv@16.4.5/node_modules/dotenv/package.json" (module) {
|
|
15353
15317
|
"use strict";
|
|
15354
15318
|
module.exports = JSON.parse('{"name":"dotenv","version":"16.4.5","description":"Loads environment variables from .env file","main":"lib/main.js","types":"lib/main.d.ts","exports":{".":{"types":"./lib/main.d.ts","require":"./lib/main.js","default":"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},"scripts":{"dts-check":"tsc --project tests/types/tsconfig.json","lint":"standard","lint-readme":"standard-markdown","pretest":"npm run lint && npm run dts-check","test":"tap tests/*.js --100 -Rspec","test:coverage":"tap --coverage-report=lcov","prerelease":"npm test","release":"standard-version"},"repository":{"type":"git","url":"git://github.com/motdotla/dotenv.git"},"funding":"https://dotenvx.com","keywords":["dotenv","env",".env","environment","variables","config","settings"],"readmeFilename":"README.md","license":"BSD-2-Clause","devDependencies":{"@definitelytyped/dtslint":"^0.0.133","@types/node":"^18.11.3","decache":"^4.6.1","sinon":"^14.0.1","standard":"^17.0.0","standard-markdown":"^7.1.0","standard-version":"^9.5.0","tap":"^16.3.0","tar":"^6.1.11","typescript":"^4.8.4"},"engines":{"node":">=12"},"browser":{"fs":false}}');
|
|
15355
15319
|
}
|
|
@@ -15396,7 +15360,7 @@ __webpack_require__.c = __webpack_module_cache__;
|
|
|
15396
15360
|
getProto([]),
|
|
15397
15361
|
getProto(getProto)
|
|
15398
15362
|
];
|
|
15399
|
-
for(var current = 2 & mode && value; 'object' == typeof current && !~leafPrototypes.indexOf(current); current = getProto(current))Object.getOwnPropertyNames(current).forEach((key)=>{
|
|
15363
|
+
for(var current = 2 & mode && value; ('object' == typeof current || 'function' == typeof current) && !~leafPrototypes.indexOf(current); current = getProto(current))Object.getOwnPropertyNames(current).forEach((key)=>{
|
|
15400
15364
|
def[key] = ()=>value[key];
|
|
15401
15365
|
});
|
|
15402
15366
|
def['default'] = ()=>value;
|
|
@@ -15433,7 +15397,7 @@ __webpack_require__.c = __webpack_module_cache__;
|
|
|
15433
15397
|
};
|
|
15434
15398
|
})();
|
|
15435
15399
|
var __webpack_exports__ = __webpack_require__(__webpack_require__.s = "./src/index.ts");
|
|
15436
|
-
for(var
|
|
15400
|
+
for(var __rspack_i in __webpack_exports__)exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
15437
15401
|
Object.defineProperty(exports, '__esModule', {
|
|
15438
15402
|
value: true
|
|
15439
15403
|
});
|