@modern-js/utils 2.69.7 → 3.0.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/cli/alias.js +76 -70
- package/dist/cjs/cli/applyOptionsChain.js +44 -45
- package/dist/cjs/cli/babel.js +100 -119
- package/dist/cjs/cli/commands.js +61 -59
- package/dist/cjs/cli/common.js +45 -37
- package/dist/cjs/cli/config.js +36 -30
- package/dist/cjs/cli/constants.js +124 -161
- package/dist/cjs/cli/ensure.js +52 -45
- package/dist/cjs/cli/fs.js +41 -38
- package/dist/cjs/cli/get/config.js +43 -38
- package/dist/cjs/cli/get/data.js +108 -125
- package/dist/cjs/cli/get/index.js +109 -58
- package/dist/cjs/cli/index.js +202 -63
- package/dist/cjs/cli/is/config.js +75 -71
- package/dist/cjs/cli/is/env.js +49 -37
- package/dist/cjs/cli/is/index.js +76 -25
- package/dist/cjs/cli/is/project.js +139 -135
- package/dist/cjs/cli/is/type.js +65 -49
- package/dist/cjs/cli/logger.js +36 -27
- package/dist/cjs/cli/monorepo.js +100 -96
- package/dist/cjs/cli/package.js +85 -82
- package/dist/cjs/cli/path.js +101 -82
- package/dist/cjs/cli/port.js +71 -74
- package/dist/cjs/cli/prettyInstructions.js +106 -116
- package/dist/cjs/cli/require.js +116 -136
- package/dist/cjs/cli/route.js +67 -77
- package/dist/cjs/cli/runtimeExports.js +16 -70
- package/dist/cjs/cli/version.js +53 -42
- package/dist/cjs/cli/watch.js +79 -72
- package/dist/cjs/compiled.js +199 -128
- package/dist/cjs/import.js +58 -33
- package/dist/cjs/index.js +69 -23
- package/dist/cjs/universal/constants.js +77 -67
- package/dist/cjs/universal/index.js +33 -25
- package/dist/cjs/universal/path.js +33 -27
- package/dist/cjs/universal/pluginDagSort.js +69 -68
- package/dist/compiled/address/index.js +171 -1
- package/dist/compiled/browserslist/index.js +1329 -1
- package/dist/compiled/chalk/index.js +2368 -1
- package/dist/compiled/chokidar/index.js +4138 -16
- package/dist/compiled/chokidar/index.js.LICENSE.txt +41 -0
- package/dist/compiled/commander/index.js +1540 -1
- package/dist/compiled/debug/index.js +621 -1
- package/dist/compiled/dotenv/index.js +101 -1
- package/dist/compiled/dotenv-expand/index.js +54 -1
- package/dist/compiled/execa/index.js +1738 -1
- package/dist/compiled/fast-glob/index.js +4645 -17
- package/dist/compiled/fast-glob/index.js.LICENSE.txt +38 -0
- package/dist/compiled/filesize/index.js +193 -4
- package/dist/compiled/filesize/index.js.LICENSE.txt +7 -0
- package/dist/compiled/fs-extra/index.js +2222 -1
- package/dist/compiled/glob/index.js +2011 -1
- package/dist/compiled/globby/index.js +690 -1
- package/dist/compiled/gzip-size/index.js +157 -1
- package/dist/compiled/import-lazy/index.js +45 -1
- package/dist/compiled/inquirer/index.js +20162 -4
- package/dist/compiled/inquirer/index.js.LICENSE.txt +7 -0
- package/dist/compiled/js-yaml/index.js +2188 -1
- package/dist/compiled/json5/index.js +983 -1
- package/dist/compiled/lodash/index.js +0 -4
- package/dist/compiled/mime-types/index.js +108 -6
- package/dist/compiled/mime-types/index.js.LICENSE.txt +13 -0
- package/dist/compiled/minimist/index.js +202 -1
- package/dist/compiled/nanoid/index.js +83 -1
- package/dist/compiled/ora/index.js +3936 -3
- package/dist/compiled/ora/index.js.LICENSE.txt +1 -0
- package/dist/compiled/pkg-up/index.js +177 -1
- package/dist/compiled/semver/index.js +1779 -1
- package/dist/compiled/signale/index.js +1704 -1
- package/dist/compiled/slash/index.js +32 -1
- package/dist/compiled/strip-ansi/index.js +34 -1
- package/dist/compiled/tsconfig-paths/index.js +629 -1
- package/dist/compiled/upath/index.js +135 -1
- package/dist/compiled/url-join/index.js +61 -1
- package/dist/compiled/webpack-chain/index.js +1475 -1
- package/dist/esm/cli/alias.mjs +31 -0
- package/dist/esm/cli/applyOptionsChain.mjs +16 -0
- package/dist/esm/cli/babel.mjs +76 -0
- package/dist/esm/cli/commands.mjs +23 -0
- package/dist/esm/cli/common.mjs +11 -0
- package/dist/esm/cli/config.mjs +5 -0
- package/dist/esm/cli/constants.mjs +29 -0
- package/dist/esm/cli/ensure.mjs +9 -0
- package/dist/esm/cli/fs.mjs +9 -0
- package/dist/esm/cli/get/config.mjs +14 -0
- package/dist/esm/cli/get/data.mjs +57 -0
- package/dist/esm/cli/get/index.mjs +18 -0
- package/dist/{esm-node/cli/index.js → esm/cli/index.mjs} +0 -1
- package/dist/esm/cli/is/config.mjs +34 -0
- package/dist/esm/cli/is/env.mjs +6 -0
- package/dist/esm/cli/is/project.mjs +104 -0
- package/dist/esm/cli/is/type.mjs +26 -0
- package/dist/esm/cli/logger.mjs +2 -0
- package/dist/esm/cli/monorepo.mjs +50 -0
- package/dist/esm/cli/package.mjs +51 -0
- package/dist/esm/cli/path.mjs +35 -0
- package/dist/esm/cli/port.mjs +35 -0
- package/dist/esm/cli/prettyInstructions.mjs +68 -0
- package/dist/esm/cli/require.mjs +79 -0
- package/dist/esm/cli/route.mjs +36 -0
- package/dist/esm/cli/runtimeExports.mjs +0 -0
- package/dist/esm/cli/version.mjs +21 -0
- package/dist/esm/cli/watch.mjs +40 -0
- package/dist/esm/compiled.mjs +115 -0
- package/dist/esm/import.mjs +25 -0
- package/dist/esm/universal/constants.mjs +13 -0
- package/dist/{esm-node/universal/index.js → esm/universal/index.mjs} +1 -3
- package/dist/esm/universal/path.mjs +2 -0
- package/dist/esm/universal/pluginDagSort.mjs +41 -0
- package/dist/esm-node/cli/alias.mjs +31 -0
- package/dist/esm-node/cli/applyOptionsChain.mjs +16 -0
- package/dist/esm-node/cli/babel.mjs +76 -0
- package/dist/esm-node/cli/commands.mjs +23 -0
- package/dist/esm-node/cli/common.mjs +11 -0
- package/dist/esm-node/cli/config.mjs +5 -0
- package/dist/esm-node/cli/constants.mjs +29 -0
- package/dist/esm-node/cli/ensure.mjs +9 -0
- package/dist/esm-node/cli/fs.mjs +9 -0
- package/dist/esm-node/cli/get/config.mjs +14 -0
- package/dist/esm-node/cli/get/data.mjs +57 -0
- package/dist/esm-node/cli/get/index.mjs +18 -0
- package/dist/esm-node/cli/index.mjs +22 -0
- package/dist/esm-node/cli/is/config.mjs +34 -0
- package/dist/esm-node/cli/is/env.mjs +6 -0
- package/dist/esm-node/cli/is/index.mjs +4 -0
- package/dist/esm-node/cli/is/project.mjs +104 -0
- package/dist/esm-node/cli/is/type.mjs +26 -0
- package/dist/esm-node/cli/logger.mjs +2 -0
- package/dist/esm-node/cli/monorepo.mjs +50 -0
- package/dist/esm-node/cli/package.mjs +51 -0
- package/dist/esm-node/cli/path.mjs +35 -0
- package/dist/esm-node/cli/port.mjs +35 -0
- package/dist/esm-node/cli/prettyInstructions.mjs +68 -0
- package/dist/esm-node/cli/require.mjs +79 -0
- package/dist/esm-node/cli/route.mjs +36 -0
- package/dist/esm-node/cli/runtimeExports.mjs +0 -0
- package/dist/esm-node/cli/version.mjs +21 -0
- package/dist/esm-node/cli/watch.mjs +40 -0
- package/dist/esm-node/compiled.mjs +115 -0
- package/dist/esm-node/import.mjs +25 -0
- package/dist/esm-node/index.mjs +3 -0
- package/dist/esm-node/universal/constants.mjs +13 -0
- package/dist/esm-node/universal/index.mjs +2 -0
- package/dist/esm-node/universal/path.mjs +2 -0
- package/dist/esm-node/universal/pluginDagSort.mjs +41 -0
- package/dist/types/cli/constants.d.ts +2 -26
- package/dist/types/cli/get/data.d.ts +0 -1
- package/dist/types/cli/index.d.ts +0 -1
- package/dist/types/cli/is/config.d.ts +1 -1
- package/dist/types/cli/runtimeExports.d.ts +1 -4
- package/dist/types/cli/watch.d.ts +1 -1
- package/dist/types/compiled.d.ts +0 -5
- package/dist/types/universal/constants.d.ts +4 -7
- package/package.json +27 -27
- package/rslib.config.mts +140 -0
- package/dist/cjs/cli/action.js +0 -55
- package/dist/cjs/universal/formatWebpack.js +0 -127
- package/dist/esm/cli/action.js +0 -68
- package/dist/esm/cli/alias.js +0 -43
- package/dist/esm/cli/applyOptionsChain.js +0 -29
- package/dist/esm/cli/babel.js +0 -122
- package/dist/esm/cli/commands.js +0 -39
- package/dist/esm/cli/common.js +0 -20
- package/dist/esm/cli/config.js +0 -11
- package/dist/esm/cli/constants.js +0 -114
- package/dist/esm/cli/ensure.js +0 -16
- package/dist/esm/cli/fs.js +0 -65
- package/dist/esm/cli/get/config.js +0 -19
- package/dist/esm/cli/get/data.js +0 -143
- package/dist/esm/cli/get/index.js +0 -38
- package/dist/esm/cli/index.js +0 -23
- package/dist/esm/cli/is/config.js +0 -70
- package/dist/esm/cli/is/env.js +0 -22
- package/dist/esm/cli/is/index.js +0 -4
- package/dist/esm/cli/is/project.js +0 -146
- package/dist/esm/cli/is/type.js +0 -39
- package/dist/esm/cli/logger.js +0 -5
- package/dist/esm/cli/monorepo.js +0 -82
- package/dist/esm/cli/package.js +0 -203
- package/dist/esm/cli/path.js +0 -66
- package/dist/esm/cli/port.js +0 -97
- package/dist/esm/cli/prettyInstructions.js +0 -102
- package/dist/esm/cli/require.js +0 -235
- package/dist/esm/cli/route.js +0 -64
- package/dist/esm/cli/runtimeExports.js +0 -44
- package/dist/esm/cli/version.js +0 -26
- package/dist/esm/cli/watch.js +0 -112
- package/dist/esm/compiled.js +0 -66
- package/dist/esm/import.js +0 -11
- package/dist/esm/index.js +0 -3
- package/dist/esm/universal/constants.js +0 -32
- package/dist/esm/universal/formatWebpack.js +0 -95
- package/dist/esm/universal/index.js +0 -4
- package/dist/esm/universal/path.js +0 -6
- package/dist/esm/universal/pluginDagSort.js +0 -73
- package/dist/esm-node/cli/action.js +0 -30
- package/dist/esm-node/cli/alias.js +0 -40
- package/dist/esm-node/cli/applyOptionsChain.js +0 -27
- package/dist/esm-node/cli/babel.js +0 -107
- package/dist/esm-node/cli/commands.js +0 -39
- package/dist/esm-node/cli/common.js +0 -15
- package/dist/esm-node/cli/config.js +0 -9
- package/dist/esm-node/cli/constants.js +0 -114
- package/dist/esm-node/cli/ensure.js +0 -14
- package/dist/esm-node/cli/fs.js +0 -18
- package/dist/esm-node/cli/get/config.js +0 -19
- package/dist/esm-node/cli/get/data.js +0 -96
- package/dist/esm-node/cli/get/index.js +0 -22
- package/dist/esm-node/cli/is/config.js +0 -50
- package/dist/esm-node/cli/is/env.js +0 -12
- package/dist/esm-node/cli/is/project.js +0 -105
- package/dist/esm-node/cli/is/type.js +0 -36
- package/dist/esm-node/cli/logger.js +0 -5
- package/dist/esm-node/cli/monorepo.js +0 -67
- package/dist/esm-node/cli/package.js +0 -66
- package/dist/esm-node/cli/path.js +0 -48
- package/dist/esm-node/cli/port.js +0 -48
- package/dist/esm-node/cli/prettyInstructions.js +0 -90
- package/dist/esm-node/cli/require.js +0 -111
- package/dist/esm-node/cli/route.js +0 -60
- package/dist/esm-node/cli/runtimeExports.js +0 -38
- package/dist/esm-node/cli/version.js +0 -26
- package/dist/esm-node/cli/watch.js +0 -45
- package/dist/esm-node/compiled.js +0 -66
- package/dist/esm-node/import.js +0 -11
- package/dist/esm-node/universal/constants.js +0 -32
- package/dist/esm-node/universal/formatWebpack.js +0 -102
- package/dist/esm-node/universal/path.js +0 -6
- package/dist/esm-node/universal/pluginDagSort.js +0 -50
- package/dist/types/cli/action.d.ts +0 -2
- package/dist/types/universal/formatWebpack.d.ts +0 -26
- /package/dist/{esm-node/cli/is/index.js → esm/cli/is/index.mjs} +0 -0
- /package/dist/{esm-node/index.js → esm/index.mjs} +0 -0
|
@@ -1 +1,1704 @@
|
|
|
1
|
-
(()=>{var e={305:(e,t,r)=>{"use strict";var n=r(837);var i=r(589);var s=function errorEx(e,t){if(!e||e.constructor!==String){t=e||{};e=Error.name}var r=function ErrorEXError(n){if(!this){return new ErrorEXError(n)}n=n instanceof Error?n.message:n||this.message;Error.call(this,n);Error.captureStackTrace(this,r);this.name=e;Object.defineProperty(this,"message",{configurable:true,enumerable:false,get:function(){var e=n.split(/\r?\n/g);for(var r in t){if(!t.hasOwnProperty(r)){continue}var s=t[r];if("message"in s){e=s.message(this[r],e)||e;if(!i(e)){e=[e]}}}return e.join("\n")},set:function(e){n=e}});var s=null;var o=Object.getOwnPropertyDescriptor(this,"stack");var c=o.get;var a=o.value;delete o.value;delete o.writable;o.set=function(e){s=e};o.get=function(){var e=(s||(c?c.call(this):a)).split(/\r?\n+/g);if(!s){e[0]=this.name+": "+this.message}var r=1;for(var n in t){if(!t.hasOwnProperty(n)){continue}var i=t[n];if("line"in i){var o=i.line(this[n]);if(o){e.splice(r++,0," "+o)}}if("stack"in i){i.stack(this[n],e)}}return e.join("\n")};Object.defineProperty(this,"stack",o)};if(Object.setPrototypeOf){Object.setPrototypeOf(r.prototype,Error.prototype);Object.setPrototypeOf(r,Error)}else{n.inherits(r,Error)}return r};s.append=function(e,t){return{message:function(r,n){r=r||t;if(r){n[0]+=" "+e.replace("%s",r.toString())}return n}}};s.line=function(e,t){return{line:function(r){r=r||t;if(r){return e.replace("%s",r.toString())}return null}}};e.exports=s},434:e=>{"use strict";var t=/[|\\{}()[\]^$+*?.]/g;e.exports=function(e){if(typeof e!=="string"){throw new TypeError("Expected a string")}return e.replace(t,"\\$&")}},877:(e,t,r)=>{"use strict";const n=r(434);const i=process.platform;const s={tick:"✔",cross:"✖",star:"★",square:"▇",squareSmall:"◻",squareSmallFilled:"◼",play:"▶",circle:"◯",circleFilled:"◉",circleDotted:"◌",circleDouble:"◎",circleCircle:"ⓞ",circleCross:"ⓧ",circlePipe:"Ⓘ",circleQuestionMark:"?⃝",bullet:"●",dot:"․",line:"─",ellipsis:"…",pointer:"❯",pointerSmall:"›",info:"ℹ",warning:"⚠",hamburger:"☰",smiley:"㋡",mustache:"෴",heart:"♥",arrowUp:"↑",arrowDown:"↓",arrowLeft:"←",arrowRight:"→",radioOn:"◉",radioOff:"◯",checkboxOn:"☒",checkboxOff:"☐",checkboxCircleOn:"ⓧ",checkboxCircleOff:"Ⓘ",questionMarkPrefix:"?⃝",oneHalf:"½",oneThird:"⅓",oneQuarter:"¼",oneFifth:"⅕",oneSixth:"⅙",oneSeventh:"⅐",oneEighth:"⅛",oneNinth:"⅑",oneTenth:"⅒",twoThirds:"⅔",twoFifths:"⅖",threeQuarters:"¾",threeFifths:"⅗",threeEighths:"⅜",fourFifths:"⅘",fiveSixths:"⅚",fiveEighths:"⅝",sevenEighths:"⅞"};const o={tick:"√",cross:"×",star:"*",square:"█",squareSmall:"[ ]",squareSmallFilled:"[█]",play:"►",circle:"( )",circleFilled:"(*)",circleDotted:"( )",circleDouble:"( )",circleCircle:"(○)",circleCross:"(×)",circlePipe:"(│)",circleQuestionMark:"(?)",bullet:"*",dot:".",line:"─",ellipsis:"...",pointer:">",pointerSmall:"»",info:"i",warning:"‼",hamburger:"≡",smiley:"☺",mustache:"┌─┐",heart:s.heart,arrowUp:s.arrowUp,arrowDown:s.arrowDown,arrowLeft:s.arrowLeft,arrowRight:s.arrowRight,radioOn:"(*)",radioOff:"( )",checkboxOn:"[×]",checkboxOff:"[ ]",checkboxCircleOn:"(×)",checkboxCircleOff:"( )",questionMarkPrefix:"?",oneHalf:"1/2",oneThird:"1/3",oneQuarter:"1/4",oneFifth:"1/5",oneSixth:"1/6",oneSeventh:"1/7",oneEighth:"1/8",oneNinth:"1/9",oneTenth:"1/10",twoThirds:"2/3",twoFifths:"2/5",threeQuarters:"3/4",threeFifths:"3/5",threeEighths:"3/8",fourFifths:"4/5",fiveSixths:"5/6",fiveEighths:"5/8",sevenEighths:"7/8"};if(i==="linux"){s.questionMarkPrefix="?"}const c=i==="win32"?o:s;const fn=e=>{if(c===s){return e}Object.keys(s).forEach((t=>{if(s[t]===c[t]){return}e=e.replace(new RegExp(n(s[t]),"g"),c[t])}));return e};e.exports=Object.assign(fn,c)},834:(e,t,r)=>{"use strict";const n=r(17);const i=r(69);e.exports=(e,t)=>{t=t||{};const r=n.resolve(t.cwd||"");const s=n.parse(r).root;const o=[].concat(e);return new Promise((e=>{(function find(t){i(o,{cwd:t}).then((r=>{if(r){e(n.join(t,r))}else if(t===s){e(null)}else{find(n.dirname(t))}}))})(r)}))};e.exports.sync=(e,t)=>{t=t||{};let r=n.resolve(t.cwd||"");const s=n.parse(r).root;const o=[].concat(e);while(true){const e=i.sync(o,{cwd:r});if(e){return n.join(r,e)}else if(r===s){return null}r=n.dirname(r)}}},132:e=>{"use strict";e.exports=clone;var t=Object.getPrototypeOf||function(e){return e.__proto__};function clone(e){if(e===null||typeof e!=="object")return e;if(e instanceof Object)var r={__proto__:t(e)};else var r=Object.create(null);Object.getOwnPropertyNames(e).forEach((function(t){Object.defineProperty(r,t,Object.getOwnPropertyDescriptor(e,t))}));return r}},127:(e,t,r)=>{var n=r(147);var i=r(738);var s=r(876);var o=r(132);var c=r(837);var a;var l;if(typeof Symbol==="function"&&typeof Symbol.for==="function"){a=Symbol.for("graceful-fs.queue");l=Symbol.for("graceful-fs.previous")}else{a="___graceful-fs.queue";l="___graceful-fs.previous"}function noop(){}function publishQueue(e,t){Object.defineProperty(e,a,{get:function(){return t}})}var f=noop;if(c.debuglog)f=c.debuglog("gfs4");else if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||""))f=function(){var e=c.format.apply(c,arguments);e="GFS4: "+e.split(/\n/).join("\nGFS4: ");console.error(e)};if(!n[a]){var u=global[a]||[];publishQueue(n,u);n.close=function(e){function close(t,r){return e.call(n,t,(function(e){if(!e){resetQueue()}if(typeof r==="function")r.apply(this,arguments)}))}Object.defineProperty(close,l,{value:e});return close}(n.close);n.closeSync=function(e){function closeSync(t){e.apply(n,arguments);resetQueue()}Object.defineProperty(closeSync,l,{value:e});return closeSync}(n.closeSync);if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")){process.on("exit",(function(){f(n[a]);r(491).equal(n[a].length,0)}))}}if(!global[a]){publishQueue(global,n[a])}e.exports=patch(o(n));if(process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!n.__patched){e.exports=patch(n);n.__patched=true}function patch(e){i(e);e.gracefulify=patch;e.createReadStream=createReadStream;e.createWriteStream=createWriteStream;var t=e.readFile;e.readFile=readFile;function readFile(e,r,n){if(typeof r==="function")n=r,r=null;return go$readFile(e,r,n);function go$readFile(e,r,n,i){return t(e,r,(function(t){if(t&&(t.code==="EMFILE"||t.code==="ENFILE"))enqueue([go$readFile,[e,r,n],t,i||Date.now(),Date.now()]);else{if(typeof n==="function")n.apply(this,arguments)}}))}}var r=e.writeFile;e.writeFile=writeFile;function writeFile(e,t,n,i){if(typeof n==="function")i=n,n=null;return go$writeFile(e,t,n,i);function go$writeFile(e,t,n,i,s){return r(e,t,n,(function(r){if(r&&(r.code==="EMFILE"||r.code==="ENFILE"))enqueue([go$writeFile,[e,t,n,i],r,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}var n=e.appendFile;if(n)e.appendFile=appendFile;function appendFile(e,t,r,i){if(typeof r==="function")i=r,r=null;return go$appendFile(e,t,r,i);function go$appendFile(e,t,r,i,s){return n(e,t,r,(function(n){if(n&&(n.code==="EMFILE"||n.code==="ENFILE"))enqueue([go$appendFile,[e,t,r,i],n,s||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}}))}}var o=e.copyFile;if(o)e.copyFile=copyFile;function copyFile(e,t,r,n){if(typeof r==="function"){n=r;r=0}return go$copyFile(e,t,r,n);function go$copyFile(e,t,r,n,i){return o(e,t,r,(function(s){if(s&&(s.code==="EMFILE"||s.code==="ENFILE"))enqueue([go$copyFile,[e,t,r,n],s,i||Date.now(),Date.now()]);else{if(typeof n==="function")n.apply(this,arguments)}}))}}var c=e.readdir;e.readdir=readdir;var a=/^v[0-5]\./;function readdir(e,t,r){if(typeof t==="function")r=t,t=null;var n=a.test(process.version)?function go$readdir(e,t,r,n){return c(e,fs$readdirCallback(e,t,r,n))}:function go$readdir(e,t,r,n){return c(e,t,fs$readdirCallback(e,t,r,n))};return n(e,t,r);function fs$readdirCallback(e,t,r,i){return function(s,o){if(s&&(s.code==="EMFILE"||s.code==="ENFILE"))enqueue([n,[e,t,r],s,i||Date.now(),Date.now()]);else{if(o&&o.sort)o.sort();if(typeof r==="function")r.call(this,s,o)}}}}if(process.version.substr(0,4)==="v0.8"){var l=s(e);ReadStream=l.ReadStream;WriteStream=l.WriteStream}var f=e.ReadStream;if(f){ReadStream.prototype=Object.create(f.prototype);ReadStream.prototype.open=ReadStream$open}var u=e.WriteStream;if(u){WriteStream.prototype=Object.create(u.prototype);WriteStream.prototype.open=WriteStream$open}Object.defineProperty(e,"ReadStream",{get:function(){return ReadStream},set:function(e){ReadStream=e},enumerable:true,configurable:true});Object.defineProperty(e,"WriteStream",{get:function(){return WriteStream},set:function(e){WriteStream=e},enumerable:true,configurable:true});var h=ReadStream;Object.defineProperty(e,"FileReadStream",{get:function(){return h},set:function(e){h=e},enumerable:true,configurable:true});var p=WriteStream;Object.defineProperty(e,"FileWriteStream",{get:function(){return p},set:function(e){p=e},enumerable:true,configurable:true});function ReadStream(e,t){if(this instanceof ReadStream)return f.apply(this,arguments),this;else return ReadStream.apply(Object.create(ReadStream.prototype),arguments)}function ReadStream$open(){var e=this;open(e.path,e.flags,e.mode,(function(t,r){if(t){if(e.autoClose)e.destroy();e.emit("error",t)}else{e.fd=r;e.emit("open",r);e.read()}}))}function WriteStream(e,t){if(this instanceof WriteStream)return u.apply(this,arguments),this;else return WriteStream.apply(Object.create(WriteStream.prototype),arguments)}function WriteStream$open(){var e=this;open(e.path,e.flags,e.mode,(function(t,r){if(t){e.destroy();e.emit("error",t)}else{e.fd=r;e.emit("open",r)}}))}function createReadStream(t,r){return new e.ReadStream(t,r)}function createWriteStream(t,r){return new e.WriteStream(t,r)}var d=e.open;e.open=open;function open(e,t,r,n){if(typeof r==="function")n=r,r=null;return go$open(e,t,r,n);function go$open(e,t,r,n,i){return d(e,t,r,(function(s,o){if(s&&(s.code==="EMFILE"||s.code==="ENFILE"))enqueue([go$open,[e,t,r,n],s,i||Date.now(),Date.now()]);else{if(typeof n==="function")n.apply(this,arguments)}}))}}return e}function enqueue(e){f("ENQUEUE",e[0].name,e[1]);n[a].push(e);retry()}var h;function resetQueue(){var e=Date.now();for(var t=0;t<n[a].length;++t){if(n[a][t].length>2){n[a][t][3]=e;n[a][t][4]=e}}retry()}function retry(){clearTimeout(h);h=undefined;if(n[a].length===0)return;var e=n[a].shift();var t=e[0];var r=e[1];var i=e[2];var s=e[3];var o=e[4];if(s===undefined){f("RETRY",t.name,r);t.apply(null,r)}else if(Date.now()-s>=6e4){f("TIMEOUT",t.name,r);var c=r.pop();if(typeof c==="function")c.call(null,i)}else{var l=Date.now()-o;var u=Math.max(o-s,1);var p=Math.min(u*1.2,100);if(l>=p){f("RETRY",t.name,r);t.apply(null,r.concat([s]))}else{n[a].push(e)}}if(h===undefined){h=setTimeout(retry,0)}}},876:(e,t,r)=>{var n=r(781).Stream;e.exports=legacy;function legacy(e){return{ReadStream:ReadStream,WriteStream:WriteStream};function ReadStream(t,r){if(!(this instanceof ReadStream))return new ReadStream(t,r);n.call(this);var i=this;this.path=t;this.fd=null;this.readable=true;this.paused=false;this.flags="r";this.mode=438;this.bufferSize=64*1024;r=r||{};var s=Object.keys(r);for(var o=0,c=s.length;o<c;o++){var a=s[o];this[a]=r[a]}if(this.encoding)this.setEncoding(this.encoding);if(this.start!==undefined){if("number"!==typeof this.start){throw TypeError("start must be a Number")}if(this.end===undefined){this.end=Infinity}else if("number"!==typeof this.end){throw TypeError("end must be a Number")}if(this.start>this.end){throw new Error("start must be <= end")}this.pos=this.start}if(this.fd!==null){process.nextTick((function(){i._read()}));return}e.open(this.path,this.flags,this.mode,(function(e,t){if(e){i.emit("error",e);i.readable=false;return}i.fd=t;i.emit("open",t);i._read()}))}function WriteStream(t,r){if(!(this instanceof WriteStream))return new WriteStream(t,r);n.call(this);this.path=t;this.fd=null;this.writable=true;this.flags="w";this.encoding="binary";this.mode=438;this.bytesWritten=0;r=r||{};var i=Object.keys(r);for(var s=0,o=i.length;s<o;s++){var c=i[s];this[c]=r[c]}if(this.start!==undefined){if("number"!==typeof this.start){throw TypeError("start must be a Number")}if(this.start<0){throw new Error("start must be >= zero")}this.pos=this.start}this.busy=false;this._queue=[];if(this.fd===null){this._open=e.open;this._queue.push([this._open,this.path,this.flags,this.mode,undefined]);this.flush()}}}},738:(e,t,r)=>{var n=r(57);var i=process.cwd;var s=null;var o=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){if(!s)s=i.call(process);return s};try{process.cwd()}catch(e){}if(typeof process.chdir==="function"){var c=process.chdir;process.chdir=function(e){s=null;c.call(process,e)};if(Object.setPrototypeOf)Object.setPrototypeOf(process.chdir,c)}e.exports=patch;function patch(e){if(n.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)){patchLchmod(e)}if(!e.lutimes){patchLutimes(e)}e.chown=chownFix(e.chown);e.fchown=chownFix(e.fchown);e.lchown=chownFix(e.lchown);e.chmod=chmodFix(e.chmod);e.fchmod=chmodFix(e.fchmod);e.lchmod=chmodFix(e.lchmod);e.chownSync=chownFixSync(e.chownSync);e.fchownSync=chownFixSync(e.fchownSync);e.lchownSync=chownFixSync(e.lchownSync);e.chmodSync=chmodFixSync(e.chmodSync);e.fchmodSync=chmodFixSync(e.fchmodSync);e.lchmodSync=chmodFixSync(e.lchmodSync);e.stat=statFix(e.stat);e.fstat=statFix(e.fstat);e.lstat=statFix(e.lstat);e.statSync=statFixSync(e.statSync);e.fstatSync=statFixSync(e.fstatSync);e.lstatSync=statFixSync(e.lstatSync);if(e.chmod&&!e.lchmod){e.lchmod=function(e,t,r){if(r)process.nextTick(r)};e.lchmodSync=function(){}}if(e.chown&&!e.lchown){e.lchown=function(e,t,r,n){if(n)process.nextTick(n)};e.lchownSync=function(){}}if(o==="win32"){e.rename=typeof e.rename!=="function"?e.rename:function(t){function rename(r,n,i){var s=Date.now();var o=0;t(r,n,(function CB(c){if(c&&(c.code==="EACCES"||c.code==="EPERM")&&Date.now()-s<6e4){setTimeout((function(){e.stat(n,(function(e,s){if(e&&e.code==="ENOENT")t(r,n,CB);else i(c)}))}),o);if(o<100)o+=10;return}if(i)i(c)}))}if(Object.setPrototypeOf)Object.setPrototypeOf(rename,t);return rename}(e.rename)}e.read=typeof e.read!=="function"?e.read:function(t){function read(r,n,i,s,o,c){var a;if(c&&typeof c==="function"){var l=0;a=function(f,u,h){if(f&&f.code==="EAGAIN"&&l<10){l++;return t.call(e,r,n,i,s,o,a)}c.apply(this,arguments)}}return t.call(e,r,n,i,s,o,a)}if(Object.setPrototypeOf)Object.setPrototypeOf(read,t);return read}(e.read);e.readSync=typeof e.readSync!=="function"?e.readSync:function(t){return function(r,n,i,s,o){var c=0;while(true){try{return t.call(e,r,n,i,s,o)}catch(e){if(e.code==="EAGAIN"&&c<10){c++;continue}throw e}}}}(e.readSync);function patchLchmod(e){e.lchmod=function(t,r,i){e.open(t,n.O_WRONLY|n.O_SYMLINK,r,(function(t,n){if(t){if(i)i(t);return}e.fchmod(n,r,(function(t){e.close(n,(function(e){if(i)i(t||e)}))}))}))};e.lchmodSync=function(t,r){var i=e.openSync(t,n.O_WRONLY|n.O_SYMLINK,r);var s=true;var o;try{o=e.fchmodSync(i,r);s=false}finally{if(s){try{e.closeSync(i)}catch(e){}}else{e.closeSync(i)}}return o}}function patchLutimes(e){if(n.hasOwnProperty("O_SYMLINK")&&e.futimes){e.lutimes=function(t,r,i,s){e.open(t,n.O_SYMLINK,(function(t,n){if(t){if(s)s(t);return}e.futimes(n,r,i,(function(t){e.close(n,(function(e){if(s)s(t||e)}))}))}))};e.lutimesSync=function(t,r,i){var s=e.openSync(t,n.O_SYMLINK);var o;var c=true;try{o=e.futimesSync(s,r,i);c=false}finally{if(c){try{e.closeSync(s)}catch(e){}}else{e.closeSync(s)}}return o}}else if(e.futimes){e.lutimes=function(e,t,r,n){if(n)process.nextTick(n)};e.lutimesSync=function(){}}}function chmodFix(t){if(!t)return t;return function(r,n,i){return t.call(e,r,n,(function(e){if(chownErOk(e))e=null;if(i)i.apply(this,arguments)}))}}function chmodFixSync(t){if(!t)return t;return function(r,n){try{return t.call(e,r,n)}catch(e){if(!chownErOk(e))throw e}}}function chownFix(t){if(!t)return t;return function(r,n,i,s){return t.call(e,r,n,i,(function(e){if(chownErOk(e))e=null;if(s)s.apply(this,arguments)}))}}function chownFixSync(t){if(!t)return t;return function(r,n,i){try{return t.call(e,r,n,i)}catch(e){if(!chownErOk(e))throw e}}}function statFix(t){if(!t)return t;return function(r,n,i){if(typeof n==="function"){i=n;n=null}function callback(e,t){if(t){if(t.uid<0)t.uid+=4294967296;if(t.gid<0)t.gid+=4294967296}if(i)i.apply(this,arguments)}return n?t.call(e,r,n,callback):t.call(e,r,callback)}}function statFixSync(t){if(!t)return t;return function(r,n){var i=n?t.call(e,r,n):t.call(e,r);if(i){if(i.uid<0)i.uid+=4294967296;if(i.gid<0)i.gid+=4294967296}return i}}function chownErOk(e){if(!e)return true;if(e.code==="ENOSYS")return true;var t=!process.getuid||process.getuid()!==0;if(t){if(e.code==="EINVAL"||e.code==="EPERM")return true}return false}}},589:e=>{"use strict";e.exports=function isArrayish(e){if(!e){return false}return e instanceof Array||Array.isArray(e)||e.length>=0&&e.splice instanceof Function}},9:e=>{"use strict";e.exports=parseJson;function parseJson(e,t,r){r=r||20;try{return JSON.parse(e,t)}catch(t){if(typeof e!=="string"){const t=Array.isArray(e)&&e.length===0;const r="Cannot parse "+(t?"an empty array":String(e));throw new TypeError(r)}const n=t.message.match(/^Unexpected token.*position\s+(\d+)/i);const i=n?+n[1]:t.message.match(/^Unexpected end of JSON.*/i)?e.length-1:null;if(i!=null){const n=i<=r?0:i-r;const s=i+r>=e.length?e.length:i+r;t.message+=` while parsing near '${n===0?"":"..."}${e.slice(n,s)}${s===e.length?"":"..."}'`}else{t.message+=` while parsing '${e.slice(0,r*2)}'`}throw t}}},324:(e,t,r)=>{"use strict";const n=r(17);const i=r(127);const s=r(308);const o=r(264);const c=r(119);const parse=(e,t)=>o(s(e),n.relative(".",t));e.exports=e=>c(i.readFile)(e,"utf8").then((t=>parse(t,e)));e.exports.sync=e=>parse(i.readFileSync(e,"utf8"),e)},69:(e,t,r)=>{"use strict";const n=r(17);const i=r(383);const s=r(367);e.exports=(e,t)=>{t=Object.assign({cwd:process.cwd()},t);return s(e,(e=>i(n.resolve(t.cwd,e))),t)};e.exports.sync=(e,t)=>{t=Object.assign({cwd:process.cwd()},t);for(const r of e){if(i.sync(n.resolve(t.cwd,r))){return r}}}},273:(e,t,r)=>{"use strict";const n=r(965);e.exports=e=>{if(e<1){throw new TypeError("Expected `concurrency` to be a number from 1 and up")}const t=[];let r=0;const next=()=>{r--;if(t.length>0){t.shift()()}};return i=>new Promise(((s,o)=>{const run=()=>{r++;n(i).then((e=>{s(e);next()}),(e=>{o(e);next()}))};if(r<e){run()}else{t.push(run)}}))}},367:(e,t,r)=>{"use strict";const n=r(273);class EndError extends Error{constructor(e){super();this.value=e}}const finder=e=>Promise.all(e).then((e=>e[1]===true&&Promise.reject(new EndError(e[0]))));e.exports=(e,t,r)=>{r=Object.assign({concurrency:Infinity,preserveOrder:true},r);const i=n(r.concurrency);const s=Array.from(e).map((e=>[e,i((()=>Promise.resolve(e).then(t)))]));const o=n(r.preserveOrder?1:Infinity);return Promise.all(s.map((e=>o((()=>finder(e)))))).then((()=>{})).catch((e=>e instanceof EndError?e.value:Promise.reject(e)))}},965:e=>{"use strict";e.exports=e=>new Promise((t=>{t(e())}))},264:(e,t,r)=>{"use strict";const n=r(305);const i=r(9);const s=n("JSONError",{fileName:n.append("in %s")});e.exports=(e,t,r)=>{if(typeof t==="string"){r=t;t=null}try{try{return JSON.parse(e,t)}catch(r){i(e,t);throw r}}catch(e){e.message=e.message.replace(/\n/g,"");const t=new s(e);if(r){t.fileName=r}throw t}}},383:(e,t,r)=>{"use strict";const n=r(147);e.exports=e=>new Promise((t=>{n.access(e,(e=>{t(!e)}))}));e.exports.sync=e=>{try{n.accessSync(e);return true}catch(e){return false}}},119:e=>{"use strict";const processFn=(e,t)=>function(){const r=t.promiseModule;const n=new Array(arguments.length);for(let e=0;e<arguments.length;e++){n[e]=arguments[e]}return new r(((r,i)=>{if(t.errorFirst){n.push((function(e,n){if(t.multiArgs){const t=new Array(arguments.length-1);for(let e=1;e<arguments.length;e++){t[e-1]=arguments[e]}if(e){t.unshift(e);i(t)}else{r(t)}}else if(e){i(e)}else{r(n)}}))}else{n.push((function(e){if(t.multiArgs){const e=new Array(arguments.length-1);for(let t=0;t<arguments.length;t++){e[t]=arguments[t]}r(e)}else{r(e)}}))}e.apply(this,n)}))};e.exports=(e,t)=>{t=Object.assign({exclude:[/.+(Sync|Stream)$/],errorFirst:true,promiseModule:Promise},t);const filter=e=>{const match=t=>typeof t==="string"?e===t:t.test(e);return t.include?t.include.some(match):!t.exclude.some(match)};let r;if(typeof e==="function"){r=function(){if(t.excludeMain){return e.apply(this,arguments)}return processFn(e,t).apply(this,arguments)}}else{r=Object.create(Object.getPrototypeOf(e))}for(const n in e){const i=e[n];r[n]=typeof i==="function"&&filter(n)?processFn(i,t):i}return r}},817:(e,t,r)=>{"use strict";const n=r(17);const i=r(834);const s=r(324);const o=new WeakMap;const filepath=e=>o.get(e);const findNextCwd=e=>n.resolve(n.dirname(e),"..");const addFp=(e,t)=>{o.set(e,t);return e};const pkgConf=(e,t)=>{if(!e){return Promise.reject(new TypeError("Expected a namespace"))}t=t||{};return i("package.json",t.cwd?{cwd:t.cwd}:{}).then((r=>{if(!r){return addFp(Object.assign({},t.defaults),r)}return s(r).then((n=>{if(t.skipOnFalse&&n[e]===false){const n=Object.assign({},t,{cwd:findNextCwd(r)});return pkgConf(e,n)}return addFp(Object.assign({},t.defaults,n[e]),r)}))}))};const sync=(e,t)=>{if(!e){throw new TypeError("Expected a namespace")}t=t||{};const r=i.sync("package.json",t.cwd?{cwd:t.cwd}:{});if(!r){return addFp(Object.assign({},t.defaults),r)}const n=s.sync(r);if(t.skipOnFalse&&n[e]===false){const n=Object.assign({},t,{cwd:findNextCwd(r)});return sync(e,n)}return addFp(Object.assign({},t.defaults,n[e]),r)};e.exports=pkgConf;e.exports.filepath=filepath;e.exports.sync=sync},567:(e,t,r)=>{"use strict";const n=r(852);e.exports=Object.assign(new n,{Signale:n})},852:(e,t,r)=>{"use strict";const n=r(837);const i=r(17);const s=r(521);const o=r(234);const c=r(877);const a=r(817);const l=r(684);const f=r(616);const{green:u,grey:h,red:p,underline:d,yellow:g}=o;let m=false;const y=l.options.default;const b=l.name;class Signale{constructor(e={}){this._interactive=e.interactive||false;this._config=Object.assign(this.packageConfiguration,e.config);this._customTypes=Object.assign({},e.types);this._disabled=e.disabled||false;this._scopeName=e.scope||"";this._timers=e.timers||new Map;this._types=this._mergeTypes(f,this._customTypes);this._stream=e.stream||process.stdout;this._longestLabel=this._getLongestLabel();this._secrets=e.secrets||[];this._generalLogLevel=this._validateLogLevel(e.logLevel);Object.keys(this._types).forEach((e=>{this[e]=this._logger.bind(this,e)}))}get _now(){return Date.now()}get scopeName(){return this._scopeName}get currentOptions(){return Object.assign({},{config:this._config,disabled:this._disabled,types:this._customTypes,interactive:this._interactive,timers:this._timers,stream:this._stream,secrets:this._secrets,logLevel:this._generalLogLevel})}get date(){return(new Date).toLocaleDateString()}get timestamp(){return(new Date).toLocaleTimeString()}get filename(){const e=Error.prepareStackTrace;Error.prepareStackTrace=(e,t)=>t;const{stack:t}=new Error;Error.prepareStackTrace=e;const r=t.map((e=>e.getFileName()));const n=r.find((e=>e!==r[0]));return n?i.basename(n):"anonymous"}get packageConfiguration(){return a.sync(b,{defaults:y})}get _longestUnderlinedLabel(){return d(this._longestLabel)}get _logLevels(){return{info:0,timer:1,debug:2,warn:3,error:4}}set configuration(e){this._config=Object.assign(this.packageConfiguration,e)}_arrayify(e){return Array.isArray(e)?e:[e]}_timeSpan(e){return this._now-e}_getLongestLabel(){const{_types:e}=this;const t=Object.keys(e).map((t=>e[t].label));return t.reduce(((e,t)=>e.length>t.length?e:t))}_validateLogLevel(e){return Object.keys(this._logLevels).includes(e)?e:"info"}_mergeTypes(e,t){const r=Object.assign({},e);Object.keys(t).forEach((e=>{r[e]=Object.assign({},r[e],t[e])}));return r}_filterSecrets(e){const{_secrets:t}=this;if(t.length===0){return e}let r=e;t.forEach((e=>{r=r.replace(new RegExp(e,"g"),"[secure]")}));return r}_formatStream(e){return this._arrayify(e)}_formatDate(){return`[${this.date}]`}_formatFilename(){return`[${this.filename}]`}_formatScopeName(){if(Array.isArray(this._scopeName)){const e=this._scopeName.filter((e=>e.length!==0));return`${e.map((e=>`[${e.trim()}]`)).join(" ")}`}return`[${this._scopeName}]`}_formatTimestamp(){return`[${this.timestamp}]`}_formatMessage(e){return n.format(...this._arrayify(e))}_meta(){const e=[];if(this._config.displayDate){e.push(this._formatDate())}if(this._config.displayTimestamp){e.push(this._formatTimestamp())}if(this._config.displayFilename){e.push(this._formatFilename())}if(this._scopeName.length!==0&&this._config.displayScope){e.push(this._formatScopeName())}if(e.length!==0){e.push(`${c.pointerSmall}`);return e.map((e=>h(e)))}return e}_hasAdditional({suffix:e,prefix:t},r){return e||t?"":this._formatMessage(r)}_buildSignale(e,...t){let[r,n]=[{},{}];if(t.length===1&&typeof t[0]==="object"&&t[0]!==null){if(t[0]instanceof Error){[r]=t}else{const[{prefix:e,message:i,suffix:s}]=t;n=Object.assign({},{suffix:s,prefix:e});r=i?this._formatMessage(i):this._hasAdditional(n,t)}}else{r=this._formatMessage(t)}const i=this._meta();if(n.prefix){if(this._config.underlinePrefix){i.push(d(n.prefix))}else{i.push(n.prefix)}}if(this._config.displayBadge&&e.badge){i.push(o[e.color](this._padEnd(e.badge,e.badge.length+1)))}if(this._config.displayLabel&&e.label){const t=this._config.uppercaseLabel?e.label.toUpperCase():e.label;if(this._config.underlineLabel){i.push(o[e.color](this._padEnd(d(t),this._longestUnderlinedLabel.length+1)))}else{i.push(o[e.color](this._padEnd(t,this._longestLabel.length+1)))}}if(r instanceof Error&&r.stack){const[e,...t]=r.stack.split("\n");if(this._config.underlineMessage){i.push(d(e))}else{i.push(e)}i.push(h(t.map((e=>e.replace(/^/,"\n"))).join("")));return i.join(" ")}if(this._config.underlineMessage){i.push(d(r))}else{i.push(r)}if(n.suffix){if(this._config.underlineSuffix){i.push(d(n.suffix))}else{i.push(n.suffix)}}return i.join(" ")}_write(e,t){if(this._interactive&&e.isTTY&&m){s.moveCursor(e,0,-1);s.clearLine(e);s.cursorTo(e,0)}e.write(t+"\n");m=this._interactive}_log(e,t=this._stream,r){if(this.isEnabled()&&this._logLevels[r]>=this._logLevels[this._generalLogLevel]){this._formatStream(t).forEach((t=>{this._write(t,e)}))}}_logger(e,...t){const{stream:r,logLevel:n}=this._types[e];const i=this._buildSignale(this._types[e],...t);this._log(this._filterSecrets(i),r,this._validateLogLevel(n))}_padEnd(e,t){e=String(e);t=parseInt(t,10)||0;if(e.length>=t){return e}if(String.prototype.padEnd){return e.padEnd(t)}t-=e.length;return e+" ".repeat(t)}addSecrets(e){if(!Array.isArray(e)){throw new TypeError("Argument must be an array.")}this._secrets.push(...e)}clearSecrets(){this._secrets=[]}config(e){this.configuration=e}disable(){this._disabled=true}enable(){this._disabled=false}isEnabled(){return!this._disabled}scope(...e){if(e.length===0){throw new Error("No scope name was defined.")}return new Signale(Object.assign(this.currentOptions,{scope:e}))}unscope(){this._scopeName=""}time(e){if(!e){e=`timer_${this._timers.size}`}this._timers.set(e,this._now);const t=this._meta();t.push(u(this._padEnd(this._types.start.badge,2)));if(this._config.underlineLabel){t.push(u(this._padEnd(d(e),this._longestUnderlinedLabel.length+1)))}else{t.push(u(this._padEnd(e,this._longestLabel.length+1)))}t.push("Initialized timer...");this._log(t.join(" "),this._stream,"timer");return e}timeEnd(e){if(!e&&this._timers.size){const is=e=>e.includes("timer_");e=[...this._timers.keys()].reduceRight(((e,t)=>is(e)?e:is(t)?t:null))}if(this._timers.has(e)){const t=this._timeSpan(this._timers.get(e));this._timers.delete(e);const r=this._meta();r.push(p(this._padEnd(this._types.pause.badge,2)));if(this._config.underlineLabel){r.push(p(this._padEnd(d(e),this._longestUnderlinedLabel.length+1)))}else{r.push(p(this._padEnd(e,this._longestLabel.length+1)))}r.push("Timer run for:");r.push(g(t<1e3?t+"ms":(t/1e3).toFixed(2)+"s"));this._log(r.join(" "),this._stream,"timer");return{label:e,span:t}}}}e.exports=Signale},616:(e,t,r)=>{"use strict";const n=r(877);e.exports={error:{badge:n.cross,color:"red",label:"error",logLevel:"error"},fatal:{badge:n.cross,color:"red",label:"fatal",logLevel:"error"},fav:{badge:n("❤"),color:"magenta",label:"favorite",logLevel:"info"},info:{badge:n.info,color:"blue",label:"info",logLevel:"info"},star:{badge:n.star,color:"yellow",label:"star",logLevel:"info"},success:{badge:n.tick,color:"green",label:"success",logLevel:"info"},wait:{badge:n.ellipsis,color:"blue",label:"waiting",logLevel:"info"},warn:{badge:n.warning,color:"yellow",label:"warning",logLevel:"warn"},complete:{badge:n.checkboxOn,color:"cyan",label:"complete",logLevel:"info"},pending:{badge:n.checkboxOff,color:"magenta",label:"pending",logLevel:"info"},note:{badge:n.bullet,color:"blue",label:"note",logLevel:"info"},start:{badge:n.play,color:"green",label:"start",logLevel:"info"},pause:{badge:n.squareSmallFilled,color:"yellow",label:"pause",logLevel:"info"},debug:{badge:n("⬤"),color:"red",label:"debug",logLevel:"debug"},await:{badge:n.ellipsis,color:"blue",label:"awaiting",logLevel:"info"},watch:{badge:n.ellipsis,color:"yellow",label:"watching",logLevel:"info"},log:{badge:"",color:"",label:"",logLevel:"info"}}},308:e=>{"use strict";e.exports=e=>{if(typeof e!=="string"){throw new TypeError("Expected a string, got "+typeof e)}if(e.charCodeAt(0)===65279){return e.slice(1)}return e}},234:e=>{"use strict";e.exports=require("../chalk")},684:e=>{"use strict";e.exports=require("./package.json")},491:e=>{"use strict";e.exports=require("assert")},57:e=>{"use strict";e.exports=require("constants")},147:e=>{"use strict";e.exports=require("fs")},17:e=>{"use strict";e.exports=require("path")},521:e=>{"use strict";e.exports=require("readline")},781:e=>{"use strict";e.exports=require("stream")},837:e=>{"use strict";e.exports=require("util")}};var t={};function __nccwpck_require__(r){var n=t[r];if(n!==undefined){return n.exports}var i=t[r]={exports:{}};var s=true;try{e[r](i,i.exports,__nccwpck_require__);s=false}finally{if(s)delete t[r]}return i.exports}if(typeof __nccwpck_require__!=="undefined")__nccwpck_require__.ab=__dirname+"/";var r=__nccwpck_require__(567);module.exports=r})();
|
|
1
|
+
(()=>{
|
|
2
|
+
var e = {
|
|
3
|
+
305: (e, t, r)=>{
|
|
4
|
+
"use strict";
|
|
5
|
+
var n = r(837);
|
|
6
|
+
var i = r(589);
|
|
7
|
+
var s = function(e, t) {
|
|
8
|
+
if (!e || e.constructor !== String) {
|
|
9
|
+
t = e || {};
|
|
10
|
+
e = Error.name;
|
|
11
|
+
}
|
|
12
|
+
var r = function ErrorEXError(n) {
|
|
13
|
+
if (!this) return new ErrorEXError(n);
|
|
14
|
+
n = n instanceof Error ? n.message : n || this.message;
|
|
15
|
+
Error.call(this, n);
|
|
16
|
+
Error.captureStackTrace(this, r);
|
|
17
|
+
this.name = e;
|
|
18
|
+
Object.defineProperty(this, "message", {
|
|
19
|
+
configurable: true,
|
|
20
|
+
enumerable: false,
|
|
21
|
+
get: function() {
|
|
22
|
+
var e = n.split(/\r?\n/g);
|
|
23
|
+
for(var r in t)if (t.hasOwnProperty(r)) {
|
|
24
|
+
var s = t[r];
|
|
25
|
+
if ("message" in s) {
|
|
26
|
+
e = s.message(this[r], e) || e;
|
|
27
|
+
if (!i(e)) e = [
|
|
28
|
+
e
|
|
29
|
+
];
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
return e.join("\n");
|
|
33
|
+
},
|
|
34
|
+
set: function(e) {
|
|
35
|
+
n = e;
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
var s = null;
|
|
39
|
+
var o = Object.getOwnPropertyDescriptor(this, "stack");
|
|
40
|
+
var c = o.get;
|
|
41
|
+
var a = o.value;
|
|
42
|
+
delete o.value;
|
|
43
|
+
delete o.writable;
|
|
44
|
+
o.set = function(e) {
|
|
45
|
+
s = e;
|
|
46
|
+
};
|
|
47
|
+
o.get = function() {
|
|
48
|
+
var e = (s || (c ? c.call(this) : a)).split(/\r?\n+/g);
|
|
49
|
+
if (!s) e[0] = this.name + ": " + this.message;
|
|
50
|
+
var r = 1;
|
|
51
|
+
for(var n in t)if (t.hasOwnProperty(n)) {
|
|
52
|
+
var i = t[n];
|
|
53
|
+
if ("line" in i) {
|
|
54
|
+
var o = i.line(this[n]);
|
|
55
|
+
if (o) e.splice(r++, 0, " " + o);
|
|
56
|
+
}
|
|
57
|
+
if ("stack" in i) i.stack(this[n], e);
|
|
58
|
+
}
|
|
59
|
+
return e.join("\n");
|
|
60
|
+
};
|
|
61
|
+
Object.defineProperty(this, "stack", o);
|
|
62
|
+
};
|
|
63
|
+
if (Object.setPrototypeOf) {
|
|
64
|
+
Object.setPrototypeOf(r.prototype, Error.prototype);
|
|
65
|
+
Object.setPrototypeOf(r, Error);
|
|
66
|
+
} else n.inherits(r, Error);
|
|
67
|
+
return r;
|
|
68
|
+
};
|
|
69
|
+
s.append = function(e, t) {
|
|
70
|
+
return {
|
|
71
|
+
message: function(r, n) {
|
|
72
|
+
r = r || t;
|
|
73
|
+
if (r) n[0] += " " + e.replace("%s", r.toString());
|
|
74
|
+
return n;
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
};
|
|
78
|
+
s.line = function(e, t) {
|
|
79
|
+
return {
|
|
80
|
+
line: function(r) {
|
|
81
|
+
r = r || t;
|
|
82
|
+
if (r) return e.replace("%s", r.toString());
|
|
83
|
+
return null;
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
};
|
|
87
|
+
e.exports = s;
|
|
88
|
+
},
|
|
89
|
+
434: (e)=>{
|
|
90
|
+
"use strict";
|
|
91
|
+
var t = /[|\\{}()[\]^$+*?.]/g;
|
|
92
|
+
e.exports = function(e) {
|
|
93
|
+
if ("string" != typeof e) throw new TypeError("Expected a string");
|
|
94
|
+
return e.replace(t, "\\$&");
|
|
95
|
+
};
|
|
96
|
+
},
|
|
97
|
+
877: (e, t, r)=>{
|
|
98
|
+
"use strict";
|
|
99
|
+
const n = r(434);
|
|
100
|
+
const i = process.platform;
|
|
101
|
+
const s = {
|
|
102
|
+
tick: "✔",
|
|
103
|
+
cross: "✖",
|
|
104
|
+
star: "★",
|
|
105
|
+
square: "▇",
|
|
106
|
+
squareSmall: "◻",
|
|
107
|
+
squareSmallFilled: "◼",
|
|
108
|
+
play: "▶",
|
|
109
|
+
circle: "◯",
|
|
110
|
+
circleFilled: "◉",
|
|
111
|
+
circleDotted: "◌",
|
|
112
|
+
circleDouble: "◎",
|
|
113
|
+
circleCircle: "ⓞ",
|
|
114
|
+
circleCross: "ⓧ",
|
|
115
|
+
circlePipe: "Ⓘ",
|
|
116
|
+
circleQuestionMark: "?⃝",
|
|
117
|
+
bullet: "●",
|
|
118
|
+
dot: "․",
|
|
119
|
+
line: "─",
|
|
120
|
+
ellipsis: "…",
|
|
121
|
+
pointer: "❯",
|
|
122
|
+
pointerSmall: "›",
|
|
123
|
+
info: "ℹ",
|
|
124
|
+
warning: "⚠",
|
|
125
|
+
hamburger: "☰",
|
|
126
|
+
smiley: "㋡",
|
|
127
|
+
mustache: "෴",
|
|
128
|
+
heart: "♥",
|
|
129
|
+
arrowUp: "↑",
|
|
130
|
+
arrowDown: "↓",
|
|
131
|
+
arrowLeft: "←",
|
|
132
|
+
arrowRight: "→",
|
|
133
|
+
radioOn: "◉",
|
|
134
|
+
radioOff: "◯",
|
|
135
|
+
checkboxOn: "☒",
|
|
136
|
+
checkboxOff: "☐",
|
|
137
|
+
checkboxCircleOn: "ⓧ",
|
|
138
|
+
checkboxCircleOff: "Ⓘ",
|
|
139
|
+
questionMarkPrefix: "?⃝",
|
|
140
|
+
oneHalf: "½",
|
|
141
|
+
oneThird: "⅓",
|
|
142
|
+
oneQuarter: "¼",
|
|
143
|
+
oneFifth: "⅕",
|
|
144
|
+
oneSixth: "⅙",
|
|
145
|
+
oneSeventh: "⅐",
|
|
146
|
+
oneEighth: "⅛",
|
|
147
|
+
oneNinth: "⅑",
|
|
148
|
+
oneTenth: "⅒",
|
|
149
|
+
twoThirds: "⅔",
|
|
150
|
+
twoFifths: "⅖",
|
|
151
|
+
threeQuarters: "¾",
|
|
152
|
+
threeFifths: "⅗",
|
|
153
|
+
threeEighths: "⅜",
|
|
154
|
+
fourFifths: "⅘",
|
|
155
|
+
fiveSixths: "⅚",
|
|
156
|
+
fiveEighths: "⅝",
|
|
157
|
+
sevenEighths: "⅞"
|
|
158
|
+
};
|
|
159
|
+
const o = {
|
|
160
|
+
tick: "√",
|
|
161
|
+
cross: "×",
|
|
162
|
+
star: "*",
|
|
163
|
+
square: "█",
|
|
164
|
+
squareSmall: "[ ]",
|
|
165
|
+
squareSmallFilled: "[█]",
|
|
166
|
+
play: "►",
|
|
167
|
+
circle: "( )",
|
|
168
|
+
circleFilled: "(*)",
|
|
169
|
+
circleDotted: "( )",
|
|
170
|
+
circleDouble: "( )",
|
|
171
|
+
circleCircle: "(○)",
|
|
172
|
+
circleCross: "(×)",
|
|
173
|
+
circlePipe: "(│)",
|
|
174
|
+
circleQuestionMark: "(?)",
|
|
175
|
+
bullet: "*",
|
|
176
|
+
dot: ".",
|
|
177
|
+
line: "─",
|
|
178
|
+
ellipsis: "...",
|
|
179
|
+
pointer: ">",
|
|
180
|
+
pointerSmall: "»",
|
|
181
|
+
info: "i",
|
|
182
|
+
warning: "‼",
|
|
183
|
+
hamburger: "≡",
|
|
184
|
+
smiley: "☺",
|
|
185
|
+
mustache: "┌─┐",
|
|
186
|
+
heart: s.heart,
|
|
187
|
+
arrowUp: s.arrowUp,
|
|
188
|
+
arrowDown: s.arrowDown,
|
|
189
|
+
arrowLeft: s.arrowLeft,
|
|
190
|
+
arrowRight: s.arrowRight,
|
|
191
|
+
radioOn: "(*)",
|
|
192
|
+
radioOff: "( )",
|
|
193
|
+
checkboxOn: "[×]",
|
|
194
|
+
checkboxOff: "[ ]",
|
|
195
|
+
checkboxCircleOn: "(×)",
|
|
196
|
+
checkboxCircleOff: "( )",
|
|
197
|
+
questionMarkPrefix: "?",
|
|
198
|
+
oneHalf: "1/2",
|
|
199
|
+
oneThird: "1/3",
|
|
200
|
+
oneQuarter: "1/4",
|
|
201
|
+
oneFifth: "1/5",
|
|
202
|
+
oneSixth: "1/6",
|
|
203
|
+
oneSeventh: "1/7",
|
|
204
|
+
oneEighth: "1/8",
|
|
205
|
+
oneNinth: "1/9",
|
|
206
|
+
oneTenth: "1/10",
|
|
207
|
+
twoThirds: "2/3",
|
|
208
|
+
twoFifths: "2/5",
|
|
209
|
+
threeQuarters: "3/4",
|
|
210
|
+
threeFifths: "3/5",
|
|
211
|
+
threeEighths: "3/8",
|
|
212
|
+
fourFifths: "4/5",
|
|
213
|
+
fiveSixths: "5/6",
|
|
214
|
+
fiveEighths: "5/8",
|
|
215
|
+
sevenEighths: "7/8"
|
|
216
|
+
};
|
|
217
|
+
if ("linux" === i) s.questionMarkPrefix = "?";
|
|
218
|
+
const c = "win32" === i ? o : s;
|
|
219
|
+
const fn = (e)=>{
|
|
220
|
+
if (c === s) return e;
|
|
221
|
+
Object.keys(s).forEach((t)=>{
|
|
222
|
+
if (s[t] === c[t]) return;
|
|
223
|
+
e = e.replace(new RegExp(n(s[t]), "g"), c[t]);
|
|
224
|
+
});
|
|
225
|
+
return e;
|
|
226
|
+
};
|
|
227
|
+
e.exports = Object.assign(fn, c);
|
|
228
|
+
},
|
|
229
|
+
834: (e, t, r)=>{
|
|
230
|
+
"use strict";
|
|
231
|
+
const n = r(17);
|
|
232
|
+
const i = r(69);
|
|
233
|
+
e.exports = (e, t)=>{
|
|
234
|
+
t = t || {};
|
|
235
|
+
const r = n.resolve(t.cwd || "");
|
|
236
|
+
const s = n.parse(r).root;
|
|
237
|
+
const o = [].concat(e);
|
|
238
|
+
return new Promise((e)=>{
|
|
239
|
+
(function find(t) {
|
|
240
|
+
i(o, {
|
|
241
|
+
cwd: t
|
|
242
|
+
}).then((r)=>{
|
|
243
|
+
if (r) e(n.join(t, r));
|
|
244
|
+
else if (t === s) e(null);
|
|
245
|
+
else find(n.dirname(t));
|
|
246
|
+
});
|
|
247
|
+
})(r);
|
|
248
|
+
});
|
|
249
|
+
};
|
|
250
|
+
e.exports.sync = (e, t)=>{
|
|
251
|
+
t = t || {};
|
|
252
|
+
let r = n.resolve(t.cwd || "");
|
|
253
|
+
const s = n.parse(r).root;
|
|
254
|
+
const o = [].concat(e);
|
|
255
|
+
while(true){
|
|
256
|
+
const e = i.sync(o, {
|
|
257
|
+
cwd: r
|
|
258
|
+
});
|
|
259
|
+
if (e) return n.join(r, e);
|
|
260
|
+
if (r === s) return null;
|
|
261
|
+
r = n.dirname(r);
|
|
262
|
+
}
|
|
263
|
+
};
|
|
264
|
+
},
|
|
265
|
+
132: (e)=>{
|
|
266
|
+
"use strict";
|
|
267
|
+
e.exports = clone;
|
|
268
|
+
var t = Object.getPrototypeOf || function(e) {
|
|
269
|
+
return e.__proto__;
|
|
270
|
+
};
|
|
271
|
+
function clone(e) {
|
|
272
|
+
if (null === e || "object" != typeof e) return e;
|
|
273
|
+
if (e instanceof Object) var r = {
|
|
274
|
+
__proto__: t(e)
|
|
275
|
+
};
|
|
276
|
+
else var r = Object.create(null);
|
|
277
|
+
Object.getOwnPropertyNames(e).forEach(function(t) {
|
|
278
|
+
Object.defineProperty(r, t, Object.getOwnPropertyDescriptor(e, t));
|
|
279
|
+
});
|
|
280
|
+
return r;
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
127: (e, t, r)=>{
|
|
284
|
+
var n = r(147);
|
|
285
|
+
var i = r(738);
|
|
286
|
+
var s = r(876);
|
|
287
|
+
var o = r(132);
|
|
288
|
+
var c = r(837);
|
|
289
|
+
var a;
|
|
290
|
+
var l;
|
|
291
|
+
if ("function" == typeof Symbol && "function" == typeof Symbol.for) {
|
|
292
|
+
a = Symbol.for("graceful-fs.queue");
|
|
293
|
+
l = Symbol.for("graceful-fs.previous");
|
|
294
|
+
} else {
|
|
295
|
+
a = "___graceful-fs.queue";
|
|
296
|
+
l = "___graceful-fs.previous";
|
|
297
|
+
}
|
|
298
|
+
function noop() {}
|
|
299
|
+
function publishQueue(e, t) {
|
|
300
|
+
Object.defineProperty(e, a, {
|
|
301
|
+
get: function() {
|
|
302
|
+
return t;
|
|
303
|
+
}
|
|
304
|
+
});
|
|
305
|
+
}
|
|
306
|
+
var f = noop;
|
|
307
|
+
if (c.debuglog) f = c.debuglog("gfs4");
|
|
308
|
+
else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) f = function() {
|
|
309
|
+
var e = c.format.apply(c, arguments);
|
|
310
|
+
e = "GFS4: " + e.split(/\n/).join("\nGFS4: ");
|
|
311
|
+
console.error(e);
|
|
312
|
+
};
|
|
313
|
+
if (!n[a]) {
|
|
314
|
+
var u = global[a] || [];
|
|
315
|
+
publishQueue(n, u);
|
|
316
|
+
n.close = function(e) {
|
|
317
|
+
function close(t, r) {
|
|
318
|
+
return e.call(n, t, function(e) {
|
|
319
|
+
if (!e) resetQueue();
|
|
320
|
+
if ("function" == typeof r) r.apply(this, arguments);
|
|
321
|
+
});
|
|
322
|
+
}
|
|
323
|
+
Object.defineProperty(close, l, {
|
|
324
|
+
value: e
|
|
325
|
+
});
|
|
326
|
+
return close;
|
|
327
|
+
}(n.close);
|
|
328
|
+
n.closeSync = function(e) {
|
|
329
|
+
function closeSync(t) {
|
|
330
|
+
e.apply(n, arguments);
|
|
331
|
+
resetQueue();
|
|
332
|
+
}
|
|
333
|
+
Object.defineProperty(closeSync, l, {
|
|
334
|
+
value: e
|
|
335
|
+
});
|
|
336
|
+
return closeSync;
|
|
337
|
+
}(n.closeSync);
|
|
338
|
+
if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) process.on("exit", function() {
|
|
339
|
+
f(n[a]);
|
|
340
|
+
r(491).equal(n[a].length, 0);
|
|
341
|
+
});
|
|
342
|
+
}
|
|
343
|
+
if (!global[a]) publishQueue(global, n[a]);
|
|
344
|
+
e.exports = patch(o(n));
|
|
345
|
+
if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !n.__patched) {
|
|
346
|
+
e.exports = patch(n);
|
|
347
|
+
n.__patched = true;
|
|
348
|
+
}
|
|
349
|
+
function patch(e) {
|
|
350
|
+
i(e);
|
|
351
|
+
e.gracefulify = patch;
|
|
352
|
+
e.createReadStream = createReadStream;
|
|
353
|
+
e.createWriteStream = createWriteStream;
|
|
354
|
+
var t = e.readFile;
|
|
355
|
+
e.readFile = readFile;
|
|
356
|
+
function readFile(e, r, n) {
|
|
357
|
+
if ("function" == typeof r) n = r, r = null;
|
|
358
|
+
return go$readFile(e, r, n);
|
|
359
|
+
function go$readFile(e, r, n, i) {
|
|
360
|
+
return t(e, r, function(t) {
|
|
361
|
+
if (t && ("EMFILE" === t.code || "ENFILE" === t.code)) enqueue([
|
|
362
|
+
go$readFile,
|
|
363
|
+
[
|
|
364
|
+
e,
|
|
365
|
+
r,
|
|
366
|
+
n
|
|
367
|
+
],
|
|
368
|
+
t,
|
|
369
|
+
i || Date.now(),
|
|
370
|
+
Date.now()
|
|
371
|
+
]);
|
|
372
|
+
else if ("function" == typeof n) n.apply(this, arguments);
|
|
373
|
+
});
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
var r = e.writeFile;
|
|
377
|
+
e.writeFile = writeFile;
|
|
378
|
+
function writeFile(e, t, n, i) {
|
|
379
|
+
if ("function" == typeof n) i = n, n = null;
|
|
380
|
+
return go$writeFile(e, t, n, i);
|
|
381
|
+
function go$writeFile(e, t, n, i, s) {
|
|
382
|
+
return r(e, t, n, function(r) {
|
|
383
|
+
if (r && ("EMFILE" === r.code || "ENFILE" === r.code)) enqueue([
|
|
384
|
+
go$writeFile,
|
|
385
|
+
[
|
|
386
|
+
e,
|
|
387
|
+
t,
|
|
388
|
+
n,
|
|
389
|
+
i
|
|
390
|
+
],
|
|
391
|
+
r,
|
|
392
|
+
s || Date.now(),
|
|
393
|
+
Date.now()
|
|
394
|
+
]);
|
|
395
|
+
else if ("function" == typeof i) i.apply(this, arguments);
|
|
396
|
+
});
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
var n = e.appendFile;
|
|
400
|
+
if (n) e.appendFile = appendFile;
|
|
401
|
+
function appendFile(e, t, r, i) {
|
|
402
|
+
if ("function" == typeof r) i = r, r = null;
|
|
403
|
+
return go$appendFile(e, t, r, i);
|
|
404
|
+
function go$appendFile(e, t, r, i, s) {
|
|
405
|
+
return n(e, t, r, function(n) {
|
|
406
|
+
if (n && ("EMFILE" === n.code || "ENFILE" === n.code)) enqueue([
|
|
407
|
+
go$appendFile,
|
|
408
|
+
[
|
|
409
|
+
e,
|
|
410
|
+
t,
|
|
411
|
+
r,
|
|
412
|
+
i
|
|
413
|
+
],
|
|
414
|
+
n,
|
|
415
|
+
s || Date.now(),
|
|
416
|
+
Date.now()
|
|
417
|
+
]);
|
|
418
|
+
else if ("function" == typeof i) i.apply(this, arguments);
|
|
419
|
+
});
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
var o = e.copyFile;
|
|
423
|
+
if (o) e.copyFile = copyFile;
|
|
424
|
+
function copyFile(e, t, r, n) {
|
|
425
|
+
if ("function" == typeof r) {
|
|
426
|
+
n = r;
|
|
427
|
+
r = 0;
|
|
428
|
+
}
|
|
429
|
+
return go$copyFile(e, t, r, n);
|
|
430
|
+
function go$copyFile(e, t, r, n, i) {
|
|
431
|
+
return o(e, t, r, function(s) {
|
|
432
|
+
if (s && ("EMFILE" === s.code || "ENFILE" === s.code)) enqueue([
|
|
433
|
+
go$copyFile,
|
|
434
|
+
[
|
|
435
|
+
e,
|
|
436
|
+
t,
|
|
437
|
+
r,
|
|
438
|
+
n
|
|
439
|
+
],
|
|
440
|
+
s,
|
|
441
|
+
i || Date.now(),
|
|
442
|
+
Date.now()
|
|
443
|
+
]);
|
|
444
|
+
else if ("function" == typeof n) n.apply(this, arguments);
|
|
445
|
+
});
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
var c = e.readdir;
|
|
449
|
+
e.readdir = readdir;
|
|
450
|
+
var a = /^v[0-5]\./;
|
|
451
|
+
function readdir(e, t, r) {
|
|
452
|
+
if ("function" == typeof t) r = t, t = null;
|
|
453
|
+
var n = a.test(process.version) ? function(e, t, r, n) {
|
|
454
|
+
return c(e, fs$readdirCallback(e, t, r, n));
|
|
455
|
+
} : function(e, t, r, n) {
|
|
456
|
+
return c(e, t, fs$readdirCallback(e, t, r, n));
|
|
457
|
+
};
|
|
458
|
+
return n(e, t, r);
|
|
459
|
+
function fs$readdirCallback(e, t, r, i) {
|
|
460
|
+
return function(s, o) {
|
|
461
|
+
if (s && ("EMFILE" === s.code || "ENFILE" === s.code)) enqueue([
|
|
462
|
+
n,
|
|
463
|
+
[
|
|
464
|
+
e,
|
|
465
|
+
t,
|
|
466
|
+
r
|
|
467
|
+
],
|
|
468
|
+
s,
|
|
469
|
+
i || Date.now(),
|
|
470
|
+
Date.now()
|
|
471
|
+
]);
|
|
472
|
+
else {
|
|
473
|
+
if (o && o.sort) o.sort();
|
|
474
|
+
if ("function" == typeof r) r.call(this, s, o);
|
|
475
|
+
}
|
|
476
|
+
};
|
|
477
|
+
}
|
|
478
|
+
}
|
|
479
|
+
if ("v0.8" === process.version.substr(0, 4)) {
|
|
480
|
+
var l = s(e);
|
|
481
|
+
ReadStream = l.ReadStream;
|
|
482
|
+
WriteStream = l.WriteStream;
|
|
483
|
+
}
|
|
484
|
+
var f = e.ReadStream;
|
|
485
|
+
if (f) {
|
|
486
|
+
ReadStream.prototype = Object.create(f.prototype);
|
|
487
|
+
ReadStream.prototype.open = ReadStream$open;
|
|
488
|
+
}
|
|
489
|
+
var u = e.WriteStream;
|
|
490
|
+
if (u) {
|
|
491
|
+
WriteStream.prototype = Object.create(u.prototype);
|
|
492
|
+
WriteStream.prototype.open = WriteStream$open;
|
|
493
|
+
}
|
|
494
|
+
Object.defineProperty(e, "ReadStream", {
|
|
495
|
+
get: function() {
|
|
496
|
+
return ReadStream;
|
|
497
|
+
},
|
|
498
|
+
set: function(e) {
|
|
499
|
+
ReadStream = e;
|
|
500
|
+
},
|
|
501
|
+
enumerable: true,
|
|
502
|
+
configurable: true
|
|
503
|
+
});
|
|
504
|
+
Object.defineProperty(e, "WriteStream", {
|
|
505
|
+
get: function() {
|
|
506
|
+
return WriteStream;
|
|
507
|
+
},
|
|
508
|
+
set: function(e) {
|
|
509
|
+
WriteStream = e;
|
|
510
|
+
},
|
|
511
|
+
enumerable: true,
|
|
512
|
+
configurable: true
|
|
513
|
+
});
|
|
514
|
+
var h = ReadStream;
|
|
515
|
+
Object.defineProperty(e, "FileReadStream", {
|
|
516
|
+
get: function() {
|
|
517
|
+
return h;
|
|
518
|
+
},
|
|
519
|
+
set: function(e) {
|
|
520
|
+
h = e;
|
|
521
|
+
},
|
|
522
|
+
enumerable: true,
|
|
523
|
+
configurable: true
|
|
524
|
+
});
|
|
525
|
+
var p = WriteStream;
|
|
526
|
+
Object.defineProperty(e, "FileWriteStream", {
|
|
527
|
+
get: function() {
|
|
528
|
+
return p;
|
|
529
|
+
},
|
|
530
|
+
set: function(e) {
|
|
531
|
+
p = e;
|
|
532
|
+
},
|
|
533
|
+
enumerable: true,
|
|
534
|
+
configurable: true
|
|
535
|
+
});
|
|
536
|
+
function ReadStream(e, t) {
|
|
537
|
+
if (this instanceof ReadStream) return f.apply(this, arguments), this;
|
|
538
|
+
return ReadStream.apply(Object.create(ReadStream.prototype), arguments);
|
|
539
|
+
}
|
|
540
|
+
function ReadStream$open() {
|
|
541
|
+
var e = this;
|
|
542
|
+
open(e.path, e.flags, e.mode, function(t, r) {
|
|
543
|
+
if (t) {
|
|
544
|
+
if (e.autoClose) e.destroy();
|
|
545
|
+
e.emit("error", t);
|
|
546
|
+
} else {
|
|
547
|
+
e.fd = r;
|
|
548
|
+
e.emit("open", r);
|
|
549
|
+
e.read();
|
|
550
|
+
}
|
|
551
|
+
});
|
|
552
|
+
}
|
|
553
|
+
function WriteStream(e, t) {
|
|
554
|
+
if (this instanceof WriteStream) return u.apply(this, arguments), this;
|
|
555
|
+
return WriteStream.apply(Object.create(WriteStream.prototype), arguments);
|
|
556
|
+
}
|
|
557
|
+
function WriteStream$open() {
|
|
558
|
+
var e = this;
|
|
559
|
+
open(e.path, e.flags, e.mode, function(t, r) {
|
|
560
|
+
if (t) {
|
|
561
|
+
e.destroy();
|
|
562
|
+
e.emit("error", t);
|
|
563
|
+
} else {
|
|
564
|
+
e.fd = r;
|
|
565
|
+
e.emit("open", r);
|
|
566
|
+
}
|
|
567
|
+
});
|
|
568
|
+
}
|
|
569
|
+
function createReadStream(t, r) {
|
|
570
|
+
return new e.ReadStream(t, r);
|
|
571
|
+
}
|
|
572
|
+
function createWriteStream(t, r) {
|
|
573
|
+
return new e.WriteStream(t, r);
|
|
574
|
+
}
|
|
575
|
+
var d = e.open;
|
|
576
|
+
e.open = open;
|
|
577
|
+
function open(e, t, r, n) {
|
|
578
|
+
if ("function" == typeof r) n = r, r = null;
|
|
579
|
+
return go$open(e, t, r, n);
|
|
580
|
+
function go$open(e, t, r, n, i) {
|
|
581
|
+
return d(e, t, r, function(s, o) {
|
|
582
|
+
if (s && ("EMFILE" === s.code || "ENFILE" === s.code)) enqueue([
|
|
583
|
+
go$open,
|
|
584
|
+
[
|
|
585
|
+
e,
|
|
586
|
+
t,
|
|
587
|
+
r,
|
|
588
|
+
n
|
|
589
|
+
],
|
|
590
|
+
s,
|
|
591
|
+
i || Date.now(),
|
|
592
|
+
Date.now()
|
|
593
|
+
]);
|
|
594
|
+
else if ("function" == typeof n) n.apply(this, arguments);
|
|
595
|
+
});
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
return e;
|
|
599
|
+
}
|
|
600
|
+
function enqueue(e) {
|
|
601
|
+
f("ENQUEUE", e[0].name, e[1]);
|
|
602
|
+
n[a].push(e);
|
|
603
|
+
retry();
|
|
604
|
+
}
|
|
605
|
+
var h;
|
|
606
|
+
function resetQueue() {
|
|
607
|
+
var e = Date.now();
|
|
608
|
+
for(var t = 0; t < n[a].length; ++t)if (n[a][t].length > 2) {
|
|
609
|
+
n[a][t][3] = e;
|
|
610
|
+
n[a][t][4] = e;
|
|
611
|
+
}
|
|
612
|
+
retry();
|
|
613
|
+
}
|
|
614
|
+
function retry() {
|
|
615
|
+
clearTimeout(h);
|
|
616
|
+
h = void 0;
|
|
617
|
+
if (0 === n[a].length) return;
|
|
618
|
+
var e = n[a].shift();
|
|
619
|
+
var t = e[0];
|
|
620
|
+
var r = e[1];
|
|
621
|
+
var i = e[2];
|
|
622
|
+
var s = e[3];
|
|
623
|
+
var o = e[4];
|
|
624
|
+
if (void 0 === s) {
|
|
625
|
+
f("RETRY", t.name, r);
|
|
626
|
+
t.apply(null, r);
|
|
627
|
+
} else if (Date.now() - s >= 6e4) {
|
|
628
|
+
f("TIMEOUT", t.name, r);
|
|
629
|
+
var c = r.pop();
|
|
630
|
+
if ("function" == typeof c) c.call(null, i);
|
|
631
|
+
} else {
|
|
632
|
+
var l = Date.now() - o;
|
|
633
|
+
var u = Math.max(o - s, 1);
|
|
634
|
+
var p = Math.min(1.2 * u, 100);
|
|
635
|
+
if (l >= p) {
|
|
636
|
+
f("RETRY", t.name, r);
|
|
637
|
+
t.apply(null, r.concat([
|
|
638
|
+
s
|
|
639
|
+
]));
|
|
640
|
+
} else n[a].push(e);
|
|
641
|
+
}
|
|
642
|
+
if (void 0 === h) h = setTimeout(retry, 0);
|
|
643
|
+
}
|
|
644
|
+
},
|
|
645
|
+
876: (e, t, r)=>{
|
|
646
|
+
var n = r(781).Stream;
|
|
647
|
+
e.exports = legacy;
|
|
648
|
+
function legacy(e) {
|
|
649
|
+
return {
|
|
650
|
+
ReadStream: ReadStream,
|
|
651
|
+
WriteStream: WriteStream
|
|
652
|
+
};
|
|
653
|
+
function ReadStream(t, r) {
|
|
654
|
+
if (!(this instanceof ReadStream)) return new ReadStream(t, r);
|
|
655
|
+
n.call(this);
|
|
656
|
+
var i = this;
|
|
657
|
+
this.path = t;
|
|
658
|
+
this.fd = null;
|
|
659
|
+
this.readable = true;
|
|
660
|
+
this.paused = false;
|
|
661
|
+
this.flags = "r";
|
|
662
|
+
this.mode = 438;
|
|
663
|
+
this.bufferSize = 65536;
|
|
664
|
+
r = r || {};
|
|
665
|
+
var s = Object.keys(r);
|
|
666
|
+
for(var o = 0, c = s.length; o < c; o++){
|
|
667
|
+
var a = s[o];
|
|
668
|
+
this[a] = r[a];
|
|
669
|
+
}
|
|
670
|
+
if (this.encoding) this.setEncoding(this.encoding);
|
|
671
|
+
if (void 0 !== this.start) {
|
|
672
|
+
if ("number" != typeof this.start) throw TypeError("start must be a Number");
|
|
673
|
+
if (void 0 === this.end) this.end = 1 / 0;
|
|
674
|
+
else if ("number" != typeof this.end) throw TypeError("end must be a Number");
|
|
675
|
+
if (this.start > this.end) throw new Error("start must be <= end");
|
|
676
|
+
this.pos = this.start;
|
|
677
|
+
}
|
|
678
|
+
if (null !== this.fd) return void process.nextTick(function() {
|
|
679
|
+
i._read();
|
|
680
|
+
});
|
|
681
|
+
e.open(this.path, this.flags, this.mode, function(e, t) {
|
|
682
|
+
if (e) {
|
|
683
|
+
i.emit("error", e);
|
|
684
|
+
i.readable = false;
|
|
685
|
+
return;
|
|
686
|
+
}
|
|
687
|
+
i.fd = t;
|
|
688
|
+
i.emit("open", t);
|
|
689
|
+
i._read();
|
|
690
|
+
});
|
|
691
|
+
}
|
|
692
|
+
function WriteStream(t, r) {
|
|
693
|
+
if (!(this instanceof WriteStream)) return new WriteStream(t, r);
|
|
694
|
+
n.call(this);
|
|
695
|
+
this.path = t;
|
|
696
|
+
this.fd = null;
|
|
697
|
+
this.writable = true;
|
|
698
|
+
this.flags = "w";
|
|
699
|
+
this.encoding = "binary";
|
|
700
|
+
this.mode = 438;
|
|
701
|
+
this.bytesWritten = 0;
|
|
702
|
+
r = r || {};
|
|
703
|
+
var i = Object.keys(r);
|
|
704
|
+
for(var s = 0, o = i.length; s < o; s++){
|
|
705
|
+
var c = i[s];
|
|
706
|
+
this[c] = r[c];
|
|
707
|
+
}
|
|
708
|
+
if (void 0 !== this.start) {
|
|
709
|
+
if ("number" != typeof this.start) throw TypeError("start must be a Number");
|
|
710
|
+
if (this.start < 0) throw new Error("start must be >= zero");
|
|
711
|
+
this.pos = this.start;
|
|
712
|
+
}
|
|
713
|
+
this.busy = false;
|
|
714
|
+
this._queue = [];
|
|
715
|
+
if (null === this.fd) {
|
|
716
|
+
this._open = e.open;
|
|
717
|
+
this._queue.push([
|
|
718
|
+
this._open,
|
|
719
|
+
this.path,
|
|
720
|
+
this.flags,
|
|
721
|
+
this.mode,
|
|
722
|
+
void 0
|
|
723
|
+
]);
|
|
724
|
+
this.flush();
|
|
725
|
+
}
|
|
726
|
+
}
|
|
727
|
+
}
|
|
728
|
+
},
|
|
729
|
+
738: (e, t, r)=>{
|
|
730
|
+
var n = r(57);
|
|
731
|
+
var i = process.cwd;
|
|
732
|
+
var s = null;
|
|
733
|
+
var o = process.env.GRACEFUL_FS_PLATFORM || process.platform;
|
|
734
|
+
process.cwd = function() {
|
|
735
|
+
if (!s) s = i.call(process);
|
|
736
|
+
return s;
|
|
737
|
+
};
|
|
738
|
+
try {
|
|
739
|
+
process.cwd();
|
|
740
|
+
} catch (e) {}
|
|
741
|
+
if ("function" == typeof process.chdir) {
|
|
742
|
+
var c = process.chdir;
|
|
743
|
+
process.chdir = function(e) {
|
|
744
|
+
s = null;
|
|
745
|
+
c.call(process, e);
|
|
746
|
+
};
|
|
747
|
+
if (Object.setPrototypeOf) Object.setPrototypeOf(process.chdir, c);
|
|
748
|
+
}
|
|
749
|
+
e.exports = patch;
|
|
750
|
+
function patch(e) {
|
|
751
|
+
if (n.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) patchLchmod(e);
|
|
752
|
+
if (!e.lutimes) patchLutimes(e);
|
|
753
|
+
e.chown = chownFix(e.chown);
|
|
754
|
+
e.fchown = chownFix(e.fchown);
|
|
755
|
+
e.lchown = chownFix(e.lchown);
|
|
756
|
+
e.chmod = chmodFix(e.chmod);
|
|
757
|
+
e.fchmod = chmodFix(e.fchmod);
|
|
758
|
+
e.lchmod = chmodFix(e.lchmod);
|
|
759
|
+
e.chownSync = chownFixSync(e.chownSync);
|
|
760
|
+
e.fchownSync = chownFixSync(e.fchownSync);
|
|
761
|
+
e.lchownSync = chownFixSync(e.lchownSync);
|
|
762
|
+
e.chmodSync = chmodFixSync(e.chmodSync);
|
|
763
|
+
e.fchmodSync = chmodFixSync(e.fchmodSync);
|
|
764
|
+
e.lchmodSync = chmodFixSync(e.lchmodSync);
|
|
765
|
+
e.stat = statFix(e.stat);
|
|
766
|
+
e.fstat = statFix(e.fstat);
|
|
767
|
+
e.lstat = statFix(e.lstat);
|
|
768
|
+
e.statSync = statFixSync(e.statSync);
|
|
769
|
+
e.fstatSync = statFixSync(e.fstatSync);
|
|
770
|
+
e.lstatSync = statFixSync(e.lstatSync);
|
|
771
|
+
if (e.chmod && !e.lchmod) {
|
|
772
|
+
e.lchmod = function(e, t, r) {
|
|
773
|
+
if (r) process.nextTick(r);
|
|
774
|
+
};
|
|
775
|
+
e.lchmodSync = function() {};
|
|
776
|
+
}
|
|
777
|
+
if (e.chown && !e.lchown) {
|
|
778
|
+
e.lchown = function(e, t, r, n) {
|
|
779
|
+
if (n) process.nextTick(n);
|
|
780
|
+
};
|
|
781
|
+
e.lchownSync = function() {};
|
|
782
|
+
}
|
|
783
|
+
if ("win32" === o) e.rename = "function" != typeof e.rename ? e.rename : function(t) {
|
|
784
|
+
function rename(r, n, i) {
|
|
785
|
+
var s = Date.now();
|
|
786
|
+
var o = 0;
|
|
787
|
+
t(r, n, function CB(c) {
|
|
788
|
+
if (c && ("EACCES" === c.code || "EPERM" === c.code) && Date.now() - s < 6e4) {
|
|
789
|
+
setTimeout(function() {
|
|
790
|
+
e.stat(n, function(e, s) {
|
|
791
|
+
if (e && "ENOENT" === e.code) t(r, n, CB);
|
|
792
|
+
else i(c);
|
|
793
|
+
});
|
|
794
|
+
}, o);
|
|
795
|
+
if (o < 100) o += 10;
|
|
796
|
+
return;
|
|
797
|
+
}
|
|
798
|
+
if (i) i(c);
|
|
799
|
+
});
|
|
800
|
+
}
|
|
801
|
+
if (Object.setPrototypeOf) Object.setPrototypeOf(rename, t);
|
|
802
|
+
return rename;
|
|
803
|
+
}(e.rename);
|
|
804
|
+
e.read = "function" != typeof e.read ? e.read : function(t) {
|
|
805
|
+
function read(r, n, i, s, o, c) {
|
|
806
|
+
var a;
|
|
807
|
+
if (c && "function" == typeof c) {
|
|
808
|
+
var l = 0;
|
|
809
|
+
a = function(f, u, h) {
|
|
810
|
+
if (f && "EAGAIN" === f.code && l < 10) {
|
|
811
|
+
l++;
|
|
812
|
+
return t.call(e, r, n, i, s, o, a);
|
|
813
|
+
}
|
|
814
|
+
c.apply(this, arguments);
|
|
815
|
+
};
|
|
816
|
+
}
|
|
817
|
+
return t.call(e, r, n, i, s, o, a);
|
|
818
|
+
}
|
|
819
|
+
if (Object.setPrototypeOf) Object.setPrototypeOf(read, t);
|
|
820
|
+
return read;
|
|
821
|
+
}(e.read);
|
|
822
|
+
e.readSync = "function" != typeof e.readSync ? e.readSync : function(t) {
|
|
823
|
+
return function(r, n, i, s, o) {
|
|
824
|
+
var c = 0;
|
|
825
|
+
while(true)try {
|
|
826
|
+
return t.call(e, r, n, i, s, o);
|
|
827
|
+
} catch (e) {
|
|
828
|
+
if ("EAGAIN" === e.code && c < 10) {
|
|
829
|
+
c++;
|
|
830
|
+
continue;
|
|
831
|
+
}
|
|
832
|
+
throw e;
|
|
833
|
+
}
|
|
834
|
+
};
|
|
835
|
+
}(e.readSync);
|
|
836
|
+
function patchLchmod(e) {
|
|
837
|
+
e.lchmod = function(t, r, i) {
|
|
838
|
+
e.open(t, n.O_WRONLY | n.O_SYMLINK, r, function(t, n) {
|
|
839
|
+
if (t) {
|
|
840
|
+
if (i) i(t);
|
|
841
|
+
return;
|
|
842
|
+
}
|
|
843
|
+
e.fchmod(n, r, function(t) {
|
|
844
|
+
e.close(n, function(e) {
|
|
845
|
+
if (i) i(t || e);
|
|
846
|
+
});
|
|
847
|
+
});
|
|
848
|
+
});
|
|
849
|
+
};
|
|
850
|
+
e.lchmodSync = function(t, r) {
|
|
851
|
+
var i = e.openSync(t, n.O_WRONLY | n.O_SYMLINK, r);
|
|
852
|
+
var s = true;
|
|
853
|
+
var o;
|
|
854
|
+
try {
|
|
855
|
+
o = e.fchmodSync(i, r);
|
|
856
|
+
s = false;
|
|
857
|
+
} finally{
|
|
858
|
+
if (s) try {
|
|
859
|
+
e.closeSync(i);
|
|
860
|
+
} catch (e) {}
|
|
861
|
+
else e.closeSync(i);
|
|
862
|
+
}
|
|
863
|
+
return o;
|
|
864
|
+
};
|
|
865
|
+
}
|
|
866
|
+
function patchLutimes(e) {
|
|
867
|
+
if (n.hasOwnProperty("O_SYMLINK") && e.futimes) {
|
|
868
|
+
e.lutimes = function(t, r, i, s) {
|
|
869
|
+
e.open(t, n.O_SYMLINK, function(t, n) {
|
|
870
|
+
if (t) {
|
|
871
|
+
if (s) s(t);
|
|
872
|
+
return;
|
|
873
|
+
}
|
|
874
|
+
e.futimes(n, r, i, function(t) {
|
|
875
|
+
e.close(n, function(e) {
|
|
876
|
+
if (s) s(t || e);
|
|
877
|
+
});
|
|
878
|
+
});
|
|
879
|
+
});
|
|
880
|
+
};
|
|
881
|
+
e.lutimesSync = function(t, r, i) {
|
|
882
|
+
var s = e.openSync(t, n.O_SYMLINK);
|
|
883
|
+
var o;
|
|
884
|
+
var c = true;
|
|
885
|
+
try {
|
|
886
|
+
o = e.futimesSync(s, r, i);
|
|
887
|
+
c = false;
|
|
888
|
+
} finally{
|
|
889
|
+
if (c) try {
|
|
890
|
+
e.closeSync(s);
|
|
891
|
+
} catch (e) {}
|
|
892
|
+
else e.closeSync(s);
|
|
893
|
+
}
|
|
894
|
+
return o;
|
|
895
|
+
};
|
|
896
|
+
} else if (e.futimes) {
|
|
897
|
+
e.lutimes = function(e, t, r, n) {
|
|
898
|
+
if (n) process.nextTick(n);
|
|
899
|
+
};
|
|
900
|
+
e.lutimesSync = function() {};
|
|
901
|
+
}
|
|
902
|
+
}
|
|
903
|
+
function chmodFix(t) {
|
|
904
|
+
if (!t) return t;
|
|
905
|
+
return function(r, n, i) {
|
|
906
|
+
return t.call(e, r, n, function(e) {
|
|
907
|
+
if (chownErOk(e)) e = null;
|
|
908
|
+
if (i) i.apply(this, arguments);
|
|
909
|
+
});
|
|
910
|
+
};
|
|
911
|
+
}
|
|
912
|
+
function chmodFixSync(t) {
|
|
913
|
+
if (!t) return t;
|
|
914
|
+
return function(r, n) {
|
|
915
|
+
try {
|
|
916
|
+
return t.call(e, r, n);
|
|
917
|
+
} catch (e) {
|
|
918
|
+
if (!chownErOk(e)) throw e;
|
|
919
|
+
}
|
|
920
|
+
};
|
|
921
|
+
}
|
|
922
|
+
function chownFix(t) {
|
|
923
|
+
if (!t) return t;
|
|
924
|
+
return function(r, n, i, s) {
|
|
925
|
+
return t.call(e, r, n, i, function(e) {
|
|
926
|
+
if (chownErOk(e)) e = null;
|
|
927
|
+
if (s) s.apply(this, arguments);
|
|
928
|
+
});
|
|
929
|
+
};
|
|
930
|
+
}
|
|
931
|
+
function chownFixSync(t) {
|
|
932
|
+
if (!t) return t;
|
|
933
|
+
return function(r, n, i) {
|
|
934
|
+
try {
|
|
935
|
+
return t.call(e, r, n, i);
|
|
936
|
+
} catch (e) {
|
|
937
|
+
if (!chownErOk(e)) throw e;
|
|
938
|
+
}
|
|
939
|
+
};
|
|
940
|
+
}
|
|
941
|
+
function statFix(t) {
|
|
942
|
+
if (!t) return t;
|
|
943
|
+
return function(r, n, i) {
|
|
944
|
+
if ("function" == typeof n) {
|
|
945
|
+
i = n;
|
|
946
|
+
n = null;
|
|
947
|
+
}
|
|
948
|
+
function callback(e, t) {
|
|
949
|
+
if (t) {
|
|
950
|
+
if (t.uid < 0) t.uid += 4294967296;
|
|
951
|
+
if (t.gid < 0) t.gid += 4294967296;
|
|
952
|
+
}
|
|
953
|
+
if (i) i.apply(this, arguments);
|
|
954
|
+
}
|
|
955
|
+
return n ? t.call(e, r, n, callback) : t.call(e, r, callback);
|
|
956
|
+
};
|
|
957
|
+
}
|
|
958
|
+
function statFixSync(t) {
|
|
959
|
+
if (!t) return t;
|
|
960
|
+
return function(r, n) {
|
|
961
|
+
var i = n ? t.call(e, r, n) : t.call(e, r);
|
|
962
|
+
if (i) {
|
|
963
|
+
if (i.uid < 0) i.uid += 4294967296;
|
|
964
|
+
if (i.gid < 0) i.gid += 4294967296;
|
|
965
|
+
}
|
|
966
|
+
return i;
|
|
967
|
+
};
|
|
968
|
+
}
|
|
969
|
+
function chownErOk(e) {
|
|
970
|
+
if (!e) return true;
|
|
971
|
+
if ("ENOSYS" === e.code) return true;
|
|
972
|
+
var t = !process.getuid || 0 !== process.getuid();
|
|
973
|
+
if (t) {
|
|
974
|
+
if ("EINVAL" === e.code || "EPERM" === e.code) return true;
|
|
975
|
+
}
|
|
976
|
+
return false;
|
|
977
|
+
}
|
|
978
|
+
}
|
|
979
|
+
},
|
|
980
|
+
589: (e)=>{
|
|
981
|
+
"use strict";
|
|
982
|
+
e.exports = function(e) {
|
|
983
|
+
if (!e) return false;
|
|
984
|
+
return e instanceof Array || Array.isArray(e) || e.length >= 0 && e.splice instanceof Function;
|
|
985
|
+
};
|
|
986
|
+
},
|
|
987
|
+
9: (e)=>{
|
|
988
|
+
"use strict";
|
|
989
|
+
e.exports = parseJson;
|
|
990
|
+
function parseJson(e, t, r) {
|
|
991
|
+
r = r || 20;
|
|
992
|
+
try {
|
|
993
|
+
return JSON.parse(e, t);
|
|
994
|
+
} catch (t) {
|
|
995
|
+
if ("string" != typeof e) {
|
|
996
|
+
const t = Array.isArray(e) && 0 === e.length;
|
|
997
|
+
const r = "Cannot parse " + (t ? "an empty array" : String(e));
|
|
998
|
+
throw new TypeError(r);
|
|
999
|
+
}
|
|
1000
|
+
const n = t.message.match(/^Unexpected token.*position\s+(\d+)/i);
|
|
1001
|
+
const i = n ? +n[1] : t.message.match(/^Unexpected end of JSON.*/i) ? e.length - 1 : null;
|
|
1002
|
+
if (null != i) {
|
|
1003
|
+
const n = i <= r ? 0 : i - r;
|
|
1004
|
+
const s = i + r >= e.length ? e.length : i + r;
|
|
1005
|
+
t.message += ` while parsing near '${0 === n ? "" : "..."}${e.slice(n, s)}${s === e.length ? "" : "..."}'`;
|
|
1006
|
+
} else t.message += ` while parsing '${e.slice(0, 2 * r)}'`;
|
|
1007
|
+
throw t;
|
|
1008
|
+
}
|
|
1009
|
+
}
|
|
1010
|
+
},
|
|
1011
|
+
324: (e, t, r)=>{
|
|
1012
|
+
"use strict";
|
|
1013
|
+
const n = r(17);
|
|
1014
|
+
const i = r(127);
|
|
1015
|
+
const s = r(308);
|
|
1016
|
+
const o = r(264);
|
|
1017
|
+
const c = r(119);
|
|
1018
|
+
const parse = (e, t)=>o(s(e), n.relative(".", t));
|
|
1019
|
+
e.exports = (e)=>c(i.readFile)(e, "utf8").then((t)=>parse(t, e));
|
|
1020
|
+
e.exports.sync = (e)=>parse(i.readFileSync(e, "utf8"), e);
|
|
1021
|
+
},
|
|
1022
|
+
69: (e, t, r)=>{
|
|
1023
|
+
"use strict";
|
|
1024
|
+
const n = r(17);
|
|
1025
|
+
const i = r(383);
|
|
1026
|
+
const s = r(367);
|
|
1027
|
+
e.exports = (e, t)=>{
|
|
1028
|
+
t = Object.assign({
|
|
1029
|
+
cwd: process.cwd()
|
|
1030
|
+
}, t);
|
|
1031
|
+
return s(e, (e)=>i(n.resolve(t.cwd, e)), t);
|
|
1032
|
+
};
|
|
1033
|
+
e.exports.sync = (e, t)=>{
|
|
1034
|
+
t = Object.assign({
|
|
1035
|
+
cwd: process.cwd()
|
|
1036
|
+
}, t);
|
|
1037
|
+
for (const r of e)if (i.sync(n.resolve(t.cwd, r))) return r;
|
|
1038
|
+
};
|
|
1039
|
+
},
|
|
1040
|
+
273: (e, t, r)=>{
|
|
1041
|
+
"use strict";
|
|
1042
|
+
const n = r(965);
|
|
1043
|
+
e.exports = (e)=>{
|
|
1044
|
+
if (e < 1) throw new TypeError("Expected `concurrency` to be a number from 1 and up");
|
|
1045
|
+
const t = [];
|
|
1046
|
+
let r = 0;
|
|
1047
|
+
const next = ()=>{
|
|
1048
|
+
r--;
|
|
1049
|
+
if (t.length > 0) t.shift()();
|
|
1050
|
+
};
|
|
1051
|
+
return (i)=>new Promise((s, o)=>{
|
|
1052
|
+
const run = ()=>{
|
|
1053
|
+
r++;
|
|
1054
|
+
n(i).then((e)=>{
|
|
1055
|
+
s(e);
|
|
1056
|
+
next();
|
|
1057
|
+
}, (e)=>{
|
|
1058
|
+
o(e);
|
|
1059
|
+
next();
|
|
1060
|
+
});
|
|
1061
|
+
};
|
|
1062
|
+
if (r < e) run();
|
|
1063
|
+
else t.push(run);
|
|
1064
|
+
});
|
|
1065
|
+
};
|
|
1066
|
+
},
|
|
1067
|
+
367: (e, t, r)=>{
|
|
1068
|
+
"use strict";
|
|
1069
|
+
const n = r(273);
|
|
1070
|
+
class EndError extends Error {
|
|
1071
|
+
constructor(e){
|
|
1072
|
+
super();
|
|
1073
|
+
this.value = e;
|
|
1074
|
+
}
|
|
1075
|
+
}
|
|
1076
|
+
const finder = (e)=>Promise.all(e).then((e)=>true === e[1] && Promise.reject(new EndError(e[0])));
|
|
1077
|
+
e.exports = (e, t, r)=>{
|
|
1078
|
+
r = Object.assign({
|
|
1079
|
+
concurrency: 1 / 0,
|
|
1080
|
+
preserveOrder: true
|
|
1081
|
+
}, r);
|
|
1082
|
+
const i = n(r.concurrency);
|
|
1083
|
+
const s = Array.from(e).map((e)=>[
|
|
1084
|
+
e,
|
|
1085
|
+
i(()=>Promise.resolve(e).then(t))
|
|
1086
|
+
]);
|
|
1087
|
+
const o = n(r.preserveOrder ? 1 : 1 / 0);
|
|
1088
|
+
return Promise.all(s.map((e)=>o(()=>finder(e)))).then(()=>{}).catch((e)=>e instanceof EndError ? e.value : Promise.reject(e));
|
|
1089
|
+
};
|
|
1090
|
+
},
|
|
1091
|
+
965: (e)=>{
|
|
1092
|
+
"use strict";
|
|
1093
|
+
e.exports = (e)=>new Promise((t)=>{
|
|
1094
|
+
t(e());
|
|
1095
|
+
});
|
|
1096
|
+
},
|
|
1097
|
+
264: (e, t, r)=>{
|
|
1098
|
+
"use strict";
|
|
1099
|
+
const n = r(305);
|
|
1100
|
+
const i = r(9);
|
|
1101
|
+
const s = n("JSONError", {
|
|
1102
|
+
fileName: n.append("in %s")
|
|
1103
|
+
});
|
|
1104
|
+
e.exports = (e, t, r)=>{
|
|
1105
|
+
if ("string" == typeof t) {
|
|
1106
|
+
r = t;
|
|
1107
|
+
t = null;
|
|
1108
|
+
}
|
|
1109
|
+
try {
|
|
1110
|
+
try {
|
|
1111
|
+
return JSON.parse(e, t);
|
|
1112
|
+
} catch (r) {
|
|
1113
|
+
i(e, t);
|
|
1114
|
+
throw r;
|
|
1115
|
+
}
|
|
1116
|
+
} catch (e) {
|
|
1117
|
+
e.message = e.message.replace(/\n/g, "");
|
|
1118
|
+
const t = new s(e);
|
|
1119
|
+
if (r) t.fileName = r;
|
|
1120
|
+
throw t;
|
|
1121
|
+
}
|
|
1122
|
+
};
|
|
1123
|
+
},
|
|
1124
|
+
383: (e, t, r)=>{
|
|
1125
|
+
"use strict";
|
|
1126
|
+
const n = r(147);
|
|
1127
|
+
e.exports = (e)=>new Promise((t)=>{
|
|
1128
|
+
n.access(e, (e)=>{
|
|
1129
|
+
t(!e);
|
|
1130
|
+
});
|
|
1131
|
+
});
|
|
1132
|
+
e.exports.sync = (e)=>{
|
|
1133
|
+
try {
|
|
1134
|
+
n.accessSync(e);
|
|
1135
|
+
return true;
|
|
1136
|
+
} catch (e) {
|
|
1137
|
+
return false;
|
|
1138
|
+
}
|
|
1139
|
+
};
|
|
1140
|
+
},
|
|
1141
|
+
119: (e)=>{
|
|
1142
|
+
"use strict";
|
|
1143
|
+
const processFn = (e, t)=>function() {
|
|
1144
|
+
const r = t.promiseModule;
|
|
1145
|
+
const n = new Array(arguments.length);
|
|
1146
|
+
for(let e = 0; e < arguments.length; e++)n[e] = arguments[e];
|
|
1147
|
+
return new r((r, i)=>{
|
|
1148
|
+
if (t.errorFirst) n.push(function(e, n) {
|
|
1149
|
+
if (t.multiArgs) {
|
|
1150
|
+
const t = new Array(arguments.length - 1);
|
|
1151
|
+
for(let e = 1; e < arguments.length; e++)t[e - 1] = arguments[e];
|
|
1152
|
+
if (e) {
|
|
1153
|
+
t.unshift(e);
|
|
1154
|
+
i(t);
|
|
1155
|
+
} else r(t);
|
|
1156
|
+
} else if (e) i(e);
|
|
1157
|
+
else r(n);
|
|
1158
|
+
});
|
|
1159
|
+
else n.push(function(e) {
|
|
1160
|
+
if (t.multiArgs) {
|
|
1161
|
+
const e = new Array(arguments.length - 1);
|
|
1162
|
+
for(let t = 0; t < arguments.length; t++)e[t] = arguments[t];
|
|
1163
|
+
r(e);
|
|
1164
|
+
} else r(e);
|
|
1165
|
+
});
|
|
1166
|
+
e.apply(this, n);
|
|
1167
|
+
});
|
|
1168
|
+
};
|
|
1169
|
+
e.exports = (e, t)=>{
|
|
1170
|
+
t = Object.assign({
|
|
1171
|
+
exclude: [
|
|
1172
|
+
/.+(Sync|Stream)$/
|
|
1173
|
+
],
|
|
1174
|
+
errorFirst: true,
|
|
1175
|
+
promiseModule: Promise
|
|
1176
|
+
}, t);
|
|
1177
|
+
const filter = (e)=>{
|
|
1178
|
+
const match = (t)=>"string" == typeof t ? e === t : t.test(e);
|
|
1179
|
+
return t.include ? t.include.some(match) : !t.exclude.some(match);
|
|
1180
|
+
};
|
|
1181
|
+
let r;
|
|
1182
|
+
r = "function" == typeof e ? function() {
|
|
1183
|
+
if (t.excludeMain) return e.apply(this, arguments);
|
|
1184
|
+
return processFn(e, t).apply(this, arguments);
|
|
1185
|
+
} : Object.create(Object.getPrototypeOf(e));
|
|
1186
|
+
for(const n in e){
|
|
1187
|
+
const i = e[n];
|
|
1188
|
+
r[n] = "function" == typeof i && filter(n) ? processFn(i, t) : i;
|
|
1189
|
+
}
|
|
1190
|
+
return r;
|
|
1191
|
+
};
|
|
1192
|
+
},
|
|
1193
|
+
817: (e, t, r)=>{
|
|
1194
|
+
"use strict";
|
|
1195
|
+
const n = r(17);
|
|
1196
|
+
const i = r(834);
|
|
1197
|
+
const s = r(324);
|
|
1198
|
+
const o = new WeakMap;
|
|
1199
|
+
const filepath = (e)=>o.get(e);
|
|
1200
|
+
const findNextCwd = (e)=>n.resolve(n.dirname(e), "..");
|
|
1201
|
+
const addFp = (e, t)=>{
|
|
1202
|
+
o.set(e, t);
|
|
1203
|
+
return e;
|
|
1204
|
+
};
|
|
1205
|
+
const pkgConf = (e, t)=>{
|
|
1206
|
+
if (!e) return Promise.reject(new TypeError("Expected a namespace"));
|
|
1207
|
+
t = t || {};
|
|
1208
|
+
return i("package.json", t.cwd ? {
|
|
1209
|
+
cwd: t.cwd
|
|
1210
|
+
} : {}).then((r)=>{
|
|
1211
|
+
if (!r) return addFp(Object.assign({}, t.defaults), r);
|
|
1212
|
+
return s(r).then((n)=>{
|
|
1213
|
+
if (t.skipOnFalse && false === n[e]) {
|
|
1214
|
+
const n = Object.assign({}, t, {
|
|
1215
|
+
cwd: findNextCwd(r)
|
|
1216
|
+
});
|
|
1217
|
+
return pkgConf(e, n);
|
|
1218
|
+
}
|
|
1219
|
+
return addFp(Object.assign({}, t.defaults, n[e]), r);
|
|
1220
|
+
});
|
|
1221
|
+
});
|
|
1222
|
+
};
|
|
1223
|
+
const sync = (e, t)=>{
|
|
1224
|
+
if (!e) throw new TypeError("Expected a namespace");
|
|
1225
|
+
t = t || {};
|
|
1226
|
+
const r = i.sync("package.json", t.cwd ? {
|
|
1227
|
+
cwd: t.cwd
|
|
1228
|
+
} : {});
|
|
1229
|
+
if (!r) return addFp(Object.assign({}, t.defaults), r);
|
|
1230
|
+
const n = s.sync(r);
|
|
1231
|
+
if (t.skipOnFalse && false === n[e]) {
|
|
1232
|
+
const n = Object.assign({}, t, {
|
|
1233
|
+
cwd: findNextCwd(r)
|
|
1234
|
+
});
|
|
1235
|
+
return sync(e, n);
|
|
1236
|
+
}
|
|
1237
|
+
return addFp(Object.assign({}, t.defaults, n[e]), r);
|
|
1238
|
+
};
|
|
1239
|
+
e.exports = pkgConf;
|
|
1240
|
+
e.exports.filepath = filepath;
|
|
1241
|
+
e.exports.sync = sync;
|
|
1242
|
+
},
|
|
1243
|
+
567: (e, t, r)=>{
|
|
1244
|
+
"use strict";
|
|
1245
|
+
const n = r(852);
|
|
1246
|
+
e.exports = Object.assign(new n, {
|
|
1247
|
+
Signale: n
|
|
1248
|
+
});
|
|
1249
|
+
},
|
|
1250
|
+
852: (e, t, r)=>{
|
|
1251
|
+
"use strict";
|
|
1252
|
+
const n = r(837);
|
|
1253
|
+
const i = r(17);
|
|
1254
|
+
const s = r(521);
|
|
1255
|
+
const o = r(234);
|
|
1256
|
+
const c = r(877);
|
|
1257
|
+
const a = r(817);
|
|
1258
|
+
const l = r(684);
|
|
1259
|
+
const f = r(616);
|
|
1260
|
+
const { green: u, grey: h, red: p, underline: d, yellow: g } = o;
|
|
1261
|
+
let m = false;
|
|
1262
|
+
const y = l.options.default;
|
|
1263
|
+
const b = l.name;
|
|
1264
|
+
class Signale {
|
|
1265
|
+
constructor(e = {}){
|
|
1266
|
+
this._interactive = e.interactive || false;
|
|
1267
|
+
this._config = Object.assign(this.packageConfiguration, e.config);
|
|
1268
|
+
this._customTypes = Object.assign({}, e.types);
|
|
1269
|
+
this._disabled = e.disabled || false;
|
|
1270
|
+
this._scopeName = e.scope || "";
|
|
1271
|
+
this._timers = e.timers || new Map;
|
|
1272
|
+
this._types = this._mergeTypes(f, this._customTypes);
|
|
1273
|
+
this._stream = e.stream || process.stdout;
|
|
1274
|
+
this._longestLabel = this._getLongestLabel();
|
|
1275
|
+
this._secrets = e.secrets || [];
|
|
1276
|
+
this._generalLogLevel = this._validateLogLevel(e.logLevel);
|
|
1277
|
+
Object.keys(this._types).forEach((e)=>{
|
|
1278
|
+
this[e] = this._logger.bind(this, e);
|
|
1279
|
+
});
|
|
1280
|
+
}
|
|
1281
|
+
get _now() {
|
|
1282
|
+
return Date.now();
|
|
1283
|
+
}
|
|
1284
|
+
get scopeName() {
|
|
1285
|
+
return this._scopeName;
|
|
1286
|
+
}
|
|
1287
|
+
get currentOptions() {
|
|
1288
|
+
return Object.assign({}, {
|
|
1289
|
+
config: this._config,
|
|
1290
|
+
disabled: this._disabled,
|
|
1291
|
+
types: this._customTypes,
|
|
1292
|
+
interactive: this._interactive,
|
|
1293
|
+
timers: this._timers,
|
|
1294
|
+
stream: this._stream,
|
|
1295
|
+
secrets: this._secrets,
|
|
1296
|
+
logLevel: this._generalLogLevel
|
|
1297
|
+
});
|
|
1298
|
+
}
|
|
1299
|
+
get date() {
|
|
1300
|
+
return (new Date).toLocaleDateString();
|
|
1301
|
+
}
|
|
1302
|
+
get timestamp() {
|
|
1303
|
+
return (new Date).toLocaleTimeString();
|
|
1304
|
+
}
|
|
1305
|
+
get filename() {
|
|
1306
|
+
const e = Error.prepareStackTrace;
|
|
1307
|
+
Error.prepareStackTrace = (e, t)=>t;
|
|
1308
|
+
const { stack: t } = new Error;
|
|
1309
|
+
Error.prepareStackTrace = e;
|
|
1310
|
+
const r = t.map((e)=>e.getFileName());
|
|
1311
|
+
const n = r.find((e)=>e !== r[0]);
|
|
1312
|
+
return n ? i.basename(n) : "anonymous";
|
|
1313
|
+
}
|
|
1314
|
+
get packageConfiguration() {
|
|
1315
|
+
return a.sync(b, {
|
|
1316
|
+
defaults: y
|
|
1317
|
+
});
|
|
1318
|
+
}
|
|
1319
|
+
get _longestUnderlinedLabel() {
|
|
1320
|
+
return d(this._longestLabel);
|
|
1321
|
+
}
|
|
1322
|
+
get _logLevels() {
|
|
1323
|
+
return {
|
|
1324
|
+
info: 0,
|
|
1325
|
+
timer: 1,
|
|
1326
|
+
debug: 2,
|
|
1327
|
+
warn: 3,
|
|
1328
|
+
error: 4
|
|
1329
|
+
};
|
|
1330
|
+
}
|
|
1331
|
+
set configuration(e) {
|
|
1332
|
+
this._config = Object.assign(this.packageConfiguration, e);
|
|
1333
|
+
}
|
|
1334
|
+
_arrayify(e) {
|
|
1335
|
+
return Array.isArray(e) ? e : [
|
|
1336
|
+
e
|
|
1337
|
+
];
|
|
1338
|
+
}
|
|
1339
|
+
_timeSpan(e) {
|
|
1340
|
+
return this._now - e;
|
|
1341
|
+
}
|
|
1342
|
+
_getLongestLabel() {
|
|
1343
|
+
const { _types: e } = this;
|
|
1344
|
+
const t = Object.keys(e).map((t)=>e[t].label);
|
|
1345
|
+
return t.reduce((e, t)=>e.length > t.length ? e : t);
|
|
1346
|
+
}
|
|
1347
|
+
_validateLogLevel(e) {
|
|
1348
|
+
return Object.keys(this._logLevels).includes(e) ? e : "info";
|
|
1349
|
+
}
|
|
1350
|
+
_mergeTypes(e, t) {
|
|
1351
|
+
const r = Object.assign({}, e);
|
|
1352
|
+
Object.keys(t).forEach((e)=>{
|
|
1353
|
+
r[e] = Object.assign({}, r[e], t[e]);
|
|
1354
|
+
});
|
|
1355
|
+
return r;
|
|
1356
|
+
}
|
|
1357
|
+
_filterSecrets(e) {
|
|
1358
|
+
const { _secrets: t } = this;
|
|
1359
|
+
if (0 === t.length) return e;
|
|
1360
|
+
let r = e;
|
|
1361
|
+
t.forEach((e)=>{
|
|
1362
|
+
r = r.replace(new RegExp(e, "g"), "[secure]");
|
|
1363
|
+
});
|
|
1364
|
+
return r;
|
|
1365
|
+
}
|
|
1366
|
+
_formatStream(e) {
|
|
1367
|
+
return this._arrayify(e);
|
|
1368
|
+
}
|
|
1369
|
+
_formatDate() {
|
|
1370
|
+
return `[${this.date}]`;
|
|
1371
|
+
}
|
|
1372
|
+
_formatFilename() {
|
|
1373
|
+
return `[${this.filename}]`;
|
|
1374
|
+
}
|
|
1375
|
+
_formatScopeName() {
|
|
1376
|
+
if (Array.isArray(this._scopeName)) {
|
|
1377
|
+
const e = this._scopeName.filter((e)=>0 !== e.length);
|
|
1378
|
+
return `${e.map((e)=>`[${e.trim()}]`).join(" ")}`;
|
|
1379
|
+
}
|
|
1380
|
+
return `[${this._scopeName}]`;
|
|
1381
|
+
}
|
|
1382
|
+
_formatTimestamp() {
|
|
1383
|
+
return `[${this.timestamp}]`;
|
|
1384
|
+
}
|
|
1385
|
+
_formatMessage(e) {
|
|
1386
|
+
return n.format(...this._arrayify(e));
|
|
1387
|
+
}
|
|
1388
|
+
_meta() {
|
|
1389
|
+
const e = [];
|
|
1390
|
+
if (this._config.displayDate) e.push(this._formatDate());
|
|
1391
|
+
if (this._config.displayTimestamp) e.push(this._formatTimestamp());
|
|
1392
|
+
if (this._config.displayFilename) e.push(this._formatFilename());
|
|
1393
|
+
if (0 !== this._scopeName.length && this._config.displayScope) e.push(this._formatScopeName());
|
|
1394
|
+
if (0 !== e.length) {
|
|
1395
|
+
e.push(`${c.pointerSmall}`);
|
|
1396
|
+
return e.map((e)=>h(e));
|
|
1397
|
+
}
|
|
1398
|
+
return e;
|
|
1399
|
+
}
|
|
1400
|
+
_hasAdditional({ suffix: e, prefix: t }, r) {
|
|
1401
|
+
return e || t ? "" : this._formatMessage(r);
|
|
1402
|
+
}
|
|
1403
|
+
_buildSignale(e, ...t) {
|
|
1404
|
+
let [r, n] = [
|
|
1405
|
+
{},
|
|
1406
|
+
{}
|
|
1407
|
+
];
|
|
1408
|
+
if (1 === t.length && "object" == typeof t[0] && null !== t[0]) if (t[0] instanceof Error) [r] = t;
|
|
1409
|
+
else {
|
|
1410
|
+
const [{ prefix: e, message: i, suffix: s }] = t;
|
|
1411
|
+
n = Object.assign({}, {
|
|
1412
|
+
suffix: s,
|
|
1413
|
+
prefix: e
|
|
1414
|
+
});
|
|
1415
|
+
r = i ? this._formatMessage(i) : this._hasAdditional(n, t);
|
|
1416
|
+
}
|
|
1417
|
+
else r = this._formatMessage(t);
|
|
1418
|
+
const i = this._meta();
|
|
1419
|
+
if (n.prefix) if (this._config.underlinePrefix) i.push(d(n.prefix));
|
|
1420
|
+
else i.push(n.prefix);
|
|
1421
|
+
if (this._config.displayBadge && e.badge) i.push(o[e.color](this._padEnd(e.badge, e.badge.length + 1)));
|
|
1422
|
+
if (this._config.displayLabel && e.label) {
|
|
1423
|
+
const t = this._config.uppercaseLabel ? e.label.toUpperCase() : e.label;
|
|
1424
|
+
if (this._config.underlineLabel) i.push(o[e.color](this._padEnd(d(t), this._longestUnderlinedLabel.length + 1)));
|
|
1425
|
+
else i.push(o[e.color](this._padEnd(t, this._longestLabel.length + 1)));
|
|
1426
|
+
}
|
|
1427
|
+
if (r instanceof Error && r.stack) {
|
|
1428
|
+
const [e, ...t] = r.stack.split("\n");
|
|
1429
|
+
if (this._config.underlineMessage) i.push(d(e));
|
|
1430
|
+
else i.push(e);
|
|
1431
|
+
i.push(h(t.map((e)=>e.replace(/^/, "\n")).join("")));
|
|
1432
|
+
return i.join(" ");
|
|
1433
|
+
}
|
|
1434
|
+
if (this._config.underlineMessage) i.push(d(r));
|
|
1435
|
+
else i.push(r);
|
|
1436
|
+
if (n.suffix) if (this._config.underlineSuffix) i.push(d(n.suffix));
|
|
1437
|
+
else i.push(n.suffix);
|
|
1438
|
+
return i.join(" ");
|
|
1439
|
+
}
|
|
1440
|
+
_write(e, t) {
|
|
1441
|
+
if (this._interactive && e.isTTY && m) {
|
|
1442
|
+
s.moveCursor(e, 0, -1);
|
|
1443
|
+
s.clearLine(e);
|
|
1444
|
+
s.cursorTo(e, 0);
|
|
1445
|
+
}
|
|
1446
|
+
e.write(t + "\n");
|
|
1447
|
+
m = this._interactive;
|
|
1448
|
+
}
|
|
1449
|
+
_log(e, t = this._stream, r) {
|
|
1450
|
+
if (this.isEnabled() && this._logLevels[r] >= this._logLevels[this._generalLogLevel]) this._formatStream(t).forEach((t)=>{
|
|
1451
|
+
this._write(t, e);
|
|
1452
|
+
});
|
|
1453
|
+
}
|
|
1454
|
+
_logger(e, ...t) {
|
|
1455
|
+
const { stream: r, logLevel: n } = this._types[e];
|
|
1456
|
+
const i = this._buildSignale(this._types[e], ...t);
|
|
1457
|
+
this._log(this._filterSecrets(i), r, this._validateLogLevel(n));
|
|
1458
|
+
}
|
|
1459
|
+
_padEnd(e, t) {
|
|
1460
|
+
e = String(e);
|
|
1461
|
+
t = parseInt(t, 10) || 0;
|
|
1462
|
+
if (e.length >= t) return e;
|
|
1463
|
+
if (String.prototype.padEnd) return e.padEnd(t);
|
|
1464
|
+
t -= e.length;
|
|
1465
|
+
return e + " ".repeat(t);
|
|
1466
|
+
}
|
|
1467
|
+
addSecrets(e) {
|
|
1468
|
+
if (!Array.isArray(e)) throw new TypeError("Argument must be an array.");
|
|
1469
|
+
this._secrets.push(...e);
|
|
1470
|
+
}
|
|
1471
|
+
clearSecrets() {
|
|
1472
|
+
this._secrets = [];
|
|
1473
|
+
}
|
|
1474
|
+
config(e) {
|
|
1475
|
+
this.configuration = e;
|
|
1476
|
+
}
|
|
1477
|
+
disable() {
|
|
1478
|
+
this._disabled = true;
|
|
1479
|
+
}
|
|
1480
|
+
enable() {
|
|
1481
|
+
this._disabled = false;
|
|
1482
|
+
}
|
|
1483
|
+
isEnabled() {
|
|
1484
|
+
return !this._disabled;
|
|
1485
|
+
}
|
|
1486
|
+
scope(...e) {
|
|
1487
|
+
if (0 === e.length) throw new Error("No scope name was defined.");
|
|
1488
|
+
return new Signale(Object.assign(this.currentOptions, {
|
|
1489
|
+
scope: e
|
|
1490
|
+
}));
|
|
1491
|
+
}
|
|
1492
|
+
unscope() {
|
|
1493
|
+
this._scopeName = "";
|
|
1494
|
+
}
|
|
1495
|
+
time(e) {
|
|
1496
|
+
if (!e) e = `timer_${this._timers.size}`;
|
|
1497
|
+
this._timers.set(e, this._now);
|
|
1498
|
+
const t = this._meta();
|
|
1499
|
+
t.push(u(this._padEnd(this._types.start.badge, 2)));
|
|
1500
|
+
if (this._config.underlineLabel) t.push(u(this._padEnd(d(e), this._longestUnderlinedLabel.length + 1)));
|
|
1501
|
+
else t.push(u(this._padEnd(e, this._longestLabel.length + 1)));
|
|
1502
|
+
t.push("Initialized timer...");
|
|
1503
|
+
this._log(t.join(" "), this._stream, "timer");
|
|
1504
|
+
return e;
|
|
1505
|
+
}
|
|
1506
|
+
timeEnd(e) {
|
|
1507
|
+
if (!e && this._timers.size) {
|
|
1508
|
+
const is = (e)=>e.includes("timer_");
|
|
1509
|
+
e = [
|
|
1510
|
+
...this._timers.keys()
|
|
1511
|
+
].reduceRight((e, t)=>is(e) ? e : is(t) ? t : null);
|
|
1512
|
+
}
|
|
1513
|
+
if (this._timers.has(e)) {
|
|
1514
|
+
const t = this._timeSpan(this._timers.get(e));
|
|
1515
|
+
this._timers.delete(e);
|
|
1516
|
+
const r = this._meta();
|
|
1517
|
+
r.push(p(this._padEnd(this._types.pause.badge, 2)));
|
|
1518
|
+
if (this._config.underlineLabel) r.push(p(this._padEnd(d(e), this._longestUnderlinedLabel.length + 1)));
|
|
1519
|
+
else r.push(p(this._padEnd(e, this._longestLabel.length + 1)));
|
|
1520
|
+
r.push("Timer run for:");
|
|
1521
|
+
r.push(g(t < 1e3 ? t + "ms" : (t / 1e3).toFixed(2) + "s"));
|
|
1522
|
+
this._log(r.join(" "), this._stream, "timer");
|
|
1523
|
+
return {
|
|
1524
|
+
label: e,
|
|
1525
|
+
span: t
|
|
1526
|
+
};
|
|
1527
|
+
}
|
|
1528
|
+
}
|
|
1529
|
+
}
|
|
1530
|
+
e.exports = Signale;
|
|
1531
|
+
},
|
|
1532
|
+
616: (e, t, r)=>{
|
|
1533
|
+
"use strict";
|
|
1534
|
+
const n = r(877);
|
|
1535
|
+
e.exports = {
|
|
1536
|
+
error: {
|
|
1537
|
+
badge: n.cross,
|
|
1538
|
+
color: "red",
|
|
1539
|
+
label: "error",
|
|
1540
|
+
logLevel: "error"
|
|
1541
|
+
},
|
|
1542
|
+
fatal: {
|
|
1543
|
+
badge: n.cross,
|
|
1544
|
+
color: "red",
|
|
1545
|
+
label: "fatal",
|
|
1546
|
+
logLevel: "error"
|
|
1547
|
+
},
|
|
1548
|
+
fav: {
|
|
1549
|
+
badge: n("❤"),
|
|
1550
|
+
color: "magenta",
|
|
1551
|
+
label: "favorite",
|
|
1552
|
+
logLevel: "info"
|
|
1553
|
+
},
|
|
1554
|
+
info: {
|
|
1555
|
+
badge: n.info,
|
|
1556
|
+
color: "blue",
|
|
1557
|
+
label: "info",
|
|
1558
|
+
logLevel: "info"
|
|
1559
|
+
},
|
|
1560
|
+
star: {
|
|
1561
|
+
badge: n.star,
|
|
1562
|
+
color: "yellow",
|
|
1563
|
+
label: "star",
|
|
1564
|
+
logLevel: "info"
|
|
1565
|
+
},
|
|
1566
|
+
success: {
|
|
1567
|
+
badge: n.tick,
|
|
1568
|
+
color: "green",
|
|
1569
|
+
label: "success",
|
|
1570
|
+
logLevel: "info"
|
|
1571
|
+
},
|
|
1572
|
+
wait: {
|
|
1573
|
+
badge: n.ellipsis,
|
|
1574
|
+
color: "blue",
|
|
1575
|
+
label: "waiting",
|
|
1576
|
+
logLevel: "info"
|
|
1577
|
+
},
|
|
1578
|
+
warn: {
|
|
1579
|
+
badge: n.warning,
|
|
1580
|
+
color: "yellow",
|
|
1581
|
+
label: "warning",
|
|
1582
|
+
logLevel: "warn"
|
|
1583
|
+
},
|
|
1584
|
+
complete: {
|
|
1585
|
+
badge: n.checkboxOn,
|
|
1586
|
+
color: "cyan",
|
|
1587
|
+
label: "complete",
|
|
1588
|
+
logLevel: "info"
|
|
1589
|
+
},
|
|
1590
|
+
pending: {
|
|
1591
|
+
badge: n.checkboxOff,
|
|
1592
|
+
color: "magenta",
|
|
1593
|
+
label: "pending",
|
|
1594
|
+
logLevel: "info"
|
|
1595
|
+
},
|
|
1596
|
+
note: {
|
|
1597
|
+
badge: n.bullet,
|
|
1598
|
+
color: "blue",
|
|
1599
|
+
label: "note",
|
|
1600
|
+
logLevel: "info"
|
|
1601
|
+
},
|
|
1602
|
+
start: {
|
|
1603
|
+
badge: n.play,
|
|
1604
|
+
color: "green",
|
|
1605
|
+
label: "start",
|
|
1606
|
+
logLevel: "info"
|
|
1607
|
+
},
|
|
1608
|
+
pause: {
|
|
1609
|
+
badge: n.squareSmallFilled,
|
|
1610
|
+
color: "yellow",
|
|
1611
|
+
label: "pause",
|
|
1612
|
+
logLevel: "info"
|
|
1613
|
+
},
|
|
1614
|
+
debug: {
|
|
1615
|
+
badge: n("⬤"),
|
|
1616
|
+
color: "red",
|
|
1617
|
+
label: "debug",
|
|
1618
|
+
logLevel: "debug"
|
|
1619
|
+
},
|
|
1620
|
+
await: {
|
|
1621
|
+
badge: n.ellipsis,
|
|
1622
|
+
color: "blue",
|
|
1623
|
+
label: "awaiting",
|
|
1624
|
+
logLevel: "info"
|
|
1625
|
+
},
|
|
1626
|
+
watch: {
|
|
1627
|
+
badge: n.ellipsis,
|
|
1628
|
+
color: "yellow",
|
|
1629
|
+
label: "watching",
|
|
1630
|
+
logLevel: "info"
|
|
1631
|
+
},
|
|
1632
|
+
log: {
|
|
1633
|
+
badge: "",
|
|
1634
|
+
color: "",
|
|
1635
|
+
label: "",
|
|
1636
|
+
logLevel: "info"
|
|
1637
|
+
}
|
|
1638
|
+
};
|
|
1639
|
+
},
|
|
1640
|
+
308: (e)=>{
|
|
1641
|
+
"use strict";
|
|
1642
|
+
e.exports = (e)=>{
|
|
1643
|
+
if ("string" != typeof e) throw new TypeError("Expected a string, got " + typeof e);
|
|
1644
|
+
if (65279 === e.charCodeAt(0)) return e.slice(1);
|
|
1645
|
+
return e;
|
|
1646
|
+
};
|
|
1647
|
+
},
|
|
1648
|
+
234: (e)=>{
|
|
1649
|
+
"use strict";
|
|
1650
|
+
e.exports = require("../chalk");
|
|
1651
|
+
},
|
|
1652
|
+
684: (e)=>{
|
|
1653
|
+
"use strict";
|
|
1654
|
+
e.exports = require("./package.json");
|
|
1655
|
+
},
|
|
1656
|
+
491: (e)=>{
|
|
1657
|
+
"use strict";
|
|
1658
|
+
e.exports = require("assert");
|
|
1659
|
+
},
|
|
1660
|
+
57: (e)=>{
|
|
1661
|
+
"use strict";
|
|
1662
|
+
e.exports = require("constants");
|
|
1663
|
+
},
|
|
1664
|
+
147: (e)=>{
|
|
1665
|
+
"use strict";
|
|
1666
|
+
e.exports = require("fs");
|
|
1667
|
+
},
|
|
1668
|
+
17: (e)=>{
|
|
1669
|
+
"use strict";
|
|
1670
|
+
e.exports = require("path");
|
|
1671
|
+
},
|
|
1672
|
+
521: (e)=>{
|
|
1673
|
+
"use strict";
|
|
1674
|
+
e.exports = require("readline");
|
|
1675
|
+
},
|
|
1676
|
+
781: (e)=>{
|
|
1677
|
+
"use strict";
|
|
1678
|
+
e.exports = require("stream");
|
|
1679
|
+
},
|
|
1680
|
+
837: (e)=>{
|
|
1681
|
+
"use strict";
|
|
1682
|
+
e.exports = require("util");
|
|
1683
|
+
}
|
|
1684
|
+
};
|
|
1685
|
+
var t = {};
|
|
1686
|
+
function __nccwpck_require__(r) {
|
|
1687
|
+
var n = t[r];
|
|
1688
|
+
if (void 0 !== n) return n.exports;
|
|
1689
|
+
var i = t[r] = {
|
|
1690
|
+
exports: {}
|
|
1691
|
+
};
|
|
1692
|
+
var s = true;
|
|
1693
|
+
try {
|
|
1694
|
+
e[r](i, i.exports, __nccwpck_require__);
|
|
1695
|
+
s = false;
|
|
1696
|
+
} finally{
|
|
1697
|
+
if (s) delete t[r];
|
|
1698
|
+
}
|
|
1699
|
+
return i.exports;
|
|
1700
|
+
}
|
|
1701
|
+
if (void 0 !== __nccwpck_require__) __nccwpck_require__.ab = __dirname + "/";
|
|
1702
|
+
var r = __nccwpck_require__(567);
|
|
1703
|
+
module.exports = r;
|
|
1704
|
+
})();
|