create-chayns-app 1.1.11 → 1.1.12
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/index.js +9 -9
- package/package.json +12 -13
- package/templates/api-v5/page/src/index.html +1 -5
- package/templates/api-v5/page-redux/src/index.html +1 -5
- package/templates/api-v5/page-ts/src/index.html +1 -5
- package/templates/api-v5/page-ts-redux/src/index.html +1 -5
- package/templates/api-v5/shared/index.html +14 -0
- package/templates/api-v5/shared/js/template-package-redux.json +9 -9
- package/templates/api-v5/shared/js/template-package.json +7 -7
- package/templates/api-v5/shared/toolkit.config-module.js +4 -2
- package/templates/api-v5/shared/toolkit.config.js +11 -1
- package/templates/api-v5/shared/ts/template-package-redux.json +12 -12
- package/templates/api-v5/shared/ts/template-package.json +10 -10
- package/templates/page/src/index.html +1 -5
package/dist/index.js
CHANGED
|
@@ -1,40 +1,40 @@
|
|
|
1
1
|
#! /usr/bin/env node
|
|
2
|
-
(()=>{var e={3803:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createFileSystemAdapter=t.FILE_SYSTEM_ADAPTER=void 0;const s=r(7147);t.FILE_SYSTEM_ADAPTER={lstat:s.lstat,stat:s.stat,lstatSync:s.lstatSync,statSync:s.statSync,readdir:s.readdir,readdirSync:s.readdirSync};function createFileSystemAdapter(e){if(e===undefined){return t.FILE_SYSTEM_ADAPTER}return Object.assign(Object.assign({},t.FILE_SYSTEM_ADAPTER),e)}t.createFileSystemAdapter=createFileSystemAdapter},8838:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;const r=process.versions.node.split(".");if(r[0]===undefined||r[1]===undefined){throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`)}const s=Number.parseInt(r[0],10);const i=Number.parseInt(r[1],10);const n=10;const o=10;const a=s>n;const l=s===n&&i>=o;t.IS_SUPPORT_READDIR_WITH_FILE_TYPES=a||l},5667:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Settings=t.scandirSync=t.scandir=void 0;const s=r(4507);const i=r(9560);const n=r(8662);t.Settings=n.default;function scandir(e,t,r){if(typeof t==="function"){s.read(e,getSettings(),t);return}s.read(e,getSettings(t),r)}t.scandir=scandir;function scandirSync(e,t){const r=getSettings(t);return i.read(e,r)}t.scandirSync=scandirSync;function getSettings(e={}){if(e instanceof n.default){return e}return new n.default(e)}},4507:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.readdir=t.readdirWithFileTypes=t.read=void 0;const s=r(109);const i=r(5288);const n=r(8838);const o=r(6297);const a=r(3847);function read(e,t,r){if(!t.stats&&n.IS_SUPPORT_READDIR_WITH_FILE_TYPES){readdirWithFileTypes(e,t,r);return}readdir(e,t,r)}t.read=read;function readdirWithFileTypes(e,t,r){t.fs.readdir(e,{withFileTypes:true},((s,n)=>{if(s!==null){callFailureCallback(r,s);return}const o=n.map((r=>({dirent:r,name:r.name,path:a.joinPathSegments(e,r.name,t.pathSegmentSeparator)})));if(!t.followSymbolicLinks){callSuccessCallback(r,o);return}const l=o.map((e=>makeRplTaskEntry(e,t)));i(l,((e,t)=>{if(e!==null){callFailureCallback(r,e);return}callSuccessCallback(r,t)}))}))}t.readdirWithFileTypes=readdirWithFileTypes;function makeRplTaskEntry(e,t){return r=>{if(!e.dirent.isSymbolicLink()){r(null,e);return}t.fs.stat(e.path,((s,i)=>{if(s!==null){if(t.throwErrorOnBrokenSymbolicLink){r(s);return}r(null,e);return}e.dirent=o.fs.createDirentFromStats(e.name,i);r(null,e)}))}}function readdir(e,t,r){t.fs.readdir(e,((n,l)=>{if(n!==null){callFailureCallback(r,n);return}const u=l.map((r=>{const i=a.joinPathSegments(e,r,t.pathSegmentSeparator);return e=>{s.stat(i,t.fsStatSettings,((s,n)=>{if(s!==null){e(s);return}const a={name:r,path:i,dirent:o.fs.createDirentFromStats(r,n)};if(t.stats){a.stats=n}e(null,a)}))}}));i(u,((e,t)=>{if(e!==null){callFailureCallback(r,e);return}callSuccessCallback(r,t)}))}))}t.readdir=readdir;function callFailureCallback(e,t){e(t)}function callSuccessCallback(e,t){e(null,t)}},3847:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.joinPathSegments=void 0;function joinPathSegments(e,t,r){if(e.endsWith(r)){return e+t}return e+r+t}t.joinPathSegments=joinPathSegments},9560:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.readdir=t.readdirWithFileTypes=t.read=void 0;const s=r(109);const i=r(8838);const n=r(6297);const o=r(3847);function read(e,t){if(!t.stats&&i.IS_SUPPORT_READDIR_WITH_FILE_TYPES){return readdirWithFileTypes(e,t)}return readdir(e,t)}t.read=read;function readdirWithFileTypes(e,t){const r=t.fs.readdirSync(e,{withFileTypes:true});return r.map((r=>{const s={dirent:r,name:r.name,path:o.joinPathSegments(e,r.name,t.pathSegmentSeparator)};if(s.dirent.isSymbolicLink()&&t.followSymbolicLinks){try{const e=t.fs.statSync(s.path);s.dirent=n.fs.createDirentFromStats(s.name,e)}catch(e){if(t.throwErrorOnBrokenSymbolicLink){throw e}}}return s}))}t.readdirWithFileTypes=readdirWithFileTypes;function readdir(e,t){const r=t.fs.readdirSync(e);return r.map((r=>{const i=o.joinPathSegments(e,r,t.pathSegmentSeparator);const a=s.statSync(i,t.fsStatSettings);const l={name:r,path:i,dirent:n.fs.createDirentFromStats(r,a)};if(t.stats){l.stats=a}return l}))}t.readdir=readdir},8662:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(1017);const i=r(109);const n=r(3803);class Settings{constructor(e={}){this._options=e;this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,false);this.fs=n.createFileSystemAdapter(this._options.fs);this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,s.sep);this.stats=this._getValue(this._options.stats,false);this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,true);this.fsStatSettings=new i.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,t){return e!==null&&e!==void 0?e:t}}t["default"]=Settings},883:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createDirentFromStats=void 0;class DirentFromStats{constructor(e,t){this.name=e;this.isBlockDevice=t.isBlockDevice.bind(t);this.isCharacterDevice=t.isCharacterDevice.bind(t);this.isDirectory=t.isDirectory.bind(t);this.isFIFO=t.isFIFO.bind(t);this.isFile=t.isFile.bind(t);this.isSocket=t.isSocket.bind(t);this.isSymbolicLink=t.isSymbolicLink.bind(t)}}function createDirentFromStats(e,t){return new DirentFromStats(e,t)}t.createDirentFromStats=createDirentFromStats},6297:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.fs=void 0;const s=r(883);t.fs=s},2987:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createFileSystemAdapter=t.FILE_SYSTEM_ADAPTER=void 0;const s=r(7147);t.FILE_SYSTEM_ADAPTER={lstat:s.lstat,stat:s.stat,lstatSync:s.lstatSync,statSync:s.statSync};function createFileSystemAdapter(e){if(e===undefined){return t.FILE_SYSTEM_ADAPTER}return Object.assign(Object.assign({},t.FILE_SYSTEM_ADAPTER),e)}t.createFileSystemAdapter=createFileSystemAdapter},109:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.statSync=t.stat=t.Settings=void 0;const s=r(4147);const i=r(4527);const n=r(2410);t.Settings=n.default;function stat(e,t,r){if(typeof t==="function"){s.read(e,getSettings(),t);return}s.read(e,getSettings(t),r)}t.stat=stat;function statSync(e,t){const r=getSettings(t);return i.read(e,r)}t.statSync=statSync;function getSettings(e={}){if(e instanceof n.default){return e}return new n.default(e)}},4147:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.read=void 0;function read(e,t,r){t.fs.lstat(e,((s,i)=>{if(s!==null){callFailureCallback(r,s);return}if(!i.isSymbolicLink()||!t.followSymbolicLink){callSuccessCallback(r,i);return}t.fs.stat(e,((e,s)=>{if(e!==null){if(t.throwErrorOnBrokenSymbolicLink){callFailureCallback(r,e);return}callSuccessCallback(r,i);return}if(t.markSymbolicLink){s.isSymbolicLink=()=>true}callSuccessCallback(r,s)}))}))}t.read=read;function callFailureCallback(e,t){e(t)}function callSuccessCallback(e,t){e(null,t)}},4527:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.read=void 0;function read(e,t){const r=t.fs.lstatSync(e);if(!r.isSymbolicLink()||!t.followSymbolicLink){return r}try{const r=t.fs.statSync(e);if(t.markSymbolicLink){r.isSymbolicLink=()=>true}return r}catch(e){if(!t.throwErrorOnBrokenSymbolicLink){return r}throw e}}t.read=read},2410:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(2987);class Settings{constructor(e={}){this._options=e;this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,true);this.fs=s.createFileSystemAdapter(this._options.fs);this.markSymbolicLink=this._getValue(this._options.markSymbolicLink,false);this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,true)}_getValue(e,t){return e!==null&&e!==void 0?e:t}}t["default"]=Settings},6026:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Settings=t.walkStream=t.walkSync=t.walk=void 0;const s=r(7523);const i=r(6737);const n=r(3068);const o=r(141);t.Settings=o.default;function walk(e,t,r){if(typeof t==="function"){new s.default(e,getSettings()).read(t);return}new s.default(e,getSettings(t)).read(r)}t.walk=walk;function walkSync(e,t){const r=getSettings(t);const s=new n.default(e,r);return s.read()}t.walkSync=walkSync;function walkStream(e,t){const r=getSettings(t);const s=new i.default(e,r);return s.read()}t.walkStream=walkStream;function getSettings(e={}){if(e instanceof o.default){return e}return new o.default(e)}},7523:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(5732);class AsyncProvider{constructor(e,t){this._root=e;this._settings=t;this._reader=new s.default(this._root,this._settings);this._storage=[]}read(e){this._reader.onError((t=>{callFailureCallback(e,t)}));this._reader.onEntry((e=>{this._storage.push(e)}));this._reader.onEnd((()=>{callSuccessCallback(e,this._storage)}));this._reader.read()}}t["default"]=AsyncProvider;function callFailureCallback(e,t){e(t)}function callSuccessCallback(e,t){e(null,t)}},6737:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(2781);const i=r(5732);class StreamProvider{constructor(e,t){this._root=e;this._settings=t;this._reader=new i.default(this._root,this._settings);this._stream=new s.Readable({objectMode:true,read:()=>{},destroy:()=>{if(!this._reader.isDestroyed){this._reader.destroy()}}})}read(){this._reader.onError((e=>{this._stream.emit("error",e)}));this._reader.onEntry((e=>{this._stream.push(e)}));this._reader.onEnd((()=>{this._stream.push(null)}));this._reader.read();return this._stream}}t["default"]=StreamProvider},3068:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(3595);class SyncProvider{constructor(e,t){this._root=e;this._settings=t;this._reader=new s.default(this._root,this._settings)}read(){return this._reader.read()}}t["default"]=SyncProvider},5732:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(2361);const i=r(5667);const n=r(7340);const o=r(7988);const a=r(8311);class AsyncReader extends a.default{constructor(e,t){super(e,t);this._settings=t;this._scandir=i.scandir;this._emitter=new s.EventEmitter;this._queue=n(this._worker.bind(this),this._settings.concurrency);this._isFatalError=false;this._isDestroyed=false;this._queue.drain=()=>{if(!this._isFatalError){this._emitter.emit("end")}}}read(){this._isFatalError=false;this._isDestroyed=false;setImmediate((()=>{this._pushToQueue(this._root,this._settings.basePath)}));return this._emitter}get isDestroyed(){return this._isDestroyed}destroy(){if(this._isDestroyed){throw new Error("The reader is already destroyed")}this._isDestroyed=true;this._queue.killAndDrain()}onEntry(e){this._emitter.on("entry",e)}onError(e){this._emitter.once("error",e)}onEnd(e){this._emitter.once("end",e)}_pushToQueue(e,t){const r={directory:e,base:t};this._queue.push(r,(e=>{if(e!==null){this._handleError(e)}}))}_worker(e,t){this._scandir(e.directory,this._settings.fsScandirSettings,((r,s)=>{if(r!==null){t(r,undefined);return}for(const t of s){this._handleEntry(t,e.base)}t(null,undefined)}))}_handleError(e){if(this._isDestroyed||!o.isFatalError(this._settings,e)){return}this._isFatalError=true;this._isDestroyed=true;this._emitter.emit("error",e)}_handleEntry(e,t){if(this._isDestroyed||this._isFatalError){return}const r=e.path;if(t!==undefined){e.path=o.joinPathSegments(t,e.name,this._settings.pathSegmentSeparator)}if(o.isAppliedFilter(this._settings.entryFilter,e)){this._emitEntry(e)}if(e.dirent.isDirectory()&&o.isAppliedFilter(this._settings.deepFilter,e)){this._pushToQueue(r,t===undefined?undefined:e.path)}}_emitEntry(e){this._emitter.emit("entry",e)}}t["default"]=AsyncReader},7988:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.joinPathSegments=t.replacePathSegmentSeparator=t.isAppliedFilter=t.isFatalError=void 0;function isFatalError(e,t){if(e.errorFilter===null){return true}return!e.errorFilter(t)}t.isFatalError=isFatalError;function isAppliedFilter(e,t){return e===null||e(t)}t.isAppliedFilter=isAppliedFilter;function replacePathSegmentSeparator(e,t){return e.split(/[/\\]/).join(t)}t.replacePathSegmentSeparator=replacePathSegmentSeparator;function joinPathSegments(e,t,r){if(e===""){return t}if(e.endsWith(r)){return e+t}return e+r+t}t.joinPathSegments=joinPathSegments},8311:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(7988);class Reader{constructor(e,t){this._root=e;this._settings=t;this._root=s.replacePathSegmentSeparator(e,t.pathSegmentSeparator)}}t["default"]=Reader},3595:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(5667);const i=r(7988);const n=r(8311);class SyncReader extends n.default{constructor(){super(...arguments);this._scandir=s.scandirSync;this._storage=[];this._queue=new Set}read(){this._pushToQueue(this._root,this._settings.basePath);this._handleQueue();return this._storage}_pushToQueue(e,t){this._queue.add({directory:e,base:t})}_handleQueue(){for(const e of this._queue.values()){this._handleDirectory(e.directory,e.base)}}_handleDirectory(e,t){try{const r=this._scandir(e,this._settings.fsScandirSettings);for(const e of r){this._handleEntry(e,t)}}catch(e){this._handleError(e)}}_handleError(e){if(!i.isFatalError(this._settings,e)){return}throw e}_handleEntry(e,t){const r=e.path;if(t!==undefined){e.path=i.joinPathSegments(t,e.name,this._settings.pathSegmentSeparator)}if(i.isAppliedFilter(this._settings.entryFilter,e)){this._pushToStorage(e)}if(e.dirent.isDirectory()&&i.isAppliedFilter(this._settings.deepFilter,e)){this._pushToQueue(r,t===undefined?undefined:e.path)}}_pushToStorage(e){this._storage.push(e)}}t["default"]=SyncReader},141:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(1017);const i=r(5667);class Settings{constructor(e={}){this._options=e;this.basePath=this._getValue(this._options.basePath,undefined);this.concurrency=this._getValue(this._options.concurrency,Number.POSITIVE_INFINITY);this.deepFilter=this._getValue(this._options.deepFilter,null);this.entryFilter=this._getValue(this._options.entryFilter,null);this.errorFilter=this._getValue(this._options.errorFilter,null);this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,s.sep);this.fsScandirSettings=new i.Settings({followSymbolicLinks:this._options.followSymbolicLinks,fs:this._options.fs,pathSegmentSeparator:this._options.pathSegmentSeparator,stats:this._options.stats,throwErrorOnBrokenSymbolicLink:this._options.throwErrorOnBrokenSymbolicLink})}_getValue(e,t){return e!==null&&e!==void 0?e:t}}t["default"]=Settings},9151:(e,t,r)=>{"use strict";const isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);const s=/[\u001b\u009b][[\]#;?()]*(?:(?:(?:[^\W_]*;?[^\W_]*)\u0007)|(?:(?:[0-9]{1,4}(;[0-9]{0,4})*)?[~0-9=<>cf-nqrtyA-PRZ]))/g;const hasColor=()=>{if(typeof process!=="undefined"){return process.env.FORCE_COLOR!=="0"}return false};const create=()=>{const e={enabled:hasColor(),visible:true,styles:{},keys:{}};const ansi=e=>{let t=e.open=`[${e.codes[0]}m`;let r=e.close=`[${e.codes[1]}m`;let s=e.regex=new RegExp(`\\u001b\\[${e.codes[1]}m`,"g");e.wrap=(e,i)=>{if(e.includes(r))e=e.replace(s,r+t);let n=t+e+r;return i?n.replace(/\r*\n/g,`${r}$&${t}`):n};return e};const wrap=(e,t,r)=>typeof e==="function"?e(t):e.wrap(t,r);const style=(t,r)=>{if(t===""||t==null)return"";if(e.enabled===false)return t;if(e.visible===false)return"";let s=""+t;let i=s.includes("\n");let n=r.length;if(n>0&&r.includes("unstyle")){r=[...new Set(["unstyle",...r])].reverse()}while(n-- >0)s=wrap(e.styles[r[n]],s,i);return s};const define=(t,r,s)=>{e.styles[t]=ansi({name:t,codes:r});let i=e.keys[s]||(e.keys[s]=[]);i.push(t);Reflect.defineProperty(e,t,{configurable:true,enumerable:true,set(r){e.alias(t,r)},get(){let color=e=>style(e,color.stack);Reflect.setPrototypeOf(color,e);color.stack=this.stack?this.stack.concat(t):[t];return color}})};define("reset",[0,0],"modifier");define("bold",[1,22],"modifier");define("dim",[2,22],"modifier");define("italic",[3,23],"modifier");define("underline",[4,24],"modifier");define("inverse",[7,27],"modifier");define("hidden",[8,28],"modifier");define("strikethrough",[9,29],"modifier");define("black",[30,39],"color");define("red",[31,39],"color");define("green",[32,39],"color");define("yellow",[33,39],"color");define("blue",[34,39],"color");define("magenta",[35,39],"color");define("cyan",[36,39],"color");define("white",[37,39],"color");define("gray",[90,39],"color");define("grey",[90,39],"color");define("bgBlack",[40,49],"bg");define("bgRed",[41,49],"bg");define("bgGreen",[42,49],"bg");define("bgYellow",[43,49],"bg");define("bgBlue",[44,49],"bg");define("bgMagenta",[45,49],"bg");define("bgCyan",[46,49],"bg");define("bgWhite",[47,49],"bg");define("blackBright",[90,39],"bright");define("redBright",[91,39],"bright");define("greenBright",[92,39],"bright");define("yellowBright",[93,39],"bright");define("blueBright",[94,39],"bright");define("magentaBright",[95,39],"bright");define("cyanBright",[96,39],"bright");define("whiteBright",[97,39],"bright");define("bgBlackBright",[100,49],"bgBright");define("bgRedBright",[101,49],"bgBright");define("bgGreenBright",[102,49],"bgBright");define("bgYellowBright",[103,49],"bgBright");define("bgBlueBright",[104,49],"bgBright");define("bgMagentaBright",[105,49],"bgBright");define("bgCyanBright",[106,49],"bgBright");define("bgWhiteBright",[107,49],"bgBright");e.ansiRegex=s;e.hasColor=e.hasAnsi=t=>{e.ansiRegex.lastIndex=0;return typeof t==="string"&&t!==""&&e.ansiRegex.test(t)};e.alias=(t,r)=>{let s=typeof r==="string"?e[r]:r;if(typeof s!=="function"){throw new TypeError("Expected alias to be the name of an existing color (string) or a function")}if(!s.stack){Reflect.defineProperty(s,"name",{value:t});e.styles[t]=s;s.stack=[t]}Reflect.defineProperty(e,t,{configurable:true,enumerable:true,set(r){e.alias(t,r)},get(){let color=e=>style(e,color.stack);Reflect.setPrototypeOf(color,e);color.stack=this.stack?this.stack.concat(s.stack):s.stack;return color}})};e.theme=t=>{if(!isObject(t))throw new TypeError("Expected theme to be an object");for(let r of Object.keys(t)){e.alias(r,t[r])}return e};e.alias("unstyle",(t=>{if(typeof t==="string"&&t!==""){e.ansiRegex.lastIndex=0;return t.replace(e.ansiRegex,"")}return""}));e.alias("noop",(e=>e));e.none=e.clear=e.noop;e.stripColor=e.unstyle;e.symbols=r(2522);e.define=define;return e};e.exports=create();e.exports.create=create},2522:e=>{"use strict";const t=typeof process!=="undefined"&&process.env.TERM_PROGRAM==="Hyper";const r=typeof process!=="undefined"&&process.platform==="win32";const s=typeof process!=="undefined"&&process.platform==="linux";const i={ballotDisabled:"☒",ballotOff:"☐",ballotOn:"☑",bullet:"•",bulletWhite:"◦",fullBlock:"█",heart:"❤",identicalTo:"≡",line:"─",mark:"※",middot:"·",minus:"-",multiplication:"×",obelus:"÷",pencilDownRight:"✎",pencilRight:"✏",pencilUpRight:"✐",percent:"%",pilcrow2:"❡",pilcrow:"¶",plusMinus:"±",question:"?",section:"§",starsOff:"☆",starsOn:"★",upDownArrow:"↕"};const n=Object.assign({},i,{check:"√",cross:"×",ellipsisLarge:"...",ellipsis:"...",info:"i",questionSmall:"?",pointer:">",pointerSmall:"»",radioOff:"( )",radioOn:"(*)",warning:"‼"});const o=Object.assign({},i,{ballotCross:"✘",check:"✔",cross:"✖",ellipsisLarge:"⋯",ellipsis:"…",info:"ℹ",questionFull:"?",questionSmall:"﹖",pointer:s?"▸":"❯",pointerSmall:s?"‣":"›",radioOff:"◯",radioOn:"◉",warning:"⚠"});e.exports=r&&!t?n:o;Reflect.defineProperty(e.exports,"common",{enumerable:false,value:i});Reflect.defineProperty(e.exports,"windows",{enumerable:false,value:n});Reflect.defineProperty(e.exports,"other",{enumerable:false,value:o})},5063:e=>{"use strict";e.exports=({onlyFirst:e=false}={})=>{const t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(t,e?undefined:"g")}},2068:(e,t,r)=>{"use strict";e=r.nmd(e);const wrapAnsi16=(e,t)=>(...r)=>{const s=e(...r);return`[${s+t}m`};const wrapAnsi256=(e,t)=>(...r)=>{const s=e(...r);return`[${38+t};5;${s}m`};const wrapAnsi16m=(e,t)=>(...r)=>{const s=e(...r);return`[${38+t};2;${s[0]};${s[1]};${s[2]}m`};const ansi2ansi=e=>e;const rgb2rgb=(e,t,r)=>[e,t,r];const setLazyProperty=(e,t,r)=>{Object.defineProperty(e,t,{get:()=>{const s=r();Object.defineProperty(e,t,{value:s,enumerable:true,configurable:true});return s},enumerable:true,configurable:true})};let s;const makeDynamicStyles=(e,t,i,n)=>{if(s===undefined){s=r(6931)}const o=n?10:0;const a={};for(const[r,n]of Object.entries(s)){const s=r==="ansi16"?"ansi":r;if(r===t){a[s]=e(i,o)}else if(typeof n==="object"){a[s]=e(n[t],o)}}return a};function assembleStyles(){const e=new Map;const t={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};t.color.gray=t.color.blackBright;t.bgColor.bgGray=t.bgColor.bgBlackBright;t.color.grey=t.color.blackBright;t.bgColor.bgGrey=t.bgColor.bgBlackBright;for(const[r,s]of Object.entries(t)){for(const[r,i]of Object.entries(s)){t[r]={open:`[${i[0]}m`,close:`[${i[1]}m`};s[r]=t[r];e.set(i[0],i[1])}Object.defineProperty(t,r,{value:s,enumerable:false})}Object.defineProperty(t,"codes",{value:e,enumerable:false});t.color.close="[39m";t.bgColor.close="[49m";setLazyProperty(t.color,"ansi",(()=>makeDynamicStyles(wrapAnsi16,"ansi16",ansi2ansi,false)));setLazyProperty(t.color,"ansi256",(()=>makeDynamicStyles(wrapAnsi256,"ansi256",ansi2ansi,false)));setLazyProperty(t.color,"ansi16m",(()=>makeDynamicStyles(wrapAnsi16m,"rgb",rgb2rgb,false)));setLazyProperty(t.bgColor,"ansi",(()=>makeDynamicStyles(wrapAnsi16,"ansi16",ansi2ansi,true)));setLazyProperty(t.bgColor,"ansi256",(()=>makeDynamicStyles(wrapAnsi256,"ansi256",ansi2ansi,true)));setLazyProperty(t.bgColor,"ansi16m",(()=>makeDynamicStyles(wrapAnsi16m,"rgb",rgb2rgb,true)));return t}Object.defineProperty(e,"exports",{enumerable:true,get:assembleStyles})},2344:(e,t,r)=>{"use strict";const{Buffer:s}=r(4300);const i=Symbol.for("BufferList");function BufferList(e){if(!(this instanceof BufferList)){return new BufferList(e)}BufferList._init.call(this,e)}BufferList._init=function _init(e){Object.defineProperty(this,i,{value:true});this._bufs=[];this.length=0;if(e){this.append(e)}};BufferList.prototype._new=function _new(e){return new BufferList(e)};BufferList.prototype._offset=function _offset(e){if(e===0){return[0,0]}let t=0;for(let r=0;r<this._bufs.length;r++){const s=t+this._bufs[r].length;if(e<s||r===this._bufs.length-1){return[r,e-t]}t=s}};BufferList.prototype._reverseOffset=function(e){const t=e[0];let r=e[1];for(let e=0;e<t;e++){r+=this._bufs[e].length}return r};BufferList.prototype.get=function get(e){if(e>this.length||e<0){return undefined}const t=this._offset(e);return this._bufs[t[0]][t[1]]};BufferList.prototype.slice=function slice(e,t){if(typeof e==="number"&&e<0){e+=this.length}if(typeof t==="number"&&t<0){t+=this.length}return this.copy(null,0,e,t)};BufferList.prototype.copy=function copy(e,t,r,i){if(typeof r!=="number"||r<0){r=0}if(typeof i!=="number"||i>this.length){i=this.length}if(r>=this.length){return e||s.alloc(0)}if(i<=0){return e||s.alloc(0)}const copy=!!e;const n=this._offset(r);const o=i-r;let a=o;let l=copy&&t||0;let u=n[1];if(r===0&&i===this.length){if(!copy){return this._bufs.length===1?this._bufs[0]:s.concat(this._bufs,this.length)}for(let t=0;t<this._bufs.length;t++){this._bufs[t].copy(e,l);l+=this._bufs[t].length}return e}if(a<=this._bufs[n[0]].length-u){return copy?this._bufs[n[0]].copy(e,t,u,u+a):this._bufs[n[0]].slice(u,u+a)}if(!copy){e=s.allocUnsafe(o)}for(let t=n[0];t<this._bufs.length;t++){const r=this._bufs[t].length-u;if(a>r){this._bufs[t].copy(e,l,u);l+=r}else{this._bufs[t].copy(e,l,u,u+a);l+=r;break}a-=r;if(u){u=0}}if(e.length>l)return e.slice(0,l);return e};BufferList.prototype.shallowSlice=function shallowSlice(e,t){e=e||0;t=typeof t!=="number"?this.length:t;if(e<0){e+=this.length}if(t<0){t+=this.length}if(e===t){return this._new()}const r=this._offset(e);const s=this._offset(t);const i=this._bufs.slice(r[0],s[0]+1);if(s[1]===0){i.pop()}else{i[i.length-1]=i[i.length-1].slice(0,s[1])}if(r[1]!==0){i[0]=i[0].slice(r[1])}return this._new(i)};BufferList.prototype.toString=function toString(e,t,r){return this.slice(t,r).toString(e)};BufferList.prototype.consume=function consume(e){e=Math.trunc(e);if(Number.isNaN(e)||e<=0)return this;while(this._bufs.length){if(e>=this._bufs[0].length){e-=this._bufs[0].length;this.length-=this._bufs[0].length;this._bufs.shift()}else{this._bufs[0]=this._bufs[0].slice(e);this.length-=e;break}}return this};BufferList.prototype.duplicate=function duplicate(){const e=this._new();for(let t=0;t<this._bufs.length;t++){e.append(this._bufs[t])}return e};BufferList.prototype.append=function append(e){if(e==null){return this}if(e.buffer){this._appendBuffer(s.from(e.buffer,e.byteOffset,e.byteLength))}else if(Array.isArray(e)){for(let t=0;t<e.length;t++){this.append(e[t])}}else if(this._isBufferList(e)){for(let t=0;t<e._bufs.length;t++){this.append(e._bufs[t])}}else{if(typeof e==="number"){e=e.toString()}this._appendBuffer(s.from(e))}return this};BufferList.prototype._appendBuffer=function appendBuffer(e){this._bufs.push(e);this.length+=e.length};BufferList.prototype.indexOf=function(e,t,r){if(r===undefined&&typeof t==="string"){r=t;t=undefined}if(typeof e==="function"||Array.isArray(e)){throw new TypeError('The "value" argument must be one of type string, Buffer, BufferList, or Uint8Array.')}else if(typeof e==="number"){e=s.from([e])}else if(typeof e==="string"){e=s.from(e,r)}else if(this._isBufferList(e)){e=e.slice()}else if(Array.isArray(e.buffer)){e=s.from(e.buffer,e.byteOffset,e.byteLength)}else if(!s.isBuffer(e)){e=s.from(e)}t=Number(t||0);if(isNaN(t)){t=0}if(t<0){t=this.length+t}if(t<0){t=0}if(e.length===0){return t>this.length?this.length:t}const i=this._offset(t);let n=i[0];let o=i[1];for(;n<this._bufs.length;n++){const t=this._bufs[n];while(o<t.length){const r=t.length-o;if(r>=e.length){const r=t.indexOf(e,o);if(r!==-1){return this._reverseOffset([n,r])}o=t.length-e.length+1}else{const t=this._reverseOffset([n,o]);if(this._match(t,e)){return t}o++}}o=0}return-1};BufferList.prototype._match=function(e,t){if(this.length-e<t.length){return false}for(let r=0;r<t.length;r++){if(this.get(e+r)!==t[r]){return false}}return true};(function(){const e={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1,readIntBE:null,readIntLE:null,readUIntBE:null,readUIntLE:null};for(const t in e){(function(t){if(e[t]===null){BufferList.prototype[t]=function(e,r){return this.slice(e,e+r)[t](0,r)}}else{BufferList.prototype[t]=function(r=0){return this.slice(r,r+e[t])[t](0)}}})(t)}})();BufferList.prototype._isBufferList=function _isBufferList(e){return e instanceof BufferList||BufferList.isBufferList(e)};BufferList.isBufferList=function isBufferList(e){return e!=null&&e[i]};e.exports=BufferList},336:(e,t,r)=>{"use strict";const s=r(1642).Duplex;const i=r(4124);const n=r(2344);function BufferListStream(e){if(!(this instanceof BufferListStream)){return new BufferListStream(e)}if(typeof e==="function"){this._callback=e;const t=function piper(e){if(this._callback){this._callback(e);this._callback=null}}.bind(this);this.on("pipe",(function onPipe(e){e.on("error",t)}));this.on("unpipe",(function onUnpipe(e){e.removeListener("error",t)}));e=null}n._init.call(this,e);s.call(this)}i(BufferListStream,s);Object.assign(BufferListStream.prototype,n.prototype);BufferListStream.prototype._new=function _new(e){return new BufferListStream(e)};BufferListStream.prototype._write=function _write(e,t,r){this._appendBuffer(e);if(typeof r==="function"){r()}};BufferListStream.prototype._read=function _read(e){if(!this.length){return this.push(null)}e=Math.min(e,this.length);this.push(this.slice(0,e));this.consume(e)};BufferListStream.prototype.end=function end(e){s.prototype.end.call(this,e);if(this._callback){this._callback(null,this.slice());this._callback=null}};BufferListStream.prototype._destroy=function _destroy(e,t){this._bufs.length=0;this.length=0;t(e)};BufferListStream.prototype._isBufferList=function _isBufferList(e){return e instanceof BufferListStream||e instanceof n||BufferListStream.isBufferList(e)};BufferListStream.isBufferList=n.isBufferList;e.exports=BufferListStream;e.exports.BufferListStream=BufferListStream;e.exports.BufferList=n},610:(e,t,r)=>{"use strict";const s=r(8750);const i=r(9434);const n=r(7493);const o=r(6477);const braces=(e,t={})=>{let r=[];if(Array.isArray(e)){for(let s of e){let e=braces.create(s,t);if(Array.isArray(e)){r.push(...e)}else{r.push(e)}}}else{r=[].concat(braces.create(e,t))}if(t&&t.expand===true&&t.nodupes===true){r=[...new Set(r)]}return r};braces.parse=(e,t={})=>o(e,t);braces.stringify=(e,t={})=>{if(typeof e==="string"){return s(braces.parse(e,t),t)}return s(e,t)};braces.compile=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}return i(e,t)};braces.expand=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}let r=n(e,t);if(t.noempty===true){r=r.filter(Boolean)}if(t.nodupes===true){r=[...new Set(r)]}return r};braces.create=(e,t={})=>{if(e===""||e.length<3){return[e]}return t.expand!==true?braces.compile(e,t):braces.expand(e,t)};e.exports=braces},9434:(e,t,r)=>{"use strict";const s=r(6330);const i=r(5207);const compile=(e,t={})=>{let walk=(e,r={})=>{let n=i.isInvalidBrace(r);let o=e.invalid===true&&t.escapeInvalid===true;let a=n===true||o===true;let l=t.escapeInvalid===true?"\\":"";let u="";if(e.isOpen===true){return l+e.value}if(e.isClose===true){return l+e.value}if(e.type==="open"){return a?l+e.value:"("}if(e.type==="close"){return a?l+e.value:")"}if(e.type==="comma"){return e.prev.type==="comma"?"":a?e.value:"|"}if(e.value){return e.value}if(e.nodes&&e.ranges>0){let r=i.reduce(e.nodes);let n=s(...r,{...t,wrap:false,toRegex:true});if(n.length!==0){return r.length>1&&n.length>1?`(${n})`:n}}if(e.nodes){for(let t of e.nodes){u+=walk(t,e)}}return u};return walk(e)};e.exports=compile},8774:e=>{"use strict";e.exports={MAX_LENGTH:1024*64,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:"\n",CHAR_NO_BREAK_SPACE:" ",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:"\t",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\ufeff"}},7493:(e,t,r)=>{"use strict";const s=r(6330);const i=r(8750);const n=r(5207);const append=(e="",t="",r=false)=>{let s=[];e=[].concat(e);t=[].concat(t);if(!t.length)return e;if(!e.length){return r?n.flatten(t).map((e=>`{${e}}`)):t}for(let i of e){if(Array.isArray(i)){for(let e of i){s.push(append(e,t,r))}}else{for(let e of t){if(r===true&&typeof e==="string")e=`{${e}}`;s.push(Array.isArray(e)?append(i,e,r):i+e)}}}return n.flatten(s)};const expand=(e,t={})=>{let r=t.rangeLimit===void 0?1e3:t.rangeLimit;let walk=(e,o={})=>{e.queue=[];let a=o;let l=o.queue;while(a.type!=="brace"&&a.type!=="root"&&a.parent){a=a.parent;l=a.queue}if(e.invalid||e.dollar){l.push(append(l.pop(),i(e,t)));return}if(e.type==="brace"&&e.invalid!==true&&e.nodes.length===2){l.push(append(l.pop(),["{}"]));return}if(e.nodes&&e.ranges>0){let o=n.reduce(e.nodes);if(n.exceedsLimit(...o,t.step,r)){throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.")}let a=s(...o,t);if(a.length===0){a=i(e,t)}l.push(append(l.pop(),a));e.nodes=[];return}let u=n.encloseBrace(e);let h=e.queue;let f=e;while(f.type!=="brace"&&f.type!=="root"&&f.parent){f=f.parent;h=f.queue}for(let t=0;t<e.nodes.length;t++){let r=e.nodes[t];if(r.type==="comma"&&e.type==="brace"){if(t===1)h.push("");h.push("");continue}if(r.type==="close"){l.push(append(l.pop(),h,u));continue}if(r.value&&r.type!=="open"){h.push(append(h.pop(),r.value));continue}if(r.nodes){walk(r,e)}}return h};return n.flatten(walk(e))};e.exports=expand},6477:(e,t,r)=>{"use strict";const s=r(8750);const{MAX_LENGTH:i,CHAR_BACKSLASH:n,CHAR_BACKTICK:o,CHAR_COMMA:a,CHAR_DOT:l,CHAR_LEFT_PARENTHESES:u,CHAR_RIGHT_PARENTHESES:h,CHAR_LEFT_CURLY_BRACE:f,CHAR_RIGHT_CURLY_BRACE:p,CHAR_LEFT_SQUARE_BRACKET:d,CHAR_RIGHT_SQUARE_BRACKET:m,CHAR_DOUBLE_QUOTE:g,CHAR_SINGLE_QUOTE:y,CHAR_NO_BREAK_SPACE:b,CHAR_ZERO_WIDTH_NOBREAK_SPACE:_}=r(8774);const parse=(e,t={})=>{if(typeof e!=="string"){throw new TypeError("Expected a string")}let r=t||{};let v=typeof r.maxLength==="number"?Math.min(i,r.maxLength):i;if(e.length>v){throw new SyntaxError(`Input length (${e.length}), exceeds max characters (${v})`)}let w={type:"root",input:e,nodes:[]};let E=[w];let S=w;let x=w;let R=0;let A=e.length;let C=0;let O=0;let k;let T={};const advance=()=>e[C++];const push=e=>{if(e.type==="text"&&x.type==="dot"){x.type="text"}if(x&&x.type==="text"&&e.type==="text"){x.value+=e.value;return}S.nodes.push(e);e.parent=S;e.prev=x;x=e;return e};push({type:"bos"});while(C<A){S=E[E.length-1];k=advance();if(k===_||k===b){continue}if(k===n){push({type:"text",value:(t.keepEscaping?k:"")+advance()});continue}if(k===m){push({type:"text",value:"\\"+k});continue}if(k===d){R++;let e=true;let t;while(C<A&&(t=advance())){k+=t;if(t===d){R++;continue}if(t===n){k+=advance();continue}if(t===m){R--;if(R===0){break}}}push({type:"text",value:k});continue}if(k===u){S=push({type:"paren",nodes:[]});E.push(S);push({type:"text",value:k});continue}if(k===h){if(S.type!=="paren"){push({type:"text",value:k});continue}S=E.pop();push({type:"text",value:k});S=E[E.length-1];continue}if(k===g||k===y||k===o){let e=k;let r;if(t.keepQuotes!==true){k=""}while(C<A&&(r=advance())){if(r===n){k+=r+advance();continue}if(r===e){if(t.keepQuotes===true)k+=r;break}k+=r}push({type:"text",value:k});continue}if(k===f){O++;let e=x.value&&x.value.slice(-1)==="$"||S.dollar===true;let t={type:"brace",open:true,close:false,dollar:e,depth:O,commas:0,ranges:0,nodes:[]};S=push(t);E.push(S);push({type:"open",value:k});continue}if(k===p){if(S.type!=="brace"){push({type:"text",value:k});continue}let e="close";S=E.pop();S.close=true;push({type:e,value:k});O--;S=E[E.length-1];continue}if(k===a&&O>0){if(S.ranges>0){S.ranges=0;let e=S.nodes.shift();S.nodes=[e,{type:"text",value:s(S)}]}push({type:"comma",value:k});S.commas++;continue}if(k===l&&O>0&&S.commas===0){let e=S.nodes;if(O===0||e.length===0){push({type:"text",value:k});continue}if(x.type==="dot"){S.range=[];x.value+=k;x.type="range";if(S.nodes.length!==3&&S.nodes.length!==5){S.invalid=true;S.ranges=0;x.type="text";continue}S.ranges++;S.args=[];continue}if(x.type==="range"){e.pop();let t=e[e.length-1];t.value+=x.value+k;x=t;S.ranges--;continue}push({type:"dot",value:k});continue}push({type:"text",value:k})}do{S=E.pop();if(S.type!=="root"){S.nodes.forEach((e=>{if(!e.nodes){if(e.type==="open")e.isOpen=true;if(e.type==="close")e.isClose=true;if(!e.nodes)e.type="text";e.invalid=true}}));let e=E[E.length-1];let t=e.nodes.indexOf(S);e.nodes.splice(t,1,...S.nodes)}}while(E.length>0);push({type:"eos"});return w};e.exports=parse},8750:(e,t,r)=>{"use strict";const s=r(5207);e.exports=(e,t={})=>{let stringify=(e,r={})=>{let i=t.escapeInvalid&&s.isInvalidBrace(r);let n=e.invalid===true&&t.escapeInvalid===true;let o="";if(e.value){if((i||n)&&s.isOpenOrClose(e)){return"\\"+e.value}return e.value}if(e.value){return e.value}if(e.nodes){for(let t of e.nodes){o+=stringify(t)}}return o};return stringify(e)}},5207:(e,t)=>{"use strict";t.isInteger=e=>{if(typeof e==="number"){return Number.isInteger(e)}if(typeof e==="string"&&e.trim()!==""){return Number.isInteger(Number(e))}return false};t.find=(e,t)=>e.nodes.find((e=>e.type===t));t.exceedsLimit=(e,r,s=1,i)=>{if(i===false)return false;if(!t.isInteger(e)||!t.isInteger(r))return false;return(Number(r)-Number(e))/Number(s)>=i};t.escapeNode=(e,t=0,r)=>{let s=e.nodes[t];if(!s)return;if(r&&s.type===r||s.type==="open"||s.type==="close"){if(s.escaped!==true){s.value="\\"+s.value;s.escaped=true}}};t.encloseBrace=e=>{if(e.type!=="brace")return false;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}return false};t.isInvalidBrace=e=>{if(e.type!=="brace")return false;if(e.invalid===true||e.dollar)return true;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}if(e.open!==true||e.close!==true){e.invalid=true;return true}return false};t.isOpenOrClose=e=>{if(e.type==="open"||e.type==="close"){return true}return e.open===true||e.close===true};t.reduce=e=>e.reduce(((e,t)=>{if(t.type==="text")e.push(t.value);if(t.type==="range")t.type="text";return e}),[]);t.flatten=(...e)=>{const t=[];const flat=e=>{for(let r=0;r<e.length;r++){let s=e[r];Array.isArray(s)?flat(s,t):s!==void 0&&t.push(s)}return t};flat(e);return t}},3818:(e,t,r)=>{"use strict";const s=r(1383);const i=["assert","buffer","child_process","cluster","console","constants","crypto","dgram","dns","domain","events","fs","http","https","module","net","os","path","punycode","querystring","readline","repl","stream","string_decoder","sys","timers","tls","tty","url","util","vm","zlib"];const n={freelist:"<6.0.0",v8:">=1.0.0",process:">=1.1.0",inspector:">=8.0.0",async_hooks:">=8.1.0",http2:">=8.4.0",perf_hooks:">=8.5.0",trace_events:">=10.0.0",worker_threads:">=12.0.0","node:test":">=18.0.0"};const o={worker_threads:">=10.5.0",wasi:">=12.16.0",diagnostics_channel:"^14.17.0 || >=15.1.0"};e.exports=({version:e=process.version,experimental:t=false}={})=>{const r=[...i];for(const[t,i]of Object.entries(n)){if(e==="*"||s.satisfies(e,i)){r.push(t)}}if(t){for(const[t,i]of Object.entries(o)){if(!r.includes(t)&&(e==="*"||s.satisfies(e,i))){r.push(t)}}}return r}},8818:(e,t,r)=>{"use strict";const s=r(2068);const{stdout:i,stderr:n}=r(9318);const{stringReplaceAll:o,stringEncaseCRLFWithFirstIndex:a}=r(2415);const{isArray:l}=Array;const u=["ansi","ansi","ansi256","ansi16m"];const h=Object.create(null);const applyOptions=(e,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3)){throw new Error("The `level` option should be an integer from 0 to 3")}const r=i?i.level:0;e.level=t.level===undefined?r:t.level};class ChalkClass{constructor(e){return chalkFactory(e)}}const chalkFactory=e=>{const t={};applyOptions(t,e);t.template=(...e)=>chalkTag(t.template,...e);Object.setPrototypeOf(t,Chalk.prototype);Object.setPrototypeOf(t.template,t);t.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")};t.template.Instance=ChalkClass;return t.template};function Chalk(e){return chalkFactory(e)}for(const[e,t]of Object.entries(s)){h[e]={get(){const r=createBuilder(this,createStyler(t.open,t.close,this._styler),this._isEmpty);Object.defineProperty(this,e,{value:r});return r}}}h.visible={get(){const e=createBuilder(this,this._styler,true);Object.defineProperty(this,"visible",{value:e});return e}};const f=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(const e of f){h[e]={get(){const{level:t}=this;return function(...r){const i=createStyler(s.color[u[t]][e](...r),s.color.close,this._styler);return createBuilder(this,i,this._isEmpty)}}}}for(const e of f){const t="bg"+e[0].toUpperCase()+e.slice(1);h[t]={get(){const{level:t}=this;return function(...r){const i=createStyler(s.bgColor[u[t]][e](...r),s.bgColor.close,this._styler);return createBuilder(this,i,this._isEmpty)}}}}const p=Object.defineProperties((()=>{}),{...h,level:{enumerable:true,get(){return this._generator.level},set(e){this._generator.level=e}}});const createStyler=(e,t,r)=>{let s;let i;if(r===undefined){s=e;i=t}else{s=r.openAll+e;i=t+r.closeAll}return{open:e,close:t,openAll:s,closeAll:i,parent:r}};const createBuilder=(e,t,r)=>{const builder=(...e)=>{if(l(e[0])&&l(e[0].raw)){return applyStyle(builder,chalkTag(builder,...e))}return applyStyle(builder,e.length===1?""+e[0]:e.join(" "))};Object.setPrototypeOf(builder,p);builder._generator=e;builder._styler=t;builder._isEmpty=r;return builder};const applyStyle=(e,t)=>{if(e.level<=0||!t){return e._isEmpty?"":t}let r=e._styler;if(r===undefined){return t}const{openAll:s,closeAll:i}=r;if(t.indexOf("")!==-1){while(r!==undefined){t=o(t,r.close,r.open);r=r.parent}}const n=t.indexOf("\n");if(n!==-1){t=a(t,i,s,n)}return s+t+i};let d;const chalkTag=(e,...t)=>{const[s]=t;if(!l(s)||!l(s.raw)){return t.join(" ")}const i=t.slice(1);const n=[s.raw[0]];for(let e=1;e<s.length;e++){n.push(String(i[e-1]).replace(/[{}\\]/g,"\\$&"),String(s.raw[e]))}if(d===undefined){d=r(500)}return d(e,n.join(""))};Object.defineProperties(Chalk.prototype,h);const m=Chalk();m.supportsColor=i;m.stderr=Chalk({level:n?n.level:0});m.stderr.supportsColor=n;e.exports=m},500:e=>{"use strict";const t=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi;const r=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g;const s=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/;const i=/\\(u(?:[a-f\d]{4}|{[a-f\d]{1,6}})|x[a-f\d]{2}|.)|([^\\])/gi;const n=new Map([["n","\n"],["r","\r"],["t","\t"],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e",""],["a",""]]);function unescape(e){const t=e[0]==="u";const r=e[1]==="{";if(t&&!r&&e.length===5||e[0]==="x"&&e.length===3){return String.fromCharCode(parseInt(e.slice(1),16))}if(t&&r){return String.fromCodePoint(parseInt(e.slice(2,-1),16))}return n.get(e)||e}function parseArguments(e,t){const r=[];const n=t.trim().split(/\s*,\s*/g);let o;for(const t of n){const n=Number(t);if(!Number.isNaN(n)){r.push(n)}else if(o=t.match(s)){r.push(o[2].replace(i,((e,t,r)=>t?unescape(t):r)))}else{throw new Error(`Invalid Chalk template style argument: ${t} (in style '${e}')`)}}return r}function parseStyle(e){r.lastIndex=0;const t=[];let s;while((s=r.exec(e))!==null){const e=s[1];if(s[2]){const r=parseArguments(e,s[2]);t.push([e].concat(r))}else{t.push([e])}}return t}function buildStyle(e,t){const r={};for(const e of t){for(const t of e.styles){r[t[0]]=e.inverse?null:t.slice(1)}}let s=e;for(const[e,t]of Object.entries(r)){if(!Array.isArray(t)){continue}if(!(e in s)){throw new Error(`Unknown Chalk style: ${e}`)}s=t.length>0?s[e](...t):s[e]}return s}e.exports=(e,r)=>{const s=[];const i=[];let n=[];r.replace(t,((t,r,o,a,l,u)=>{if(r){n.push(unescape(r))}else if(a){const t=n.join("");n=[];i.push(s.length===0?t:buildStyle(e,s)(t));s.push({inverse:o,styles:parseStyle(a)})}else if(l){if(s.length===0){throw new Error("Found extraneous } in Chalk template literal")}i.push(buildStyle(e,s)(n.join("")));n=[];s.pop()}else{n.push(u)}}));i.push(n.join(""));if(s.length>0){const e=`Chalk template literal is missing ${s.length} closing bracket${s.length===1?"":"s"} (\`}\`)`;throw new Error(e)}return i.join("")}},2415:e=>{"use strict";const stringReplaceAll=(e,t,r)=>{let s=e.indexOf(t);if(s===-1){return e}const i=t.length;let n=0;let o="";do{o+=e.substr(n,s-n)+t+r;n=s+i;s=e.indexOf(t,n)}while(s!==-1);o+=e.substr(n);return o};const stringEncaseCRLFWithFirstIndex=(e,t,r,s)=>{let i=0;let n="";do{const o=e[s-1]==="\r";n+=e.substr(i,(o?s-1:s)-i)+t+(o?"\r\n":"\n")+r;i=s+1;s=e.indexOf("\n",i)}while(s!==-1);n+=e.substr(i);return n};e.exports={stringReplaceAll:stringReplaceAll,stringEncaseCRLFWithFirstIndex:stringEncaseCRLFWithFirstIndex}},9482:(e,t,r)=>{"use strict";const s=r(5847);let i=false;t.show=(e=process.stderr)=>{if(!e.isTTY){return}i=false;e.write("[?25h")};t.hide=(e=process.stderr)=>{if(!e.isTTY){return}s();i=true;e.write("[?25l")};t.toggle=(e,r)=>{if(e!==undefined){i=e}if(i){t.show(r)}else{t.hide(r)}}},2031:(e,t,r)=>{"use strict";const s=Object.assign({},r(6374));const i=Object.keys(s);Object.defineProperty(s,"random",{get(){const e=Math.floor(Math.random()*i.length);const t=i[e];return s[t]}});e.exports=s},8606:e=>{var t=function(){"use strict";function clone(e,t,r,s){var i;if(typeof t==="object"){r=t.depth;s=t.prototype;i=t.filter;t=t.circular}var n=[];var o=[];var a=typeof Buffer!="undefined";if(typeof t=="undefined")t=true;if(typeof r=="undefined")r=Infinity;function _clone(e,r){if(e===null)return null;if(r==0)return e;var i;var l;if(typeof e!="object"){return e}if(clone.__isArray(e)){i=[]}else if(clone.__isRegExp(e)){i=new RegExp(e.source,__getRegExpFlags(e));if(e.lastIndex)i.lastIndex=e.lastIndex}else if(clone.__isDate(e)){i=new Date(e.getTime())}else if(a&&Buffer.isBuffer(e)){if(Buffer.allocUnsafe){i=Buffer.allocUnsafe(e.length)}else{i=new Buffer(e.length)}e.copy(i);return i}else{if(typeof s=="undefined"){l=Object.getPrototypeOf(e);i=Object.create(l)}else{i=Object.create(s);l=s}}if(t){var u=n.indexOf(e);if(u!=-1){return o[u]}n.push(e);o.push(i)}for(var h in e){var f;if(l){f=Object.getOwnPropertyDescriptor(l,h)}if(f&&f.set==null){continue}i[h]=_clone(e[h],r-1)}return i}return _clone(e,r)}clone.clonePrototype=function clonePrototype(e){if(e===null)return null;var c=function(){};c.prototype=e;return new c};function __objToStr(e){return Object.prototype.toString.call(e)}clone.__objToStr=__objToStr;function __isDate(e){return typeof e==="object"&&__objToStr(e)==="[object Date]"}clone.__isDate=__isDate;function __isArray(e){return typeof e==="object"&&__objToStr(e)==="[object Array]"}clone.__isArray=__isArray;function __isRegExp(e){return typeof e==="object"&&__objToStr(e)==="[object RegExp]"}clone.__isRegExp=__isRegExp;function __getRegExpFlags(e){var t="";if(e.global)t+="g";if(e.ignoreCase)t+="i";if(e.multiline)t+="m";return t}clone.__getRegExpFlags=__getRegExpFlags;return clone}();if(true&&e.exports){e.exports=t}},7391:(e,t,r)=>{const s=r(8510);const i={};for(const e of Object.keys(s)){i[s[e]]=e}const n={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=n;for(const e of Object.keys(n)){if(!("channels"in n[e])){throw new Error("missing channels property: "+e)}if(!("labels"in n[e])){throw new Error("missing channel labels property: "+e)}if(n[e].labels.length!==n[e].channels){throw new Error("channel and label counts mismatch: "+e)}const{channels:t,labels:r}=n[e];delete n[e].channels;delete n[e].labels;Object.defineProperty(n[e],"channels",{value:t});Object.defineProperty(n[e],"labels",{value:r})}n.rgb.hsl=function(e){const t=e[0]/255;const r=e[1]/255;const s=e[2]/255;const i=Math.min(t,r,s);const n=Math.max(t,r,s);const o=n-i;let a;let l;if(n===i){a=0}else if(t===n){a=(r-s)/o}else if(r===n){a=2+(s-t)/o}else if(s===n){a=4+(t-r)/o}a=Math.min(a*60,360);if(a<0){a+=360}const u=(i+n)/2;if(n===i){l=0}else if(u<=.5){l=o/(n+i)}else{l=o/(2-n-i)}return[a,l*100,u*100]};n.rgb.hsv=function(e){let t;let r;let s;let i;let n;const o=e[0]/255;const a=e[1]/255;const l=e[2]/255;const u=Math.max(o,a,l);const h=u-Math.min(o,a,l);const diffc=function(e){return(u-e)/6/h+1/2};if(h===0){i=0;n=0}else{n=h/u;t=diffc(o);r=diffc(a);s=diffc(l);if(o===u){i=s-r}else if(a===u){i=1/3+t-s}else if(l===u){i=2/3+r-t}if(i<0){i+=1}else if(i>1){i-=1}}return[i*360,n*100,u*100]};n.rgb.hwb=function(e){const t=e[0];const r=e[1];let s=e[2];const i=n.rgb.hsl(e)[0];const o=1/255*Math.min(t,Math.min(r,s));s=1-1/255*Math.max(t,Math.max(r,s));return[i,o*100,s*100]};n.rgb.cmyk=function(e){const t=e[0]/255;const r=e[1]/255;const s=e[2]/255;const i=Math.min(1-t,1-r,1-s);const n=(1-t-i)/(1-i)||0;const o=(1-r-i)/(1-i)||0;const a=(1-s-i)/(1-i)||0;return[n*100,o*100,a*100,i*100]};function comparativeDistance(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}n.rgb.keyword=function(e){const t=i[e];if(t){return t}let r=Infinity;let n;for(const t of Object.keys(s)){const i=s[t];const o=comparativeDistance(e,i);if(o<r){r=o;n=t}}return n};n.keyword.rgb=function(e){return s[e]};n.rgb.xyz=function(e){let t=e[0]/255;let r=e[1]/255;let s=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92;r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;s=s>.04045?((s+.055)/1.055)**2.4:s/12.92;const i=t*.4124+r*.3576+s*.1805;const n=t*.2126+r*.7152+s*.0722;const o=t*.0193+r*.1192+s*.9505;return[i*100,n*100,o*100]};n.rgb.lab=function(e){const t=n.rgb.xyz(e);let r=t[0];let s=t[1];let i=t[2];r/=95.047;s/=100;i/=108.883;r=r>.008856?r**(1/3):7.787*r+16/116;s=s>.008856?s**(1/3):7.787*s+16/116;i=i>.008856?i**(1/3):7.787*i+16/116;const o=116*s-16;const a=500*(r-s);const l=200*(s-i);return[o,a,l]};n.hsl.rgb=function(e){const t=e[0]/360;const r=e[1]/100;const s=e[2]/100;let i;let n;let o;if(r===0){o=s*255;return[o,o,o]}if(s<.5){i=s*(1+r)}else{i=s+r-s*r}const a=2*s-i;const l=[0,0,0];for(let e=0;e<3;e++){n=t+1/3*-(e-1);if(n<0){n++}if(n>1){n--}if(6*n<1){o=a+(i-a)*6*n}else if(2*n<1){o=i}else if(3*n<2){o=a+(i-a)*(2/3-n)*6}else{o=a}l[e]=o*255}return l};n.hsl.hsv=function(e){const t=e[0];let r=e[1]/100;let s=e[2]/100;let i=r;const n=Math.max(s,.01);s*=2;r*=s<=1?s:2-s;i*=n<=1?n:2-n;const o=(s+r)/2;const a=s===0?2*i/(n+i):2*r/(s+r);return[t,a*100,o*100]};n.hsv.rgb=function(e){const t=e[0]/60;const r=e[1]/100;let s=e[2]/100;const i=Math.floor(t)%6;const n=t-Math.floor(t);const o=255*s*(1-r);const a=255*s*(1-r*n);const l=255*s*(1-r*(1-n));s*=255;switch(i){case 0:return[s,l,o];case 1:return[a,s,o];case 2:return[o,s,l];case 3:return[o,a,s];case 4:return[l,o,s];case 5:return[s,o,a]}};n.hsv.hsl=function(e){const t=e[0];const r=e[1]/100;const s=e[2]/100;const i=Math.max(s,.01);let n;let o;o=(2-r)*s;const a=(2-r)*i;n=r*i;n/=a<=1?a:2-a;n=n||0;o/=2;return[t,n*100,o*100]};n.hwb.rgb=function(e){const t=e[0]/360;let r=e[1]/100;let s=e[2]/100;const i=r+s;let n;if(i>1){r/=i;s/=i}const o=Math.floor(6*t);const a=1-s;n=6*t-o;if((o&1)!==0){n=1-n}const l=r+n*(a-r);let u;let h;let f;switch(o){default:case 6:case 0:u=a;h=l;f=r;break;case 1:u=l;h=a;f=r;break;case 2:u=r;h=a;f=l;break;case 3:u=r;h=l;f=a;break;case 4:u=l;h=r;f=a;break;case 5:u=a;h=r;f=l;break}return[u*255,h*255,f*255]};n.cmyk.rgb=function(e){const t=e[0]/100;const r=e[1]/100;const s=e[2]/100;const i=e[3]/100;const n=1-Math.min(1,t*(1-i)+i);const o=1-Math.min(1,r*(1-i)+i);const a=1-Math.min(1,s*(1-i)+i);return[n*255,o*255,a*255]};n.xyz.rgb=function(e){const t=e[0]/100;const r=e[1]/100;const s=e[2]/100;let i;let n;let o;i=t*3.2406+r*-1.5372+s*-.4986;n=t*-.9689+r*1.8758+s*.0415;o=t*.0557+r*-.204+s*1.057;i=i>.0031308?1.055*i**(1/2.4)-.055:i*12.92;n=n>.0031308?1.055*n**(1/2.4)-.055:n*12.92;o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92;i=Math.min(Math.max(0,i),1);n=Math.min(Math.max(0,n),1);o=Math.min(Math.max(0,o),1);return[i*255,n*255,o*255]};n.xyz.lab=function(e){let t=e[0];let r=e[1];let s=e[2];t/=95.047;r/=100;s/=108.883;t=t>.008856?t**(1/3):7.787*t+16/116;r=r>.008856?r**(1/3):7.787*r+16/116;s=s>.008856?s**(1/3):7.787*s+16/116;const i=116*r-16;const n=500*(t-r);const o=200*(r-s);return[i,n,o]};n.lab.xyz=function(e){const t=e[0];const r=e[1];const s=e[2];let i;let n;let o;n=(t+16)/116;i=r/500+n;o=n-s/200;const a=n**3;const l=i**3;const u=o**3;n=a>.008856?a:(n-16/116)/7.787;i=l>.008856?l:(i-16/116)/7.787;o=u>.008856?u:(o-16/116)/7.787;i*=95.047;n*=100;o*=108.883;return[i,n,o]};n.lab.lch=function(e){const t=e[0];const r=e[1];const s=e[2];let i;const n=Math.atan2(s,r);i=n*360/2/Math.PI;if(i<0){i+=360}const o=Math.sqrt(r*r+s*s);return[t,o,i]};n.lch.lab=function(e){const t=e[0];const r=e[1];const s=e[2];const i=s/360*2*Math.PI;const n=r*Math.cos(i);const o=r*Math.sin(i);return[t,n,o]};n.rgb.ansi16=function(e,t=null){const[r,s,i]=e;let o=t===null?n.rgb.hsv(e)[2]:t;o=Math.round(o/50);if(o===0){return 30}let a=30+(Math.round(i/255)<<2|Math.round(s/255)<<1|Math.round(r/255));if(o===2){a+=60}return a};n.hsv.ansi16=function(e){return n.rgb.ansi16(n.hsv.rgb(e),e[2])};n.rgb.ansi256=function(e){const t=e[0];const r=e[1];const s=e[2];if(t===r&&r===s){if(t<8){return 16}if(t>248){return 231}return Math.round((t-8)/247*24)+232}const i=16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(s/255*5);return i};n.ansi16.rgb=function(e){let t=e%10;if(t===0||t===7){if(e>50){t+=3.5}t=t/10.5*255;return[t,t,t]}const r=(~~(e>50)+1)*.5;const s=(t&1)*r*255;const i=(t>>1&1)*r*255;const n=(t>>2&1)*r*255;return[s,i,n]};n.ansi256.rgb=function(e){if(e>=232){const t=(e-232)*10+8;return[t,t,t]}e-=16;let t;const r=Math.floor(e/36)/5*255;const s=Math.floor((t=e%36)/6)/5*255;const i=t%6/5*255;return[r,s,i]};n.rgb.hex=function(e){const t=((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255);const r=t.toString(16).toUpperCase();return"000000".substring(r.length)+r};n.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t){return[0,0,0]}let r=t[0];if(t[0].length===3){r=r.split("").map((e=>e+e)).join("")}const s=parseInt(r,16);const i=s>>16&255;const n=s>>8&255;const o=s&255;return[i,n,o]};n.rgb.hcg=function(e){const t=e[0]/255;const r=e[1]/255;const s=e[2]/255;const i=Math.max(Math.max(t,r),s);const n=Math.min(Math.min(t,r),s);const o=i-n;let a;let l;if(o<1){a=n/(1-o)}else{a=0}if(o<=0){l=0}else if(i===t){l=(r-s)/o%6}else if(i===r){l=2+(s-t)/o}else{l=4+(t-r)/o}l/=6;l%=1;return[l*360,o*100,a*100]};n.hsl.hcg=function(e){const t=e[1]/100;const r=e[2]/100;const s=r<.5?2*t*r:2*t*(1-r);let i=0;if(s<1){i=(r-.5*s)/(1-s)}return[e[0],s*100,i*100]};n.hsv.hcg=function(e){const t=e[1]/100;const r=e[2]/100;const s=t*r;let i=0;if(s<1){i=(r-s)/(1-s)}return[e[0],s*100,i*100]};n.hcg.rgb=function(e){const t=e[0]/360;const r=e[1]/100;const s=e[2]/100;if(r===0){return[s*255,s*255,s*255]}const i=[0,0,0];const n=t%1*6;const o=n%1;const a=1-o;let l=0;switch(Math.floor(n)){case 0:i[0]=1;i[1]=o;i[2]=0;break;case 1:i[0]=a;i[1]=1;i[2]=0;break;case 2:i[0]=0;i[1]=1;i[2]=o;break;case 3:i[0]=0;i[1]=a;i[2]=1;break;case 4:i[0]=o;i[1]=0;i[2]=1;break;default:i[0]=1;i[1]=0;i[2]=a}l=(1-r)*s;return[(r*i[0]+l)*255,(r*i[1]+l)*255,(r*i[2]+l)*255]};n.hcg.hsv=function(e){const t=e[1]/100;const r=e[2]/100;const s=t+r*(1-t);let i=0;if(s>0){i=t/s}return[e[0],i*100,s*100]};n.hcg.hsl=function(e){const t=e[1]/100;const r=e[2]/100;const s=r*(1-t)+.5*t;let i=0;if(s>0&&s<.5){i=t/(2*s)}else if(s>=.5&&s<1){i=t/(2*(1-s))}return[e[0],i*100,s*100]};n.hcg.hwb=function(e){const t=e[1]/100;const r=e[2]/100;const s=t+r*(1-t);return[e[0],(s-t)*100,(1-s)*100]};n.hwb.hcg=function(e){const t=e[1]/100;const r=e[2]/100;const s=1-r;const i=s-t;let n=0;if(i<1){n=(s-i)/(1-i)}return[e[0],i*100,n*100]};n.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};n.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};n.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};n.gray.hsl=function(e){return[0,0,e[0]]};n.gray.hsv=n.gray.hsl;n.gray.hwb=function(e){return[0,100,e[0]]};n.gray.cmyk=function(e){return[0,0,0,e[0]]};n.gray.lab=function(e){return[e[0],0,0]};n.gray.hex=function(e){const t=Math.round(e[0]/100*255)&255;const r=(t<<16)+(t<<8)+t;const s=r.toString(16).toUpperCase();return"000000".substring(s.length)+s};n.rgb.gray=function(e){const t=(e[0]+e[1]+e[2])/3;return[t/255*100]}},6931:(e,t,r)=>{const s=r(7391);const i=r(880);const n={};const o=Object.keys(s);function wrapRaw(e){const wrappedFn=function(...t){const r=t[0];if(r===undefined||r===null){return r}if(r.length>1){t=r}return e(t)};if("conversion"in e){wrappedFn.conversion=e.conversion}return wrappedFn}function wrapRounded(e){const wrappedFn=function(...t){const r=t[0];if(r===undefined||r===null){return r}if(r.length>1){t=r}const s=e(t);if(typeof s==="object"){for(let e=s.length,t=0;t<e;t++){s[t]=Math.round(s[t])}}return s};if("conversion"in e){wrappedFn.conversion=e.conversion}return wrappedFn}o.forEach((e=>{n[e]={};Object.defineProperty(n[e],"channels",{value:s[e].channels});Object.defineProperty(n[e],"labels",{value:s[e].labels});const t=i(e);const r=Object.keys(t);r.forEach((r=>{const s=t[r];n[e][r]=wrapRounded(s);n[e][r].raw=wrapRaw(s)}))}));e.exports=n},880:(e,t,r)=>{const s=r(7391);function buildGraph(){const e={};const t=Object.keys(s);for(let r=t.length,s=0;s<r;s++){e[t[s]]={distance:-1,parent:null}}return e}function deriveBFS(e){const t=buildGraph();const r=[e];t[e].distance=0;while(r.length){const e=r.pop();const i=Object.keys(s[e]);for(let s=i.length,n=0;n<s;n++){const s=i[n];const o=t[s];if(o.distance===-1){o.distance=t[e].distance+1;o.parent=e;r.unshift(s)}}}return t}function link(e,t){return function(r){return t(e(r))}}function wrapConversion(e,t){const r=[t[e].parent,e];let i=s[t[e].parent][e];let n=t[e].parent;while(t[n].parent){r.unshift(t[n].parent);i=link(s[t[n].parent][n],i);n=t[n].parent}i.conversion=r;return i}e.exports=function(e){const t=deriveBFS(e);const r={};const s=Object.keys(t);for(let e=s.length,i=0;i<e;i++){const e=s[i];const n=t[e];if(n.parent===null){continue}r[e]=wrapConversion(e,t)}return r}},8510:e=>{"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},2746:(e,t,r)=>{"use strict";const s=r(2081);const i=r(6855);const n=r(4101);function spawn(e,t,r){const o=i(e,t,r);const a=s.spawn(o.command,o.args,o.options);n.hookChildProcess(a,o);return a}function spawnSync(e,t,r){const o=i(e,t,r);const a=s.spawnSync(o.command,o.args,o.options);a.error=a.error||n.verifyENOENTSync(a.status,o);return a}e.exports=spawn;e.exports.spawn=spawn;e.exports.sync=spawnSync;e.exports._parse=i;e.exports._enoent=n},4101:e=>{"use strict";const t=process.platform==="win32";function notFoundError(e,t){return Object.assign(new Error(`${t} ${e.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t} ${e.command}`,path:e.command,spawnargs:e.args})}function hookChildProcess(e,r){if(!t){return}const s=e.emit;e.emit=function(t,i){if(t==="exit"){const t=verifyENOENT(i,r,"spawn");if(t){return s.call(e,"error",t)}}return s.apply(e,arguments)}}function verifyENOENT(e,r){if(t&&e===1&&!r.file){return notFoundError(r.original,"spawn")}return null}function verifyENOENTSync(e,r){if(t&&e===1&&!r.file){return notFoundError(r.original,"spawnSync")}return null}e.exports={hookChildProcess:hookChildProcess,verifyENOENT:verifyENOENT,verifyENOENTSync:verifyENOENTSync,notFoundError:notFoundError}},6855:(e,t,r)=>{"use strict";const s=r(1017);const i=r(7274);const n=r(4274);const o=r(1252);const a=process.platform==="win32";const l=/\.(?:com|exe)$/i;const u=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function detectShebang(e){e.file=i(e);const t=e.file&&o(e.file);if(t){e.args.unshift(e.file);e.command=t;return i(e)}return e.file}function parseNonShell(e){if(!a){return e}const t=detectShebang(e);const r=!l.test(t);if(e.options.forceShell||r){const r=u.test(t);e.command=s.normalize(e.command);e.command=n.command(e.command);e.args=e.args.map((e=>n.argument(e,r)));const i=[e.command].concat(e.args).join(" ");e.args=["/d","/s","/c",`"${i}"`];e.command=process.env.comspec||"cmd.exe";e.options.windowsVerbatimArguments=true}return e}function parse(e,t,r){if(t&&!Array.isArray(t)){r=t;t=null}t=t?t.slice(0):[];r=Object.assign({},r);const s={command:e,args:t,options:r,file:undefined,original:{command:e,args:t}};return r.shell?s:parseNonShell(s)}e.exports=parse},4274:e=>{"use strict";const t=/([()\][%!^"`<>&|;, *?])/g;function escapeCommand(e){e=e.replace(t,"^$1");return e}function escapeArgument(e,r){e=`${e}`;e=e.replace(/(\\*)"/g,'$1$1\\"');e=e.replace(/(\\*)$/,"$1$1");e=`"${e}"`;e=e.replace(t,"^$1");if(r){e=e.replace(t,"^$1")}return e}e.exports.command=escapeCommand;e.exports.argument=escapeArgument},1252:(e,t,r)=>{"use strict";const s=r(7147);const i=r(7032);function readShebang(e){const t=150;const r=Buffer.alloc(t);let n;try{n=s.openSync(e,"r");s.readSync(n,r,0,t,0);s.closeSync(n)}catch(e){}return i(r.toString())}e.exports=readShebang},7274:(e,t,r)=>{"use strict";const s=r(1017);const i=r(4207);const n=r(539);function resolveCommandAttempt(e,t){const r=e.options.env||process.env;const o=process.cwd();const a=e.options.cwd!=null;const l=a&&process.chdir!==undefined&&!process.chdir.disabled;if(l){try{process.chdir(e.options.cwd)}catch(e){}}let u;try{u=i.sync(e.command,{path:r[n({env:r})],pathExt:t?s.delimiter:undefined})}catch(e){}finally{if(l){process.chdir(o)}}if(u){u=s.resolve(a?e.options.cwd:"",u)}return u}function resolveCommand(e){return resolveCommandAttempt(e)||resolveCommandAttempt(e,true)}e.exports=resolveCommand},732:(e,t,r)=>{var s=r(8606);e.exports=function(e,t){e=e||{};Object.keys(t).forEach((function(r){if(typeof e[r]==="undefined"){e[r]=s(t[r])}}));return e}},6587:(e,t,r)=>{"use strict";const s=r(9491);const i=r(2361);const n=r(8527);class Enquirer extends i{constructor(e,t){super();this.options=n.merge({},e);this.answers={...t}}register(e,t){if(n.isObject(e)){for(let t of Object.keys(e))this.register(t,e[t]);return this}s.equal(typeof t,"function","expected a function");let r=e.toLowerCase();if(t.prototype instanceof this.Prompt){this.prompts[r]=t}else{this.prompts[r]=t(this.Prompt,this)}return this}async prompt(e=[]){for(let t of[].concat(e)){try{if(typeof t==="function")t=await t.call(this);await this.ask(n.merge({},this.options,t))}catch(e){return Promise.reject(e)}}return this.answers}async ask(e){if(typeof e==="function"){e=await e.call(this)}let t=n.merge({},this.options,e);let{type:r,name:i}=e;let{set:o,get:a}=n;if(typeof r==="function"){r=await r.call(this,e,this.answers)}if(!r)return this.answers[i];s(this.prompts[r],`Prompt "${r}" is not registered`);let l=new this.prompts[r](t);let u=a(this.answers,i);l.state.answers=this.answers;l.enquirer=this;if(i){l.on("submit",(e=>{this.emit("answer",i,e,l);o(this.answers,i,e)}))}let h=l.emit.bind(l);l.emit=(...e)=>{this.emit.call(this,...e);return h(...e)};this.emit("prompt",l,this);if(t.autofill&&u!=null){l.value=l.input=u;if(t.autofill==="show"){await l.submit()}}else{u=l.value=await l.run()}return u}use(e){e.call(this,this);return this}set Prompt(e){this._Prompt=e}get Prompt(){return this._Prompt||this.constructor.Prompt}get prompts(){return this.constructor.prompts}static set Prompt(e){this._Prompt=e}static get Prompt(){return this._Prompt||r(7072)}static get prompts(){return r(6048)}static get types(){return r(891)}static get prompt(){const fn=(e,...t)=>{let r=new this(...t);let s=r.emit.bind(r);r.emit=(...e)=>{fn.emit(...e);return s(...e)};return r.prompt(e)};n.mixinEmitter(fn,new i);return fn}}n.mixinEmitter(Enquirer,new i);const o=Enquirer.prompts;for(let e of Object.keys(o)){let t=e.toLowerCase();let run=t=>new o[e](t).run();Enquirer.prompt[t]=run;Enquirer[t]=run;if(!Enquirer[e]){Reflect.defineProperty(Enquirer,e,{get:()=>o[e]})}}const exp=e=>{n.defineExport(Enquirer,e,(()=>Enquirer.types[e]))};exp("ArrayPrompt");exp("AuthPrompt");exp("BooleanPrompt");exp("NumberPrompt");exp("StringPrompt");e.exports=Enquirer},1330:(e,t,r)=>{"use strict";const s=process.env.TERM_PROGRAM==="Apple_Terminal";const i=r(9151);const n=r(8527);const o=e.exports=t;const a="[";const l="";let u=false;const h=o.code={bell:l,beep:l,beginning:`${a}G`,down:`${a}J`,esc:a,getPosition:`${a}6n`,hide:`${a}?25l`,line:`${a}2K`,lineEnd:`${a}K`,lineStart:`${a}1K`,restorePosition:a+(s?"8":"u"),savePosition:a+(s?"7":"s"),screen:`${a}2J`,show:`${a}?25h`,up:`${a}1J`};const f=o.cursor={get hidden(){return u},hide(){u=true;return h.hide},show(){u=false;return h.show},forward:(e=1)=>`${a}${e}C`,backward:(e=1)=>`${a}${e}D`,nextLine:(e=1)=>`${a}E`.repeat(e),prevLine:(e=1)=>`${a}F`.repeat(e),up:(e=1)=>e?`${a}${e}A`:"",down:(e=1)=>e?`${a}${e}B`:"",right:(e=1)=>e?`${a}${e}C`:"",left:(e=1)=>e?`${a}${e}D`:"",to(e,t){return t?`${a}${t+1};${e+1}H`:`${a}${e+1}G`},move(e=0,t=0){let r="";r+=e<0?f.left(-e):e>0?f.right(e):"";r+=t<0?f.up(-t):t>0?f.down(t):"";return r},restore(e={}){let{after:t,cursor:r,initial:s,input:i,prompt:a,size:l,value:u}=e;s=n.isPrimitive(s)?String(s):"";i=n.isPrimitive(i)?String(i):"";u=n.isPrimitive(u)?String(u):"";if(l){let e=o.cursor.up(l)+o.cursor.to(a.length);let t=i.length-r;if(t>0){e+=o.cursor.left(t)}return e}if(u||t){let e=!i&&!!s?-s.length:-i.length+r;if(t)e-=t.length;if(i===""&&s&&!a.includes(s)){e+=s.length}return o.cursor.move(e)}}};const p=o.erase={screen:h.screen,up:h.up,down:h.down,line:h.line,lineEnd:h.lineEnd,lineStart:h.lineStart,lines(e){let t="";for(let r=0;r<e;r++){t+=o.erase.line+(r<e-1?o.cursor.up(1):"")}if(e)t+=o.code.beginning;return t}};o.clear=(e="",t=process.stdout.columns)=>{if(!t)return p.line+f.to(0);let width=e=>[...i.unstyle(e)].length;let r=e.split(/\r?\n/);let s=0;for(let e of r){s+=1+Math.floor(Math.max(width(e)-1,0)/t)}return(p.line+f.prevLine()).repeat(s-1)+p.line+f.to(0)}},6580:(e,t)=>{"use strict";t.ctrl={a:"first",b:"backward",c:"cancel",d:"deleteForward",e:"last",f:"forward",g:"reset",i:"tab",k:"cutForward",l:"reset",n:"newItem",m:"cancel",j:"submit",p:"search",r:"remove",s:"save",u:"undo",w:"cutLeft",x:"toggleCursor",v:"paste"};t.shift={up:"shiftUp",down:"shiftDown",left:"shiftLeft",right:"shiftRight",tab:"prev"};t.fn={up:"pageUp",down:"pageDown",left:"pageLeft",right:"pageRight",delete:"deleteForward"};t.option={b:"backward",f:"forward",d:"cutRight",left:"cutLeft",up:"altUp",down:"altDown"};t.keys={pageup:"pageUp",pagedown:"pageDown",home:"home",end:"end",cancel:"cancel",delete:"deleteForward",backspace:"delete",down:"down",enter:"submit",escape:"cancel",left:"left",space:"space",number:"number",return:"submit",right:"right",tab:"next",up:"up"}},4130:e=>{"use strict";const unique=e=>e.filter(((t,r)=>e.lastIndexOf(t)===r));const compact=e=>unique(e).filter(Boolean);e.exports=(e,t={},r="")=>{let{past:s=[],present:i=""}=t;let n,o;switch(e){case"prev":case"undo":n=s.slice(0,s.length-1);o=s[s.length-1]||"";return{past:compact([r,...n]),present:o};case"next":case"redo":n=s.slice(1);o=s[0]||"";return{past:compact([...n,r]),present:o};case"save":return{past:compact([...s,r]),present:""};case"remove":o=compact(s.filter((e=>e!==r)));i="";if(o.length){i=o.pop()}return{past:o,present:i};default:{throw new Error(`Invalid action: "${e}"`)}}}},2299:(e,t,r)=>{"use strict";const s=r(9151);const clean=(e="")=>typeof e==="string"?e.replace(/^['"]|['"]$/g,""):"";class Item{constructor(e){this.name=e.key;this.field=e.field||{};this.value=clean(e.initial||this.field.initial||"");this.message=e.message||this.name;this.cursor=0;this.input="";this.lines=[]}}const tokenize=async(e={},t={},r=(e=>e))=>{let s=new Set;let i=e.fields||[];let n=e.template;let o=[];let a=[];let l=[];let u=1;if(typeof n==="function"){n=await n()}let h=-1;let next=()=>n[++h];let peek=()=>n[h+1];let push=e=>{e.line=u;o.push(e)};push({type:"bos",value:""});while(h<n.length-1){let e=next();if(/^[^\S\n ]$/.test(e)){push({type:"text",value:e});continue}if(e==="\n"){push({type:"newline",value:e});u++;continue}if(e==="\\"){e+=next();push({type:"text",value:e});continue}if((e==="$"||e==="#"||e==="{")&&peek()==="{"){let n=next();e+=n;let o={type:"template",open:e,inner:"",close:"",value:e};let u;while(u=next()){if(u==="}"){if(peek()==="}")u+=next();o.value+=u;o.close=u;break}if(u===":"){o.initial="";o.key=o.inner}else if(o.initial!==void 0){o.initial+=u}o.value+=u;o.inner+=u}o.template=o.open+(o.initial||o.inner)+o.close;o.key=o.key||o.inner;if(t.hasOwnProperty(o.key)){o.initial=t[o.key]}o=r(o);push(o);l.push(o.key);s.add(o.key);let h=a.find((e=>e.name===o.key));o.field=i.find((e=>e.name===o.key));if(!h){h=new Item(o);a.push(h)}h.lines.push(o.line-1);continue}let n=o[o.length-1];if(n.type==="text"&&n.line===u){n.value+=e}else{push({type:"text",value:e})}}push({type:"eos",value:""});return{input:n,tabstops:o,unique:s,keys:l,items:a}};e.exports=async e=>{let t=e.options;let r=new Set(t.required===true?[]:t.required||[]);let i={...t.values,...t.initial};let{tabstops:n,items:o,keys:a}=await tokenize(t,i);let l=createFn("result",e,t);let u=createFn("format",e,t);let h=createFn("validate",e,t,true);let f=e.isValue.bind(e);return async(i={},p=false)=>{let d=0;i.required=r;i.items=o;i.keys=a;i.output="";let validate=async(e,t,r,s)=>{let i=await h(e,t,r,s);if(i===false){return"Invalid field "+r.name}return i};for(let r of n){let n=r.value;let a=r.key;if(r.type!=="template"){if(n)i.output+=n;continue}if(r.type==="template"){let h=o.find((e=>e.name===a));if(t.required===true){i.required.add(h.name)}let m=[h.input,i.values[h.value],h.value,n].find(f);let g=h.field||{};let y=g.message||r.inner;if(p){let e=await validate(i.values[a],i,h,d);if(e&&typeof e==="string"||e===false){i.invalid.set(a,e);continue}i.invalid.delete(a);let t=await l(i.values[a],i,h,d);i.output+=s.unstyle(t);continue}h.placeholder=false;let b=n;n=await u(n,i,h,d);if(m!==n){i.values[a]=m;n=e.styles.typing(m);i.missing.delete(y)}else{i.values[a]=void 0;m=`<${y}>`;n=e.styles.primary(m);h.placeholder=true;if(i.required.has(a)){i.missing.add(y)}}if(i.missing.has(y)&&i.validating){n=e.styles.warning(m)}if(i.invalid.has(a)&&i.validating){n=e.styles.danger(m)}if(d===i.index){if(b!==n){n=e.styles.underline(n)}else{n=e.styles.heading(s.unstyle(n))}}d++}if(n){i.output+=n}}let m=i.output.split("\n").map((e=>" "+e));let g=o.length;let y=0;for(let t of o){if(i.invalid.has(t.name)){t.lines.forEach((e=>{if(m[e][0]!==" ")return;m[e]=i.styles.danger(i.symbols.bullet)+m[e].slice(1)}))}if(e.isValue(i.values[t.name])){y++}}i.completed=(y/g*100).toFixed(0);i.output=m.join("\n");return i.output}};function createFn(e,t,r,s){return(r,i,n,o)=>{if(typeof n.field[e]==="function"){return n.field[e].call(t,r,i,n,o)}return[s,r].find((e=>t.isValue(e)))}}},4162:(e,t,r)=>{"use strict";const s=r(4521);const i=r(6580);const n=/^(?:\x1b)([a-zA-Z0-9])$/;const o=/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/;const a={OP:"f1",OQ:"f2",OR:"f3",OS:"f4","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[A":"up","[B":"down","[C":"right","[D":"left","[E":"clear","[F":"end","[H":"home",OA:"up",OB:"down",OC:"right",OD:"left",OE:"clear",OF:"end",OH:"home","[1~":"home","[2~":"insert","[3~":"delete","[4~":"end","[5~":"pageup","[6~":"pagedown","[[5~":"pageup","[[6~":"pagedown","[7~":"home","[8~":"end","[a":"up","[b":"down","[c":"right","[d":"left","[e":"clear","[2$":"insert","[3$":"delete","[5$":"pageup","[6$":"pagedown","[7$":"home","[8$":"end",Oa:"up",Ob:"down",Oc:"right",Od:"left",Oe:"clear","[2^":"insert","[3^":"delete","[5^":"pageup","[6^":"pagedown","[7^":"home","[8^":"end","[Z":"tab"};function isShiftKey(e){return["[a","[b","[c","[d","[e","[2$","[3$","[5$","[6$","[7$","[8$","[Z"].includes(e)}function isCtrlKey(e){return["Oa","Ob","Oc","Od","Oe","[2^","[3^","[5^","[6^","[7^","[8^"].includes(e)}const keypress=(e="",t={})=>{let r;let s={name:t.name,ctrl:false,meta:false,shift:false,option:false,sequence:e,raw:e,...t};if(Buffer.isBuffer(e)){if(e[0]>127&&e[1]===void 0){e[0]-=128;e=""+String(e)}else{e=String(e)}}else if(e!==void 0&&typeof e!=="string"){e=String(e)}else if(!e){e=s.sequence||""}s.sequence=s.sequence||e||s.name;if(e==="\r"){s.raw=void 0;s.name="return"}else if(e==="\n"){s.name="enter"}else if(e==="\t"){s.name="tab"}else if(e==="\b"||e===""||e===""||e==="\b"){s.name="backspace";s.meta=e.charAt(0)===""}else if(e===""||e===""){s.name="escape";s.meta=e.length===2}else if(e===" "||e===" "){s.name="space";s.meta=e.length===2}else if(e<=""){s.name=String.fromCharCode(e.charCodeAt(0)+"a".charCodeAt(0)-1);s.ctrl=true}else if(e.length===1&&e>="0"&&e<="9"){s.name="number"}else if(e.length===1&&e>="a"&&e<="z"){s.name=e}else if(e.length===1&&e>="A"&&e<="Z"){s.name=e.toLowerCase();s.shift=true}else if(r=n.exec(e)){s.meta=true;s.shift=/^[A-Z]$/.test(r[1])}else if(r=o.exec(e)){let t=[...e];if(t[0]===""&&t[1]===""){s.option=true}let i=[r[1],r[2],r[4],r[6]].filter(Boolean).join("");let n=(r[3]||r[5]||1)-1;s.ctrl=!!(n&4);s.meta=!!(n&10);s.shift=!!(n&1);s.code=i;s.name=a[i];s.shift=isShiftKey(i)||s.shift;s.ctrl=isCtrlKey(i)||s.ctrl}return s};keypress.listen=(e={},t)=>{let{stdin:r}=e;if(!r||r!==process.stdin&&!r.isTTY){throw new Error("Invalid stream passed")}let i=s.createInterface({terminal:true,input:r});s.emitKeypressEvents(r,i);let on=(e,r)=>t(e,keypress(e,r),i);let n=r.isRaw;if(r.isTTY)r.setRawMode(true);r.on("keypress",on);i.resume();let off=()=>{if(r.isTTY)r.setRawMode(n);r.removeListener("keypress",on);i.pause();i.close()};return off};keypress.action=(e,t,r)=>{let s={...i,...r};if(t.ctrl){t.action=s.ctrl[t.name];return t}if(t.option&&s.option){t.action=s.option[t.name];return t}if(t.shift){t.action=s.shift[t.name];return t}t.action=s.keys[t.name];return t};e.exports=keypress},9690:(e,t,r)=>{"use strict";const s=r(8527);e.exports=(e,t={})=>{e.cursorHide();let{input:r="",initial:i="",pos:n,showCursor:o=true,color:a}=t;let l=a||e.styles.placeholder;let u=s.inverse(e.styles.primary);let blinker=t=>u(e.styles.black(t));let h=r;let f=" ";let p=blinker(f);if(e.blink&&e.blink.off===true){blinker=e=>e;p=""}if(o&&n===0&&i===""&&r===""){return blinker(f)}if(o&&n===0&&(r===i||r==="")){return blinker(i[0])+l(i.slice(1))}i=s.isPrimitive(i)?`${i}`:"";r=s.isPrimitive(r)?`${r}`:"";let d=i&&i.startsWith(r)&&i!==r;let m=d?blinker(i[r.length]):p;if(n!==r.length&&o===true){h=r.slice(0,n)+blinker(r[n])+r.slice(n+1);m=""}if(o===false){m=""}if(d){let t=e.styles.unstyle(h+m);return h+m+l(i.slice(t.length))}return h+m}},7072:(e,t,r)=>{"use strict";const s=r(2361);const i=r(9151);const n=r(4162);const o=r(7711);const a=r(1686);const l=r(6739);const u=r(8527);const h=r(1330);class Prompt extends s{constructor(e={}){super();this.name=e.name;this.type=e.type;this.options=e;l(this);o(this);this.state=new a(this);this.initial=[e.initial,e.default].find((e=>e!=null));this.stdout=e.stdout||process.stdout;this.stdin=e.stdin||process.stdin;this.scale=e.scale||1;this.term=this.options.term||process.env.TERM_PROGRAM;this.margin=margin(this.options.margin);this.setMaxListeners(0);setOptions(this)}async keypress(e,t={}){this.keypressed=true;let r=n.action(e,n(e,t),this.options.actions);this.state.keypress=r;this.emit("keypress",e,r);this.emit("state",this.state.clone());let s=this.options[r.action]||this[r.action]||this.dispatch;if(typeof s==="function"){return await s.call(this,e,r)}this.alert()}alert(){delete this.state.alert;if(this.options.show===false){this.emit("alert")}else{this.stdout.write(h.code.beep)}}cursorHide(){this.stdout.write(h.cursor.hide());u.onExit((()=>this.cursorShow()))}cursorShow(){this.stdout.write(h.cursor.show())}write(e){if(!e)return;if(this.stdout&&this.state.show!==false){this.stdout.write(e)}this.state.buffer+=e}clear(e=0){let t=this.state.buffer;this.state.buffer="";if(!t&&!e||this.options.show===false)return;this.stdout.write(h.cursor.down(e)+h.clear(t,this.width))}restore(){if(this.state.closed||this.options.show===false)return;let{prompt:e,after:t,rest:r}=this.sections();let{cursor:s,initial:i="",input:n="",value:o=""}=this;let a=this.state.size=r.length;let l={after:t,cursor:s,initial:i,input:n,prompt:e,size:a,value:o};let u=h.cursor.restore(l);if(u){this.stdout.write(u)}}sections(){let{buffer:e,input:t,prompt:r}=this.state;r=i.unstyle(r);let s=i.unstyle(e);let n=s.indexOf(r);let o=s.slice(0,n);let a=s.slice(n);let l=a.split("\n");let u=l[0];let h=l[l.length-1];let f=r+(t?" "+t:"");let p=f.length;let d=p<u.length?u.slice(p+1):"";return{header:o,prompt:u,after:d,rest:l.slice(1),last:h}}async submit(){this.state.submitted=true;this.state.validating=true;if(this.options.onSubmit){await this.options.onSubmit.call(this,this.name,this.value,this)}let e=this.state.error||await this.validate(this.value,this.state);if(e!==true){let t="\n"+this.symbols.pointer+" ";if(typeof e==="string"){t+=e.trim()}else{t+="Invalid input"}this.state.error="\n"+this.styles.danger(t);this.state.submitted=false;await this.render();await this.alert();this.state.validating=false;this.state.error=void 0;return}this.state.validating=false;await this.render();await this.close();this.value=await this.result(this.value);this.emit("submit",this.value)}async cancel(e){this.state.cancelled=this.state.submitted=true;await this.render();await this.close();if(typeof this.options.onCancel==="function"){await this.options.onCancel.call(this,this.name,this.value,this)}this.emit("cancel",await this.error(e))}async close(){this.state.closed=true;try{let e=this.sections();let t=Math.ceil(e.prompt.length/this.width);if(e.rest){this.write(h.cursor.down(e.rest.length))}this.write("\n".repeat(t))}catch(e){}this.emit("close")}start(){if(!this.stop&&this.options.show!==false){this.stop=n.listen(this,this.keypress.bind(this));this.once("close",this.stop)}}async skip(){this.skipped=this.options.skip===true;if(typeof this.options.skip==="function"){this.skipped=await this.options.skip.call(this,this.name,this.value)}return this.skipped}async initialize(){let{format:e,options:t,result:r}=this;this.format=()=>e.call(this,this.value);this.result=()=>r.call(this,this.value);if(typeof t.initial==="function"){this.initial=await t.initial.call(this,this)}if(typeof t.onRun==="function"){await t.onRun.call(this,this)}if(typeof t.onSubmit==="function"){let e=t.onSubmit.bind(this);let r=this.submit.bind(this);delete this.options.onSubmit;this.submit=async()=>{await e(this.name,this.value,this);return r()}}await this.start();await this.render()}render(){throw new Error("expected prompt to have a custom render method")}run(){return new Promise((async(e,t)=>{this.once("submit",e);this.once("cancel",t);if(await this.skip()){this.render=()=>{};return this.submit()}await this.initialize();this.emit("run")}))}async element(e,t,r){let{options:s,state:i,symbols:n,timers:o}=this;let a=o&&o[e];i.timer=a;let l=s[e]||i[e]||n[e];let u=t&&t[e]!=null?t[e]:await l;if(u==="")return u;let h=await this.resolve(u,i,t,r);if(!h&&t&&t[e]){return this.resolve(l,i,t,r)}return h}async prefix(){let e=await this.element("prefix")||this.symbols;let t=this.timers&&this.timers.prefix;let r=this.state;r.timer=t;if(u.isObject(e))e=e[r.status]||e.pending;if(!u.hasColor(e)){let t=this.styles[r.status]||this.styles.pending;return t(e)}return e}async message(){let e=await this.element("message");if(!u.hasColor(e)){return this.styles.strong(e)}return e}async separator(){let e=await this.element("separator")||this.symbols;let t=this.timers&&this.timers.separator;let r=this.state;r.timer=t;let s=e[r.status]||e.pending||r.separator;let i=await this.resolve(s,r);if(u.isObject(i))i=i[r.status]||i.pending;if(!u.hasColor(i)){return this.styles.muted(i)}return i}async pointer(e,t){let r=await this.element("pointer",e,t);if(typeof r==="string"&&u.hasColor(r)){return r}if(r){let e=this.styles;let s=this.index===t;let i=s?e.primary:e=>e;let n=await this.resolve(r[s?"on":"off"]||r,this.state);let o=!u.hasColor(n)?i(n):n;return s?o:" ".repeat(n.length)}}async indicator(e,t){let r=await this.element("indicator",e,t);if(typeof r==="string"&&u.hasColor(r)){return r}if(r){let t=this.styles;let s=e.enabled===true;let i=s?t.success:t.dark;let n=r[s?"on":"off"]||r;return!u.hasColor(n)?i(n):n}return""}body(){return null}footer(){if(this.state.status==="pending"){return this.element("footer")}}header(){if(this.state.status==="pending"){return this.element("header")}}async hint(){if(this.state.status==="pending"&&!this.isValue(this.state.input)){let e=await this.element("hint");if(!u.hasColor(e)){return this.styles.muted(e)}return e}}error(e){return!this.state.submitted?e||this.state.error:""}format(e){return e}result(e){return e}validate(e){if(this.options.required===true){return this.isValue(e)}return true}isValue(e){return e!=null&&e!==""}resolve(e,...t){return u.resolve(this,e,...t)}get base(){return Prompt.prototype}get style(){return this.styles[this.state.status]}get height(){return this.options.rows||u.height(this.stdout,25)}get width(){return this.options.columns||u.width(this.stdout,80)}get size(){return{width:this.width,height:this.height}}set cursor(e){this.state.cursor=e}get cursor(){return this.state.cursor}set input(e){this.state.input=e}get input(){return this.state.input}set value(e){this.state.value=e}get value(){let{input:e,value:t}=this.state;let r=[t,e].find(this.isValue.bind(this));return this.isValue(r)?r:this.initial}static get prompt(){return e=>new this(e).run()}}function setOptions(e){let isValidKey=t=>e[t]===void 0||typeof e[t]==="function";let t=["actions","choices","initial","margin","roles","styles","symbols","theme","timers","value"];let r=["body","footer","error","header","hint","indicator","message","prefix","separator","skip"];for(let s of Object.keys(e.options)){if(t.includes(s))continue;if(/^on[A-Z]/.test(s))continue;let i=e.options[s];if(typeof i==="function"&&isValidKey(s)){if(!r.includes(s)){e[s]=i.bind(e)}}else if(typeof e[s]!=="function"){e[s]=i}}}function margin(e){if(typeof e==="number"){e=[e,e,e,e]}let t=[].concat(e||[]);let pad=e=>e%2===0?"\n":" ";let r=[];for(let e=0;e<4;e++){let s=pad(e);if(t[e]){r.push(s.repeat(t[e]))}else{r.push("")}}return r}e.exports=Prompt},4858:(e,t,r)=>{"use strict";const s=r(4449);const highlight=(e,t)=>{let r=e.toLowerCase();return e=>{let s=e.toLowerCase();let i=s.indexOf(r);let n=t(e.slice(i,i+r.length));return i>=0?e.slice(0,i)+n+e.slice(i+r.length):e}};class AutoComplete extends s{constructor(e){super(e);this.cursorShow()}moveCursor(e){this.state.cursor+=e}dispatch(e){return this.append(e)}space(e){return this.options.multiple?super.space(e):this.append(e)}append(e){let{cursor:t,input:r}=this.state;this.input=r.slice(0,t)+e+r.slice(t);this.moveCursor(1);return this.complete()}delete(){let{cursor:e,input:t}=this.state;if(!t)return this.alert();this.input=t.slice(0,e-1)+t.slice(e);this.moveCursor(-1);return this.complete()}deleteForward(){let{cursor:e,input:t}=this.state;if(t[e]===void 0)return this.alert();this.input=`${t}`.slice(0,e)+`${t}`.slice(e+1);return this.complete()}number(e){return this.append(e)}async complete(){this.completing=true;this.choices=await this.suggest(this.input,this.state._choices);this.state.limit=void 0;this.index=Math.min(Math.max(this.visible.length-1,0),this.index);await this.render();this.completing=false}suggest(e=this.input,t=this.state._choices){if(typeof this.options.suggest==="function"){return this.options.suggest.call(this,e,t)}let r=e.toLowerCase();return t.filter((e=>e.message.toLowerCase().includes(r)))}pointer(){return""}format(){if(!this.focused)return this.input;if(this.options.multiple&&this.state.submitted){return this.selected.map((e=>this.styles.primary(e.message))).join(", ")}if(this.state.submitted){let e=this.value=this.input=this.focused.value;return this.styles.primary(e)}return this.input}async render(){if(this.state.status!=="pending")return super.render();let e=this.options.highlight?this.options.highlight.bind(this):this.styles.placeholder;let t=highlight(this.input,e);let r=this.choices;this.choices=r.map((e=>({...e,message:t(e.message)})));await super.render();this.choices=r}submit(){if(this.options.multiple){this.value=this.selected.map((e=>e.name))}return super.submit()}}e.exports=AutoComplete},5389:(e,t,r)=>{"use strict";const s=r(3315);function defaultAuthenticate(e,t){if(e.username===this.options.username&&e.password===this.options.password){return true}return false}const factory=(e=defaultAuthenticate)=>{const t=[{name:"username",message:"username"},{name:"password",message:"password",format(e){if(this.options.showPassword){return e}let t=this.state.submitted?this.styles.primary:this.styles.muted;return t(this.symbols.asterisk.repeat(e.length))}}];class BasicAuthPrompt extends(s.create(e)){constructor(e){super({...e,choices:t})}static create(e){return factory(e)}}return BasicAuthPrompt};e.exports=factory()},410:(e,t,r)=>{"use strict";const s=r(3055);class ConfirmPrompt extends s{constructor(e){super(e);this.default=this.options.default||(this.initial?"(Y/n)":"(y/N)")}}e.exports=ConfirmPrompt},8408:(e,t,r)=>{"use strict";const s=r(4449);const i=r(1787);const n=i.prototype;class Editable extends s{constructor(e){super({...e,multiple:true});this.align=[this.options.align,"left"].find((e=>e!=null));this.emptyError="";this.values={}}dispatch(e,t){let r=this.focused;let s=r.parent||{};if(!r.editable&&!s.editable){if(e==="a"||e==="i")return super[e]()}return n.dispatch.call(this,e,t)}append(e,t){return n.append.call(this,e,t)}delete(e,t){return n.delete.call(this,e,t)}space(e){return this.focused.editable?this.append(e):super.space()}number(e){return this.focused.editable?this.append(e):super.number(e)}next(){return this.focused.editable?n.next.call(this):super.next()}prev(){return this.focused.editable?n.prev.call(this):super.prev()}async indicator(e,t){let r=e.indicator||"";let s=e.editable?r:super.indicator(e,t);return await this.resolve(s,this.state,e,t)||""}indent(e){return e.role==="heading"?"":e.editable?" ":" "}async renderChoice(e,t){e.indent="";if(e.editable)return n.renderChoice.call(this,e,t);return super.renderChoice(e,t)}error(){return""}footer(){return this.state.error}async validate(){let e=true;for(let t of this.choices){if(typeof t.validate!=="function"){continue}if(t.role==="heading"){continue}let r=t.parent?this.value[t.parent.name]:this.value;if(t.editable){r=t.value===t.name?t.initial||"":t.value}else if(!this.isDisabled(t)){r=t.enabled===true}e=await t.validate(r,this.state);if(e!==true){break}}if(e!==true){this.state.error=typeof e==="string"?e:"Invalid Input"}return e}submit(){if(this.focused.newChoice===true)return super.submit();if(this.choices.some((e=>e.newChoice))){return this.alert()}this.value={};for(let e of this.choices){let t=e.parent?this.value[e.parent.name]:this.value;if(e.role==="heading"){this.value[e.name]={};continue}if(e.editable){t[e.name]=e.value===e.name?e.initial||"":e.value}else if(!this.isDisabled(e)){t[e.name]=e.enabled===true}}return this.base.submit.call(this)}}e.exports=Editable},1787:(e,t,r)=>{"use strict";const s=r(9151);const i=r(4449);const n=r(9690);class FormPrompt extends i{constructor(e){super({...e,multiple:true});this.type="form";this.initial=this.options.initial;this.align=[this.options.align,"right"].find((e=>e!=null));this.emptyError="";this.values={}}async reset(e){await super.reset();if(e===true)this._index=this.index;this.index=this._index;this.values={};this.choices.forEach((e=>e.reset&&e.reset()));return this.render()}dispatch(e){return!!e&&this.append(e)}append(e){let t=this.focused;if(!t)return this.alert();let{cursor:r,input:s}=t;t.value=t.input=s.slice(0,r)+e+s.slice(r);t.cursor++;return this.render()}delete(){let e=this.focused;if(!e||e.cursor<=0)return this.alert();let{cursor:t,input:r}=e;e.value=e.input=r.slice(0,t-1)+r.slice(t);e.cursor--;return this.render()}deleteForward(){let e=this.focused;if(!e)return this.alert();let{cursor:t,input:r}=e;if(r[t]===void 0)return this.alert();let s=`${r}`.slice(0,t)+`${r}`.slice(t+1);e.value=e.input=s;return this.render()}right(){let e=this.focused;if(!e)return this.alert();if(e.cursor>=e.input.length)return this.alert();e.cursor++;return this.render()}left(){let e=this.focused;if(!e)return this.alert();if(e.cursor<=0)return this.alert();e.cursor--;return this.render()}space(e,t){return this.dispatch(e,t)}number(e,t){return this.dispatch(e,t)}next(){let e=this.focused;if(!e)return this.alert();let{initial:t,input:r}=e;if(t&&t.startsWith(r)&&r!==t){e.value=e.input=t;e.cursor=e.value.length;return this.render()}return super.next()}prev(){let e=this.focused;if(!e)return this.alert();if(e.cursor===0)return super.prev();e.value=e.input="";e.cursor=0;return this.render()}separator(){return""}format(e){return!this.state.submitted?super.format(e):""}pointer(){return""}indicator(e){return e.input?"⦿":"⊙"}async choiceSeparator(e,t){let r=await this.resolve(e.separator,this.state,e,t)||":";return r?" "+this.styles.disabled(r):""}async renderChoice(e,t){await this.onChoice(e,t);let{state:r,styles:i}=this;let{cursor:o,initial:a="",name:l,hint:u,input:h=""}=e;let{muted:f,submitted:p,primary:d,danger:m}=i;let g=u;let y=this.index===t;let b=e.validate||(()=>true);let _=await this.choiceSeparator(e,t);let v=e.message;if(this.align==="right")v=v.padStart(this.longest+1," ");if(this.align==="left")v=v.padEnd(this.longest+1," ");let w=this.values[l]=h||a;let E=h?"success":"dark";if(await b.call(e,w,this.state)!==true){E="danger"}let S=i[E];let x=S(await this.indicator(e,t))+(e.pad||"");let R=this.indent(e);let line=()=>[R,x,v+_,h,g].filter(Boolean).join(" ");if(r.submitted){v=s.unstyle(v);h=p(h);g="";return line()}if(e.format){h=await e.format.call(this,h,e,t)}else{let e=this.styles.muted;let t={input:h,initial:a,pos:o,showCursor:y,color:e};h=n(this,t)}if(!this.isValue(h)){h=this.styles.muted(this.symbols.ellipsis)}if(e.result){this.values[l]=await e.result.call(this,w,e,t)}if(y){v=d(v)}if(e.error){h+=(h?" ":"")+m(e.error.trim())}else if(e.hint){h+=(h?" ":"")+f(e.hint.trim())}return line()}async submit(){this.value=this.values;return super.base.submit.call(this)}}e.exports=FormPrompt},6048:(e,t,r)=>{"use strict";const s=r(8527);const define=(e,r)=>{s.defineExport(t,e,r);s.defineExport(t,e.toLowerCase(),r)};define("AutoComplete",(()=>r(4858)));define("BasicAuth",(()=>r(5389)));define("Confirm",(()=>r(410)));define("Editable",(()=>r(8408)));define("Form",(()=>r(1787)));define("Input",(()=>r(338)));define("Invisible",(()=>r(1289)));define("List",(()=>r(1996)));define("MultiSelect",(()=>r(2350)));define("Numeral",(()=>r(3542)));define("Password",(()=>r(2824)));define("Scale",(()=>r(3513)));define("Select",(()=>r(4449)));define("Snippet",(()=>r(3625)));define("Sort",(()=>r(5873)));define("Survey",(()=>r(5610)));define("Text",(()=>r(8355)));define("Toggle",(()=>r(1394)));define("Quiz",(()=>r(3981)))},338:(e,t,r)=>{"use strict";const s=r(1401);const i=r(4130);class Input extends s{constructor(e){super(e);let t=this.options.history;if(t&&t.store){let e=t.values||this.initial;this.autosave=!!t.autosave;this.store=t.store;this.data=this.store.get("values")||{past:[],present:e};this.initial=this.data.present||this.data.past[this.data.past.length-1]}}completion(e){if(!this.store)return this.alert();this.data=i(e,this.data,this.input);if(!this.data.present)return this.alert();this.input=this.data.present;this.cursor=this.input.length;return this.render()}altUp(){return this.completion("prev")}altDown(){return this.completion("next")}prev(){this.save();return super.prev()}save(){if(!this.store)return;this.data=i("save",this.data,this.input);this.store.set("values",this.data)}submit(){if(this.store&&this.autosave===true){this.save()}return super.submit()}}e.exports=Input},1289:(e,t,r)=>{"use strict";const s=r(1401);class InvisiblePrompt extends s{format(){return""}}e.exports=InvisiblePrompt},1996:(e,t,r)=>{"use strict";const s=r(1401);class ListPrompt extends s{constructor(e={}){super(e);this.sep=this.options.separator||/, */;this.initial=e.initial||""}split(e=this.value){return e?String(e).split(this.sep):[]}format(){let e=this.state.submitted?this.styles.primary:e=>e;return this.list.map(e).join(", ")}async submit(e){let t=this.state.error||await this.validate(this.list,this.state);if(t!==true){this.state.error=t;return super.submit()}this.value=this.list;return super.submit()}get list(){return this.split()}}e.exports=ListPrompt},2350:(e,t,r)=>{"use strict";const s=r(4449);class MultiSelect extends s{constructor(e){super({...e,multiple:true})}}e.exports=MultiSelect},3542:(e,t,r)=>{e.exports=r(7572)},2824:(e,t,r)=>{"use strict";const s=r(1401);class PasswordPrompt extends s{constructor(e){super(e);this.cursorShow()}format(e=this.input){if(!this.keypressed)return"";let t=this.state.submitted?this.styles.primary:this.styles.muted;return t(this.symbols.asterisk.repeat(e.length))}}e.exports=PasswordPrompt},3981:(e,t,r)=>{"use strict";const s=r(4449);class Quiz extends s{constructor(e){super(e);if(typeof this.options.correctChoice!=="number"||this.options.correctChoice<0){throw new Error("Please specify the index of the correct answer from the list of choices")}}async toChoices(e,t){let r=await super.toChoices(e,t);if(r.length<2){throw new Error("Please give at least two choices to the user")}if(this.options.correctChoice>r.length){throw new Error("Please specify the index of the correct answer from the list of choices")}return r}check(e){return e.index===this.options.correctChoice}async result(e){return{selectedAnswer:e,correctAnswer:this.options.choices[this.options.correctChoice].value,correct:await this.check(this.state)}}}e.exports=Quiz},3513:(e,t,r)=>{"use strict";const s=r(9151);const i=r(7633);const n=r(8527);class LikertScale extends i{constructor(e={}){super(e);this.widths=[].concat(e.messageWidth||50);this.align=[].concat(e.align||"left");this.linebreak=e.linebreak||false;this.edgeLength=e.edgeLength||3;this.newline=e.newline||"\n ";let t=e.startNumber||1;if(typeof this.scale==="number"){this.scaleKey=false;this.scale=Array(this.scale).fill(0).map(((e,r)=>({name:r+t})))}}async reset(){this.tableized=false;await super.reset();return this.render()}tableize(){if(this.tableized===true)return;this.tableized=true;let e=0;for(let t of this.choices){e=Math.max(e,t.message.length);t.scaleIndex=t.initial||2;t.scale=[];for(let e=0;e<this.scale.length;e++){t.scale.push({index:e})}}this.widths[0]=Math.min(this.widths[0],e+3)}async dispatch(e,t){if(this.multiple){return this[t.name]?await this[t.name](e,t):await super.dispatch(e,t)}this.alert()}heading(e,t,r){return this.styles.strong(e)}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;if(e.scaleIndex>=this.scale.length-1)return this.alert();e.scaleIndex++;return this.render()}left(){let e=this.focused;if(e.scaleIndex<=0)return this.alert();e.scaleIndex--;return this.render()}indent(){return""}format(){if(this.state.submitted){let e=this.choices.map((e=>this.styles.info(e.index)));return e.join(", ")}return""}pointer(){return""}renderScaleKey(){if(this.scaleKey===false)return"";if(this.state.submitted)return"";let e=this.scale.map((e=>` ${e.name} - ${e.message}`));let t=["",...e].map((e=>this.styles.muted(e)));return t.join("\n")}renderScaleHeading(e){let t=this.scale.map((e=>e.name));if(typeof this.options.renderScaleHeading==="function"){t=this.options.renderScaleHeading.call(this,e)}let r=this.scaleLength-t.join("").length;let s=Math.round(r/(t.length-1));let i=t.map((e=>this.styles.strong(e)));let n=i.join(" ".repeat(s));let o=" ".repeat(this.widths[0]);return this.margin[3]+o+this.margin[1]+n}scaleIndicator(e,t,r){if(typeof this.options.scaleIndicator==="function"){return this.options.scaleIndicator.call(this,e,t,r)}let s=e.scaleIndex===t.index;if(t.disabled)return this.styles.hint(this.symbols.radio.disabled);if(s)return this.styles.success(this.symbols.radio.on);return this.symbols.radio.off}renderScale(e,t){let r=e.scale.map((r=>this.scaleIndicator(e,r,t)));let s=this.term==="Hyper"?"":" ";return r.join(s+this.symbols.line.repeat(this.edgeLength))}async renderChoice(e,t){await this.onChoice(e,t);let r=this.index===t;let i=await this.pointer(e,t);let o=await e.hint;if(o&&!n.hasColor(o)){o=this.styles.muted(o)}let pad=e=>this.margin[3]+e.replace(/\s+$/,"").padEnd(this.widths[0]," ");let a=this.newline;let l=this.indent(e);let u=await this.resolve(e.message,this.state,e,t);let h=await this.renderScale(e,t);let f=this.margin[1]+this.margin[3];this.scaleLength=s.unstyle(h).length;this.widths[0]=Math.min(this.widths[0],this.width-this.scaleLength-f.length);let p=n.wordWrap(u,{width:this.widths[0],newline:a});let d=p.split("\n").map((e=>pad(e)+this.margin[1]));if(r){h=this.styles.info(h);d=d.map((e=>this.styles.info(e)))}d[0]+=h;if(this.linebreak)d.push("");return[l+i,d.join("\n")].filter(Boolean)}async renderChoices(){if(this.state.submitted)return"";this.tableize();let e=this.visible.map((async(e,t)=>await this.renderChoice(e,t)));let t=await Promise.all(e);let r=await this.renderScaleHeading();return this.margin[0]+[r,...t.map((e=>e.join(" ")))].join("\n")}async render(){let{submitted:e,size:t}=this.state;let r=await this.prefix();let s=await this.separator();let i=await this.message();let n="";if(this.options.promptLine!==false){n=[r,i,s,""].join(" ");this.state.prompt=n}let o=await this.header();let a=await this.format();let l=await this.renderScaleKey();let u=await this.error()||await this.hint();let h=await this.renderChoices();let f=await this.footer();let p=this.emptyError;if(a)n+=a;if(u&&!n.includes(u))n+=" "+u;if(e&&!a&&!h.trim()&&this.multiple&&p!=null){n+=this.styles.danger(p)}this.clear(t);this.write([o,n,l,h,f].filter(Boolean).join("\n"));if(!this.state.submitted){this.write(this.margin[2])}this.restore()}submit(){this.value={};for(let e of this.choices){this.value[e.name]=e.scaleIndex}return this.base.submit.call(this)}}e.exports=LikertScale},4449:(e,t,r)=>{"use strict";const s=r(7633);const i=r(8527);class SelectPrompt extends s{constructor(e){super(e);this.emptyError=this.options.emptyError||"No items were selected"}async dispatch(e,t){if(this.multiple){return this[t.name]?await this[t.name](e,t):await super.dispatch(e,t)}this.alert()}separator(){if(this.options.separator)return super.separator();let e=this.styles.muted(this.symbols.ellipsis);return this.state.submitted?super.separator():e}pointer(e,t){return!this.multiple||this.options.pointer?super.pointer(e,t):""}indicator(e,t){return this.multiple?super.indicator(e,t):""}choiceMessage(e,t){let r=this.resolve(e.message,this.state,e,t);if(e.role==="heading"&&!i.hasColor(r)){r=this.styles.strong(r)}return this.resolve(r,this.state,e,t)}choiceSeparator(){return":"}async renderChoice(e,t){await this.onChoice(e,t);let r=this.index===t;let s=await this.pointer(e,t);let n=await this.indicator(e,t)+(e.pad||"");let o=await this.resolve(e.hint,this.state,e,t);if(o&&!i.hasColor(o)){o=this.styles.muted(o)}let a=this.indent(e);let l=await this.choiceMessage(e,t);let line=()=>[this.margin[3],a+s+n,l,this.margin[1],o].filter(Boolean).join(" ");if(e.role==="heading"){return line()}if(e.disabled){if(!i.hasColor(l)){l=this.styles.disabled(l)}return line()}if(r){l=this.styles.em(l)}return line()}async renderChoices(){if(this.state.loading==="choices"){return this.styles.warning("Loading choices")}if(this.state.submitted)return"";let e=this.visible.map((async(e,t)=>await this.renderChoice(e,t)));let t=await Promise.all(e);if(!t.length)t.push(this.styles.danger("No matching choices"));let r=this.margin[0]+t.join("\n");let s;if(this.options.choicesHeader){s=await this.resolve(this.options.choicesHeader,this.state)}return[s,r].filter(Boolean).join("\n")}format(){if(!this.state.submitted||this.state.cancelled)return"";if(Array.isArray(this.selected)){return this.selected.map((e=>this.styles.primary(e.name))).join(", ")}return this.styles.primary(this.selected.name)}async render(){let{submitted:e,size:t}=this.state;let r="";let s=await this.header();let i=await this.prefix();let n=await this.separator();let o=await this.message();if(this.options.promptLine!==false){r=[i,o,n,""].join(" ");this.state.prompt=r}let a=await this.format();let l=await this.error()||await this.hint();let u=await this.renderChoices();let h=await this.footer();if(a)r+=a;if(l&&!r.includes(l))r+=" "+l;if(e&&!a&&!u.trim()&&this.multiple&&this.emptyError!=null){r+=this.styles.danger(this.emptyError)}this.clear(t);this.write([s,r,u,h].filter(Boolean).join("\n"));this.write(this.margin[2]);this.restore()}}e.exports=SelectPrompt},3625:(e,t,r)=>{"use strict";const s=r(9151);const i=r(2299);const n=r(7072);class SnippetPrompt extends n{constructor(e){super(e);this.cursorHide();this.reset(true)}async initialize(){this.interpolate=await i(this);await super.initialize()}async reset(e){this.state.keys=[];this.state.invalid=new Map;this.state.missing=new Set;this.state.completed=0;this.state.values={};if(e!==true){await this.initialize();await this.render()}}moveCursor(e){let t=this.getItem();this.cursor+=e;t.cursor+=e}dispatch(e,t){if(!t.code&&!t.ctrl&&e!=null&&this.getItem()){this.append(e,t);return}this.alert()}append(e,t){let r=this.getItem();let s=r.input.slice(0,this.cursor);let i=r.input.slice(this.cursor);this.input=r.input=`${s}${e}${i}`;this.moveCursor(1);this.render()}delete(){let e=this.getItem();if(this.cursor<=0||!e.input)return this.alert();let t=e.input.slice(this.cursor);let r=e.input.slice(0,this.cursor-1);this.input=e.input=`${r}${t}`;this.moveCursor(-1);this.render()}increment(e){return e>=this.state.keys.length-1?0:e+1}decrement(e){return e<=0?this.state.keys.length-1:e-1}first(){this.state.index=0;this.render()}last(){this.state.index=this.state.keys.length-1;this.render()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1);this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1);this.render()}prev(){this.state.index=this.decrement(this.state.index);this.getItem();this.render()}next(){this.state.index=this.increment(this.state.index);this.getItem();this.render()}up(){this.prev()}down(){this.next()}format(e){let t=this.state.completed<100?this.styles.warning:this.styles.success;if(this.state.submitted===true&&this.state.completed!==100){t=this.styles.danger}return t(`${this.state.completed}% completed`)}async render(){let{index:e,keys:t=[],submitted:r,size:s}=this.state;let i=[this.options.newline,"\n"].find((e=>e!=null));let n=await this.prefix();let o=await this.separator();let a=await this.message();let l=[n,a,o].filter(Boolean).join(" ");this.state.prompt=l;let u=await this.header();let h=await this.error()||"";let f=await this.hint()||"";let p=r?"":await this.interpolate(this.state);let d=this.state.key=t[e]||"";let m=await this.format(d);let g=await this.footer();if(m)l+=" "+m;if(f&&!m&&this.state.completed===0)l+=" "+f;this.clear(s);let y=[u,l,p,g,h.trim()];this.write(y.filter(Boolean).join(i));this.restore()}getItem(e){let{items:t,keys:r,index:s}=this.state;let i=t.find((e=>e.name===r[s]));if(i&&i.input!=null){this.input=i.input;this.cursor=i.cursor}return i}async submit(){if(typeof this.interpolate!=="function")await this.initialize();await this.interpolate(this.state,true);let{invalid:e,missing:t,output:r,values:i}=this.state;if(e.size){let t="";for(let[r,s]of e)t+=`Invalid ${r}: ${s}\n`;this.state.error=t;return super.submit()}if(t.size){this.state.error="Required: "+[...t.keys()].join(", ");return super.submit()}let n=s.unstyle(r).split("\n");let o=n.map((e=>e.slice(1))).join("\n");this.value={values:i,result:o};return super.submit()}}e.exports=SnippetPrompt},5873:(e,t,r)=>{"use strict";const s="(Use <shift>+<up/down> to sort)";const i=r(4449);class Sort extends i{constructor(e){super({...e,reorder:false,sort:true,multiple:true});this.state.hint=[this.options.hint,s].find(this.isValue.bind(this))}indicator(){return""}async renderChoice(e,t){let r=await super.renderChoice(e,t);let s=this.symbols.identicalTo+" ";let i=this.index===t&&this.sorting?this.styles.muted(s):" ";if(this.options.drag===false)i="";if(this.options.numbered===true){return i+`${t+1} - `+r}return i+r}get selected(){return this.choices}submit(){this.value=this.choices.map((e=>e.value));return super.submit()}}e.exports=Sort},5610:(e,t,r)=>{"use strict";const s=r(7633);class Survey extends s{constructor(e={}){super(e);this.emptyError=e.emptyError||"No items were selected";this.term=process.env.TERM_PROGRAM;if(!this.options.header){let e=["","4 - Strongly Agree","3 - Agree","2 - Neutral","1 - Disagree","0 - Strongly Disagree",""];e=e.map((e=>this.styles.muted(e)));this.state.header=e.join("\n ")}}async toChoices(...e){if(this.createdScales)return false;this.createdScales=true;let t=await super.toChoices(...e);for(let e of t){e.scale=createScale(5,this.options);e.scaleIdx=2}return t}dispatch(){this.alert()}space(){let e=this.focused;let t=e.scale[e.scaleIdx];let r=t.selected;e.scale.forEach((e=>e.selected=false));t.selected=!r;return this.render()}indicator(){return""}pointer(){return""}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;if(e.scaleIdx>=e.scale.length-1)return this.alert();e.scaleIdx++;return this.render()}left(){let e=this.focused;if(e.scaleIdx<=0)return this.alert();e.scaleIdx--;return this.render()}indent(){return" "}async renderChoice(e,t){await this.onChoice(e,t);let r=this.index===t;let s=this.term==="Hyper";let i=!s?8:9;let n=!s?" ":"";let o=this.symbols.line.repeat(i);let a=" ".repeat(i+(s?0:1));let dot=e=>(e?this.styles.success("◉"):"◯")+n;let l=t+1+".";let u=r?this.styles.heading:this.styles.noop;let h=await this.resolve(e.message,this.state,e,t);let f=this.indent(e);let p=f+e.scale.map(((t,r)=>dot(r===e.scaleIdx))).join(o);let val=t=>t===e.scaleIdx?u(t):t;let d=f+e.scale.map(((e,t)=>val(t))).join(a);let line=()=>[l,h].filter(Boolean).join(" ");let lines=()=>[line(),p,d," "].filter(Boolean).join("\n");if(r){p=this.styles.cyan(p);d=this.styles.cyan(d)}return lines()}async renderChoices(){if(this.state.submitted)return"";let e=this.visible.map((async(e,t)=>await this.renderChoice(e,t)));let t=await Promise.all(e);if(!t.length)t.push(this.styles.danger("No matching choices"));return t.join("\n")}format(){if(this.state.submitted){let e=this.choices.map((e=>this.styles.info(e.scaleIdx)));return e.join(", ")}return""}async render(){let{submitted:e,size:t}=this.state;let r=await this.prefix();let s=await this.separator();let i=await this.message();let n=[r,i,s].filter(Boolean).join(" ");this.state.prompt=n;let o=await this.header();let a=await this.format();let l=await this.error()||await this.hint();let u=await this.renderChoices();let h=await this.footer();if(a||!l)n+=" "+a;if(l&&!n.includes(l))n+=" "+l;if(e&&!a&&!u&&this.multiple&&this.type!=="form"){n+=this.styles.danger(this.emptyError)}this.clear(t);this.write([n,o,u,h].filter(Boolean).join("\n"));this.restore()}submit(){this.value={};for(let e of this.choices){this.value[e.name]=e.scaleIdx}return this.base.submit.call(this)}}function createScale(e,t={}){if(Array.isArray(t.scale)){return t.scale.map((e=>({...e})))}let r=[];for(let t=1;t<e+1;t++)r.push({i:t,selected:false});return r}e.exports=Survey},8355:(e,t,r)=>{e.exports=r(338)},1394:(e,t,r)=>{"use strict";const s=r(3055);class TogglePrompt extends s{async initialize(){await super.initialize();this.value=this.initial=!!this.options.initial;this.disabled=this.options.disabled||"no";this.enabled=this.options.enabled||"yes";await this.render()}reset(){this.value=this.initial;this.render()}delete(){this.alert()}toggle(){this.value=!this.value;this.render()}enable(){if(this.value===true)return this.alert();this.value=true;this.render()}disable(){if(this.value===false)return this.alert();this.value=false;this.render()}up(){this.toggle()}down(){this.toggle()}right(){this.toggle()}left(){this.toggle()}next(){this.toggle()}prev(){this.toggle()}dispatch(e="",t){switch(e.toLowerCase()){case" ":return this.toggle();case"1":case"y":case"t":return this.enable();case"0":case"n":case"f":return this.disable();default:{return this.alert()}}}format(){let active=e=>this.styles.primary.underline(e);let e=[this.value?this.disabled:active(this.disabled),this.value?active(this.enabled):this.enabled];return e.join(this.styles.muted(" / "))}async render(){let{size:e}=this.state;let t=await this.header();let r=await this.prefix();let s=await this.separator();let i=await this.message();let n=await this.format();let o=await this.error()||await this.hint();let a=await this.footer();let l=[r,i,s,n].join(" ");this.state.prompt=l;if(o&&!l.includes(o))l+=" "+o;this.clear(e);this.write([t,l,a].filter(Boolean).join("\n"));this.write(this.margin[2]);this.restore()}}e.exports=TogglePrompt},1487:(e,t,r)=>{"use strict";const s=r(8527);const i={default(e,t){return t},checkbox(e,t){throw new Error("checkbox role is not implemented yet")},editable(e,t){throw new Error("editable role is not implemented yet")},expandable(e,t){throw new Error("expandable role is not implemented yet")},heading(e,t){t.disabled="";t.indicator=[t.indicator," "].find((e=>e!=null));t.message=t.message||"";return t},input(e,t){throw new Error("input role is not implemented yet")},option(e,t){return i.default(e,t)},radio(e,t){throw new Error("radio role is not implemented yet")},separator(e,t){t.disabled="";t.indicator=[t.indicator," "].find((e=>e!=null));t.message=t.message||e.symbols.line.repeat(5);return t},spacer(e,t){return t}};e.exports=(e,t={})=>{let r=s.merge({},i,t.roles);return r[e]||r.default}},1686:(e,t,r)=>{"use strict";const{define:s,width:i}=r(8527);class State{constructor(e){let t=e.options;s(this,"_prompt",e);this.type=e.type;this.name=e.name;this.message="";this.header="";this.footer="";this.error="";this.hint="";this.input="";this.cursor=0;this.index=0;this.lines=0;this.tick=0;this.prompt="";this.buffer="";this.width=i(t.stdout||process.stdout);Object.assign(this,t);this.name=this.name||this.message;this.message=this.message||this.name;this.symbols=e.symbols;this.styles=e.styles;this.required=new Set;this.cancelled=false;this.submitted=false}clone(){let e={...this};e.status=this.status;e.buffer=Buffer.from(e.buffer);delete e.clone;return e}set color(e){this._color=e}get color(){let e=this.prompt.styles;if(this.cancelled)return e.cancelled;if(this.submitted)return e.submitted;let t=this._color||e[this.status];return typeof t==="function"?t:e.pending}set loading(e){this._loading=e}get loading(){if(typeof this._loading==="boolean")return this._loading;if(this.loadingChoices)return"choices";return false}get status(){if(this.cancelled)return"cancelled";if(this.submitted)return"submitted";return"pending"}}e.exports=State},3751:(e,t,r)=>{"use strict";const s=r(8527);const i=r(9151);const n={default:i.noop,noop:i.noop,set inverse(e){this._inverse=e},get inverse(){return this._inverse||s.inverse(this.primary)},set complement(e){this._complement=e},get complement(){return this._complement||s.complement(this.primary)},primary:i.cyan,success:i.green,danger:i.magenta,strong:i.bold,warning:i.yellow,muted:i.dim,disabled:i.gray,dark:i.dim.gray,underline:i.underline,set info(e){this._info=e},get info(){return this._info||this.primary},set em(e){this._em=e},get em(){return this._em||this.primary.underline},set heading(e){this._heading=e},get heading(){return this._heading||this.muted.underline},set pending(e){this._pending=e},get pending(){return this._pending||this.primary},set submitted(e){this._submitted=e},get submitted(){return this._submitted||this.success},set cancelled(e){this._cancelled=e},get cancelled(){return this._cancelled||this.danger},set typing(e){this._typing=e},get typing(){return this._typing||this.dim},set placeholder(e){this._placeholder=e},get placeholder(){return this._placeholder||this.primary.dim},set highlight(e){this._highlight=e},get highlight(){return this._highlight||this.inverse}};n.merge=(e={})=>{if(e.styles&&typeof e.styles.enabled==="boolean"){i.enabled=e.styles.enabled}if(e.styles&&typeof e.styles.visible==="boolean"){i.visible=e.styles.visible}let t=s.merge({},n,e.styles);delete t.merge;for(let e of Object.keys(i)){if(!t.hasOwnProperty(e)){Reflect.defineProperty(t,e,{get:()=>i[e]})}}for(let e of Object.keys(i.styles)){if(!t.hasOwnProperty(e)){Reflect.defineProperty(t,e,{get:()=>i[e]})}}return t};e.exports=n},5586:(e,t,r)=>{"use strict";const s=process.platform==="win32";const i=r(9151);const n=r(8527);const o={...i.symbols,upDownDoubleArrow:"⇕",upDownDoubleArrow2:"⬍",upDownArrow:"↕",asterisk:"*",asterism:"⁂",bulletWhite:"◦",electricArrow:"⌁",ellipsisLarge:"⋯",ellipsisSmall:"…",fullBlock:"█",identicalTo:"≡",indicator:i.symbols.check,leftAngle:"‹",mark:"※",minus:"−",multiplication:"×",obelus:"÷",percent:"%",pilcrow:"¶",pilcrow2:"❡",pencilUpRight:"✐",pencilDownRight:"✎",pencilRight:"✏",plus:"+",plusMinus:"±",pointRight:"☞",rightAngle:"›",section:"§",hexagon:{off:"⬡",on:"⬢",disabled:"⬢"},ballot:{on:"☑",off:"☐",disabled:"☒"},stars:{on:"★",off:"☆",disabled:"☆"},folder:{on:"▼",off:"▶",disabled:"▶"},prefix:{pending:i.symbols.question,submitted:i.symbols.check,cancelled:i.symbols.cross},separator:{pending:i.symbols.pointerSmall,submitted:i.symbols.middot,cancelled:i.symbols.middot},radio:{off:s?"( )":"◯",on:s?"(*)":"◉",disabled:s?"(|)":"Ⓘ"},numbers:["⓪","①","②","③","④","⑤","⑥","⑦","⑧","⑨","⑩","⑪","⑫","⑬","⑭","⑮","⑯","⑰","⑱","⑲","⑳","㉑","㉒","㉓","㉔","㉕","㉖","㉗","㉘","㉙","㉚","㉛","㉜","㉝","㉞","㉟","㊱","㊲","㊳","㊴","㊵","㊶","㊷","㊸","㊹","㊺","㊻","㊼","㊽","㊾","㊿"]};o.merge=e=>{let t=n.merge({},i.symbols,o,e.symbols);delete t.merge;return t};e.exports=o},6739:(e,t,r)=>{"use strict";const s=r(3751);const i=r(5586);const n=r(8527);e.exports=e=>{e.options=n.merge({},e.options.theme,e.options);e.symbols=i.merge(e.options);e.styles=s.merge(e.options)}},7711:e=>{"use strict";e.exports=e=>{e.timers=e.timers||{};let t=e.options.timers;if(!t)return;for(let r of Object.keys(t)){let s=t[r];if(typeof s==="number"){s={interval:s}}create(e,r,s)}};function create(e,t,r={}){let s=e.timers[t]={name:t,start:Date.now(),ms:0,tick:0};let i=r.interval||120;s.frames=r.frames||[];s.loading=true;let n=setInterval((()=>{s.ms=Date.now()-s.start;s.tick++;e.render()}),i);s.stop=()=>{s.loading=false;clearInterval(n)};Reflect.defineProperty(s,"interval",{value:n});e.once("close",(()=>s.stop()));return s.stop}},7633:(e,t,r)=>{"use strict";const s=r(9151);const i=r(7072);const n=r(1487);const o=r(8527);const{reorder:a,scrollUp:l,scrollDown:u,isObject:h,swap:f}=o;class ArrayPrompt extends i{constructor(e){super(e);this.cursorHide();this.maxSelected=e.maxSelected||Infinity;this.multiple=e.multiple||false;this.initial=e.initial||0;this.delay=e.delay||0;this.longest=0;this.num=""}async initialize(){if(typeof this.options.initial==="function"){this.initial=await this.options.initial.call(this)}await this.reset(true);await super.initialize()}async reset(){let{choices:e,initial:t,autofocus:r,suggest:s}=this.options;this.state._choices=[];this.state.choices=[];this.choices=await Promise.all(await this.toChoices(e));this.choices.forEach((e=>e.enabled=false));if(typeof s!=="function"&&this.selectable.length===0){throw new Error("At least one choice must be selectable")}if(h(t))t=Object.keys(t);if(Array.isArray(t)){if(r!=null)this.index=this.findIndex(r);t.forEach((e=>this.enable(this.find(e))));await this.render()}else{if(r!=null)t=r;if(typeof t==="string")t=this.findIndex(t);if(typeof t==="number"&&t>-1){this.index=Math.max(0,Math.min(t,this.choices.length));this.enable(this.find(this.index))}}if(this.isDisabled(this.focused)){await this.down()}}async toChoices(e,t){this.state.loadingChoices=true;let r=[];let s=0;let toChoices=async(e,t)=>{if(typeof e==="function")e=await e.call(this);if(e instanceof Promise)e=await e;for(let i=0;i<e.length;i++){let n=e[i]=await this.toChoice(e[i],s++,t);r.push(n);if(n.choices){await toChoices(n.choices,n)}}return r};return toChoices(e,t).then((e=>{this.state.loadingChoices=false;return e}))}async toChoice(e,t,r){if(typeof e==="function")e=await e.call(this,this);if(e instanceof Promise)e=await e;if(typeof e==="string")e={name:e};if(e.normalized)return e;e.normalized=true;let i=e.value;let a=n(e.role,this.options);e=a(this,e);if(typeof e.disabled==="string"&&!e.hint){e.hint=e.disabled;e.disabled=true}if(e.disabled===true&&e.hint==null){e.hint="(disabled)"}if(e.index!=null)return e;e.name=e.name||e.key||e.title||e.value||e.message;e.message=e.message||e.name||"";e.value=[e.value,e.name].find(this.isValue.bind(this));e.input="";e.index=t;e.cursor=0;o.define(e,"parent",r);e.level=r?r.level+1:1;if(e.indent==null){e.indent=r?r.indent+" ":e.indent||""}e.path=r?r.path+"."+e.name:e.name;e.enabled=!!(this.multiple&&!this.isDisabled(e)&&(e.enabled||this.isSelected(e)));if(!this.isDisabled(e)){this.longest=Math.max(this.longest,s.unstyle(e.message).length)}let l={...e};e.reset=(t=l.input,r=l.value)=>{for(let t of Object.keys(l))e[t]=l[t];e.input=t;e.value=r};if(i==null&&typeof e.initial==="function"){e.input=await e.initial.call(this,this.state,e,t)}return e}async onChoice(e,t){this.emit("choice",e,t,this);if(typeof e.onChoice==="function"){await e.onChoice.call(this,this.state,e,t)}}async addChoice(e,t,r){let s=await this.toChoice(e,t,r);this.choices.push(s);this.index=this.choices.length-1;this.limit=this.choices.length;return s}async newItem(e,t,r){let s={name:"New choice name?",editable:true,newChoice:true,...e};let i=await this.addChoice(s,t,r);i.updateChoice=()=>{delete i.newChoice;i.name=i.message=i.input;i.input="";i.cursor=0};return this.render()}indent(e){if(e.indent==null){return e.level>1?" ".repeat(e.level-1):""}return e.indent}dispatch(e,t){if(this.multiple&&this[t.name])return this[t.name]();this.alert()}focus(e,t){if(typeof t!=="boolean")t=e.enabled;if(t&&!e.enabled&&this.selected.length>=this.maxSelected){return this.alert()}this.index=e.index;e.enabled=t&&!this.isDisabled(e);return e}space(){if(!this.multiple)return this.alert();this.toggle(this.focused);return this.render()}a(){if(this.maxSelected<this.choices.length)return this.alert();let e=this.selectable.every((e=>e.enabled));this.choices.forEach((t=>t.enabled=!e));return this.render()}i(){if(this.choices.length-this.selected.length>this.maxSelected){return this.alert()}this.choices.forEach((e=>e.enabled=!e.enabled));return this.render()}g(e=this.focused){if(!this.choices.some((e=>!!e.parent)))return this.a();this.toggle(e.parent&&!e.choices?e.parent:e);return this.render()}toggle(e,t){if(!e.enabled&&this.selected.length>=this.maxSelected){return this.alert()}if(typeof t!=="boolean")t=!e.enabled;e.enabled=t;if(e.choices){e.choices.forEach((e=>this.toggle(e,t)))}let r=e.parent;while(r){let e=r.choices.filter((e=>this.isDisabled(e)));r.enabled=e.every((e=>e.enabled===true));r=r.parent}reset(this,this.choices);this.emit("toggle",e,this);return e}enable(e){if(this.selected.length>=this.maxSelected)return this.alert();e.enabled=!this.isDisabled(e);e.choices&&e.choices.forEach(this.enable.bind(this));return e}disable(e){e.enabled=false;e.choices&&e.choices.forEach(this.disable.bind(this));return e}number(e){this.num+=e;let number=e=>{let t=Number(e);if(t>this.choices.length-1)return this.alert();let r=this.focused;let s=this.choices.find((e=>t===e.index));if(!s.enabled&&this.selected.length>=this.maxSelected){return this.alert()}if(this.visible.indexOf(s)===-1){let e=a(this.choices);let t=e.indexOf(s);if(r.index>t){let r=e.slice(t,t+this.limit);let s=e.filter((e=>!r.includes(e)));this.choices=r.concat(s)}else{let r=t-this.limit+1;this.choices=e.slice(r).concat(e.slice(0,r))}}this.index=this.choices.indexOf(s);this.toggle(this.focused);return this.render()};clearTimeout(this.numberTimeout);return new Promise((e=>{let t=this.choices.length;let r=this.num;let handle=(t=false,s)=>{clearTimeout(this.numberTimeout);if(t)s=number(r);this.num="";e(s)};if(r==="0"||r.length===1&&Number(r+"0")>t){return handle(true)}if(Number(r)>t){return handle(false,this.alert())}this.numberTimeout=setTimeout((()=>handle(true)),this.delay)}))}home(){this.choices=a(this.choices);this.index=0;return this.render()}end(){let e=this.choices.length-this.limit;let t=a(this.choices);this.choices=t.slice(e).concat(t.slice(0,e));this.index=this.limit-1;return this.render()}first(){this.index=0;return this.render()}last(){this.index=this.visible.length-1;return this.render()}prev(){if(this.visible.length<=1)return this.alert();return this.up()}next(){if(this.visible.length<=1)return this.alert();return this.down()}right(){if(this.cursor>=this.input.length)return this.alert();this.cursor++;return this.render()}left(){if(this.cursor<=0)return this.alert();this.cursor--;return this.render()}up(){let e=this.choices.length;let t=this.visible.length;let r=this.index;if(this.options.scroll===false&&r===0){return this.alert()}if(e>t&&r===0){return this.scrollUp()}this.index=(r-1%e+e)%e;if(this.isDisabled()){return this.up()}return this.render()}down(){let e=this.choices.length;let t=this.visible.length;let r=this.index;if(this.options.scroll===false&&r===t-1){return this.alert()}if(e>t&&r===t-1){return this.scrollDown()}this.index=(r+1)%e;if(this.isDisabled()){return this.down()}return this.render()}scrollUp(e=0){this.choices=l(this.choices);this.index=e;if(this.isDisabled()){return this.up()}return this.render()}scrollDown(e=this.visible.length-1){this.choices=u(this.choices);this.index=e;if(this.isDisabled()){return this.down()}return this.render()}async shiftUp(){if(this.options.sort===true){this.sorting=true;this.swap(this.index-1);await this.up();this.sorting=false;return}return this.scrollUp(this.index)}async shiftDown(){if(this.options.sort===true){this.sorting=true;this.swap(this.index+1);await this.down();this.sorting=false;return}return this.scrollDown(this.index)}pageUp(){if(this.visible.length<=1)return this.alert();this.limit=Math.max(this.limit-1,0);this.index=Math.min(this.limit-1,this.index);this._limit=this.limit;if(this.isDisabled()){return this.up()}return this.render()}pageDown(){if(this.visible.length>=this.choices.length)return this.alert();this.index=Math.max(0,this.index);this.limit=Math.min(this.limit+1,this.choices.length);this._limit=this.limit;if(this.isDisabled()){return this.down()}return this.render()}swap(e){f(this.choices,this.index,e)}isDisabled(e=this.focused){let t=["disabled","collapsed","hidden","completing","readonly"];if(e&&t.some((t=>e[t]===true))){return true}return e&&e.role==="heading"}isEnabled(e=this.focused){if(Array.isArray(e))return e.every((e=>this.isEnabled(e)));if(e.choices){let t=e.choices.filter((e=>!this.isDisabled(e)));return e.enabled&&t.every((e=>this.isEnabled(e)))}return e.enabled&&!this.isDisabled(e)}isChoice(e,t){return e.name===t||e.index===Number(t)}isSelected(e){if(Array.isArray(this.initial)){return this.initial.some((t=>this.isChoice(e,t)))}return this.isChoice(e,this.initial)}map(e=[],t="value"){return[].concat(e||[]).reduce(((e,r)=>{e[r]=this.find(r,t);return e}),{})}filter(e,t){let isChoice=(t,r)=>[t.name,r].includes(e);let r=typeof e==="function"?e:isChoice;let s=this.options.multiple?this.state._choices:this.choices;let i=s.filter(r);if(t){return i.map((e=>e[t]))}return i}find(e,t){if(h(e))return t?e[t]:e;let isChoice=(t,r)=>[t.name,r].includes(e);let r=typeof e==="function"?e:isChoice;let s=this.choices.find(r);if(s){return t?s[t]:s}}findIndex(e){return this.choices.indexOf(this.find(e))}async submit(){let e=this.focused;if(!e)return this.alert();if(e.newChoice){if(!e.input)return this.alert();e.updateChoice();return this.render()}if(this.choices.some((e=>e.newChoice))){return this.alert()}let{reorder:t,sort:r}=this.options;let s=this.multiple===true;let i=this.selected;if(i===void 0){return this.alert()}if(Array.isArray(i)&&t!==false&&r!==true){i=o.reorder(i)}this.value=s?i.map((e=>e.name)):i.name;return super.submit()}set choices(e=[]){this.state._choices=this.state._choices||[];this.state.choices=e;for(let t of e){if(!this.state._choices.some((e=>e.name===t.name))){this.state._choices.push(t)}}if(!this._initial&&this.options.initial){this._initial=true;let e=this.initial;if(typeof e==="string"||typeof e==="number"){let t=this.find(e);if(t){this.initial=t.index;this.focus(t,true)}}}}get choices(){return reset(this,this.state.choices||[])}set visible(e){this.state.visible=e}get visible(){return(this.state.visible||this.choices).slice(0,this.limit)}set limit(e){this.state.limit=e}get limit(){let{state:e,options:t,choices:r}=this;let s=e.limit||this._limit||t.limit||r.length;return Math.min(s,this.height)}set value(e){super.value=e}get value(){if(typeof super.value!=="string"&&super.value===this.initial){return this.input}return super.value}set index(e){this.state.index=e}get index(){return Math.max(0,this.state?this.state.index:0)}get enabled(){return this.filter(this.isEnabled.bind(this))}get focused(){let e=this.choices[this.index];if(e&&this.state.submitted&&this.multiple!==true){e.enabled=true}return e}get selectable(){return this.choices.filter((e=>!this.isDisabled(e)))}get selected(){return this.multiple?this.enabled:this.focused}}function reset(e,t){if(t instanceof Promise)return t;if(typeof t==="function"){if(o.isAsyncFn(t))return t;t=t.call(e,e)}for(let r of t){if(Array.isArray(r.choices)){let t=r.choices.filter((t=>!e.isDisabled(t)));r.enabled=t.every((e=>e.enabled===true))}if(e.isDisabled(r)===true){delete r.enabled}}return t}e.exports=ArrayPrompt},3315:(e,t,r)=>{"use strict";const s=r(1787);const defaultAuthenticate=()=>{throw new Error("expected prompt to have a custom authenticate method")};const factory=(e=defaultAuthenticate)=>{class AuthPrompt extends s{constructor(e){super(e)}async submit(){this.value=await e.call(this,this.values,this.state);super.base.submit.call(this)}static create(e){return factory(e)}}return AuthPrompt};e.exports=factory()},3055:(e,t,r)=>{"use strict";const s=r(7072);const{isPrimitive:i,hasColor:n}=r(8527);class BooleanPrompt extends s{constructor(e){super(e);this.cursorHide()}async initialize(){let e=await this.resolve(this.initial,this.state);this.input=await this.cast(e);await super.initialize()}dispatch(e){if(!this.isValue(e))return this.alert();this.input=e;return this.submit()}format(e){let{styles:t,state:r}=this;return!r.submitted?t.primary(e):t.success(e)}cast(e){return this.isTrue(e)}isTrue(e){return/^[ty1]/i.test(e)}isFalse(e){return/^[fn0]/i.test(e)}isValue(e){return i(e)&&(this.isTrue(e)||this.isFalse(e))}async hint(){if(this.state.status==="pending"){let e=await this.element("hint");if(!n(e)){return this.styles.muted(e)}return e}}async render(){let{input:e,size:t}=this.state;let r=await this.prefix();let s=await this.separator();let i=await this.message();let n=this.styles.muted(this.default);let o=[r,i,n,s].filter(Boolean).join(" ");this.state.prompt=o;let a=await this.header();let l=this.value=this.cast(e);let u=await this.format(l);let h=await this.error()||await this.hint();let f=await this.footer();if(h&&!o.includes(h))u+=" "+h;o+=" "+u;this.clear(t);this.write([a,o,f].filter(Boolean).join("\n"));this.restore()}set value(e){super.value=e}get value(){return this.cast(super.value)}}e.exports=BooleanPrompt},891:(e,t,r)=>{e.exports={ArrayPrompt:r(7633),AuthPrompt:r(3315),BooleanPrompt:r(3055),NumberPrompt:r(7572),StringPrompt:r(1401)}},7572:(e,t,r)=>{"use strict";const s=r(1401);class NumberPrompt extends s{constructor(e={}){super({style:"number",...e});this.min=this.isValue(e.min)?this.toNumber(e.min):-Infinity;this.max=this.isValue(e.max)?this.toNumber(e.max):Infinity;this.delay=e.delay!=null?e.delay:1e3;this.float=e.float!==false;this.round=e.round===true||e.float===false;this.major=e.major||10;this.minor=e.minor||1;this.initial=e.initial!=null?e.initial:"";this.input=String(this.initial);this.cursor=this.input.length;this.cursorShow()}append(e){if(!/[-+.]/.test(e)||e==="."&&this.input.includes(".")){return this.alert("invalid number")}return super.append(e)}number(e){return super.append(e)}next(){if(this.input&&this.input!==this.initial)return this.alert();if(!this.isValue(this.initial))return this.alert();this.input=this.initial;this.cursor=String(this.initial).length;return this.render()}up(e){let t=e||this.minor;let r=this.toNumber(this.input);if(r>this.max+t)return this.alert();this.input=`${r+t}`;return this.render()}down(e){let t=e||this.minor;let r=this.toNumber(this.input);if(r<this.min-t)return this.alert();this.input=`${r-t}`;return this.render()}shiftDown(){return this.down(this.major)}shiftUp(){return this.up(this.major)}format(e=this.input){if(typeof this.options.format==="function"){return this.options.format.call(this,e)}return this.styles.info(e)}toNumber(e=""){return this.float?+e:Math.round(+e)}isValue(e){return/^[-+]?[0-9]+((\.)|(\.[0-9]+))?$/.test(e)}submit(){let e=[this.input,this.initial].find((e=>this.isValue(e)));this.value=this.toNumber(e||0);return super.submit()}}e.exports=NumberPrompt},1401:(e,t,r)=>{"use strict";const s=r(7072);const i=r(9690);const{isPrimitive:n}=r(8527);class StringPrompt extends s{constructor(e){super(e);this.initial=n(this.initial)?String(this.initial):"";if(this.initial)this.cursorHide();this.state.prevCursor=0;this.state.clipboard=[]}async keypress(e,t={}){let r=this.state.prevKeypress;this.state.prevKeypress=t;if(this.options.multiline===true&&t.name==="return"){if(!r||r.name!=="return"){return this.append("\n",t)}}return super.keypress(e,t)}moveCursor(e){this.cursor+=e}reset(){this.input=this.value="";this.cursor=0;return this.render()}dispatch(e,t){if(!e||t.ctrl||t.code)return this.alert();this.append(e)}append(e){let{cursor:t,input:r}=this.state;this.input=`${r}`.slice(0,t)+e+`${r}`.slice(t);this.moveCursor(String(e).length);this.render()}insert(e){this.append(e)}delete(){let{cursor:e,input:t}=this.state;if(e<=0)return this.alert();this.input=`${t}`.slice(0,e-1)+`${t}`.slice(e);this.moveCursor(-1);this.render()}deleteForward(){let{cursor:e,input:t}=this.state;if(t[e]===void 0)return this.alert();this.input=`${t}`.slice(0,e)+`${t}`.slice(e+1);this.render()}cutForward(){let e=this.cursor;if(this.input.length<=e)return this.alert();this.state.clipboard.push(this.input.slice(e));this.input=this.input.slice(0,e);this.render()}cutLeft(){let e=this.cursor;if(e===0)return this.alert();let t=this.input.slice(0,e);let r=this.input.slice(e);let s=t.split(" ");this.state.clipboard.push(s.pop());this.input=s.join(" ");this.cursor=this.input.length;this.input+=r;this.render()}paste(){if(!this.state.clipboard.length)return this.alert();this.insert(this.state.clipboard.pop());this.render()}toggleCursor(){if(this.state.prevCursor){this.cursor=this.state.prevCursor;this.state.prevCursor=0}else{this.state.prevCursor=this.cursor;this.cursor=0}this.render()}first(){this.cursor=0;this.render()}last(){this.cursor=this.input.length-1;this.render()}next(){let e=this.initial!=null?String(this.initial):"";if(!e||!e.startsWith(this.input))return this.alert();this.input=this.initial;this.cursor=this.initial.length;this.render()}prev(){if(!this.input)return this.alert();this.reset()}backward(){return this.left()}forward(){return this.right()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1);return this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1);return this.render()}isValue(e){return!!e}async format(e=this.value){let t=await this.resolve(this.initial,this.state);if(!this.state.submitted){return i(this,{input:e,initial:t,pos:this.cursor})}return this.styles.submitted(e||t)}async render(){let e=this.state.size;let t=await this.prefix();let r=await this.separator();let s=await this.message();let i=[t,s,r].filter(Boolean).join(" ");this.state.prompt=i;let n=await this.header();let o=await this.format();let a=await this.error()||await this.hint();let l=await this.footer();if(a&&!o.includes(a))o+=" "+a;i+=" "+o;this.clear(e);this.write([n,i,l].filter(Boolean).join("\n"));this.restore()}}e.exports=StringPrompt},8527:(e,t,r)=>{"use strict";const s=Object.prototype.toString;const i=r(9151);let n=false;let o=[];const a={yellow:"blue",cyan:"red",green:"magenta",black:"white",blue:"yellow",red:"cyan",magenta:"green",white:"black"};t.longest=(e,t)=>e.reduce(((e,r)=>Math.max(e,t?r[t].length:r.length)),0);t.hasColor=e=>!!e&&i.hasColor(e);const l=t.isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);t.nativeType=e=>s.call(e).slice(8,-1).toLowerCase().replace(/\s/g,"");t.isAsyncFn=e=>t.nativeType(e)==="asyncfunction";t.isPrimitive=e=>e!=null&&typeof e!=="object"&&typeof e!=="function";t.resolve=(e,t,...r)=>{if(typeof t==="function"){return t.call(e,...r)}return t};t.scrollDown=(e=[])=>[...e.slice(1),e[0]];t.scrollUp=(e=[])=>[e.pop(),...e];t.reorder=(e=[])=>{let t=e.slice();t.sort(((e,t)=>{if(e.index>t.index)return 1;if(e.index<t.index)return-1;return 0}));return t};t.swap=(e,t,r)=>{let s=e.length;let i=r===s?0:r<0?s-1:r;let n=e[t];e[t]=e[i];e[i]=n};t.width=(e,t=80)=>{let r=e&&e.columns?e.columns:t;if(e&&typeof e.getWindowSize==="function"){r=e.getWindowSize()[0]}if(process.platform==="win32"){return r-1}return r};t.height=(e,t=20)=>{let r=e&&e.rows?e.rows:t;if(e&&typeof e.getWindowSize==="function"){r=e.getWindowSize()[1]}return r};t.wordWrap=(e,t={})=>{if(!e)return e;if(typeof t==="number"){t={width:t}}let{indent:r="",newline:s="\n"+r,width:i=80}=t;let n=(s+r).match(/[^\S\n]/g)||[];i-=n.length;let o=`.{1,${i}}([\\s\\u200B]+|$)|[^\\s\\u200B]+?([\\s\\u200B]+|$)`;let a=e.trim();let l=new RegExp(o,"g");let u=a.match(l)||[];u=u.map((e=>e.replace(/\n$/,"")));if(t.padEnd)u=u.map((e=>e.padEnd(i," ")));if(t.padStart)u=u.map((e=>e.padStart(i," ")));return r+u.join(s)};t.unmute=e=>{let t=e.stack.find((e=>i.keys.color.includes(e)));if(t){return i[t]}let r=e.stack.find((e=>e.slice(2)==="bg"));if(r){return i[t.slice(2)]}return e=>e};t.pascal=e=>e?e[0].toUpperCase()+e.slice(1):"";t.inverse=e=>{if(!e||!e.stack)return e;let r=e.stack.find((e=>i.keys.color.includes(e)));if(r){let s=i["bg"+t.pascal(r)];return s?s.black:e}let s=e.stack.find((e=>e.slice(0,2)==="bg"));if(s){return i[s.slice(2).toLowerCase()]||e}return i.none};t.complement=e=>{if(!e||!e.stack)return e;let r=e.stack.find((e=>i.keys.color.includes(e)));let s=e.stack.find((e=>e.slice(0,2)==="bg"));if(r&&!s){return i[a[r]||r]}if(s){let r=s.slice(2).toLowerCase();let n=a[r];if(!n)return e;return i["bg"+t.pascal(n)]||e}return i.none};t.meridiem=e=>{let t=e.getHours();let r=e.getMinutes();let s=t>=12?"pm":"am";t=t%12;let i=t===0?12:t;let n=r<10?"0"+r:r;return i+":"+n+" "+s};t.set=(e={},r="",s)=>r.split(".").reduce(((e,r,i,n)=>{let o=n.length-1>i?e[r]||{}:s;if(!t.isObject(o)&&i<n.length-1)o={};return e[r]=o}),e);t.get=(e={},t="",r)=>{let s=e[t]==null?t.split(".").reduce(((e,t)=>e&&e[t]),e):e[t];return s==null?r:s};t.mixin=(e,r)=>{if(!l(e))return r;if(!l(r))return e;for(let s of Object.keys(r)){let i=Object.getOwnPropertyDescriptor(r,s);if(i.hasOwnProperty("value")){if(e.hasOwnProperty(s)&&l(i.value)){let n=Object.getOwnPropertyDescriptor(e,s);if(l(n.value)){e[s]=t.merge({},e[s],r[s])}else{Reflect.defineProperty(e,s,i)}}else{Reflect.defineProperty(e,s,i)}}else{Reflect.defineProperty(e,s,i)}}return e};t.merge=(...e)=>{let r={};for(let s of e)t.mixin(r,s);return r};t.mixinEmitter=(e,r)=>{let s=r.constructor.prototype;for(let i of Object.keys(s)){let n=s[i];if(typeof n==="function"){t.define(e,i,n.bind(r))}else{t.define(e,i,n)}}};t.onExit=e=>{const onExit=(e,t)=>{if(n)return;n=true;o.forEach((e=>e()));if(e===true){process.exit(128+t)}};if(o.length===0){process.once("SIGTERM",onExit.bind(null,true,15));process.once("SIGINT",onExit.bind(null,true,2));process.once("exit",onExit)}o.push(e)};t.define=(e,t,r)=>{Reflect.defineProperty(e,t,{value:r})};t.defineExport=(e,t,r)=>{let s;Reflect.defineProperty(e,t,{enumerable:true,configurable:true,set(e){s=e},get(){return s?s():r()}})}},5447:(e,t,r)=>{"use strict";const s=r(1017);const i=r(2081);const n=r(2746);const o=r(8174);const a=r(502);const l=r(9082);const u=r(2187);const h=r(166);const{spawnedKill:f,spawnedCancel:p,setupTimeout:d,validateTimeout:m,setExitHandler:g}=r(9819);const{handleInput:y,getSpawnedResult:b,makeAllStream:_,validateInputSync:v}=r(2592);const{mergePromise:w,getSpawnedPromise:E}=r(7814);const{joinCommand:S,parseCommand:x,getEscapedCommand:R}=r(8286);const A=1e3*1e3*100;const getEnv=({env:e,extendEnv:t,preferLocal:r,localDir:s,execPath:i})=>{const n=t?{...process.env,...e}:e;if(r){return a.env({env:n,cwd:s,execPath:i})}return n};const handleArguments=(e,t,r={})=>{const i=n._parse(e,t,r);e=i.command;t=i.args;r=i.options;r={maxBuffer:A,buffer:true,stripFinalNewline:true,extendEnv:true,preferLocal:false,localDir:r.cwd||process.cwd(),execPath:process.execPath,encoding:"utf8",reject:true,cleanup:true,all:false,windowsHide:true,...r};r.env=getEnv(r);r.stdio=h(r);if(process.platform==="win32"&&s.basename(e,".exe")==="cmd"){t.unshift("/q")}return{file:e,args:t,options:r,parsed:i}};const handleOutput=(e,t,r)=>{if(typeof t!=="string"&&!Buffer.isBuffer(t)){return r===undefined?undefined:""}if(e.stripFinalNewline){return o(t)}return t};const execa=(e,t,r)=>{const s=handleArguments(e,t,r);const n=S(e,t);const o=R(e,t);m(s.options);let a;try{a=i.spawn(s.file,s.args,s.options)}catch(e){const t=new i.ChildProcess;const r=Promise.reject(u({error:e,stdout:"",stderr:"",all:"",command:n,escapedCommand:o,parsed:s,timedOut:false,isCanceled:false,killed:false}));return w(t,r)}const h=E(a);const v=d(a,s.options,h);const x=g(a,s.options,v);const A={isCanceled:false};a.kill=f.bind(null,a.kill.bind(a));a.cancel=p.bind(null,a,A);const handlePromise=async()=>{const[{error:e,exitCode:t,signal:r,timedOut:i},l,h,f]=await b(a,s.options,x);const p=handleOutput(s.options,l);const d=handleOutput(s.options,h);const m=handleOutput(s.options,f);if(e||t!==0||r!==null){const l=u({error:e,exitCode:t,signal:r,stdout:p,stderr:d,all:m,command:n,escapedCommand:o,parsed:s,timedOut:i,isCanceled:A.isCanceled,killed:a.killed});if(!s.options.reject){return l}throw l}return{command:n,escapedCommand:o,exitCode:0,stdout:p,stderr:d,all:m,failed:false,timedOut:false,isCanceled:false,killed:false}};const C=l(handlePromise);y(a,s.options.input);a.all=_(a,s.options);return w(a,C)};e.exports=execa;e.exports.sync=(e,t,r)=>{const s=handleArguments(e,t,r);const n=S(e,t);const o=R(e,t);v(s.options);let a;try{a=i.spawnSync(s.file,s.args,s.options)}catch(e){throw u({error:e,stdout:"",stderr:"",all:"",command:n,escapedCommand:o,parsed:s,timedOut:false,isCanceled:false,killed:false})}const l=handleOutput(s.options,a.stdout,a.error);const h=handleOutput(s.options,a.stderr,a.error);if(a.error||a.status!==0||a.signal!==null){const e=u({stdout:l,stderr:h,error:a.error,signal:a.signal,exitCode:a.status,command:n,escapedCommand:o,parsed:s,timedOut:a.error&&a.error.code==="ETIMEDOUT",isCanceled:false,killed:a.signal!==null});if(!s.options.reject){return e}throw e}return{command:n,escapedCommand:o,exitCode:0,stdout:l,stderr:h,failed:false,timedOut:false,isCanceled:false,killed:false}};e.exports.command=(e,t)=>{const[r,...s]=x(e);return execa(r,s,t)};e.exports.commandSync=(e,t)=>{const[r,...s]=x(e);return execa.sync(r,s,t)};e.exports.node=(e,t,r={})=>{if(t&&!Array.isArray(t)&&typeof t==="object"){r=t;t=[]}const s=h.node(r);const i=process.execArgv.filter((e=>!e.startsWith("--inspect")));const{nodePath:n=process.execPath,nodeOptions:o=i}=r;return execa(n,[...o,e,...Array.isArray(t)?t:[]],{...r,stdin:undefined,stdout:undefined,stderr:undefined,stdio:s,shell:false})}},8286:e=>{"use strict";const normalizeArgs=(e,t=[])=>{if(!Array.isArray(t)){return[e]}return[e,...t]};const t=/^[\w.-]+$/;const r=/"/g;const escapeArg=e=>{if(typeof e!=="string"||t.test(e)){return e}return`"${e.replace(r,'\\"')}"`};const joinCommand=(e,t)=>normalizeArgs(e,t).join(" ");const getEscapedCommand=(e,t)=>normalizeArgs(e,t).map((e=>escapeArg(e))).join(" ");const s=/ +/g;const parseCommand=e=>{const t=[];for(const r of e.trim().split(s)){const e=t[t.length-1];if(e&&e.endsWith("\\")){t[t.length-1]=`${e.slice(0,-1)} ${r}`}else{t.push(r)}}return t};e.exports={joinCommand:joinCommand,getEscapedCommand:getEscapedCommand,parseCommand:parseCommand}},2187:(e,t,r)=>{"use strict";const{signalsByName:s}=r(2779);const getErrorPrefix=({timedOut:e,timeout:t,errorCode:r,signal:s,signalDescription:i,exitCode:n,isCanceled:o})=>{if(e){return`timed out after ${t} milliseconds`}if(o){return"was canceled"}if(r!==undefined){return`failed with ${r}`}if(s!==undefined){return`was killed with ${s} (${i})`}if(n!==undefined){return`failed with exit code ${n}`}return"failed"};const makeError=({stdout:e,stderr:t,all:r,error:i,signal:n,exitCode:o,command:a,escapedCommand:l,timedOut:u,isCanceled:h,killed:f,parsed:{options:{timeout:p}}})=>{o=o===null?undefined:o;n=n===null?undefined:n;const d=n===undefined?undefined:s[n].description;const m=i&&i.code;const g=getErrorPrefix({timedOut:u,timeout:p,errorCode:m,signal:n,signalDescription:d,exitCode:o,isCanceled:h});const y=`Command ${g}: ${a}`;const b=Object.prototype.toString.call(i)==="[object Error]";const _=b?`${y}\n${i.message}`:y;const v=[_,t,e].filter(Boolean).join("\n");if(b){i.originalMessage=i.message;i.message=v}else{i=new Error(v)}i.shortMessage=_;i.command=a;i.escapedCommand=l;i.exitCode=o;i.signal=n;i.signalDescription=d;i.stdout=e;i.stderr=t;if(r!==undefined){i.all=r}if("bufferedData"in i){delete i.bufferedData}i.failed=true;i.timedOut=Boolean(u);i.isCanceled=h;i.killed=f&&!u;return i};e.exports=makeError},9819:(e,t,r)=>{"use strict";const s=r(2037);const i=r(4931);const n=1e3*5;const spawnedKill=(e,t="SIGTERM",r={})=>{const s=e(t);setKillTimeout(e,t,r,s);return s};const setKillTimeout=(e,t,r,s)=>{if(!shouldForceKill(t,r,s)){return}const i=getForceKillAfterTimeout(r);const n=setTimeout((()=>{e("SIGKILL")}),i);if(n.unref){n.unref()}};const shouldForceKill=(e,{forceKillAfterTimeout:t},r)=>isSigterm(e)&&t!==false&&r;const isSigterm=e=>e===s.constants.signals.SIGTERM||typeof e==="string"&&e.toUpperCase()==="SIGTERM";const getForceKillAfterTimeout=({forceKillAfterTimeout:e=true})=>{if(e===true){return n}if(!Number.isFinite(e)||e<0){throw new TypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${e}\` (${typeof e})`)}return e};const spawnedCancel=(e,t)=>{const r=e.kill();if(r){t.isCanceled=true}};const timeoutKill=(e,t,r)=>{e.kill(t);r(Object.assign(new Error("Timed out"),{timedOut:true,signal:t}))};const setupTimeout=(e,{timeout:t,killSignal:r="SIGTERM"},s)=>{if(t===0||t===undefined){return s}let i;const n=new Promise(((s,n)=>{i=setTimeout((()=>{timeoutKill(e,r,n)}),t)}));const o=s.finally((()=>{clearTimeout(i)}));return Promise.race([n,o])};const validateTimeout=({timeout:e})=>{if(e!==undefined&&(!Number.isFinite(e)||e<0)){throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${e}\` (${typeof e})`)}};const setExitHandler=async(e,{cleanup:t,detached:r},s)=>{if(!t||r){return s}const n=i((()=>{e.kill()}));return s.finally((()=>{n()}))};e.exports={spawnedKill:spawnedKill,spawnedCancel:spawnedCancel,setupTimeout:setupTimeout,validateTimeout:validateTimeout,setExitHandler:setExitHandler}},7814:e=>{"use strict";const t=(async()=>{})().constructor.prototype;const r=["then","catch","finally"].map((e=>[e,Reflect.getOwnPropertyDescriptor(t,e)]));const mergePromise=(e,t)=>{for(const[s,i]of r){const r=typeof t==="function"?(...e)=>Reflect.apply(i.value,t(),e):i.value.bind(t);Reflect.defineProperty(e,s,{...i,value:r})}return e};const getSpawnedPromise=e=>new Promise(((t,r)=>{e.on("exit",((e,r)=>{t({exitCode:e,signal:r})}));e.on("error",(e=>{r(e)}));if(e.stdin){e.stdin.on("error",(e=>{r(e)}))}}));e.exports={mergePromise:mergePromise,getSpawnedPromise:getSpawnedPromise}},166:e=>{"use strict";const t=["stdin","stdout","stderr"];const hasAlias=e=>t.some((t=>e[t]!==undefined));const normalizeStdio=e=>{if(!e){return}const{stdio:r}=e;if(r===undefined){return t.map((t=>e[t]))}if(hasAlias(e)){throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${t.map((e=>`\`${e}\``)).join(", ")}`)}if(typeof r==="string"){return r}if(!Array.isArray(r)){throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof r}\``)}const s=Math.max(r.length,t.length);return Array.from({length:s},((e,t)=>r[t]))};e.exports=normalizeStdio;e.exports.node=e=>{const t=normalizeStdio(e);if(t==="ipc"){return"ipc"}if(t===undefined||typeof t==="string"){return[t,t,t,"ipc"]}if(t.includes("ipc")){return t}return[...t,"ipc"]}},2592:(e,t,r)=>{"use strict";const s=r(1554);const i=r(1766);const n=r(2621);const handleInput=(e,t)=>{if(t===undefined||e.stdin===undefined){return}if(s(t)){t.pipe(e.stdin)}else{e.stdin.end(t)}};const makeAllStream=(e,{all:t})=>{if(!t||!e.stdout&&!e.stderr){return}const r=n();if(e.stdout){r.add(e.stdout)}if(e.stderr){r.add(e.stderr)}return r};const getBufferedData=async(e,t)=>{if(!e){return}e.destroy();try{return await t}catch(e){return e.bufferedData}};const getStreamPromise=(e,{encoding:t,buffer:r,maxBuffer:s})=>{if(!e||!r){return}if(t){return i(e,{encoding:t,maxBuffer:s})}return i.buffer(e,{maxBuffer:s})};const getSpawnedResult=async({stdout:e,stderr:t,all:r},{encoding:s,buffer:i,maxBuffer:n},o)=>{const a=getStreamPromise(e,{encoding:s,buffer:i,maxBuffer:n});const l=getStreamPromise(t,{encoding:s,buffer:i,maxBuffer:n});const u=getStreamPromise(r,{encoding:s,buffer:i,maxBuffer:n*2});try{return await Promise.all([o,a,l,u])}catch(s){return Promise.all([{error:s,signal:s.signal,timedOut:s.timedOut},getBufferedData(e,a),getBufferedData(t,l),getBufferedData(r,u)])}};const validateInputSync=({input:e})=>{if(s(e)){throw new TypeError("The `input` option cannot be a stream in sync mode")}};e.exports={handleInput:handleInput,makeAllStream:makeAllStream,getSpawnedResult:getSpawnedResult,validateInputSync:validateInputSync}},4460:(e,t,r)=>{"use strict";var s=r(4466);var i=r(1017).posix.dirname;var n=r(2037).platform()==="win32";var o="/";var a=/\\/g;var l=/[\{\[].*[\}\]]$/;var u=/(^|[^\\])([\{\[]|\([^\)]+$)/;var h=/\\([\!\*\?\|\[\]\(\)\{\}])/g;e.exports=function globParent(e,t){var r=Object.assign({flipBackslashes:true},t);if(r.flipBackslashes&&n&&e.indexOf(o)<0){e=e.replace(a,o)}if(l.test(e)){e+=o}e+="a";do{e=i(e)}while(s(e)||u.test(e));return e.replace(h,"$1")}},3664:(e,t,r)=>{"use strict";const s=r(2708);const i=r(8306);const n=r(5679);const o=r(4630);const a=r(2405);const l=r(952);const u=r(5444);async function FastGlob(e,t){assertPatternsInput(e);const r=getWorks(e,n.default,t);const s=await Promise.all(r);return u.array.flatten(s)}(function(e){function sync(e,t){assertPatternsInput(e);const r=getWorks(e,a.default,t);return u.array.flatten(r)}e.sync=sync;function stream(e,t){assertPatternsInput(e);const r=getWorks(e,o.default,t);return u.stream.merge(r)}e.stream=stream;function generateTasks(e,t){assertPatternsInput(e);const r=i.transform([].concat(e));const n=new l.default(t);return s.generate(r,n)}e.generateTasks=generateTasks;function isDynamicPattern(e,t){assertPatternsInput(e);const r=new l.default(t);return u.pattern.isDynamicPattern(e,r)}e.isDynamicPattern=isDynamicPattern;function escapePath(e){assertPatternsInput(e);return u.path.escape(e)}e.escapePath=escapePath})(FastGlob||(FastGlob={}));function getWorks(e,t,r){const n=i.transform([].concat(e));const o=new l.default(r);const a=s.generate(n,o);const u=new t(o);return a.map(u.read,u)}function assertPatternsInput(e){const t=[].concat(e);const r=t.every((e=>u.string.isString(e)&&!u.string.isEmpty(e)));if(!r){throw new TypeError("Patterns must be a string (non empty) or an array of strings")}}e.exports=FastGlob},8306:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.removeDuplicateSlashes=t.transform=void 0;const r=/(?!^)\/{2,}/g;function transform(e){return e.map((e=>removeDuplicateSlashes(e)))}t.transform=transform;function removeDuplicateSlashes(e){return e.replace(r,"/")}t.removeDuplicateSlashes=removeDuplicateSlashes},2708:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.convertPatternGroupToTask=t.convertPatternGroupsToTasks=t.groupPatternsByBaseDirectory=t.getNegativePatternsAsPositive=t.getPositivePatterns=t.convertPatternsToTasks=t.generate=void 0;const s=r(5444);function generate(e,t){const r=getPositivePatterns(e);const i=getNegativePatternsAsPositive(e,t.ignore);const n=r.filter((e=>s.pattern.isStaticPattern(e,t)));const o=r.filter((e=>s.pattern.isDynamicPattern(e,t)));const a=convertPatternsToTasks(n,i,false);const l=convertPatternsToTasks(o,i,true);return a.concat(l)}t.generate=generate;function convertPatternsToTasks(e,t,r){const i=[];const n=s.pattern.getPatternsOutsideCurrentDirectory(e);const o=s.pattern.getPatternsInsideCurrentDirectory(e);const a=groupPatternsByBaseDirectory(n);const l=groupPatternsByBaseDirectory(o);i.push(...convertPatternGroupsToTasks(a,t,r));if("."in l){i.push(convertPatternGroupToTask(".",o,t,r))}else{i.push(...convertPatternGroupsToTasks(l,t,r))}return i}t.convertPatternsToTasks=convertPatternsToTasks;function getPositivePatterns(e){return s.pattern.getPositivePatterns(e)}t.getPositivePatterns=getPositivePatterns;function getNegativePatternsAsPositive(e,t){const r=s.pattern.getNegativePatterns(e).concat(t);const i=r.map(s.pattern.convertToPositivePattern);return i}t.getNegativePatternsAsPositive=getNegativePatternsAsPositive;function groupPatternsByBaseDirectory(e){const t={};return e.reduce(((e,t)=>{const r=s.pattern.getBaseDirectory(t);if(r in e){e[r].push(t)}else{e[r]=[t]}return e}),t)}t.groupPatternsByBaseDirectory=groupPatternsByBaseDirectory;function convertPatternGroupsToTasks(e,t,r){return Object.keys(e).map((s=>convertPatternGroupToTask(s,e[s],t,r)))}t.convertPatternGroupsToTasks=convertPatternGroupsToTasks;function convertPatternGroupToTask(e,t,r,i){return{dynamic:i,positive:t,negative:r,base:e,patterns:[].concat(t,r.map(s.pattern.convertToNegativePattern))}}t.convertPatternGroupToTask=convertPatternGroupToTask},5679:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(7747);const i=r(257);class ProviderAsync extends i.default{constructor(){super(...arguments);this._reader=new s.default(this._settings)}async read(e){const t=this._getRootDirectory(e);const r=this._getReaderOptions(e);const s=await this.api(t,e,r);return s.map((e=>r.transform(e)))}api(e,t,r){if(t.dynamic){return this._reader.dynamic(e,r)}return this._reader.static(t.patterns,r)}}t["default"]=ProviderAsync},6983:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(5444);const i=r(5295);class DeepFilter{constructor(e,t){this._settings=e;this._micromatchOptions=t}getFilter(e,t,r){const s=this._getMatcher(t);const i=this._getNegativePatternsRe(r);return t=>this._filter(e,t,s,i)}_getMatcher(e){return new i.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){const t=e.filter(s.pattern.isAffectDepthOfReadingPattern);return s.pattern.convertPatternsToRe(t,this._micromatchOptions)}_filter(e,t,r,i){if(this._isSkippedByDeep(e,t.path)){return false}if(this._isSkippedSymbolicLink(t)){return false}const n=s.path.removeLeadingDotSegment(t.path);if(this._isSkippedByPositivePatterns(n,r)){return false}return this._isSkippedByNegativePatterns(n,i)}_isSkippedByDeep(e,t){if(this._settings.deep===Infinity){return false}return this._getEntryLevel(e,t)>=this._settings.deep}_getEntryLevel(e,t){const r=t.split("/").length;if(e===""){return r}const s=e.split("/").length;return r-s}_isSkippedSymbolicLink(e){return!this._settings.followSymbolicLinks&&e.dirent.isSymbolicLink()}_isSkippedByPositivePatterns(e,t){return!this._settings.baseNameMatch&&!t.match(e)}_isSkippedByNegativePatterns(e,t){return!s.pattern.matchAny(e,t)}}t["default"]=DeepFilter},1343:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(5444);class EntryFilter{constructor(e,t){this._settings=e;this._micromatchOptions=t;this.index=new Map}getFilter(e,t){const r=s.pattern.convertPatternsToRe(e,this._micromatchOptions);const i=s.pattern.convertPatternsToRe(t,this._micromatchOptions);return e=>this._filter(e,r,i)}_filter(e,t,r){if(this._settings.unique&&this._isDuplicateEntry(e)){return false}if(this._onlyFileFilter(e)||this._onlyDirectoryFilter(e)){return false}if(this._isSkippedByAbsoluteNegativePatterns(e.path,r)){return false}const s=this._settings.baseNameMatch?e.name:e.path;const i=e.dirent.isDirectory();const n=this._isMatchToPatterns(s,t,i)&&!this._isMatchToPatterns(e.path,r,i);if(this._settings.unique&&n){this._createIndexRecord(e)}return n}_isDuplicateEntry(e){return this.index.has(e.path)}_createIndexRecord(e){this.index.set(e.path,undefined)}_onlyFileFilter(e){return this._settings.onlyFiles&&!e.dirent.isFile()}_onlyDirectoryFilter(e){return this._settings.onlyDirectories&&!e.dirent.isDirectory()}_isSkippedByAbsoluteNegativePatterns(e,t){if(!this._settings.absolute){return false}const r=s.path.makeAbsolute(this._settings.cwd,e);return s.pattern.matchAny(r,t)}_isMatchToPatterns(e,t,r){const i=s.path.removeLeadingDotSegment(e);const n=s.pattern.matchAny(i,t);if(!n&&r){return s.pattern.matchAny(i+"/",t)}return n}}t["default"]=EntryFilter},6654:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(5444);class ErrorFilter{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return s.errno.isEnoentCodeError(e)||this._settings.suppressErrors}}t["default"]=ErrorFilter},2576:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(5444);class Matcher{constructor(e,t,r){this._patterns=e;this._settings=t;this._micromatchOptions=r;this._storage=[];this._fillStorage()}_fillStorage(){const e=s.pattern.expandPatternsWithBraceExpansion(this._patterns);for(const t of e){const e=this._getPatternSegments(t);const r=this._splitSegmentsIntoSections(e);this._storage.push({complete:r.length<=1,pattern:t,segments:e,sections:r})}}_getPatternSegments(e){const t=s.pattern.getPatternParts(e,this._micromatchOptions);return t.map((e=>{const t=s.pattern.isDynamicPattern(e,this._settings);if(!t){return{dynamic:false,pattern:e}}return{dynamic:true,pattern:e,patternRe:s.pattern.makeRe(e,this._micromatchOptions)}}))}_splitSegmentsIntoSections(e){return s.array.splitWhen(e,(e=>e.dynamic&&s.pattern.hasGlobStar(e.pattern)))}}t["default"]=Matcher},5295:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(2576);class PartialMatcher extends s.default{match(e){const t=e.split("/");const r=t.length;const s=this._storage.filter((e=>!e.complete||e.segments.length>r));for(const e of s){const s=e.sections[0];if(!e.complete&&r>s.length){return true}const i=t.every(((t,r)=>{const s=e.segments[r];if(s.dynamic&&s.patternRe.test(t)){return true}if(!s.dynamic&&s.pattern===t){return true}return false}));if(i){return true}}return false}}t["default"]=PartialMatcher},257:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(1017);const i=r(6983);const n=r(1343);const o=r(6654);const a=r(4029);class Provider{constructor(e){this._settings=e;this.errorFilter=new o.default(this._settings);this.entryFilter=new n.default(this._settings,this._getMicromatchOptions());this.deepFilter=new i.default(this._settings,this._getMicromatchOptions());this.entryTransformer=new a.default(this._settings)}_getRootDirectory(e){return s.resolve(this._settings.cwd,e.base)}_getReaderOptions(e){const t=e.base==="."?"":e.base;return{basePath:t,pathSegmentSeparator:"/",concurrency:this._settings.concurrency,deepFilter:this.deepFilter.getFilter(t,e.positive,e.negative),entryFilter:this.entryFilter.getFilter(e.positive,e.negative),errorFilter:this.errorFilter.getFilter(),followSymbolicLinks:this._settings.followSymbolicLinks,fs:this._settings.fs,stats:this._settings.stats,throwErrorOnBrokenSymbolicLink:this._settings.throwErrorOnBrokenSymbolicLink,transform:this.entryTransformer.getTransformer()}}_getMicromatchOptions(){return{dot:this._settings.dot,matchBase:this._settings.baseNameMatch,nobrace:!this._settings.braceExpansion,nocase:!this._settings.caseSensitiveMatch,noext:!this._settings.extglob,noglobstar:!this._settings.globstar,posix:true,strictSlashes:false}}}t["default"]=Provider},4630:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(2781);const i=r(2083);const n=r(257);class ProviderStream extends n.default{constructor(){super(...arguments);this._reader=new i.default(this._settings)}read(e){const t=this._getRootDirectory(e);const r=this._getReaderOptions(e);const i=this.api(t,e,r);const n=new s.Readable({objectMode:true,read:()=>{}});i.once("error",(e=>n.emit("error",e))).on("data",(e=>n.emit("data",r.transform(e)))).once("end",(()=>n.emit("end")));n.once("close",(()=>i.destroy()));return n}api(e,t,r){if(t.dynamic){return this._reader.dynamic(e,r)}return this._reader.static(t.patterns,r)}}t["default"]=ProviderStream},2405:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(6234);const i=r(257);class ProviderSync extends i.default{constructor(){super(...arguments);this._reader=new s.default(this._settings)}read(e){const t=this._getRootDirectory(e);const r=this._getReaderOptions(e);const s=this.api(t,e,r);return s.map(r.transform)}api(e,t,r){if(t.dynamic){return this._reader.dynamic(e,r)}return this._reader.static(t.patterns,r)}}t["default"]=ProviderSync},4029:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(5444);class EntryTransformer{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let t=e.path;if(this._settings.absolute){t=s.path.makeAbsolute(this._settings.cwd,t);t=s.path.unixify(t)}if(this._settings.markDirectories&&e.dirent.isDirectory()){t+="/"}if(!this._settings.objectMode){return t}return Object.assign(Object.assign({},e),{path:t})}}t["default"]=EntryTransformer},7747:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(6026);const i=r(5582);const n=r(2083);class ReaderAsync extends i.default{constructor(){super(...arguments);this._walkAsync=s.walk;this._readerStream=new n.default(this._settings)}dynamic(e,t){return new Promise(((r,s)=>{this._walkAsync(e,t,((e,t)=>{if(e===null){r(t)}else{s(e)}}))}))}async static(e,t){const r=[];const s=this._readerStream.static(e,t);return new Promise(((e,t)=>{s.once("error",t);s.on("data",(e=>r.push(e)));s.once("end",(()=>e(r)))}))}}t["default"]=ReaderAsync},5582:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(1017);const i=r(109);const n=r(5444);class Reader{constructor(e){this._settings=e;this._fsStatSettings=new i.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return s.resolve(this._settings.cwd,e)}_makeEntry(e,t){const r={name:t,path:t,dirent:n.fs.createDirentFromStats(t,e)};if(this._settings.stats){r.stats=e}return r}_isFatalError(e){return!n.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}}t["default"]=Reader},2083:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(2781);const i=r(109);const n=r(6026);const o=r(5582);class ReaderStream extends o.default{constructor(){super(...arguments);this._walkStream=n.walkStream;this._stat=i.stat}dynamic(e,t){return this._walkStream(e,t)}static(e,t){const r=e.map(this._getFullEntryPath,this);const i=new s.PassThrough({objectMode:true});i._write=(s,n,o)=>this._getEntry(r[s],e[s],t).then((e=>{if(e!==null&&t.entryFilter(e)){i.push(e)}if(s===r.length-1){i.end()}o()})).catch(o);for(let e=0;e<r.length;e++){i.write(e)}return i}_getEntry(e,t,r){return this._getStat(e).then((e=>this._makeEntry(e,t))).catch((e=>{if(r.errorFilter(e)){return null}throw e}))}_getStat(e){return new Promise(((t,r)=>{this._stat(e,this._fsStatSettings,((e,s)=>e===null?t(s):r(e)))}))}}t["default"]=ReaderStream},6234:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const s=r(109);const i=r(6026);const n=r(5582);class ReaderSync extends n.default{constructor(){super(...arguments);this._walkSync=i.walkSync;this._statSync=s.statSync}dynamic(e,t){return this._walkSync(e,t)}static(e,t){const r=[];for(const s of e){const e=this._getFullEntryPath(s);const i=this._getEntry(e,s,t);if(i===null||!t.entryFilter(i)){continue}r.push(i)}return r}_getEntry(e,t,r){try{const r=this._getStat(e);return this._makeEntry(r,t)}catch(e){if(r.errorFilter(e)){return null}throw e}}_getStat(e){return this._statSync(e,this._fsStatSettings)}}t["default"]=ReaderSync},952:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DEFAULT_FILE_SYSTEM_ADAPTER=void 0;const s=r(7147);const i=r(2037);const n=Math.max(i.cpus().length,1);t.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:s.lstat,lstatSync:s.lstatSync,stat:s.stat,statSync:s.statSync,readdir:s.readdir,readdirSync:s.readdirSync};class Settings{constructor(e={}){this._options=e;this.absolute=this._getValue(this._options.absolute,false);this.baseNameMatch=this._getValue(this._options.baseNameMatch,false);this.braceExpansion=this._getValue(this._options.braceExpansion,true);this.caseSensitiveMatch=this._getValue(this._options.caseSensitiveMatch,true);this.concurrency=this._getValue(this._options.concurrency,n);this.cwd=this._getValue(this._options.cwd,process.cwd());this.deep=this._getValue(this._options.deep,Infinity);this.dot=this._getValue(this._options.dot,false);this.extglob=this._getValue(this._options.extglob,true);this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,true);this.fs=this._getFileSystemMethods(this._options.fs);this.globstar=this._getValue(this._options.globstar,true);this.ignore=this._getValue(this._options.ignore,[]);this.markDirectories=this._getValue(this._options.markDirectories,false);this.objectMode=this._getValue(this._options.objectMode,false);this.onlyDirectories=this._getValue(this._options.onlyDirectories,false);this.onlyFiles=this._getValue(this._options.onlyFiles,true);this.stats=this._getValue(this._options.stats,false);this.suppressErrors=this._getValue(this._options.suppressErrors,false);this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,false);this.unique=this._getValue(this._options.unique,true);if(this.onlyDirectories){this.onlyFiles=false}if(this.stats){this.objectMode=true}}_getValue(e,t){return e===undefined?t:e}_getFileSystemMethods(e={}){return Object.assign(Object.assign({},t.DEFAULT_FILE_SYSTEM_ADAPTER),e)}}t["default"]=Settings},5325:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.splitWhen=t.flatten=void 0;function flatten(e){return e.reduce(((e,t)=>[].concat(e,t)),[])}t.flatten=flatten;function splitWhen(e,t){const r=[[]];let s=0;for(const i of e){if(t(i)){s++;r[s]=[]}else{r[s].push(i)}}return r}t.splitWhen=splitWhen},1230:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isEnoentCodeError=void 0;function isEnoentCodeError(e){return e.code==="ENOENT"}t.isEnoentCodeError=isEnoentCodeError},7543:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createDirentFromStats=void 0;class DirentFromStats{constructor(e,t){this.name=e;this.isBlockDevice=t.isBlockDevice.bind(t);this.isCharacterDevice=t.isCharacterDevice.bind(t);this.isDirectory=t.isDirectory.bind(t);this.isFIFO=t.isFIFO.bind(t);this.isFile=t.isFile.bind(t);this.isSocket=t.isSocket.bind(t);this.isSymbolicLink=t.isSymbolicLink.bind(t)}}function createDirentFromStats(e,t){return new DirentFromStats(e,t)}t.createDirentFromStats=createDirentFromStats},5444:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.string=t.stream=t.pattern=t.path=t.fs=t.errno=t.array=void 0;const s=r(5325);t.array=s;const i=r(1230);t.errno=i;const n=r(7543);t.fs=n;const o=r(3873);t.path=o;const a=r(1221);t.pattern=a;const l=r(8382);t.stream=l;const u=r(2203);t.string=u},3873:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.removeLeadingDotSegment=t.escape=t.makeAbsolute=t.unixify=void 0;const s=r(1017);const i=2;const n=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\())/g;function unixify(e){return e.replace(/\\/g,"/")}t.unixify=unixify;function makeAbsolute(e,t){return s.resolve(e,t)}t.makeAbsolute=makeAbsolute;function escape(e){return e.replace(n,"\\$2")}t.escape=escape;function removeLeadingDotSegment(e){if(e.charAt(0)==="."){const t=e.charAt(1);if(t==="/"||t==="\\"){return e.slice(i)}}return e}t.removeLeadingDotSegment=removeLeadingDotSegment},1221:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.matchAny=t.convertPatternsToRe=t.makeRe=t.getPatternParts=t.expandBraceExpansion=t.expandPatternsWithBraceExpansion=t.isAffectDepthOfReadingPattern=t.endsWithSlashGlobStar=t.hasGlobStar=t.getBaseDirectory=t.isPatternRelatedToParentDirectory=t.getPatternsOutsideCurrentDirectory=t.getPatternsInsideCurrentDirectory=t.getPositivePatterns=t.getNegativePatterns=t.isPositivePattern=t.isNegativePattern=t.convertToNegativePattern=t.convertToPositivePattern=t.isDynamicPattern=t.isStaticPattern=void 0;const s=r(1017);const i=r(4460);const n=r(6228);const o="**";const a="\\";const l=/[*?]|^!/;const u=/\[[^[]*]/;const h=/(?:^|[^!*+?@])\([^(]*\|[^|]*\)/;const f=/[!*+?@]\([^(]*\)/;const p=/,|\.\./;function isStaticPattern(e,t={}){return!isDynamicPattern(e,t)}t.isStaticPattern=isStaticPattern;function isDynamicPattern(e,t={}){if(e===""){return false}if(t.caseSensitiveMatch===false||e.includes(a)){return true}if(l.test(e)||u.test(e)||h.test(e)){return true}if(t.extglob!==false&&f.test(e)){return true}if(t.braceExpansion!==false&&hasBraceExpansion(e)){return true}return false}t.isDynamicPattern=isDynamicPattern;function hasBraceExpansion(e){const t=e.indexOf("{");if(t===-1){return false}const r=e.indexOf("}",t+1);if(r===-1){return false}const s=e.slice(t,r);return p.test(s)}function convertToPositivePattern(e){return isNegativePattern(e)?e.slice(1):e}t.convertToPositivePattern=convertToPositivePattern;function convertToNegativePattern(e){return"!"+e}t.convertToNegativePattern=convertToNegativePattern;function isNegativePattern(e){return e.startsWith("!")&&e[1]!=="("}t.isNegativePattern=isNegativePattern;function isPositivePattern(e){return!isNegativePattern(e)}t.isPositivePattern=isPositivePattern;function getNegativePatterns(e){return e.filter(isNegativePattern)}t.getNegativePatterns=getNegativePatterns;function getPositivePatterns(e){return e.filter(isPositivePattern)}t.getPositivePatterns=getPositivePatterns;function getPatternsInsideCurrentDirectory(e){return e.filter((e=>!isPatternRelatedToParentDirectory(e)))}t.getPatternsInsideCurrentDirectory=getPatternsInsideCurrentDirectory;function getPatternsOutsideCurrentDirectory(e){return e.filter(isPatternRelatedToParentDirectory)}t.getPatternsOutsideCurrentDirectory=getPatternsOutsideCurrentDirectory;function isPatternRelatedToParentDirectory(e){return e.startsWith("..")||e.startsWith("./..")}t.isPatternRelatedToParentDirectory=isPatternRelatedToParentDirectory;function getBaseDirectory(e){return i(e,{flipBackslashes:false})}t.getBaseDirectory=getBaseDirectory;function hasGlobStar(e){return e.includes(o)}t.hasGlobStar=hasGlobStar;function endsWithSlashGlobStar(e){return e.endsWith("/"+o)}t.endsWithSlashGlobStar=endsWithSlashGlobStar;function isAffectDepthOfReadingPattern(e){const t=s.basename(e);return endsWithSlashGlobStar(e)||isStaticPattern(t)}t.isAffectDepthOfReadingPattern=isAffectDepthOfReadingPattern;function expandPatternsWithBraceExpansion(e){return e.reduce(((e,t)=>e.concat(expandBraceExpansion(t))),[])}t.expandPatternsWithBraceExpansion=expandPatternsWithBraceExpansion;function expandBraceExpansion(e){return n.braces(e,{expand:true,nodupes:true})}t.expandBraceExpansion=expandBraceExpansion;function getPatternParts(e,t){let{parts:r}=n.scan(e,Object.assign(Object.assign({},t),{parts:true}));if(r.length===0){r=[e]}if(r[0].startsWith("/")){r[0]=r[0].slice(1);r.unshift("")}return r}t.getPatternParts=getPatternParts;function makeRe(e,t){return n.makeRe(e,t)}t.makeRe=makeRe;function convertPatternsToRe(e,t){return e.map((e=>makeRe(e,t)))}t.convertPatternsToRe=convertPatternsToRe;function matchAny(e,t){return t.some((t=>t.test(e)))}t.matchAny=matchAny},8382:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.merge=void 0;const s=r(2578);function merge(e){const t=s(e);e.forEach((e=>{e.once("error",(e=>t.emit("error",e)))}));t.once("close",(()=>propagateCloseEventToSources(e)));t.once("end",(()=>propagateCloseEventToSources(e)));return t}t.merge=merge;function propagateCloseEventToSources(e){e.forEach((e=>e.emit("close")))}},2203:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isEmpty=t.isString=void 0;function isString(e){return typeof e==="string"}t.isString=isString;function isEmpty(e){return e===""}t.isEmpty=isEmpty},7340:(e,t,r)=>{"use strict";var s=r(2113);function fastqueue(e,t,r){if(typeof e==="function"){r=t;t=e;e=null}if(r<1){throw new Error("fastqueue concurrency must be greater than 1")}var i=s(Task);var n=null;var o=null;var a=0;var l=null;var u={push:push,drain:noop,saturated:noop,pause:pause,paused:false,concurrency:r,running:running,resume:resume,idle:idle,length:length,getQueue:getQueue,unshift:unshift,empty:noop,kill:kill,killAndDrain:killAndDrain,error:error};return u;function running(){return a}function pause(){u.paused=true}function length(){var e=n;var t=0;while(e){e=e.next;t++}return t}function getQueue(){var e=n;var t=[];while(e){t.push(e.value);e=e.next}return t}function resume(){if(!u.paused)return;u.paused=false;for(var e=0;e<u.concurrency;e++){a++;release()}}function idle(){return a===0&&u.length()===0}function push(r,s){var h=i.get();h.context=e;h.release=release;h.value=r;h.callback=s||noop;h.errorHandler=l;if(a===u.concurrency||u.paused){if(o){o.next=h;o=h}else{n=h;o=h;u.saturated()}}else{a++;t.call(e,h.value,h.worked)}}function unshift(r,s){var l=i.get();l.context=e;l.release=release;l.value=r;l.callback=s||noop;if(a===u.concurrency||u.paused){if(n){l.next=n;n=l}else{n=l;o=l;u.saturated()}}else{a++;t.call(e,l.value,l.worked)}}function release(r){if(r){i.release(r)}var s=n;if(s){if(!u.paused){if(o===n){o=null}n=s.next;s.next=null;t.call(e,s.value,s.worked);if(o===null){u.empty()}}else{a--}}else if(--a===0){u.drain()}}function kill(){n=null;o=null;u.drain=noop}function killAndDrain(){n=null;o=null;u.drain();u.drain=noop}function error(e){l=e}}function noop(){}function Task(){this.value=null;this.callback=noop;this.next=null;this.release=noop;this.context=null;this.errorHandler=null;var e=this;this.worked=function worked(t,r){var s=e.callback;var i=e.errorHandler;var n=e.value;e.value=null;e.callback=noop;if(e.errorHandler){i(t,n)}s.call(e.context,t,r);e.release(e)}}function queueAsPromised(e,t,r){if(typeof e==="function"){r=t;t=e;e=null}function asyncWrapper(e,r){t.call(this,e).then((function(e){r(null,e)}),r)}var s=fastqueue(e,asyncWrapper,r);var i=s.push;var n=s.unshift;s.push=push;s.unshift=unshift;s.drained=drained;return s;function push(e){var t=new Promise((function(t,r){i(e,(function(e,s){if(e){r(e);return}t(s)}))}));t.catch(noop);return t}function unshift(e){var t=new Promise((function(t,r){n(e,(function(e,s){if(e){r(e);return}t(s)}))}));t.catch(noop);return t}function drained(){var e=s.drain;var t=new Promise((function(t){s.drain=function(){e();t()}}));return t}}e.exports=fastqueue;e.exports.promise=queueAsPromised},6330:(e,t,r)=>{"use strict";
|
|
2
|
+
(()=>{var e={2400:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createFileSystemAdapter=t.FILE_SYSTEM_ADAPTER=void 0;const i=r(9896);t.FILE_SYSTEM_ADAPTER={lstat:i.lstat,stat:i.stat,lstatSync:i.lstatSync,statSync:i.statSync,readdir:i.readdir,readdirSync:i.readdirSync};function createFileSystemAdapter(e){if(e===undefined){return t.FILE_SYSTEM_ADAPTER}return Object.assign(Object.assign({},t.FILE_SYSTEM_ADAPTER),e)}t.createFileSystemAdapter=createFileSystemAdapter},2479:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;const r=process.versions.node.split(".");if(r[0]===undefined||r[1]===undefined){throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`)}const i=Number.parseInt(r[0],10);const n=Number.parseInt(r[1],10);const s=10;const o=10;const a=i>s;const l=i===s&&n>=o;t.IS_SUPPORT_READDIR_WITH_FILE_TYPES=a||l},7198:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Settings=t.scandirSync=t.scandir=void 0;const i=r(7299);const n=r(7200);const s=r(2501);t.Settings=s.default;function scandir(e,t,r){if(typeof t==="function"){i.read(e,getSettings(),t);return}i.read(e,getSettings(t),r)}t.scandir=scandir;function scandirSync(e,t){const r=getSettings(t);return n.read(e,r)}t.scandirSync=scandirSync;function getSettings(e={}){if(e instanceof s.default){return e}return new s.default(e)}},7299:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.readdir=t.readdirWithFileTypes=t.read=void 0;const i=r(1470);const n=r(2743);const s=r(2479);const o=r(1144);const a=r(770);function read(e,t,r){if(!t.stats&&s.IS_SUPPORT_READDIR_WITH_FILE_TYPES){readdirWithFileTypes(e,t,r);return}readdir(e,t,r)}t.read=read;function readdirWithFileTypes(e,t,r){t.fs.readdir(e,{withFileTypes:true},((i,s)=>{if(i!==null){callFailureCallback(r,i);return}const o=s.map((r=>({dirent:r,name:r.name,path:a.joinPathSegments(e,r.name,t.pathSegmentSeparator)})));if(!t.followSymbolicLinks){callSuccessCallback(r,o);return}const l=o.map((e=>makeRplTaskEntry(e,t)));n(l,((e,t)=>{if(e!==null){callFailureCallback(r,e);return}callSuccessCallback(r,t)}))}))}t.readdirWithFileTypes=readdirWithFileTypes;function makeRplTaskEntry(e,t){return r=>{if(!e.dirent.isSymbolicLink()){r(null,e);return}t.fs.stat(e.path,((i,n)=>{if(i!==null){if(t.throwErrorOnBrokenSymbolicLink){r(i);return}r(null,e);return}e.dirent=o.fs.createDirentFromStats(e.name,n);r(null,e)}))}}function readdir(e,t,r){t.fs.readdir(e,((s,l)=>{if(s!==null){callFailureCallback(r,s);return}const u=l.map((r=>{const n=a.joinPathSegments(e,r,t.pathSegmentSeparator);return e=>{i.stat(n,t.fsStatSettings,((i,s)=>{if(i!==null){e(i);return}const a={name:r,path:n,dirent:o.fs.createDirentFromStats(r,s)};if(t.stats){a.stats=s}e(null,a)}))}}));n(u,((e,t)=>{if(e!==null){callFailureCallback(r,e);return}callSuccessCallback(r,t)}))}))}t.readdir=readdir;function callFailureCallback(e,t){e(t)}function callSuccessCallback(e,t){e(null,t)}},770:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.joinPathSegments=void 0;function joinPathSegments(e,t,r){if(e.endsWith(r)){return e+t}return e+r+t}t.joinPathSegments=joinPathSegments},7200:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.readdir=t.readdirWithFileTypes=t.read=void 0;const i=r(1470);const n=r(2479);const s=r(1144);const o=r(770);function read(e,t){if(!t.stats&&n.IS_SUPPORT_READDIR_WITH_FILE_TYPES){return readdirWithFileTypes(e,t)}return readdir(e,t)}t.read=read;function readdirWithFileTypes(e,t){const r=t.fs.readdirSync(e,{withFileTypes:true});return r.map((r=>{const i={dirent:r,name:r.name,path:o.joinPathSegments(e,r.name,t.pathSegmentSeparator)};if(i.dirent.isSymbolicLink()&&t.followSymbolicLinks){try{const e=t.fs.statSync(i.path);i.dirent=s.fs.createDirentFromStats(i.name,e)}catch(e){if(t.throwErrorOnBrokenSymbolicLink){throw e}}}return i}))}t.readdirWithFileTypes=readdirWithFileTypes;function readdir(e,t){const r=t.fs.readdirSync(e);return r.map((r=>{const n=o.joinPathSegments(e,r,t.pathSegmentSeparator);const a=i.statSync(n,t.fsStatSettings);const l={name:r,path:n,dirent:s.fs.createDirentFromStats(r,a)};if(t.stats){l.stats=a}return l}))}t.readdir=readdir},2501:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6928);const n=r(1470);const s=r(2400);class Settings{constructor(e={}){this._options=e;this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,false);this.fs=s.createFileSystemAdapter(this._options.fs);this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,i.sep);this.stats=this._getValue(this._options.stats,false);this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,true);this.fsStatSettings=new n.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,t){return e!==null&&e!==void 0?e:t}}t["default"]=Settings},5497:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createDirentFromStats=void 0;class DirentFromStats{constructor(e,t){this.name=e;this.isBlockDevice=t.isBlockDevice.bind(t);this.isCharacterDevice=t.isCharacterDevice.bind(t);this.isDirectory=t.isDirectory.bind(t);this.isFIFO=t.isFIFO.bind(t);this.isFile=t.isFile.bind(t);this.isSocket=t.isSocket.bind(t);this.isSymbolicLink=t.isSymbolicLink.bind(t)}}function createDirentFromStats(e,t){return new DirentFromStats(e,t)}t.createDirentFromStats=createDirentFromStats},1144:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.fs=void 0;const i=r(5497);t.fs=i},4368:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createFileSystemAdapter=t.FILE_SYSTEM_ADAPTER=void 0;const i=r(9896);t.FILE_SYSTEM_ADAPTER={lstat:i.lstat,stat:i.stat,lstatSync:i.lstatSync,statSync:i.statSync};function createFileSystemAdapter(e){if(e===undefined){return t.FILE_SYSTEM_ADAPTER}return Object.assign(Object.assign({},t.FILE_SYSTEM_ADAPTER),e)}t.createFileSystemAdapter=createFileSystemAdapter},1470:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.statSync=t.stat=t.Settings=void 0;const i=r(1539);const n=r(6544);const s=r(4853);t.Settings=s.default;function stat(e,t,r){if(typeof t==="function"){i.read(e,getSettings(),t);return}i.read(e,getSettings(t),r)}t.stat=stat;function statSync(e,t){const r=getSettings(t);return n.read(e,r)}t.statSync=statSync;function getSettings(e={}){if(e instanceof s.default){return e}return new s.default(e)}},1539:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.read=void 0;function read(e,t,r){t.fs.lstat(e,((i,n)=>{if(i!==null){callFailureCallback(r,i);return}if(!n.isSymbolicLink()||!t.followSymbolicLink){callSuccessCallback(r,n);return}t.fs.stat(e,((e,i)=>{if(e!==null){if(t.throwErrorOnBrokenSymbolicLink){callFailureCallback(r,e);return}callSuccessCallback(r,n);return}if(t.markSymbolicLink){i.isSymbolicLink=()=>true}callSuccessCallback(r,i)}))}))}t.read=read;function callFailureCallback(e,t){e(t)}function callSuccessCallback(e,t){e(null,t)}},6544:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.read=void 0;function read(e,t){const r=t.fs.lstatSync(e);if(!r.isSymbolicLink()||!t.followSymbolicLink){return r}try{const r=t.fs.statSync(e);if(t.markSymbolicLink){r.isSymbolicLink=()=>true}return r}catch(e){if(!t.throwErrorOnBrokenSymbolicLink){return r}throw e}}t.read=read},4853:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(4368);class Settings{constructor(e={}){this._options=e;this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,true);this.fs=i.createFileSystemAdapter(this._options.fs);this.markSymbolicLink=this._getValue(this._options.markSymbolicLink,false);this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,true)}_getValue(e,t){return e!==null&&e!==void 0?e:t}}t["default"]=Settings},9337:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Settings=t.walkStream=t.walkSync=t.walk=void 0;const i=r(1936);const n=r(8986);const s=r(8769);const o=r(244);t.Settings=o.default;function walk(e,t,r){if(typeof t==="function"){new i.default(e,getSettings()).read(t);return}new i.default(e,getSettings(t)).read(r)}t.walk=walk;function walkSync(e,t){const r=getSettings(t);const i=new s.default(e,r);return i.read()}t.walkSync=walkSync;function walkStream(e,t){const r=getSettings(t);const i=new n.default(e,r);return i.read()}t.walkStream=walkStream;function getSettings(e={}){if(e instanceof o.default){return e}return new o.default(e)}},1936:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(1906);class AsyncProvider{constructor(e,t){this._root=e;this._settings=t;this._reader=new i.default(this._root,this._settings);this._storage=[]}read(e){this._reader.onError((t=>{callFailureCallback(e,t)}));this._reader.onEntry((e=>{this._storage.push(e)}));this._reader.onEnd((()=>{callSuccessCallback(e,this._storage)}));this._reader.read()}}t["default"]=AsyncProvider;function callFailureCallback(e,t){e(t)}function callSuccessCallback(e,t){e(null,t)}},8986:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(2203);const n=r(1906);class StreamProvider{constructor(e,t){this._root=e;this._settings=t;this._reader=new n.default(this._root,this._settings);this._stream=new i.Readable({objectMode:true,read:()=>{},destroy:()=>{if(!this._reader.isDestroyed){this._reader.destroy()}}})}read(){this._reader.onError((e=>{this._stream.emit("error",e)}));this._reader.onEntry((e=>{this._stream.push(e)}));this._reader.onEnd((()=>{this._stream.push(null)}));this._reader.read();return this._stream}}t["default"]=StreamProvider},8769:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(3431);class SyncProvider{constructor(e,t){this._root=e;this._settings=t;this._reader=new i.default(this._root,this._settings)}read(){return this._reader.read()}}t["default"]=SyncProvider},1906:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(4434);const n=r(7198);const s=r(8230);const o=r(4449);const a=r(5903);class AsyncReader extends a.default{constructor(e,t){super(e,t);this._settings=t;this._scandir=n.scandir;this._emitter=new i.EventEmitter;this._queue=s(this._worker.bind(this),this._settings.concurrency);this._isFatalError=false;this._isDestroyed=false;this._queue.drain=()=>{if(!this._isFatalError){this._emitter.emit("end")}}}read(){this._isFatalError=false;this._isDestroyed=false;setImmediate((()=>{this._pushToQueue(this._root,this._settings.basePath)}));return this._emitter}get isDestroyed(){return this._isDestroyed}destroy(){if(this._isDestroyed){throw new Error("The reader is already destroyed")}this._isDestroyed=true;this._queue.killAndDrain()}onEntry(e){this._emitter.on("entry",e)}onError(e){this._emitter.once("error",e)}onEnd(e){this._emitter.once("end",e)}_pushToQueue(e,t){const r={directory:e,base:t};this._queue.push(r,(e=>{if(e!==null){this._handleError(e)}}))}_worker(e,t){this._scandir(e.directory,this._settings.fsScandirSettings,((r,i)=>{if(r!==null){t(r,undefined);return}for(const t of i){this._handleEntry(t,e.base)}t(null,undefined)}))}_handleError(e){if(this._isDestroyed||!o.isFatalError(this._settings,e)){return}this._isFatalError=true;this._isDestroyed=true;this._emitter.emit("error",e)}_handleEntry(e,t){if(this._isDestroyed||this._isFatalError){return}const r=e.path;if(t!==undefined){e.path=o.joinPathSegments(t,e.name,this._settings.pathSegmentSeparator)}if(o.isAppliedFilter(this._settings.entryFilter,e)){this._emitEntry(e)}if(e.dirent.isDirectory()&&o.isAppliedFilter(this._settings.deepFilter,e)){this._pushToQueue(r,t===undefined?undefined:e.path)}}_emitEntry(e){this._emitter.emit("entry",e)}}t["default"]=AsyncReader},4449:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.joinPathSegments=t.replacePathSegmentSeparator=t.isAppliedFilter=t.isFatalError=void 0;function isFatalError(e,t){if(e.errorFilter===null){return true}return!e.errorFilter(t)}t.isFatalError=isFatalError;function isAppliedFilter(e,t){return e===null||e(t)}t.isAppliedFilter=isAppliedFilter;function replacePathSegmentSeparator(e,t){return e.split(/[/\\]/).join(t)}t.replacePathSegmentSeparator=replacePathSegmentSeparator;function joinPathSegments(e,t,r){if(e===""){return t}if(e.endsWith(r)){return e+t}return e+r+t}t.joinPathSegments=joinPathSegments},5903:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(4449);class Reader{constructor(e,t){this._root=e;this._settings=t;this._root=i.replacePathSegmentSeparator(e,t.pathSegmentSeparator)}}t["default"]=Reader},3431:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(7198);const n=r(4449);const s=r(5903);class SyncReader extends s.default{constructor(){super(...arguments);this._scandir=i.scandirSync;this._storage=[];this._queue=new Set}read(){this._pushToQueue(this._root,this._settings.basePath);this._handleQueue();return this._storage}_pushToQueue(e,t){this._queue.add({directory:e,base:t})}_handleQueue(){for(const e of this._queue.values()){this._handleDirectory(e.directory,e.base)}}_handleDirectory(e,t){try{const r=this._scandir(e,this._settings.fsScandirSettings);for(const e of r){this._handleEntry(e,t)}}catch(e){this._handleError(e)}}_handleError(e){if(!n.isFatalError(this._settings,e)){return}throw e}_handleEntry(e,t){const r=e.path;if(t!==undefined){e.path=n.joinPathSegments(t,e.name,this._settings.pathSegmentSeparator)}if(n.isAppliedFilter(this._settings.entryFilter,e)){this._pushToStorage(e)}if(e.dirent.isDirectory()&&n.isAppliedFilter(this._settings.deepFilter,e)){this._pushToQueue(r,t===undefined?undefined:e.path)}}_pushToStorage(e){this._storage.push(e)}}t["default"]=SyncReader},244:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6928);const n=r(7198);class Settings{constructor(e={}){this._options=e;this.basePath=this._getValue(this._options.basePath,undefined);this.concurrency=this._getValue(this._options.concurrency,Number.POSITIVE_INFINITY);this.deepFilter=this._getValue(this._options.deepFilter,null);this.entryFilter=this._getValue(this._options.entryFilter,null);this.errorFilter=this._getValue(this._options.errorFilter,null);this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,i.sep);this.fsScandirSettings=new n.Settings({followSymbolicLinks:this._options.followSymbolicLinks,fs:this._options.fs,pathSegmentSeparator:this._options.pathSegmentSeparator,stats:this._options.stats,throwErrorOnBrokenSymbolicLink:this._options.throwErrorOnBrokenSymbolicLink})}_getValue(e,t){return e!==null&&e!==void 0?e:t}}t["default"]=Settings},7182:(e,t,r)=>{"use strict";const isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);const i=/[\u001b\u009b][[\]#;?()]*(?:(?:(?:[^\W_]*;?[^\W_]*)\u0007)|(?:(?:[0-9]{1,4}(;[0-9]{0,4})*)?[~0-9=<>cf-nqrtyA-PRZ]))/g;const hasColor=()=>{if(typeof process!=="undefined"){return process.env.FORCE_COLOR!=="0"}return false};const create=()=>{const e={enabled:hasColor(),visible:true,styles:{},keys:{}};const ansi=e=>{let t=e.open=`[${e.codes[0]}m`;let r=e.close=`[${e.codes[1]}m`;let i=e.regex=new RegExp(`\\u001b\\[${e.codes[1]}m`,"g");e.wrap=(e,n)=>{if(e.includes(r))e=e.replace(i,r+t);let s=t+e+r;return n?s.replace(/\r*\n/g,`${r}$&${t}`):s};return e};const wrap=(e,t,r)=>typeof e==="function"?e(t):e.wrap(t,r);const style=(t,r)=>{if(t===""||t==null)return"";if(e.enabled===false)return t;if(e.visible===false)return"";let i=""+t;let n=i.includes("\n");let s=r.length;if(s>0&&r.includes("unstyle")){r=[...new Set(["unstyle",...r])].reverse()}while(s-- >0)i=wrap(e.styles[r[s]],i,n);return i};const define=(t,r,i)=>{e.styles[t]=ansi({name:t,codes:r});let n=e.keys[i]||(e.keys[i]=[]);n.push(t);Reflect.defineProperty(e,t,{configurable:true,enumerable:true,set(r){e.alias(t,r)},get(){let color=e=>style(e,color.stack);Reflect.setPrototypeOf(color,e);color.stack=this.stack?this.stack.concat(t):[t];return color}})};define("reset",[0,0],"modifier");define("bold",[1,22],"modifier");define("dim",[2,22],"modifier");define("italic",[3,23],"modifier");define("underline",[4,24],"modifier");define("inverse",[7,27],"modifier");define("hidden",[8,28],"modifier");define("strikethrough",[9,29],"modifier");define("black",[30,39],"color");define("red",[31,39],"color");define("green",[32,39],"color");define("yellow",[33,39],"color");define("blue",[34,39],"color");define("magenta",[35,39],"color");define("cyan",[36,39],"color");define("white",[37,39],"color");define("gray",[90,39],"color");define("grey",[90,39],"color");define("bgBlack",[40,49],"bg");define("bgRed",[41,49],"bg");define("bgGreen",[42,49],"bg");define("bgYellow",[43,49],"bg");define("bgBlue",[44,49],"bg");define("bgMagenta",[45,49],"bg");define("bgCyan",[46,49],"bg");define("bgWhite",[47,49],"bg");define("blackBright",[90,39],"bright");define("redBright",[91,39],"bright");define("greenBright",[92,39],"bright");define("yellowBright",[93,39],"bright");define("blueBright",[94,39],"bright");define("magentaBright",[95,39],"bright");define("cyanBright",[96,39],"bright");define("whiteBright",[97,39],"bright");define("bgBlackBright",[100,49],"bgBright");define("bgRedBright",[101,49],"bgBright");define("bgGreenBright",[102,49],"bgBright");define("bgYellowBright",[103,49],"bgBright");define("bgBlueBright",[104,49],"bgBright");define("bgMagentaBright",[105,49],"bgBright");define("bgCyanBright",[106,49],"bgBright");define("bgWhiteBright",[107,49],"bgBright");e.ansiRegex=i;e.hasColor=e.hasAnsi=t=>{e.ansiRegex.lastIndex=0;return typeof t==="string"&&t!==""&&e.ansiRegex.test(t)};e.alias=(t,r)=>{let i=typeof r==="string"?e[r]:r;if(typeof i!=="function"){throw new TypeError("Expected alias to be the name of an existing color (string) or a function")}if(!i.stack){Reflect.defineProperty(i,"name",{value:t});e.styles[t]=i;i.stack=[t]}Reflect.defineProperty(e,t,{configurable:true,enumerable:true,set(r){e.alias(t,r)},get(){let color=e=>style(e,color.stack);Reflect.setPrototypeOf(color,e);color.stack=this.stack?this.stack.concat(i.stack):i.stack;return color}})};e.theme=t=>{if(!isObject(t))throw new TypeError("Expected theme to be an object");for(let r of Object.keys(t)){e.alias(r,t[r])}return e};e.alias("unstyle",(t=>{if(typeof t==="string"&&t!==""){e.ansiRegex.lastIndex=0;return t.replace(e.ansiRegex,"")}return""}));e.alias("noop",(e=>e));e.none=e.clear=e.noop;e.stripColor=e.unstyle;e.symbols=r(4763);e.define=define;return e};e.exports=create();e.exports.create=create},4763:e=>{"use strict";const t=typeof process!=="undefined"&&process.env.TERM_PROGRAM==="Hyper";const r=typeof process!=="undefined"&&process.platform==="win32";const i=typeof process!=="undefined"&&process.platform==="linux";const n={ballotDisabled:"☒",ballotOff:"☐",ballotOn:"☑",bullet:"•",bulletWhite:"◦",fullBlock:"█",heart:"❤",identicalTo:"≡",line:"─",mark:"※",middot:"·",minus:"-",multiplication:"×",obelus:"÷",pencilDownRight:"✎",pencilRight:"✏",pencilUpRight:"✐",percent:"%",pilcrow2:"❡",pilcrow:"¶",plusMinus:"±",question:"?",section:"§",starsOff:"☆",starsOn:"★",upDownArrow:"↕"};const s=Object.assign({},n,{check:"√",cross:"×",ellipsisLarge:"...",ellipsis:"...",info:"i",questionSmall:"?",pointer:">",pointerSmall:"»",radioOff:"( )",radioOn:"(*)",warning:"‼"});const o=Object.assign({},n,{ballotCross:"✘",check:"✔",cross:"✖",ellipsisLarge:"⋯",ellipsis:"…",info:"ℹ",questionFull:"?",questionSmall:"﹖",pointer:i?"▸":"❯",pointerSmall:i?"‣":"›",radioOff:"◯",radioOn:"◉",warning:"⚠"});e.exports=r&&!t?s:o;Reflect.defineProperty(e.exports,"common",{enumerable:false,value:n});Reflect.defineProperty(e.exports,"windows",{enumerable:false,value:s});Reflect.defineProperty(e.exports,"other",{enumerable:false,value:o})},21:e=>{"use strict";e.exports=({onlyFirst:e=false}={})=>{const t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(t,e?undefined:"g")}},4412:(e,t,r)=>{"use strict";e=r.nmd(e);const wrapAnsi16=(e,t)=>(...r)=>{const i=e(...r);return`[${i+t}m`};const wrapAnsi256=(e,t)=>(...r)=>{const i=e(...r);return`[${38+t};5;${i}m`};const wrapAnsi16m=(e,t)=>(...r)=>{const i=e(...r);return`[${38+t};2;${i[0]};${i[1]};${i[2]}m`};const ansi2ansi=e=>e;const rgb2rgb=(e,t,r)=>[e,t,r];const setLazyProperty=(e,t,r)=>{Object.defineProperty(e,t,{get:()=>{const i=r();Object.defineProperty(e,t,{value:i,enumerable:true,configurable:true});return i},enumerable:true,configurable:true})};let i;const makeDynamicStyles=(e,t,n,s)=>{if(i===undefined){i=r(4185)}const o=s?10:0;const a={};for(const[r,s]of Object.entries(i)){const i=r==="ansi16"?"ansi":r;if(r===t){a[i]=e(n,o)}else if(typeof s==="object"){a[i]=e(s[t],o)}}return a};function assembleStyles(){const e=new Map;const t={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};t.color.gray=t.color.blackBright;t.bgColor.bgGray=t.bgColor.bgBlackBright;t.color.grey=t.color.blackBright;t.bgColor.bgGrey=t.bgColor.bgBlackBright;for(const[r,i]of Object.entries(t)){for(const[r,n]of Object.entries(i)){t[r]={open:`[${n[0]}m`,close:`[${n[1]}m`};i[r]=t[r];e.set(n[0],n[1])}Object.defineProperty(t,r,{value:i,enumerable:false})}Object.defineProperty(t,"codes",{value:e,enumerable:false});t.color.close="[39m";t.bgColor.close="[49m";setLazyProperty(t.color,"ansi",(()=>makeDynamicStyles(wrapAnsi16,"ansi16",ansi2ansi,false)));setLazyProperty(t.color,"ansi256",(()=>makeDynamicStyles(wrapAnsi256,"ansi256",ansi2ansi,false)));setLazyProperty(t.color,"ansi16m",(()=>makeDynamicStyles(wrapAnsi16m,"rgb",rgb2rgb,false)));setLazyProperty(t.bgColor,"ansi",(()=>makeDynamicStyles(wrapAnsi16,"ansi16",ansi2ansi,true)));setLazyProperty(t.bgColor,"ansi256",(()=>makeDynamicStyles(wrapAnsi256,"ansi256",ansi2ansi,true)));setLazyProperty(t.bgColor,"ansi16m",(()=>makeDynamicStyles(wrapAnsi16m,"rgb",rgb2rgb,true)));return t}Object.defineProperty(e,"exports",{enumerable:true,get:assembleStyles})},5234:(e,t,r)=>{"use strict";const{Buffer:i}=r(181);const n=Symbol.for("BufferList");function BufferList(e){if(!(this instanceof BufferList)){return new BufferList(e)}BufferList._init.call(this,e)}BufferList._init=function _init(e){Object.defineProperty(this,n,{value:true});this._bufs=[];this.length=0;if(e){this.append(e)}};BufferList.prototype._new=function _new(e){return new BufferList(e)};BufferList.prototype._offset=function _offset(e){if(e===0){return[0,0]}let t=0;for(let r=0;r<this._bufs.length;r++){const i=t+this._bufs[r].length;if(e<i||r===this._bufs.length-1){return[r,e-t]}t=i}};BufferList.prototype._reverseOffset=function(e){const t=e[0];let r=e[1];for(let e=0;e<t;e++){r+=this._bufs[e].length}return r};BufferList.prototype.get=function get(e){if(e>this.length||e<0){return undefined}const t=this._offset(e);return this._bufs[t[0]][t[1]]};BufferList.prototype.slice=function slice(e,t){if(typeof e==="number"&&e<0){e+=this.length}if(typeof t==="number"&&t<0){t+=this.length}return this.copy(null,0,e,t)};BufferList.prototype.copy=function copy(e,t,r,n){if(typeof r!=="number"||r<0){r=0}if(typeof n!=="number"||n>this.length){n=this.length}if(r>=this.length){return e||i.alloc(0)}if(n<=0){return e||i.alloc(0)}const copy=!!e;const s=this._offset(r);const o=n-r;let a=o;let l=copy&&t||0;let u=s[1];if(r===0&&n===this.length){if(!copy){return this._bufs.length===1?this._bufs[0]:i.concat(this._bufs,this.length)}for(let t=0;t<this._bufs.length;t++){this._bufs[t].copy(e,l);l+=this._bufs[t].length}return e}if(a<=this._bufs[s[0]].length-u){return copy?this._bufs[s[0]].copy(e,t,u,u+a):this._bufs[s[0]].slice(u,u+a)}if(!copy){e=i.allocUnsafe(o)}for(let t=s[0];t<this._bufs.length;t++){const r=this._bufs[t].length-u;if(a>r){this._bufs[t].copy(e,l,u);l+=r}else{this._bufs[t].copy(e,l,u,u+a);l+=r;break}a-=r;if(u){u=0}}if(e.length>l)return e.slice(0,l);return e};BufferList.prototype.shallowSlice=function shallowSlice(e,t){e=e||0;t=typeof t!=="number"?this.length:t;if(e<0){e+=this.length}if(t<0){t+=this.length}if(e===t){return this._new()}const r=this._offset(e);const i=this._offset(t);const n=this._bufs.slice(r[0],i[0]+1);if(i[1]===0){n.pop()}else{n[n.length-1]=n[n.length-1].slice(0,i[1])}if(r[1]!==0){n[0]=n[0].slice(r[1])}return this._new(n)};BufferList.prototype.toString=function toString(e,t,r){return this.slice(t,r).toString(e)};BufferList.prototype.consume=function consume(e){e=Math.trunc(e);if(Number.isNaN(e)||e<=0)return this;while(this._bufs.length){if(e>=this._bufs[0].length){e-=this._bufs[0].length;this.length-=this._bufs[0].length;this._bufs.shift()}else{this._bufs[0]=this._bufs[0].slice(e);this.length-=e;break}}return this};BufferList.prototype.duplicate=function duplicate(){const e=this._new();for(let t=0;t<this._bufs.length;t++){e.append(this._bufs[t])}return e};BufferList.prototype.append=function append(e){if(e==null){return this}if(e.buffer){this._appendBuffer(i.from(e.buffer,e.byteOffset,e.byteLength))}else if(Array.isArray(e)){for(let t=0;t<e.length;t++){this.append(e[t])}}else if(this._isBufferList(e)){for(let t=0;t<e._bufs.length;t++){this.append(e._bufs[t])}}else{if(typeof e==="number"){e=e.toString()}this._appendBuffer(i.from(e))}return this};BufferList.prototype._appendBuffer=function appendBuffer(e){this._bufs.push(e);this.length+=e.length};BufferList.prototype.indexOf=function(e,t,r){if(r===undefined&&typeof t==="string"){r=t;t=undefined}if(typeof e==="function"||Array.isArray(e)){throw new TypeError('The "value" argument must be one of type string, Buffer, BufferList, or Uint8Array.')}else if(typeof e==="number"){e=i.from([e])}else if(typeof e==="string"){e=i.from(e,r)}else if(this._isBufferList(e)){e=e.slice()}else if(Array.isArray(e.buffer)){e=i.from(e.buffer,e.byteOffset,e.byteLength)}else if(!i.isBuffer(e)){e=i.from(e)}t=Number(t||0);if(isNaN(t)){t=0}if(t<0){t=this.length+t}if(t<0){t=0}if(e.length===0){return t>this.length?this.length:t}const n=this._offset(t);let s=n[0];let o=n[1];for(;s<this._bufs.length;s++){const t=this._bufs[s];while(o<t.length){const r=t.length-o;if(r>=e.length){const r=t.indexOf(e,o);if(r!==-1){return this._reverseOffset([s,r])}o=t.length-e.length+1}else{const t=this._reverseOffset([s,o]);if(this._match(t,e)){return t}o++}}o=0}return-1};BufferList.prototype._match=function(e,t){if(this.length-e<t.length){return false}for(let r=0;r<t.length;r++){if(this.get(e+r)!==t[r]){return false}}return true};(function(){const e={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1,readIntBE:null,readIntLE:null,readUIntBE:null,readUIntLE:null};for(const t in e){(function(t){if(e[t]===null){BufferList.prototype[t]=function(e,r){return this.slice(e,e+r)[t](0,r)}}else{BufferList.prototype[t]=function(r=0){return this.slice(r,r+e[t])[t](0)}}})(t)}})();BufferList.prototype._isBufferList=function _isBufferList(e){return e instanceof BufferList||BufferList.isBufferList(e)};BufferList.isBufferList=function isBufferList(e){return e!=null&&e[n]};e.exports=BufferList},794:(e,t,r)=>{"use strict";const i=r(6131).Duplex;const n=r(9598);const s=r(5234);function BufferListStream(e){if(!(this instanceof BufferListStream)){return new BufferListStream(e)}if(typeof e==="function"){this._callback=e;const t=function piper(e){if(this._callback){this._callback(e);this._callback=null}}.bind(this);this.on("pipe",(function onPipe(e){e.on("error",t)}));this.on("unpipe",(function onUnpipe(e){e.removeListener("error",t)}));e=null}s._init.call(this,e);i.call(this)}n(BufferListStream,i);Object.assign(BufferListStream.prototype,s.prototype);BufferListStream.prototype._new=function _new(e){return new BufferListStream(e)};BufferListStream.prototype._write=function _write(e,t,r){this._appendBuffer(e);if(typeof r==="function"){r()}};BufferListStream.prototype._read=function _read(e){if(!this.length){return this.push(null)}e=Math.min(e,this.length);this.push(this.slice(0,e));this.consume(e)};BufferListStream.prototype.end=function end(e){i.prototype.end.call(this,e);if(this._callback){this._callback(null,this.slice());this._callback=null}};BufferListStream.prototype._destroy=function _destroy(e,t){this._bufs.length=0;this.length=0;t(e)};BufferListStream.prototype._isBufferList=function _isBufferList(e){return e instanceof BufferListStream||e instanceof s||BufferListStream.isBufferList(e)};BufferListStream.isBufferList=s.isBufferList;e.exports=BufferListStream;e.exports.BufferListStream=BufferListStream;e.exports.BufferList=s},748:(e,t,r)=>{"use strict";const i=r(3317);const n=r(1113);const s=r(5290);const o=r(507);const braces=(e,t={})=>{let r=[];if(Array.isArray(e)){for(const i of e){const e=braces.create(i,t);if(Array.isArray(e)){r.push(...e)}else{r.push(e)}}}else{r=[].concat(braces.create(e,t))}if(t&&t.expand===true&&t.nodupes===true){r=[...new Set(r)]}return r};braces.parse=(e,t={})=>o(e,t);braces.stringify=(e,t={})=>{if(typeof e==="string"){return i(braces.parse(e,t),t)}return i(e,t)};braces.compile=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}return n(e,t)};braces.expand=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}let r=s(e,t);if(t.noempty===true){r=r.filter(Boolean)}if(t.nodupes===true){r=[...new Set(r)]}return r};braces.create=(e,t={})=>{if(e===""||e.length<3){return[e]}return t.expand!==true?braces.compile(e,t):braces.expand(e,t)};e.exports=braces},1113:(e,t,r)=>{"use strict";const i=r(877);const n=r(2257);const compile=(e,t={})=>{const walk=(e,r={})=>{const s=n.isInvalidBrace(r);const o=e.invalid===true&&t.escapeInvalid===true;const a=s===true||o===true;const l=t.escapeInvalid===true?"\\":"";let u="";if(e.isOpen===true){return l+e.value}if(e.isClose===true){console.log("node.isClose",l,e.value);return l+e.value}if(e.type==="open"){return a?l+e.value:"("}if(e.type==="close"){return a?l+e.value:")"}if(e.type==="comma"){return e.prev.type==="comma"?"":a?e.value:"|"}if(e.value){return e.value}if(e.nodes&&e.ranges>0){const r=n.reduce(e.nodes);const s=i(...r,{...t,wrap:false,toRegex:true,strictZeros:true});if(s.length!==0){return r.length>1&&s.length>1?`(${s})`:s}}if(e.nodes){for(const t of e.nodes){u+=walk(t,e)}}return u};return walk(e)};e.exports=compile},2477:e=>{"use strict";e.exports={MAX_LENGTH:1e4,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:"\n",CHAR_NO_BREAK_SPACE:" ",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:"\t",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\ufeff"}},5290:(e,t,r)=>{"use strict";const i=r(877);const n=r(3317);const s=r(2257);const append=(e="",t="",r=false)=>{const i=[];e=[].concat(e);t=[].concat(t);if(!t.length)return e;if(!e.length){return r?s.flatten(t).map((e=>`{${e}}`)):t}for(const n of e){if(Array.isArray(n)){for(const e of n){i.push(append(e,t,r))}}else{for(let e of t){if(r===true&&typeof e==="string")e=`{${e}}`;i.push(Array.isArray(e)?append(n,e,r):n+e)}}}return s.flatten(i)};const expand=(e,t={})=>{const r=t.rangeLimit===undefined?1e3:t.rangeLimit;const walk=(e,o={})=>{e.queue=[];let a=o;let l=o.queue;while(a.type!=="brace"&&a.type!=="root"&&a.parent){a=a.parent;l=a.queue}if(e.invalid||e.dollar){l.push(append(l.pop(),n(e,t)));return}if(e.type==="brace"&&e.invalid!==true&&e.nodes.length===2){l.push(append(l.pop(),["{}"]));return}if(e.nodes&&e.ranges>0){const o=s.reduce(e.nodes);if(s.exceedsLimit(...o,t.step,r)){throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.")}let a=i(...o,t);if(a.length===0){a=n(e,t)}l.push(append(l.pop(),a));e.nodes=[];return}const u=s.encloseBrace(e);let h=e.queue;let f=e;while(f.type!=="brace"&&f.type!=="root"&&f.parent){f=f.parent;h=f.queue}for(let t=0;t<e.nodes.length;t++){const r=e.nodes[t];if(r.type==="comma"&&e.type==="brace"){if(t===1)h.push("");h.push("");continue}if(r.type==="close"){l.push(append(l.pop(),h,u));continue}if(r.value&&r.type!=="open"){h.push(append(h.pop(),r.value));continue}if(r.nodes){walk(r,e)}}return h};return s.flatten(walk(e))};e.exports=expand},507:(e,t,r)=>{"use strict";const i=r(3317);const{MAX_LENGTH:n,CHAR_BACKSLASH:s,CHAR_BACKTICK:o,CHAR_COMMA:a,CHAR_DOT:l,CHAR_LEFT_PARENTHESES:u,CHAR_RIGHT_PARENTHESES:h,CHAR_LEFT_CURLY_BRACE:f,CHAR_RIGHT_CURLY_BRACE:p,CHAR_LEFT_SQUARE_BRACKET:d,CHAR_RIGHT_SQUARE_BRACKET:m,CHAR_DOUBLE_QUOTE:g,CHAR_SINGLE_QUOTE:y,CHAR_NO_BREAK_SPACE:b,CHAR_ZERO_WIDTH_NOBREAK_SPACE:_}=r(2477);const parse=(e,t={})=>{if(typeof e!=="string"){throw new TypeError("Expected a string")}const r=t||{};const v=typeof r.maxLength==="number"?Math.min(n,r.maxLength):n;if(e.length>v){throw new SyntaxError(`Input length (${e.length}), exceeds max characters (${v})`)}const w={type:"root",input:e,nodes:[]};const S=[w];let x=w;let E=w;let A=0;const k=e.length;let C=0;let R=0;let P;const advance=()=>e[C++];const push=e=>{if(e.type==="text"&&E.type==="dot"){E.type="text"}if(E&&E.type==="text"&&e.type==="text"){E.value+=e.value;return}x.nodes.push(e);e.parent=x;e.prev=E;E=e;return e};push({type:"bos"});while(C<k){x=S[S.length-1];P=advance();if(P===_||P===b){continue}if(P===s){push({type:"text",value:(t.keepEscaping?P:"")+advance()});continue}if(P===m){push({type:"text",value:"\\"+P});continue}if(P===d){A++;let e;while(C<k&&(e=advance())){P+=e;if(e===d){A++;continue}if(e===s){P+=advance();continue}if(e===m){A--;if(A===0){break}}}push({type:"text",value:P});continue}if(P===u){x=push({type:"paren",nodes:[]});S.push(x);push({type:"text",value:P});continue}if(P===h){if(x.type!=="paren"){push({type:"text",value:P});continue}x=S.pop();push({type:"text",value:P});x=S[S.length-1];continue}if(P===g||P===y||P===o){const e=P;let r;if(t.keepQuotes!==true){P=""}while(C<k&&(r=advance())){if(r===s){P+=r+advance();continue}if(r===e){if(t.keepQuotes===true)P+=r;break}P+=r}push({type:"text",value:P});continue}if(P===f){R++;const e=E.value&&E.value.slice(-1)==="$"||x.dollar===true;const t={type:"brace",open:true,close:false,dollar:e,depth:R,commas:0,ranges:0,nodes:[]};x=push(t);S.push(x);push({type:"open",value:P});continue}if(P===p){if(x.type!=="brace"){push({type:"text",value:P});continue}const e="close";x=S.pop();x.close=true;push({type:e,value:P});R--;x=S[S.length-1];continue}if(P===a&&R>0){if(x.ranges>0){x.ranges=0;const e=x.nodes.shift();x.nodes=[e,{type:"text",value:i(x)}]}push({type:"comma",value:P});x.commas++;continue}if(P===l&&R>0&&x.commas===0){const e=x.nodes;if(R===0||e.length===0){push({type:"text",value:P});continue}if(E.type==="dot"){x.range=[];E.value+=P;E.type="range";if(x.nodes.length!==3&&x.nodes.length!==5){x.invalid=true;x.ranges=0;E.type="text";continue}x.ranges++;x.args=[];continue}if(E.type==="range"){e.pop();const t=e[e.length-1];t.value+=E.value+P;E=t;x.ranges--;continue}push({type:"dot",value:P});continue}push({type:"text",value:P})}do{x=S.pop();if(x.type!=="root"){x.nodes.forEach((e=>{if(!e.nodes){if(e.type==="open")e.isOpen=true;if(e.type==="close")e.isClose=true;if(!e.nodes)e.type="text";e.invalid=true}}));const e=S[S.length-1];const t=e.nodes.indexOf(x);e.nodes.splice(t,1,...x.nodes)}}while(S.length>0);push({type:"eos"});return w};e.exports=parse},3317:(e,t,r)=>{"use strict";const i=r(2257);e.exports=(e,t={})=>{const stringify=(e,r={})=>{const n=t.escapeInvalid&&i.isInvalidBrace(r);const s=e.invalid===true&&t.escapeInvalid===true;let o="";if(e.value){if((n||s)&&i.isOpenOrClose(e)){return"\\"+e.value}return e.value}if(e.value){return e.value}if(e.nodes){for(const t of e.nodes){o+=stringify(t)}}return o};return stringify(e)}},2257:(e,t)=>{"use strict";t.isInteger=e=>{if(typeof e==="number"){return Number.isInteger(e)}if(typeof e==="string"&&e.trim()!==""){return Number.isInteger(Number(e))}return false};t.find=(e,t)=>e.nodes.find((e=>e.type===t));t.exceedsLimit=(e,r,i=1,n)=>{if(n===false)return false;if(!t.isInteger(e)||!t.isInteger(r))return false;return(Number(r)-Number(e))/Number(i)>=n};t.escapeNode=(e,t=0,r)=>{const i=e.nodes[t];if(!i)return;if(r&&i.type===r||i.type==="open"||i.type==="close"){if(i.escaped!==true){i.value="\\"+i.value;i.escaped=true}}};t.encloseBrace=e=>{if(e.type!=="brace")return false;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}return false};t.isInvalidBrace=e=>{if(e.type!=="brace")return false;if(e.invalid===true||e.dollar)return true;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}if(e.open!==true||e.close!==true){e.invalid=true;return true}return false};t.isOpenOrClose=e=>{if(e.type==="open"||e.type==="close"){return true}return e.open===true||e.close===true};t.reduce=e=>e.reduce(((e,t)=>{if(t.type==="text")e.push(t.value);if(t.type==="range")t.type="text";return e}),[]);t.flatten=(...e)=>{const t=[];const flat=e=>{for(let r=0;r<e.length;r++){const i=e[r];if(Array.isArray(i)){flat(i);continue}if(i!==undefined){t.push(i)}}return t};flat(e);return t}},465:(e,t,r)=>{"use strict";const i=r(4412);const{stdout:n,stderr:s}=r(1450);const{stringReplaceAll:o,stringEncaseCRLFWithFirstIndex:a}=r(8809);const{isArray:l}=Array;const u=["ansi","ansi","ansi256","ansi16m"];const h=Object.create(null);const applyOptions=(e,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3)){throw new Error("The `level` option should be an integer from 0 to 3")}const r=n?n.level:0;e.level=t.level===undefined?r:t.level};class ChalkClass{constructor(e){return chalkFactory(e)}}const chalkFactory=e=>{const t={};applyOptions(t,e);t.template=(...e)=>chalkTag(t.template,...e);Object.setPrototypeOf(t,Chalk.prototype);Object.setPrototypeOf(t.template,t);t.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")};t.template.Instance=ChalkClass;return t.template};function Chalk(e){return chalkFactory(e)}for(const[e,t]of Object.entries(i)){h[e]={get(){const r=createBuilder(this,createStyler(t.open,t.close,this._styler),this._isEmpty);Object.defineProperty(this,e,{value:r});return r}}}h.visible={get(){const e=createBuilder(this,this._styler,true);Object.defineProperty(this,"visible",{value:e});return e}};const f=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(const e of f){h[e]={get(){const{level:t}=this;return function(...r){const n=createStyler(i.color[u[t]][e](...r),i.color.close,this._styler);return createBuilder(this,n,this._isEmpty)}}}}for(const e of f){const t="bg"+e[0].toUpperCase()+e.slice(1);h[t]={get(){const{level:t}=this;return function(...r){const n=createStyler(i.bgColor[u[t]][e](...r),i.bgColor.close,this._styler);return createBuilder(this,n,this._isEmpty)}}}}const p=Object.defineProperties((()=>{}),{...h,level:{enumerable:true,get(){return this._generator.level},set(e){this._generator.level=e}}});const createStyler=(e,t,r)=>{let i;let n;if(r===undefined){i=e;n=t}else{i=r.openAll+e;n=t+r.closeAll}return{open:e,close:t,openAll:i,closeAll:n,parent:r}};const createBuilder=(e,t,r)=>{const builder=(...e)=>{if(l(e[0])&&l(e[0].raw)){return applyStyle(builder,chalkTag(builder,...e))}return applyStyle(builder,e.length===1?""+e[0]:e.join(" "))};Object.setPrototypeOf(builder,p);builder._generator=e;builder._styler=t;builder._isEmpty=r;return builder};const applyStyle=(e,t)=>{if(e.level<=0||!t){return e._isEmpty?"":t}let r=e._styler;if(r===undefined){return t}const{openAll:i,closeAll:n}=r;if(t.indexOf("")!==-1){while(r!==undefined){t=o(t,r.close,r.open);r=r.parent}}const s=t.indexOf("\n");if(s!==-1){t=a(t,n,i,s)}return i+t+n};let d;const chalkTag=(e,...t)=>{const[i]=t;if(!l(i)||!l(i.raw)){return t.join(" ")}const n=t.slice(1);const s=[i.raw[0]];for(let e=1;e<i.length;e++){s.push(String(n[e-1]).replace(/[{}\\]/g,"\\$&"),String(i.raw[e]))}if(d===undefined){d=r(4670)}return d(e,s.join(""))};Object.defineProperties(Chalk.prototype,h);const m=Chalk();m.supportsColor=n;m.stderr=Chalk({level:s?s.level:0});m.stderr.supportsColor=s;e.exports=m},4670:e=>{"use strict";const t=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi;const r=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g;const i=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/;const n=/\\(u(?:[a-f\d]{4}|{[a-f\d]{1,6}})|x[a-f\d]{2}|.)|([^\\])/gi;const s=new Map([["n","\n"],["r","\r"],["t","\t"],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e",""],["a",""]]);function unescape(e){const t=e[0]==="u";const r=e[1]==="{";if(t&&!r&&e.length===5||e[0]==="x"&&e.length===3){return String.fromCharCode(parseInt(e.slice(1),16))}if(t&&r){return String.fromCodePoint(parseInt(e.slice(2,-1),16))}return s.get(e)||e}function parseArguments(e,t){const r=[];const s=t.trim().split(/\s*,\s*/g);let o;for(const t of s){const s=Number(t);if(!Number.isNaN(s)){r.push(s)}else if(o=t.match(i)){r.push(o[2].replace(n,((e,t,r)=>t?unescape(t):r)))}else{throw new Error(`Invalid Chalk template style argument: ${t} (in style '${e}')`)}}return r}function parseStyle(e){r.lastIndex=0;const t=[];let i;while((i=r.exec(e))!==null){const e=i[1];if(i[2]){const r=parseArguments(e,i[2]);t.push([e].concat(r))}else{t.push([e])}}return t}function buildStyle(e,t){const r={};for(const e of t){for(const t of e.styles){r[t[0]]=e.inverse?null:t.slice(1)}}let i=e;for(const[e,t]of Object.entries(r)){if(!Array.isArray(t)){continue}if(!(e in i)){throw new Error(`Unknown Chalk style: ${e}`)}i=t.length>0?i[e](...t):i[e]}return i}e.exports=(e,r)=>{const i=[];const n=[];let s=[];r.replace(t,((t,r,o,a,l,u)=>{if(r){s.push(unescape(r))}else if(a){const t=s.join("");s=[];n.push(i.length===0?t:buildStyle(e,i)(t));i.push({inverse:o,styles:parseStyle(a)})}else if(l){if(i.length===0){throw new Error("Found extraneous } in Chalk template literal")}n.push(buildStyle(e,i)(s.join("")));s=[];i.pop()}else{s.push(u)}}));n.push(s.join(""));if(i.length>0){const e=`Chalk template literal is missing ${i.length} closing bracket${i.length===1?"":"s"} (\`}\`)`;throw new Error(e)}return n.join("")}},8809:e=>{"use strict";const stringReplaceAll=(e,t,r)=>{let i=e.indexOf(t);if(i===-1){return e}const n=t.length;let s=0;let o="";do{o+=e.substr(s,i-s)+t+r;s=i+n;i=e.indexOf(t,s)}while(i!==-1);o+=e.substr(s);return o};const stringEncaseCRLFWithFirstIndex=(e,t,r,i)=>{let n=0;let s="";do{const o=e[i-1]==="\r";s+=e.substr(n,(o?i-1:i)-n)+t+(o?"\r\n":"\n")+r;n=i+1;i=e.indexOf("\n",n)}while(i!==-1);s+=e.substr(n);return s};e.exports={stringReplaceAll:stringReplaceAll,stringEncaseCRLFWithFirstIndex:stringEncaseCRLFWithFirstIndex}},1687:(e,t,r)=>{"use strict";const i=r(4023);let n=false;t.show=(e=process.stderr)=>{if(!e.isTTY){return}n=false;e.write("[?25h")};t.hide=(e=process.stderr)=>{if(!e.isTTY){return}i();n=true;e.write("[?25l")};t.toggle=(e,r)=>{if(e!==undefined){n=e}if(n){t.show(r)}else{t.hide(r)}}},6487:(e,t,r)=>{"use strict";const i=Object.assign({},r(8629));const n=Object.keys(i);Object.defineProperty(i,"random",{get(){const e=Math.floor(Math.random()*n.length);const t=n[e];return i[t]}});e.exports=i},4980:e=>{var t=function(){"use strict";function clone(e,t,r,i){var n;if(typeof t==="object"){r=t.depth;i=t.prototype;n=t.filter;t=t.circular}var s=[];var o=[];var a=typeof Buffer!="undefined";if(typeof t=="undefined")t=true;if(typeof r=="undefined")r=Infinity;function _clone(e,r){if(e===null)return null;if(r==0)return e;var n;var l;if(typeof e!="object"){return e}if(clone.__isArray(e)){n=[]}else if(clone.__isRegExp(e)){n=new RegExp(e.source,__getRegExpFlags(e));if(e.lastIndex)n.lastIndex=e.lastIndex}else if(clone.__isDate(e)){n=new Date(e.getTime())}else if(a&&Buffer.isBuffer(e)){if(Buffer.allocUnsafe){n=Buffer.allocUnsafe(e.length)}else{n=new Buffer(e.length)}e.copy(n);return n}else{if(typeof i=="undefined"){l=Object.getPrototypeOf(e);n=Object.create(l)}else{n=Object.create(i);l=i}}if(t){var u=s.indexOf(e);if(u!=-1){return o[u]}s.push(e);o.push(n)}for(var h in e){var f;if(l){f=Object.getOwnPropertyDescriptor(l,h)}if(f&&f.set==null){continue}n[h]=_clone(e[h],r-1)}return n}return _clone(e,r)}clone.clonePrototype=function clonePrototype(e){if(e===null)return null;var c=function(){};c.prototype=e;return new c};function __objToStr(e){return Object.prototype.toString.call(e)}clone.__objToStr=__objToStr;function __isDate(e){return typeof e==="object"&&__objToStr(e)==="[object Date]"}clone.__isDate=__isDate;function __isArray(e){return typeof e==="object"&&__objToStr(e)==="[object Array]"}clone.__isArray=__isArray;function __isRegExp(e){return typeof e==="object"&&__objToStr(e)==="[object RegExp]"}clone.__isRegExp=__isRegExp;function __getRegExpFlags(e){var t="";if(e.global)t+="g";if(e.ignoreCase)t+="i";if(e.multiline)t+="m";return t}clone.__getRegExpFlags=__getRegExpFlags;return clone}();if(true&&e.exports){e.exports=t}},6872:(e,t,r)=>{const i=r(4953);const n={};for(const e of Object.keys(i)){n[i[e]]=e}const s={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=s;for(const e of Object.keys(s)){if(!("channels"in s[e])){throw new Error("missing channels property: "+e)}if(!("labels"in s[e])){throw new Error("missing channel labels property: "+e)}if(s[e].labels.length!==s[e].channels){throw new Error("channel and label counts mismatch: "+e)}const{channels:t,labels:r}=s[e];delete s[e].channels;delete s[e].labels;Object.defineProperty(s[e],"channels",{value:t});Object.defineProperty(s[e],"labels",{value:r})}s.rgb.hsl=function(e){const t=e[0]/255;const r=e[1]/255;const i=e[2]/255;const n=Math.min(t,r,i);const s=Math.max(t,r,i);const o=s-n;let a;let l;if(s===n){a=0}else if(t===s){a=(r-i)/o}else if(r===s){a=2+(i-t)/o}else if(i===s){a=4+(t-r)/o}a=Math.min(a*60,360);if(a<0){a+=360}const u=(n+s)/2;if(s===n){l=0}else if(u<=.5){l=o/(s+n)}else{l=o/(2-s-n)}return[a,l*100,u*100]};s.rgb.hsv=function(e){let t;let r;let i;let n;let s;const o=e[0]/255;const a=e[1]/255;const l=e[2]/255;const u=Math.max(o,a,l);const h=u-Math.min(o,a,l);const diffc=function(e){return(u-e)/6/h+1/2};if(h===0){n=0;s=0}else{s=h/u;t=diffc(o);r=diffc(a);i=diffc(l);if(o===u){n=i-r}else if(a===u){n=1/3+t-i}else if(l===u){n=2/3+r-t}if(n<0){n+=1}else if(n>1){n-=1}}return[n*360,s*100,u*100]};s.rgb.hwb=function(e){const t=e[0];const r=e[1];let i=e[2];const n=s.rgb.hsl(e)[0];const o=1/255*Math.min(t,Math.min(r,i));i=1-1/255*Math.max(t,Math.max(r,i));return[n,o*100,i*100]};s.rgb.cmyk=function(e){const t=e[0]/255;const r=e[1]/255;const i=e[2]/255;const n=Math.min(1-t,1-r,1-i);const s=(1-t-n)/(1-n)||0;const o=(1-r-n)/(1-n)||0;const a=(1-i-n)/(1-n)||0;return[s*100,o*100,a*100,n*100]};function comparativeDistance(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}s.rgb.keyword=function(e){const t=n[e];if(t){return t}let r=Infinity;let s;for(const t of Object.keys(i)){const n=i[t];const o=comparativeDistance(e,n);if(o<r){r=o;s=t}}return s};s.keyword.rgb=function(e){return i[e]};s.rgb.xyz=function(e){let t=e[0]/255;let r=e[1]/255;let i=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92;r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;i=i>.04045?((i+.055)/1.055)**2.4:i/12.92;const n=t*.4124+r*.3576+i*.1805;const s=t*.2126+r*.7152+i*.0722;const o=t*.0193+r*.1192+i*.9505;return[n*100,s*100,o*100]};s.rgb.lab=function(e){const t=s.rgb.xyz(e);let r=t[0];let i=t[1];let n=t[2];r/=95.047;i/=100;n/=108.883;r=r>.008856?r**(1/3):7.787*r+16/116;i=i>.008856?i**(1/3):7.787*i+16/116;n=n>.008856?n**(1/3):7.787*n+16/116;const o=116*i-16;const a=500*(r-i);const l=200*(i-n);return[o,a,l]};s.hsl.rgb=function(e){const t=e[0]/360;const r=e[1]/100;const i=e[2]/100;let n;let s;let o;if(r===0){o=i*255;return[o,o,o]}if(i<.5){n=i*(1+r)}else{n=i+r-i*r}const a=2*i-n;const l=[0,0,0];for(let e=0;e<3;e++){s=t+1/3*-(e-1);if(s<0){s++}if(s>1){s--}if(6*s<1){o=a+(n-a)*6*s}else if(2*s<1){o=n}else if(3*s<2){o=a+(n-a)*(2/3-s)*6}else{o=a}l[e]=o*255}return l};s.hsl.hsv=function(e){const t=e[0];let r=e[1]/100;let i=e[2]/100;let n=r;const s=Math.max(i,.01);i*=2;r*=i<=1?i:2-i;n*=s<=1?s:2-s;const o=(i+r)/2;const a=i===0?2*n/(s+n):2*r/(i+r);return[t,a*100,o*100]};s.hsv.rgb=function(e){const t=e[0]/60;const r=e[1]/100;let i=e[2]/100;const n=Math.floor(t)%6;const s=t-Math.floor(t);const o=255*i*(1-r);const a=255*i*(1-r*s);const l=255*i*(1-r*(1-s));i*=255;switch(n){case 0:return[i,l,o];case 1:return[a,i,o];case 2:return[o,i,l];case 3:return[o,a,i];case 4:return[l,o,i];case 5:return[i,o,a]}};s.hsv.hsl=function(e){const t=e[0];const r=e[1]/100;const i=e[2]/100;const n=Math.max(i,.01);let s;let o;o=(2-r)*i;const a=(2-r)*n;s=r*n;s/=a<=1?a:2-a;s=s||0;o/=2;return[t,s*100,o*100]};s.hwb.rgb=function(e){const t=e[0]/360;let r=e[1]/100;let i=e[2]/100;const n=r+i;let s;if(n>1){r/=n;i/=n}const o=Math.floor(6*t);const a=1-i;s=6*t-o;if((o&1)!==0){s=1-s}const l=r+s*(a-r);let u;let h;let f;switch(o){default:case 6:case 0:u=a;h=l;f=r;break;case 1:u=l;h=a;f=r;break;case 2:u=r;h=a;f=l;break;case 3:u=r;h=l;f=a;break;case 4:u=l;h=r;f=a;break;case 5:u=a;h=r;f=l;break}return[u*255,h*255,f*255]};s.cmyk.rgb=function(e){const t=e[0]/100;const r=e[1]/100;const i=e[2]/100;const n=e[3]/100;const s=1-Math.min(1,t*(1-n)+n);const o=1-Math.min(1,r*(1-n)+n);const a=1-Math.min(1,i*(1-n)+n);return[s*255,o*255,a*255]};s.xyz.rgb=function(e){const t=e[0]/100;const r=e[1]/100;const i=e[2]/100;let n;let s;let o;n=t*3.2406+r*-1.5372+i*-.4986;s=t*-.9689+r*1.8758+i*.0415;o=t*.0557+r*-.204+i*1.057;n=n>.0031308?1.055*n**(1/2.4)-.055:n*12.92;s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92;o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92;n=Math.min(Math.max(0,n),1);s=Math.min(Math.max(0,s),1);o=Math.min(Math.max(0,o),1);return[n*255,s*255,o*255]};s.xyz.lab=function(e){let t=e[0];let r=e[1];let i=e[2];t/=95.047;r/=100;i/=108.883;t=t>.008856?t**(1/3):7.787*t+16/116;r=r>.008856?r**(1/3):7.787*r+16/116;i=i>.008856?i**(1/3):7.787*i+16/116;const n=116*r-16;const s=500*(t-r);const o=200*(r-i);return[n,s,o]};s.lab.xyz=function(e){const t=e[0];const r=e[1];const i=e[2];let n;let s;let o;s=(t+16)/116;n=r/500+s;o=s-i/200;const a=s**3;const l=n**3;const u=o**3;s=a>.008856?a:(s-16/116)/7.787;n=l>.008856?l:(n-16/116)/7.787;o=u>.008856?u:(o-16/116)/7.787;n*=95.047;s*=100;o*=108.883;return[n,s,o]};s.lab.lch=function(e){const t=e[0];const r=e[1];const i=e[2];let n;const s=Math.atan2(i,r);n=s*360/2/Math.PI;if(n<0){n+=360}const o=Math.sqrt(r*r+i*i);return[t,o,n]};s.lch.lab=function(e){const t=e[0];const r=e[1];const i=e[2];const n=i/360*2*Math.PI;const s=r*Math.cos(n);const o=r*Math.sin(n);return[t,s,o]};s.rgb.ansi16=function(e,t=null){const[r,i,n]=e;let o=t===null?s.rgb.hsv(e)[2]:t;o=Math.round(o/50);if(o===0){return 30}let a=30+(Math.round(n/255)<<2|Math.round(i/255)<<1|Math.round(r/255));if(o===2){a+=60}return a};s.hsv.ansi16=function(e){return s.rgb.ansi16(s.hsv.rgb(e),e[2])};s.rgb.ansi256=function(e){const t=e[0];const r=e[1];const i=e[2];if(t===r&&r===i){if(t<8){return 16}if(t>248){return 231}return Math.round((t-8)/247*24)+232}const n=16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(i/255*5);return n};s.ansi16.rgb=function(e){let t=e%10;if(t===0||t===7){if(e>50){t+=3.5}t=t/10.5*255;return[t,t,t]}const r=(~~(e>50)+1)*.5;const i=(t&1)*r*255;const n=(t>>1&1)*r*255;const s=(t>>2&1)*r*255;return[i,n,s]};s.ansi256.rgb=function(e){if(e>=232){const t=(e-232)*10+8;return[t,t,t]}e-=16;let t;const r=Math.floor(e/36)/5*255;const i=Math.floor((t=e%36)/6)/5*255;const n=t%6/5*255;return[r,i,n]};s.rgb.hex=function(e){const t=((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255);const r=t.toString(16).toUpperCase();return"000000".substring(r.length)+r};s.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t){return[0,0,0]}let r=t[0];if(t[0].length===3){r=r.split("").map((e=>e+e)).join("")}const i=parseInt(r,16);const n=i>>16&255;const s=i>>8&255;const o=i&255;return[n,s,o]};s.rgb.hcg=function(e){const t=e[0]/255;const r=e[1]/255;const i=e[2]/255;const n=Math.max(Math.max(t,r),i);const s=Math.min(Math.min(t,r),i);const o=n-s;let a;let l;if(o<1){a=s/(1-o)}else{a=0}if(o<=0){l=0}else if(n===t){l=(r-i)/o%6}else if(n===r){l=2+(i-t)/o}else{l=4+(t-r)/o}l/=6;l%=1;return[l*360,o*100,a*100]};s.hsl.hcg=function(e){const t=e[1]/100;const r=e[2]/100;const i=r<.5?2*t*r:2*t*(1-r);let n=0;if(i<1){n=(r-.5*i)/(1-i)}return[e[0],i*100,n*100]};s.hsv.hcg=function(e){const t=e[1]/100;const r=e[2]/100;const i=t*r;let n=0;if(i<1){n=(r-i)/(1-i)}return[e[0],i*100,n*100]};s.hcg.rgb=function(e){const t=e[0]/360;const r=e[1]/100;const i=e[2]/100;if(r===0){return[i*255,i*255,i*255]}const n=[0,0,0];const s=t%1*6;const o=s%1;const a=1-o;let l=0;switch(Math.floor(s)){case 0:n[0]=1;n[1]=o;n[2]=0;break;case 1:n[0]=a;n[1]=1;n[2]=0;break;case 2:n[0]=0;n[1]=1;n[2]=o;break;case 3:n[0]=0;n[1]=a;n[2]=1;break;case 4:n[0]=o;n[1]=0;n[2]=1;break;default:n[0]=1;n[1]=0;n[2]=a}l=(1-r)*i;return[(r*n[0]+l)*255,(r*n[1]+l)*255,(r*n[2]+l)*255]};s.hcg.hsv=function(e){const t=e[1]/100;const r=e[2]/100;const i=t+r*(1-t);let n=0;if(i>0){n=t/i}return[e[0],n*100,i*100]};s.hcg.hsl=function(e){const t=e[1]/100;const r=e[2]/100;const i=r*(1-t)+.5*t;let n=0;if(i>0&&i<.5){n=t/(2*i)}else if(i>=.5&&i<1){n=t/(2*(1-i))}return[e[0],n*100,i*100]};s.hcg.hwb=function(e){const t=e[1]/100;const r=e[2]/100;const i=t+r*(1-t);return[e[0],(i-t)*100,(1-i)*100]};s.hwb.hcg=function(e){const t=e[1]/100;const r=e[2]/100;const i=1-r;const n=i-t;let s=0;if(n<1){s=(i-n)/(1-n)}return[e[0],n*100,s*100]};s.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};s.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};s.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};s.gray.hsl=function(e){return[0,0,e[0]]};s.gray.hsv=s.gray.hsl;s.gray.hwb=function(e){return[0,100,e[0]]};s.gray.cmyk=function(e){return[0,0,0,e[0]]};s.gray.lab=function(e){return[e[0],0,0]};s.gray.hex=function(e){const t=Math.round(e[0]/100*255)&255;const r=(t<<16)+(t<<8)+t;const i=r.toString(16).toUpperCase();return"000000".substring(i.length)+i};s.rgb.gray=function(e){const t=(e[0]+e[1]+e[2])/3;return[t/255*100]}},4185:(e,t,r)=>{const i=r(6872);const n=r(4200);const s={};const o=Object.keys(i);function wrapRaw(e){const wrappedFn=function(...t){const r=t[0];if(r===undefined||r===null){return r}if(r.length>1){t=r}return e(t)};if("conversion"in e){wrappedFn.conversion=e.conversion}return wrappedFn}function wrapRounded(e){const wrappedFn=function(...t){const r=t[0];if(r===undefined||r===null){return r}if(r.length>1){t=r}const i=e(t);if(typeof i==="object"){for(let e=i.length,t=0;t<e;t++){i[t]=Math.round(i[t])}}return i};if("conversion"in e){wrappedFn.conversion=e.conversion}return wrappedFn}o.forEach((e=>{s[e]={};Object.defineProperty(s[e],"channels",{value:i[e].channels});Object.defineProperty(s[e],"labels",{value:i[e].labels});const t=n(e);const r=Object.keys(t);r.forEach((r=>{const i=t[r];s[e][r]=wrapRounded(i);s[e][r].raw=wrapRaw(i)}))}));e.exports=s},4200:(e,t,r)=>{const i=r(6872);function buildGraph(){const e={};const t=Object.keys(i);for(let r=t.length,i=0;i<r;i++){e[t[i]]={distance:-1,parent:null}}return e}function deriveBFS(e){const t=buildGraph();const r=[e];t[e].distance=0;while(r.length){const e=r.pop();const n=Object.keys(i[e]);for(let i=n.length,s=0;s<i;s++){const i=n[s];const o=t[i];if(o.distance===-1){o.distance=t[e].distance+1;o.parent=e;r.unshift(i)}}}return t}function link(e,t){return function(r){return t(e(r))}}function wrapConversion(e,t){const r=[t[e].parent,e];let n=i[t[e].parent][e];let s=t[e].parent;while(t[s].parent){r.unshift(t[s].parent);n=link(i[t[s].parent][s],n);s=t[s].parent}n.conversion=r;return n}e.exports=function(e){const t=deriveBFS(e);const r={};const i=Object.keys(t);for(let e=i.length,n=0;n<e;n++){const e=i[n];const s=t[e];if(s.parent===null){continue}r[e]=wrapConversion(e,t)}return r}},4953:e=>{"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},546:(e,t,r)=>{"use strict";const i=r(5317);const n=r(7877);const s=r(6469);function spawn(e,t,r){const o=n(e,t,r);const a=i.spawn(o.command,o.args,o.options);s.hookChildProcess(a,o);return a}function spawnSync(e,t,r){const o=n(e,t,r);const a=i.spawnSync(o.command,o.args,o.options);a.error=a.error||s.verifyENOENTSync(a.status,o);return a}e.exports=spawn;e.exports.spawn=spawn;e.exports.sync=spawnSync;e.exports._parse=n;e.exports._enoent=s},6469:e=>{"use strict";const t=process.platform==="win32";function notFoundError(e,t){return Object.assign(new Error(`${t} ${e.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t} ${e.command}`,path:e.command,spawnargs:e.args})}function hookChildProcess(e,r){if(!t){return}const i=e.emit;e.emit=function(t,n){if(t==="exit"){const t=verifyENOENT(n,r);if(t){return i.call(e,"error",t)}}return i.apply(e,arguments)}}function verifyENOENT(e,r){if(t&&e===1&&!r.file){return notFoundError(r.original,"spawn")}return null}function verifyENOENTSync(e,r){if(t&&e===1&&!r.file){return notFoundError(r.original,"spawnSync")}return null}e.exports={hookChildProcess:hookChildProcess,verifyENOENT:verifyENOENT,verifyENOENTSync:verifyENOENTSync,notFoundError:notFoundError}},7877:(e,t,r)=>{"use strict";const i=r(6928);const n=r(4866);const s=r(2164);const o=r(599);const a=process.platform==="win32";const l=/\.(?:com|exe)$/i;const u=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function detectShebang(e){e.file=n(e);const t=e.file&&o(e.file);if(t){e.args.unshift(e.file);e.command=t;return n(e)}return e.file}function parseNonShell(e){if(!a){return e}const t=detectShebang(e);const r=!l.test(t);if(e.options.forceShell||r){const r=u.test(t);e.command=i.normalize(e.command);e.command=s.command(e.command);e.args=e.args.map((e=>s.argument(e,r)));const n=[e.command].concat(e.args).join(" ");e.args=["/d","/s","/c",`"${n}"`];e.command=process.env.comspec||"cmd.exe";e.options.windowsVerbatimArguments=true}return e}function parse(e,t,r){if(t&&!Array.isArray(t)){r=t;t=null}t=t?t.slice(0):[];r=Object.assign({},r);const i={command:e,args:t,options:r,file:undefined,original:{command:e,args:t}};return r.shell?i:parseNonShell(i)}e.exports=parse},2164:e=>{"use strict";const t=/([()\][%!^"`<>&|;, *?])/g;function escapeCommand(e){e=e.replace(t,"^$1");return e}function escapeArgument(e,r){e=`${e}`;e=e.replace(/(?=(\\+?)?)\1"/g,'$1$1\\"');e=e.replace(/(?=(\\+?)?)\1$/,"$1$1");e=`"${e}"`;e=e.replace(t,"^$1");if(r){e=e.replace(t,"^$1")}return e}e.exports.command=escapeCommand;e.exports.argument=escapeArgument},599:(e,t,r)=>{"use strict";const i=r(9896);const n=r(9152);function readShebang(e){const t=150;const r=Buffer.alloc(t);let s;try{s=i.openSync(e,"r");i.readSync(s,r,0,t,0);i.closeSync(s)}catch(e){}return n(r.toString())}e.exports=readShebang},4866:(e,t,r)=>{"use strict";const i=r(6928);const n=r(6848);const s=r(6689);function resolveCommandAttempt(e,t){const r=e.options.env||process.env;const o=process.cwd();const a=e.options.cwd!=null;const l=a&&process.chdir!==undefined&&!process.chdir.disabled;if(l){try{process.chdir(e.options.cwd)}catch(e){}}let u;try{u=n.sync(e.command,{path:r[s({env:r})],pathExt:t?i.delimiter:undefined})}catch(e){}finally{if(l){process.chdir(o)}}if(u){u=i.resolve(a?e.options.cwd:"",u)}return u}function resolveCommand(e){return resolveCommandAttempt(e)||resolveCommandAttempt(e,true)}e.exports=resolveCommand},7730:(e,t,r)=>{var i=r(4980);e.exports=function(e,t){e=e||{};Object.keys(t).forEach((function(r){if(typeof e[r]==="undefined"){e[r]=i(t[r])}}));return e}},9973:(e,t,r)=>{"use strict";const i=r(2613);const n=r(4434);const s=r(6600);class Enquirer extends n{constructor(e,t){super();this.options=s.merge({},e);this.answers={...t}}register(e,t){if(s.isObject(e)){for(let t of Object.keys(e))this.register(t,e[t]);return this}i.equal(typeof t,"function","expected a function");const r=e.toLowerCase();if(t.prototype instanceof this.Prompt){this.prompts[r]=t}else{this.prompts[r]=t(this.Prompt,this)}return this}async prompt(e=[]){for(let t of[].concat(e)){try{if(typeof t==="function")t=await t.call(this);await this.ask(s.merge({},this.options,t))}catch(e){return Promise.reject(e)}}return this.answers}async ask(e){if(typeof e==="function"){e=await e.call(this)}let t=s.merge({},this.options,e);let{type:r,name:n}=e;let{set:o,get:a}=s;if(typeof r==="function"){r=await r.call(this,e,this.answers)}if(!r)return this.answers[n];if(r==="number")r="numeral";i(this.prompts[r],`Prompt "${r}" is not registered`);let l=new this.prompts[r](t);let u=a(this.answers,n);l.state.answers=this.answers;l.enquirer=this;if(n){l.on("submit",(e=>{this.emit("answer",n,e,l);o(this.answers,n,e)}))}let h=l.emit.bind(l);l.emit=(...e)=>{this.emit.call(this,...e);return h(...e)};this.emit("prompt",l,this);if(t.autofill&&u!=null){l.value=l.input=u;if(t.autofill==="show"){await l.submit()}}else{u=l.value=await l.run()}return u}use(e){e.call(this,this);return this}set Prompt(e){this._Prompt=e}get Prompt(){return this._Prompt||this.constructor.Prompt}get prompts(){return this.constructor.prompts}static set Prompt(e){this._Prompt=e}static get Prompt(){return this._Prompt||r(379)}static get prompts(){return r(2637)}static get types(){return r(8075)}static get prompt(){const fn=(e,...t)=>{let r=new this(...t);let i=r.emit.bind(r);r.emit=(...e)=>{fn.emit(...e);return i(...e)};return r.prompt(e)};s.mixinEmitter(fn,new n);return fn}}s.mixinEmitter(Enquirer,new n);const o=Enquirer.prompts;for(let e of Object.keys(o)){let t=e.toLowerCase();let run=t=>new o[e](t).run();Enquirer.prompt[t]=run;Enquirer[t]=run;if(!Enquirer[e]){Reflect.defineProperty(Enquirer,e,{get:()=>o[e]})}}const define=e=>{s.defineExport(Enquirer,e,(()=>Enquirer.types[e]))};define("ArrayPrompt");define("AuthPrompt");define("BooleanPrompt");define("NumberPrompt");define("StringPrompt");e.exports=Enquirer},4102:(e,t,r)=>{"use strict";const i=process.env.TERM_PROGRAM==="Apple_Terminal";const n=r(3958);const s=r(6600);const o=e.exports=t;const a="[";const l="";let u=false;const h=o.code={bell:l,beep:l,beginning:`${a}G`,down:`${a}J`,esc:a,getPosition:`${a}6n`,hide:`${a}?25l`,line:`${a}2K`,lineEnd:`${a}K`,lineStart:`${a}1K`,restorePosition:a+(i?"8":"u"),savePosition:a+(i?"7":"s"),screen:`${a}2J`,show:`${a}?25h`,up:`${a}1J`};const f=o.cursor={get hidden(){return u},hide(){u=true;return h.hide},show(){u=false;return h.show},forward:(e=1)=>`${a}${e}C`,backward:(e=1)=>`${a}${e}D`,nextLine:(e=1)=>`${a}E`.repeat(e),prevLine:(e=1)=>`${a}F`.repeat(e),up:(e=1)=>e?`${a}${e}A`:"",down:(e=1)=>e?`${a}${e}B`:"",right:(e=1)=>e?`${a}${e}C`:"",left:(e=1)=>e?`${a}${e}D`:"",to(e,t){return t?`${a}${t+1};${e+1}H`:`${a}${e+1}G`},move(e=0,t=0){let r="";r+=e<0?f.left(-e):e>0?f.right(e):"";r+=t<0?f.up(-t):t>0?f.down(t):"";return r},strLen(e){var t=0,r=e.length,i=-1;for(var n=0;n<r;n++){i=e.charCodeAt(n);if(i>=0&&i<=128)t+=1;else t+=2}return t},restore(e={}){let{after:t,cursor:r,initial:i,input:n,prompt:a,size:l,value:u}=e;i=s.isPrimitive(i)?String(i):"";n=s.isPrimitive(n)?String(n):"";u=s.isPrimitive(u)?String(u):"";if(l){let e=o.cursor.up(l)+o.cursor.to(this.strLen(a));let t=n.length-r;if(t>0){e+=o.cursor.left(t)}return e}if(u||t){let e=!n&&!!i?-this.strLen(i):-this.strLen(n)+r;if(t)e-=this.strLen(t);if(n===""&&i&&!a.includes(i)){e+=this.strLen(i)}return o.cursor.move(e)}}};const p=o.erase={screen:h.screen,up:h.up,down:h.down,line:h.line,lineEnd:h.lineEnd,lineStart:h.lineStart,lines(e){let t="";for(let r=0;r<e;r++){t+=o.erase.line+(r<e-1?o.cursor.up(1):"")}if(e)t+=o.code.beginning;return t}};o.clear=(e="",t=process.stdout.columns)=>{if(!t)return p.line+f.to(0);let width=e=>[...n(e)].length;let r=e.split(/\r?\n/);let i=0;for(let e of r){i+=1+Math.floor(Math.max(width(e)-1,0)/t)}return(p.line+f.prevLine()).repeat(i-1)+p.line+f.to(0)}},1946:(e,t)=>{"use strict";t.ctrl={a:"first",b:"backward",c:"cancel",d:"deleteForward",e:"last",f:"forward",g:"reset",i:"tab",k:"cutForward",l:"reset",n:"newItem",m:"cancel",j:"submit",p:"search",r:"remove",s:"save",u:"undo",w:"cutLeft",x:"toggleCursor",v:"paste"};t.shift={up:"shiftUp",down:"shiftDown",left:"shiftLeft",right:"shiftRight",tab:"prev"};t.fn={up:"pageUp",down:"pageDown",left:"pageLeft",right:"pageRight",delete:"deleteForward"};t.option={b:"backward",f:"forward",d:"cutRight",left:"cutLeft",up:"altUp",down:"altDown"};t.keys={pageup:"pageUp",pagedown:"pageDown",home:"home",end:"end",cancel:"cancel",delete:"deleteForward",backspace:"delete",down:"down",enter:"submit",escape:"cancel",left:"left",space:"space",number:"number",return:"submit",right:"right",tab:"next",up:"up"}},1606:e=>{"use strict";const unique=e=>e.filter(((t,r)=>e.lastIndexOf(t)===r));const compact=e=>unique(e).filter(Boolean);e.exports=(e,t={},r="")=>{let{past:i=[],present:n=""}=t;let s,o;switch(e){case"prev":case"undo":s=i.slice(0,i.length-1);o=i[i.length-1]||"";return{past:compact([r,...s]),present:o};case"next":case"redo":s=i.slice(1);o=i[0]||"";return{past:compact([...s,r]),present:o};case"save":return{past:compact([...i,r]),present:""};case"remove":o=compact(i.filter((e=>e!==r)));n="";if(o.length){n=o.pop()}return{past:o,present:n};default:{throw new Error(`Invalid action: "${e}"`)}}}},6454:(e,t,r)=>{"use strict";const i=r(3958);const clean=(e="")=>typeof e==="string"?e.replace(/^['"]|['"]$/g,""):"";class Item{constructor(e){this.name=e.key;this.field=e.field||{};this.value=clean(e.initial||this.field.initial||"");this.message=e.message||this.name;this.cursor=0;this.input="";this.lines=[]}}const tokenize=async(e={},t={},r=e=>e)=>{let i=new Set;let n=e.fields||[];let s=e.template;let o=[];let a=[];let l=[];let u=1;if(typeof s==="function"){s=await s()}let h=-1;let next=()=>s[++h];let peek=()=>s[h+1];let push=e=>{e.line=u;o.push(e)};push({type:"bos",value:""});while(h<s.length-1){let e=next();if(/^[^\S\n ]$/.test(e)){push({type:"text",value:e});continue}if(e==="\n"){push({type:"newline",value:e});u++;continue}if(e==="\\"){e+=next();push({type:"text",value:e});continue}if((e==="$"||e==="#"||e==="{")&&peek()==="{"){let s=next();e+=s;let o={type:"template",open:e,inner:"",close:"",value:e};let u;while(u=next()){if(u==="}"){if(peek()==="}")u+=next();o.value+=u;o.close=u;break}if(u===":"){o.initial="";o.key=o.inner}else if(o.initial!==void 0){o.initial+=u}o.value+=u;o.inner+=u}o.template=o.open+(o.initial||o.inner)+o.close;o.key=o.key||o.inner;if(hasOwnProperty.call(t,o.key)){o.initial=t[o.key]}o=r(o);push(o);l.push(o.key);i.add(o.key);let h=a.find((e=>e.name===o.key));o.field=n.find((e=>e.name===o.key));if(!h){h=new Item(o);a.push(h)}h.lines.push(o.line-1);continue}let s=o[o.length-1];if(s.type==="text"&&s.line===u){s.value+=e}else{push({type:"text",value:e})}}push({type:"eos",value:""});return{input:s,tabstops:o,unique:i,keys:l,items:a}};e.exports=async e=>{let t=e.options;let r=new Set(t.required===true?[]:t.required||[]);let n={...t.values,...t.initial};let{tabstops:s,items:o,keys:a}=await tokenize(t,n);let l=createFn("result",e,t);let u=createFn("format",e,t);let h=createFn("validate",e,t,true);let f=e.isValue.bind(e);return async(n={},p=false)=>{let d=0;n.required=r;n.items=o;n.keys=a;n.output="";let validate=async(e,t,r,i)=>{let n=await h(e,t,r,i);if(n===false){return"Invalid field "+r.name}return n};for(let r of s){let s=r.value;let a=r.key;if(r.type!=="template"){if(s)n.output+=s;continue}if(r.type==="template"){let h=o.find((e=>e.name===a));if(t.required===true){n.required.add(h.name)}let m=[h.input,n.values[h.value],h.value,s].find(f);let g=h.field||{};let y=g.message||r.inner;if(p){let e=await validate(n.values[a],n,h,d);if(e&&typeof e==="string"||e===false){n.invalid.set(a,e);continue}n.invalid.delete(a);let t=await l(n.values[a],n,h,d);n.output+=i(t);continue}h.placeholder=false;let b=s;s=await u(s,n,h,d);if(m!==s){n.values[a]=m;s=e.styles.typing(m);n.missing.delete(y)}else{n.values[a]=void 0;m=`<${y}>`;s=e.styles.primary(m);h.placeholder=true;if(n.required.has(a)){n.missing.add(y)}}if(n.missing.has(y)&&n.validating){s=e.styles.warning(m)}if(n.invalid.has(a)&&n.validating){s=e.styles.danger(m)}if(d===n.index){if(b!==s){s=e.styles.underline(s)}else{s=e.styles.heading(i(s))}}d++}if(s){n.output+=s}}let m=n.output.split("\n").map((e=>" "+e));let g=o.length;let y=0;for(let t of o){if(n.invalid.has(t.name)){t.lines.forEach((e=>{if(m[e][0]!==" ")return;m[e]=n.styles.danger(n.symbols.bullet)+m[e].slice(1)}))}if(e.isValue(n.values[t.name])){y++}}n.completed=(y/g*100).toFixed(0);n.output=m.join("\n");return n.output}};function createFn(e,t,r,i){return(r,n,s,o)=>{if(typeof s.field[e]==="function"){return s.field[e].call(t,r,n,s,o)}return[i,r].find((e=>t.isValue(e)))}}},3491:(e,t,r)=>{"use strict";const i=r(3785);const n=r(1946);const s=r(8290);const o=/^(?:\x1b)([a-zA-Z0-9])$/;const a=/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/;const l={OP:"f1",OQ:"f2",OR:"f3",OS:"f4","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[A":"up","[B":"down","[C":"right","[D":"left","[E":"clear","[F":"end","[H":"home",OA:"up",OB:"down",OC:"right",OD:"left",OE:"clear",OF:"end",OH:"home","[1~":"home","[2~":"insert","[3~":"delete","[4~":"end","[5~":"pageup","[6~":"pagedown","[[5~":"pageup","[[6~":"pagedown","[7~":"home","[8~":"end","[a":"up","[b":"down","[c":"right","[d":"left","[e":"clear","[2$":"insert","[3$":"delete","[5$":"pageup","[6$":"pagedown","[7$":"home","[8$":"end",Oa:"up",Ob:"down",Oc:"right",Od:"left",Oe:"clear","[2^":"insert","[3^":"delete","[5^":"pageup","[6^":"pagedown","[7^":"home","[8^":"end","[Z":"tab"};function isShiftKey(e){return["[a","[b","[c","[d","[e","[2$","[3$","[5$","[6$","[7$","[8$","[Z"].includes(e)}function isCtrlKey(e){return["Oa","Ob","Oc","Od","Oe","[2^","[3^","[5^","[6^","[7^","[8^"].includes(e)}const keypress=(e="",t={})=>{let r;let i={name:t.name,ctrl:false,meta:false,shift:false,option:false,sequence:e,raw:e,...t};if(Buffer.isBuffer(e)){if(e[0]>127&&e[1]===void 0){e[0]-=128;e=""+String(e)}else{e=String(e)}}else if(e!==void 0&&typeof e!=="string"){e=String(e)}else if(!e){e=i.sequence||""}i.sequence=i.sequence||e||i.name;if(e==="\r"){i.raw=void 0;i.name="return"}else if(e==="\n"){i.name="enter"}else if(e==="\t"){i.name="tab"}else if(e==="\b"||e===""||e===""||e==="\b"){i.name="backspace";i.meta=e.charAt(0)===""}else if(e===""||e===""){i.name="escape";i.meta=e.length===2}else if(e===" "||e===" "){i.name="space";i.meta=e.length===2}else if(e<=""){i.name=String.fromCharCode(e.charCodeAt(0)+"a".charCodeAt(0)-1);i.ctrl=true}else if(e.length===1&&e>="0"&&e<="9"){i.name="number"}else if(e.length===1&&e>="a"&&e<="z"){i.name=e}else if(e.length===1&&e>="A"&&e<="Z"){i.name=e.toLowerCase();i.shift=true}else if(r=o.exec(e)){i.meta=true;i.shift=/^[A-Z]$/.test(r[1])}else if(r=a.exec(e)){let t=[...e];if(t[0]===""&&t[1]===""){i.option=true}let n=[r[1],r[2],r[4],r[6]].filter(Boolean).join("");let s=(r[3]||r[5]||1)-1;i.ctrl=!!(s&4);i.meta=!!(s&10);i.shift=!!(s&1);i.code=n;i.name=l[n];i.shift=isShiftKey(n)||i.shift;i.ctrl=isCtrlKey(n)||i.ctrl}return i};keypress.listen=(e={},t)=>{let{stdin:r}=e;if(!r||r!==process.stdin&&!r.isTTY){throw new Error("Invalid stream passed")}let n=i.createInterface({terminal:true,input:r});i.emitKeypressEvents(r,n);const o=new s(((e,r)=>t(e,keypress(e,r),n)));let a=r.isRaw;if(r.isTTY)r.setRawMode(true);r.on("keypress",o.enqueue);n.resume();let off=()=>{if(r.isTTY)r.setRawMode(a);r.removeListener("keypress",o.enqueue);o.destroy();n.pause();n.close()};return off};keypress.action=(e,t,r)=>{let i={...n,...r};if(t.ctrl){t.action=i.ctrl[t.name];return t}if(t.option&&i.option){t.action=i.option[t.name];return t}if(t.shift){t.action=i.shift[t.name];return t}t.action=i.keys[t.name];return t};e.exports=keypress},2768:(e,t,r)=>{"use strict";const i=r(6600);e.exports=(e,t={})=>{e.cursorHide();let{input:r="",initial:n="",pos:s,showCursor:o=true,color:a}=t;let l=a||e.styles.placeholder;let u=i.inverse(e.styles.primary);let blinker=t=>u(e.styles.black(t));let h=r;let f=" ";let p=blinker(f);if(e.blink&&e.blink.off===true){blinker=e=>e;p=""}if(o&&s===0&&n===""&&r===""){return blinker(f)}if(o&&s===0&&(r===n||r==="")){return blinker(n[0])+l(n.slice(1))}n=i.isPrimitive(n)?`${n}`:"";r=i.isPrimitive(r)?`${r}`:"";let d=n&&n.startsWith(r)&&n!==r;let m=d?blinker(n[r.length]):p;if(s!==r.length&&o===true){h=r.slice(0,s)+blinker(r[s])+r.slice(s+1);m=""}if(o===false){m=""}if(d){let t=e.styles.unstyle(h+m);return h+m+l(n.slice(t.length))}return h+m}},379:(e,t,r)=>{"use strict";const i=r(4434);const n=r(3958);const s=r(3491);const o=r(8740);const a=r(1600);const l=r(6868);const u=r(6600);const h=r(4102);class Prompt extends i{constructor(e={}){super();this.name=e.name;this.type=e.type;this.options=e;l(this);o(this);this.state=new a(this);this.initial=[e.initial,e.default].find((e=>e!=null));this.stdout=e.stdout||process.stdout;this.stdin=e.stdin||process.stdin;this.scale=e.scale||1;this.term=this.options.term||process.env.TERM_PROGRAM;this.margin=margin(this.options.margin);this.setMaxListeners(0);setOptions(this)}async keypress(e,t={}){this.keypressed=true;let r=s.action(e,s(e,t),this.options.actions);this.state.keypress=r;this.emit("keypress",e,r);this.emit("state",this.state.clone());const i=this.options[r.action]||this[r.action]||this.dispatch;if(typeof i==="function"){return await i.call(this,e,r)}this.alert()}alert(){delete this.state.alert;if(this.options.show===false){this.emit("alert")}else{this.stdout.write(h.code.beep)}}cursorHide(){this.stdout.write(h.cursor.hide());const e=u.onExit((()=>this.cursorShow()));this.on("close",(()=>{this.cursorShow();e()}))}cursorShow(){this.stdout.write(h.cursor.show())}write(e){if(!e)return;if(this.stdout&&this.state.show!==false){this.stdout.write(e)}this.state.buffer+=e}clear(e=0){let t=this.state.buffer;this.state.buffer="";if(!t&&!e||this.options.show===false)return;this.stdout.write(h.cursor.down(e)+h.clear(t,this.width))}restore(){if(this.state.closed||this.options.show===false)return;let{prompt:e,after:t,rest:r}=this.sections();let{cursor:i,initial:n="",input:s="",value:o=""}=this;let a=this.state.size=r.length;let l={after:t,cursor:i,initial:n,input:s,prompt:e,size:a,value:o};let u=h.cursor.restore(l);if(u){this.stdout.write(u)}}sections(){let{buffer:e,input:t,prompt:r}=this.state;r=n(r);let i=n(e);let s=i.indexOf(r);let o=i.slice(0,s);let a=i.slice(s);let l=a.split("\n");let u=l[0];let h=l[l.length-1];let f=r+(t?" "+t:"");let p=f.length;let d=p<u.length?u.slice(p+1):"";return{header:o,prompt:u,after:d,rest:l.slice(1),last:h}}async submit(){this.state.submitted=true;this.state.validating=true;if(this.options.onSubmit){await this.options.onSubmit.call(this,this.name,this.value,this)}let e=this.state.error||await this.validate(this.value,this.state);if(e!==true){let t="\n"+this.symbols.pointer+" ";if(typeof e==="string"){t+=e.trim()}else{t+="Invalid input"}this.state.error="\n"+this.styles.danger(t);this.state.submitted=false;await this.render();await this.alert();this.state.validating=false;this.state.error=void 0;return}this.state.validating=false;await this.render();await this.close();this.value=await this.result(this.value);this.emit("submit",this.value)}async cancel(e){this.state.cancelled=this.state.submitted=true;await this.render();await this.close();if(typeof this.options.onCancel==="function"){await this.options.onCancel.call(this,this.name,this.value,this)}this.emit("cancel",await this.error(e))}async close(){this.state.closed=true;try{let e=this.sections();let t=Math.ceil(e.prompt.length/this.width);if(e.rest){this.write(h.cursor.down(e.rest.length))}this.write("\n".repeat(t))}catch(e){}this.emit("close")}start(){if(!this.stop&&this.options.show!==false){this.stop=s.listen(this,this.keypress.bind(this));this.once("close",this.stop);this.emit("start",this)}}async skip(){this.skipped=this.options.skip===true;if(typeof this.options.skip==="function"){this.skipped=await this.options.skip.call(this,this.name,this.value)}return this.skipped}async initialize(){let{format:e,options:t,result:r}=this;this.format=()=>e.call(this,this.value);this.result=()=>r.call(this,this.value);if(typeof t.initial==="function"){this.initial=await t.initial.call(this,this)}if(typeof t.onRun==="function"){await t.onRun.call(this,this)}if(typeof t.onSubmit==="function"){let e=t.onSubmit.bind(this);let r=this.submit.bind(this);delete this.options.onSubmit;this.submit=async()=>{await e(this.name,this.value,this);return r()}}await this.start();await this.render()}render(){throw new Error("expected prompt to have a custom render method")}run(){return new Promise((async(e,t)=>{this.once("submit",e);this.once("cancel",t);if(await this.skip()){this.render=()=>{};return this.submit()}await this.initialize();this.emit("run")}))}async element(e,t,r){let{options:i,state:n,symbols:s,timers:o}=this;let a=o&&o[e];n.timer=a;let l=i[e]||n[e]||s[e];let u=t&&t[e]!=null?t[e]:await l;if(u==="")return u;let h=await this.resolve(u,n,t,r);if(!h&&t&&t[e]){return this.resolve(l,n,t,r)}return h}async prefix(){let e=await this.element("prefix")||this.symbols;let t=this.timers&&this.timers.prefix;let r=this.state;r.timer=t;if(u.isObject(e))e=e[r.status]||e.pending;if(!u.hasColor(e)){let t=this.styles[r.status]||this.styles.pending;return t(e)}return e}async message(){let e=await this.element("message");if(!u.hasColor(e)){return this.styles.strong(e)}return e}async separator(){let e=await this.element("separator")||this.symbols;let t=this.timers&&this.timers.separator;let r=this.state;r.timer=t;let i=e[r.status]||e.pending||r.separator;let n=await this.resolve(i,r);if(u.isObject(n))n=n[r.status]||n.pending;if(!u.hasColor(n)){return this.styles.muted(n)}return n}async pointer(e,t){let r=await this.element("pointer",e,t);if(typeof r==="string"&&u.hasColor(r)){return r}if(r){let e=this.styles;let i=this.index===t;let n=i?e.primary:e=>e;let s=await this.resolve(r[i?"on":"off"]||r,this.state);let o=!u.hasColor(s)?n(s):s;return i?o:" ".repeat(s.length)}}async indicator(e,t){let r=await this.element("indicator",e,t);if(typeof r==="string"&&u.hasColor(r)){return r}if(r){let t=this.styles;let i=e.enabled===true;let n=i?t.success:t.dark;let s=r[i?"on":"off"]||r;return!u.hasColor(s)?n(s):s}return""}body(){return null}footer(){if(this.state.status==="pending"){return this.element("footer")}}header(){if(this.state.status==="pending"){return this.element("header")}}async hint(){if(this.state.status==="pending"&&!this.isValue(this.state.input)){let e=await this.element("hint");if(!u.hasColor(e)){return this.styles.muted(e)}return e}}error(e){return!this.state.submitted?e||this.state.error:""}format(e){return e}result(e){return e}validate(e){if(this.options.required===true){return this.isValue(e)}return true}isValue(e){return e!=null&&e!==""}resolve(e,...t){return u.resolve(this,e,...t)}get base(){return Prompt.prototype}get style(){return this.styles[this.state.status]}get height(){return this.options.rows||u.height(this.stdout,25)}get width(){return this.options.columns||u.width(this.stdout,80)}get size(){return{width:this.width,height:this.height}}set cursor(e){this.state.cursor=e}get cursor(){return this.state.cursor}set input(e){this.state.input=e}get input(){return this.state.input}set value(e){this.state.value=e}get value(){let{input:e,value:t}=this.state;let r=[t,e].find(this.isValue.bind(this));return this.isValue(r)?r:this.initial}static get prompt(){return e=>new this(e).run()}}function setOptions(e){let isValidKey=t=>e[t]===void 0||typeof e[t]==="function";let t=["actions","choices","initial","margin","roles","styles","symbols","theme","timers","value"];let r=["body","footer","error","header","hint","indicator","message","prefix","separator","skip"];for(let i of Object.keys(e.options)){if(t.includes(i))continue;if(/^on[A-Z]/.test(i))continue;let n=e.options[i];if(typeof n==="function"&&isValidKey(i)){if(!r.includes(i)){e[i]=n.bind(e)}}else if(typeof e[i]!=="function"){e[i]=n}}}function margin(e){if(typeof e==="number"){e=[e,e,e,e]}let t=[].concat(e||[]);let pad=e=>e%2===0?"\n":" ";let r=[];for(let e=0;e<4;e++){let i=pad(e);if(t[e]){r.push(i.repeat(t[e]))}else{r.push("")}}return r}e.exports=Prompt},9385:(e,t,r)=>{"use strict";const i=r(5705);const highlight=(e,t)=>{const r=e?new RegExp(e,"ig"):/$^/;return i=>e?i.replace(r,(e=>t(e))):i};class AutoComplete extends i{constructor(e){super(e);this.cursorShow()}moveCursor(e){this.state.cursor+=e}dispatch(e){return this.append(e)}space(e){return this.options.multiple?super.space(e):this.append(e)}append(e){let{cursor:t,input:r}=this.state;this.input=r.slice(0,t)+e+r.slice(t);this.moveCursor(1);return this.complete()}delete(){let{cursor:e,input:t}=this.state;if(!t)return this.alert();this.input=t.slice(0,e-1)+t.slice(e);this.moveCursor(-1);return this.complete()}deleteForward(){let{cursor:e,input:t}=this.state;if(t[e]===void 0)return this.alert();this.input=`${t}`.slice(0,e)+`${t}`.slice(e+1);return this.complete()}number(e){return this.append(e)}async complete(){this.completing=true;this.choices=await this.suggest(this.input,this.state._choices);this.state.limit=void 0;this.index=Math.min(Math.max(this.visible.length-1,0),this.index);await this.render();this.completing=false}suggest(e=this.input,t=this.state._choices){if(typeof this.options.suggest==="function"){return this.options.suggest.call(this,e,t)}let r=e.toLowerCase();return t.filter((e=>e.message.toLowerCase().includes(r)))}pointer(){return""}format(){if(!this.focused)return this.input;if(this.options.multiple&&this.state.submitted){return this.selected.map((e=>this.styles.primary(e.message))).join(", ")}if(this.state.submitted){let e=this.value=this.input=this.focused.value;return this.styles.primary(e)}return this.input}async render(){if(this.state.status!=="pending")return super.render();const e=this.options.highlight||this.styles.complement;const style=(t,r)=>{if(!t)return t;if(e.stack)return e(t);return e.call(this,t)};const t=highlight(this.input,style);const r=this.choices;this.choices=r.map((e=>({...e,message:t(e.message)})));await super.render();this.choices=r}submit(){if(this.options.multiple){this.value=this.selected.map((e=>e.name))}return super.submit()}}e.exports=AutoComplete},3837:(e,t,r)=>{"use strict";const i=r(8401);function defaultAuthenticate(e,t){if(e.username===this.options.username&&e.password===this.options.password){return true}return false}const factory=(e=defaultAuthenticate)=>{const t=[{name:"username",message:"username"},{name:"password",message:"password",format(e){if(this.options.showPassword){return e}let t=this.state.submitted?this.styles.primary:this.styles.muted;return t(this.symbols.asterisk.repeat(e.length))}}];class BasicAuthPrompt extends(i.create(e)){constructor(e){super({...e,choices:t})}static create(e){return factory(e)}}return BasicAuthPrompt};e.exports=factory()},5305:(e,t,r)=>{"use strict";const i=r(8651);class ConfirmPrompt extends i{constructor(e){super(e);this.default=this.options.default||(this.initial?"(Y/n)":"(y/N)")}}e.exports=ConfirmPrompt},3073:(e,t,r)=>{"use strict";const i=r(5705);const n=r(6151);const s=n.prototype;class Editable extends i{constructor(e){super({...e,multiple:true});this.align=[this.options.align,"left"].find((e=>e!=null));this.emptyError="";this.values={}}dispatch(e,t){let r=this.focused;let i=r.parent||{};if(!r.editable&&!i.editable){if(e==="a"||e==="i")return super[e]()}return s.dispatch.call(this,e,t)}append(e,t){return s.append.call(this,e,t)}delete(e,t){return s.delete.call(this,e,t)}space(e){return this.focused.editable?this.append(e):super.space()}number(e){return this.focused.editable?this.append(e):super.number(e)}next(){return this.focused.editable?s.next.call(this):super.next()}prev(){return this.focused.editable?s.prev.call(this):super.prev()}async indicator(e,t){let r=e.indicator||"";let i=e.editable?r:super.indicator(e,t);return await this.resolve(i,this.state,e,t)||""}indent(e){return e.role==="heading"?"":e.editable?" ":" "}async renderChoice(e,t){e.indent="";if(e.editable)return s.renderChoice.call(this,e,t);return super.renderChoice(e,t)}error(){return""}footer(){return this.state.error}async validate(){let e=true;for(let t of this.choices){if(typeof t.validate!=="function"){continue}if(t.role==="heading"){continue}let r=t.parent?this.value[t.parent.name]:this.value;if(t.editable){r=t.value===t.name?t.initial||"":t.value}else if(!this.isDisabled(t)){r=t.enabled===true}e=await t.validate(r,this.state);if(e!==true){break}}if(e!==true){this.state.error=typeof e==="string"?e:"Invalid Input"}return e}submit(){if(this.focused.newChoice===true)return super.submit();if(this.choices.some((e=>e.newChoice))){return this.alert()}this.value={};for(let e of this.choices){let t=e.parent?this.value[e.parent.name]:this.value;if(e.role==="heading"){this.value[e.name]={};continue}if(e.editable){t[e.name]=e.value===e.name?e.initial||"":e.value}else if(!this.isDisabled(e)){t[e.name]=e.enabled===true}}return this.base.submit.call(this)}}e.exports=Editable},6151:(e,t,r)=>{"use strict";const i=r(3958);const n=r(5705);const s=r(2768);class FormPrompt extends n{constructor(e){super({...e,multiple:true});this.type="form";this.initial=this.options.initial;this.align=[this.options.align,"right"].find((e=>e!=null));this.emptyError="";this.values={}}async reset(e){await super.reset();if(e===true)this._index=this.index;this.index=this._index;this.values={};this.choices.forEach((e=>e.reset&&e.reset()));return this.render()}dispatch(e){return!!e&&this.append(e)}append(e){let t=this.focused;if(!t)return this.alert();let{cursor:r,input:i}=t;t.value=t.input=i.slice(0,r)+e+i.slice(r);t.cursor++;return this.render()}delete(){let e=this.focused;if(!e||e.cursor<=0)return this.alert();let{cursor:t,input:r}=e;e.value=e.input=r.slice(0,t-1)+r.slice(t);e.cursor--;return this.render()}deleteForward(){let e=this.focused;if(!e)return this.alert();let{cursor:t,input:r}=e;if(r[t]===void 0)return this.alert();let i=`${r}`.slice(0,t)+`${r}`.slice(t+1);e.value=e.input=i;return this.render()}right(){let e=this.focused;if(!e)return this.alert();if(e.cursor>=e.input.length)return this.alert();e.cursor++;return this.render()}left(){let e=this.focused;if(!e)return this.alert();if(e.cursor<=0)return this.alert();e.cursor--;return this.render()}space(e,t){return this.dispatch(e,t)}number(e,t){return this.dispatch(e,t)}next(){let e=this.focused;if(!e)return this.alert();let{initial:t,input:r}=e;if(t&&t.startsWith(r)&&r!==t){e.value=e.input=t;e.cursor=e.value.length;return this.render()}return super.next()}prev(){let e=this.focused;if(!e)return this.alert();if(e.cursor===0)return super.prev();e.value=e.input="";e.cursor=0;return this.render()}separator(){return""}format(e){return!this.state.submitted?super.format(e):""}pointer(){return""}indicator(e){return e.input?"⦿":"⊙"}async choiceSeparator(e,t){let r=await this.resolve(e.separator,this.state,e,t)||":";return r?" "+this.styles.disabled(r):""}async renderChoice(e,t){await this.onChoice(e,t);let{state:r,styles:n}=this;let{cursor:o,initial:a="",name:l,input:u=""}=e;let{muted:h,submitted:f,primary:p,danger:d}=n;let m=this.index===t;let g=e.validate||(()=>true);let y=await this.choiceSeparator(e,t);let b=e.message;if(this.align==="right")b=b.padStart(this.longest+1," ");if(this.align==="left")b=b.padEnd(this.longest+1," ");let _=this.values[l]=u||a;let v=u?"success":"dark";if(await g.call(e,_,this.state)!==true){v="danger"}let w=n[v];let S=w(await this.indicator(e,t))+(e.pad||"");let x=this.indent(e);let line=()=>[x,S,b+y,u].filter(Boolean).join(" ");if(r.submitted){b=i(b);u=f(u);return line()}if(e.format){u=await e.format.call(this,u,e,t)}else{let e=this.styles.muted;let t={input:u,initial:a,pos:o,showCursor:m,color:e};u=s(this,t)}if(!this.isValue(u)){u=this.styles.muted(this.symbols.ellipsis)}if(e.result){this.values[l]=await e.result.call(this,_,e,t)}if(m){b=p(b)}if(e.error){u+=(u?" ":"")+d(e.error.trim())}else if(e.hint){u+=(u?" ":"")+h(e.hint.trim())}return line()}async submit(){this.value=this.values;return super.base.submit.call(this)}}e.exports=FormPrompt},2637:(e,t,r)=>{"use strict";const i=r(6600);const define=(e,r)=>{i.defineExport(t,e,r);i.defineExport(t,e.toLowerCase(),r)};define("AutoComplete",(()=>r(9385)));define("BasicAuth",(()=>r(3837)));define("Confirm",(()=>r(5305)));define("Editable",(()=>r(3073)));define("Form",(()=>r(6151)));define("Input",(()=>r(3629)));define("Invisible",(()=>r(6062)));define("List",(()=>r(8021)));define("MultiSelect",(()=>r(8564)));define("Numeral",(()=>r(3299)));define("Password",(()=>r(1992)));define("Scale",(()=>r(1859)));define("Select",(()=>r(5705)));define("Snippet",(()=>r(6396)));define("Sort",(()=>r(6529)));define("Survey",(()=>r(1991)));define("Text",(()=>r(1102)));define("Toggle",(()=>r(6217)));define("Quiz",(()=>r(7120)))},3629:(e,t,r)=>{"use strict";const i=r(3474);const n=r(1606);class Input extends i{constructor(e){super(e);let t=this.options.history;if(t&&t.store){let e=t.values||this.initial;this.autosave=!!t.autosave;this.store=t.store;this.data=this.store.get("values")||{past:[],present:e};this.initial=this.data.present||this.data.past[this.data.past.length-1]}}completion(e){if(!this.store)return this.alert();this.data=n(e,this.data,this.input);if(!this.data.present)return this.alert();this.input=this.data.present;this.cursor=this.input.length;return this.render()}altUp(){return this.completion("prev")}altDown(){return this.completion("next")}prev(){this.save();return super.prev()}save(){if(!this.store)return;this.data=n("save",this.data,this.input);this.store.set("values",this.data)}submit(){if(this.store&&this.autosave===true){this.save()}return super.submit()}}e.exports=Input},6062:(e,t,r)=>{"use strict";const i=r(3474);class InvisiblePrompt extends i{format(){return""}}e.exports=InvisiblePrompt},8021:(e,t,r)=>{"use strict";const i=r(3474);class ListPrompt extends i{constructor(e={}){super(e);this.sep=this.options.separator||/, */;this.initial=e.initial||""}split(e=this.value){return e?String(e).split(this.sep):[]}format(){let e=this.state.submitted?this.styles.primary:e=>e;return this.list.map(e).join(", ")}async submit(e){let t=this.state.error||await this.validate(this.list,this.state);if(t!==true){this.state.error=t;return super.submit()}this.value=this.list;return super.submit()}get list(){return this.split()}}e.exports=ListPrompt},8564:(e,t,r)=>{"use strict";const i=r(5705);class MultiSelect extends i{constructor(e){super({...e,multiple:true})}}e.exports=MultiSelect},3299:(e,t,r)=>{e.exports=r(4530)},1992:(e,t,r)=>{"use strict";const i=r(3474);class PasswordPrompt extends i{constructor(e){super(e);this.cursorShow()}format(e=this.input){if(!this.keypressed)return"";let t=this.state.submitted?this.styles.primary:this.styles.muted;return t(this.symbols.asterisk.repeat(e.length))}}e.exports=PasswordPrompt},7120:(e,t,r)=>{"use strict";const i=r(5705);class Quiz extends i{constructor(e){super(e);if(typeof this.options.correctChoice!=="number"||this.options.correctChoice<0){throw new Error("Please specify the index of the correct answer from the list of choices")}}async toChoices(e,t){let r=await super.toChoices(e,t);if(r.length<2){throw new Error("Please give at least two choices to the user")}if(this.options.correctChoice>r.length){throw new Error("Please specify the index of the correct answer from the list of choices")}return r}check(e){return e.index===this.options.correctChoice}async result(e){return{selectedAnswer:e,correctAnswer:this.options.choices[this.options.correctChoice].value,correct:await this.check(this.state)}}}e.exports=Quiz},1859:(e,t,r)=>{"use strict";const i=r(3958);const n=r(4334);const s=r(6600);class LikertScale extends n{constructor(e={}){super(e);this.widths=[].concat(e.messageWidth||50);this.align=[].concat(e.align||"left");this.linebreak=e.linebreak||false;this.edgeLength=e.edgeLength||3;this.newline=e.newline||"\n ";let t=e.startNumber||1;if(typeof this.scale==="number"){this.scaleKey=false;this.scale=Array(this.scale).fill(0).map(((e,r)=>({name:r+t})))}}async reset(){this.tableized=false;await super.reset();return this.render()}tableize(){if(this.tableized===true)return;this.tableized=true;let e=0;for(let t of this.choices){e=Math.max(e,t.message.length);t.scaleIndex=t.initial||2;t.scale=[];for(let e=0;e<this.scale.length;e++){t.scale.push({index:e})}}this.widths[0]=Math.min(this.widths[0],e+3)}async dispatch(e,t){if(this.multiple){return this[t.name]?await this[t.name](e,t):await super.dispatch(e,t)}this.alert()}heading(e,t,r){return this.styles.strong(e)}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;if(e.scaleIndex>=this.scale.length-1)return this.alert();e.scaleIndex++;return this.render()}left(){let e=this.focused;if(e.scaleIndex<=0)return this.alert();e.scaleIndex--;return this.render()}indent(){return""}format(){if(this.state.submitted){let e=this.choices.map((e=>this.styles.info(e.index)));return e.join(", ")}return""}pointer(){return""}renderScaleKey(){if(this.scaleKey===false)return"";if(this.state.submitted)return"";let e=this.scale.map((e=>` ${e.name} - ${e.message}`));let t=["",...e].map((e=>this.styles.muted(e)));return t.join("\n")}renderScaleHeading(e){let t=this.scale.map((e=>e.name));if(typeof this.options.renderScaleHeading==="function"){t=this.options.renderScaleHeading.call(this,e)}let r=this.scaleLength-t.join("").length;let i=Math.round(r/(t.length-1));let n=t.map((e=>this.styles.strong(e)));let s=n.join(" ".repeat(i));let o=" ".repeat(this.widths[0]);return this.margin[3]+o+this.margin[1]+s}scaleIndicator(e,t,r){if(typeof this.options.scaleIndicator==="function"){return this.options.scaleIndicator.call(this,e,t,r)}let i=e.scaleIndex===t.index;if(t.disabled)return this.styles.hint(this.symbols.radio.disabled);if(i)return this.styles.success(this.symbols.radio.on);return this.symbols.radio.off}renderScale(e,t){let r=e.scale.map((r=>this.scaleIndicator(e,r,t)));let i=this.term==="Hyper"?"":" ";return r.join(i+this.symbols.line.repeat(this.edgeLength))}async renderChoice(e,t){await this.onChoice(e,t);let r=this.index===t;let n=await this.pointer(e,t);let o=await e.hint;if(o&&!s.hasColor(o)){o=this.styles.muted(o)}let pad=e=>this.margin[3]+e.replace(/\s+$/,"").padEnd(this.widths[0]," ");let a=this.newline;let l=this.indent(e);let u=await this.resolve(e.message,this.state,e,t);let h=await this.renderScale(e,t);let f=this.margin[1]+this.margin[3];this.scaleLength=i(h).length;this.widths[0]=Math.min(this.widths[0],this.width-this.scaleLength-f.length);let p=s.wordWrap(u,{width:this.widths[0],newline:a});let d=p.split("\n").map((e=>pad(e)+this.margin[1]));if(r){h=this.styles.info(h);d=d.map((e=>this.styles.info(e)))}d[0]+=h;if(this.linebreak)d.push("");return[l+n,d.join("\n")].filter(Boolean)}async renderChoices(){if(this.state.submitted)return"";this.tableize();let e=this.visible.map((async(e,t)=>await this.renderChoice(e,t)));let t=await Promise.all(e);let r=await this.renderScaleHeading();return this.margin[0]+[r,...t.map((e=>e.join(" ")))].join("\n")}async render(){let{submitted:e,size:t}=this.state;let r=await this.prefix();let i=await this.separator();let n=await this.message();let s="";if(this.options.promptLine!==false){s=[r,n,i,""].join(" ");this.state.prompt=s}let o=await this.header();let a=await this.format();let l=await this.renderScaleKey();let u=await this.error()||await this.hint();let h=await this.renderChoices();let f=await this.footer();let p=this.emptyError;if(a)s+=a;if(u&&!s.includes(u))s+=" "+u;if(e&&!a&&!h.trim()&&this.multiple&&p!=null){s+=this.styles.danger(p)}this.clear(t);this.write([o,s,l,h,f].filter(Boolean).join("\n"));if(!this.state.submitted){this.write(this.margin[2])}this.restore()}submit(){this.value={};for(let e of this.choices){this.value[e.name]=e.scaleIndex}return this.base.submit.call(this)}}e.exports=LikertScale},5705:(e,t,r)=>{"use strict";const i=r(4334);const n=r(6600);class SelectPrompt extends i{constructor(e){super(e);this.emptyError=this.options.emptyError||"No items were selected"}async dispatch(e,t){if(this.multiple){return this[t.name]?await this[t.name](e,t):await super.dispatch(e,t)}this.alert()}separator(){if(this.options.separator)return super.separator();let e=this.styles.muted(this.symbols.ellipsis);return this.state.submitted?super.separator():e}pointer(e,t){return!this.multiple||this.options.pointer?super.pointer(e,t):""}indicator(e,t){return this.multiple?super.indicator(e,t):""}choiceMessage(e,t){let r=this.resolve(e.message,this.state,e,t);if(e.role==="heading"&&!n.hasColor(r)){r=this.styles.strong(r)}return this.resolve(r,this.state,e,t)}choiceSeparator(){return":"}async renderChoice(e,t){await this.onChoice(e,t);let r=this.index===t;let i=await this.pointer(e,t);let s=await this.indicator(e,t)+(e.pad||"");let o=await this.resolve(e.hint,this.state,e,t);if(o&&!n.hasColor(o)){o=this.styles.muted(o)}let a=this.indent(e);let l=await this.choiceMessage(e,t);let line=()=>[this.margin[3],a+i+s,l,this.margin[1],o].filter(Boolean).join(" ");if(e.role==="heading"){return line()}if(e.disabled){if(!n.hasColor(l)){l=this.styles.disabled(l)}return line()}if(r){l=this.styles.em(l)}return line()}async renderChoices(){if(this.state.loading==="choices"){return this.styles.warning("Loading choices")}if(this.state.submitted)return"";let e=this.visible.map((async(e,t)=>await this.renderChoice(e,t)));let t=await Promise.all(e);if(!t.length)t.push(this.styles.danger("No matching choices"));let r=this.margin[0]+t.join("\n");let i;if(this.options.choicesHeader){i=await this.resolve(this.options.choicesHeader,this.state)}return[i,r].filter(Boolean).join("\n")}format(){if(!this.state.submitted||this.state.cancelled)return"";if(Array.isArray(this.selected)){return this.selected.map((e=>this.styles.primary(e.name))).join(", ")}return this.styles.primary(this.selected.name)}async render(){let{submitted:e,size:t}=this.state;let r="";let i=await this.header();let n=await this.prefix();let s=await this.separator();let o=await this.message();if(this.options.promptLine!==false){r=[n,o,s,""].join(" ");this.state.prompt=r}let a=await this.format();let l=await this.error()||await this.hint();let u=await this.renderChoices();let h=await this.footer();if(a)r+=a;if(l&&!r.includes(l))r+=" "+l;if(e&&!a&&!u.trim()&&this.multiple&&this.emptyError!=null){r+=this.styles.danger(this.emptyError)}this.clear(t);this.write([i,r,u,h].filter(Boolean).join("\n"));this.write(this.margin[2]);this.restore()}}e.exports=SelectPrompt},6396:(e,t,r)=>{"use strict";const i=r(3958);const n=r(6454);const s=r(379);class SnippetPrompt extends s{constructor(e){super(e);this.cursorHide();this.reset(true)}async initialize(){this.interpolate=await n(this);await super.initialize()}async reset(e){this.state.keys=[];this.state.invalid=new Map;this.state.missing=new Set;this.state.completed=0;this.state.values={};if(e!==true){await this.initialize();await this.render()}}moveCursor(e){let t=this.getItem();this.cursor+=e;t.cursor+=e}dispatch(e,t){if(!t.code&&!t.ctrl&&e!=null&&this.getItem()){this.append(e,t);return}this.alert()}append(e,t){let r=this.getItem();let i=r.input.slice(0,this.cursor);let n=r.input.slice(this.cursor);this.input=r.input=`${i}${e}${n}`;this.moveCursor(1);this.render()}delete(){let e=this.getItem();if(this.cursor<=0||!e.input)return this.alert();let t=e.input.slice(this.cursor);let r=e.input.slice(0,this.cursor-1);this.input=e.input=`${r}${t}`;this.moveCursor(-1);this.render()}increment(e){return e>=this.state.keys.length-1?0:e+1}decrement(e){return e<=0?this.state.keys.length-1:e-1}first(){this.state.index=0;this.render()}last(){this.state.index=this.state.keys.length-1;this.render()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1);this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1);this.render()}prev(){this.state.index=this.decrement(this.state.index);this.getItem();this.render()}next(){this.state.index=this.increment(this.state.index);this.getItem();this.render()}up(){this.prev()}down(){this.next()}format(e){let t=this.state.completed<100?this.styles.warning:this.styles.success;if(this.state.submitted===true&&this.state.completed!==100){t=this.styles.danger}return t(`${this.state.completed}% completed`)}async render(){let{index:e,keys:t=[],submitted:r,size:i}=this.state;let n=[this.options.newline,"\n"].find((e=>e!=null));let s=await this.prefix();let o=await this.separator();let a=await this.message();let l=[s,a,o].filter(Boolean).join(" ");this.state.prompt=l;let u=await this.header();let h=await this.error()||"";let f=await this.hint()||"";let p=r?"":await this.interpolate(this.state);let d=this.state.key=t[e]||"";let m=await this.format(d);let g=await this.footer();if(m)l+=" "+m;if(f&&!m&&this.state.completed===0)l+=" "+f;this.clear(i);let y=[u,l,p,g,h.trim()];this.write(y.filter(Boolean).join(n));this.restore()}getItem(e){let{items:t,keys:r,index:i}=this.state;let n=t.find((e=>e.name===r[i]));if(n&&n.input!=null){this.input=n.input;this.cursor=n.cursor}return n}async submit(){if(typeof this.interpolate!=="function")await this.initialize();await this.interpolate(this.state,true);let{invalid:e,missing:t,output:r,values:n}=this.state;if(e.size){let t="";for(let[r,i]of e)t+=`Invalid ${r}: ${i}\n`;this.state.error=t;return super.submit()}if(t.size){this.state.error="Required: "+[...t.keys()].join(", ");return super.submit()}let s=i(r).split("\n");let o=s.map((e=>e.slice(1))).join("\n");this.value={values:n,result:o};return super.submit()}}e.exports=SnippetPrompt},6529:(e,t,r)=>{"use strict";const i="(Use <shift>+<up/down> to sort)";const n=r(5705);class Sort extends n{constructor(e){super({...e,reorder:false,sort:true,multiple:true});this.state.hint=[this.options.hint,i].find(this.isValue.bind(this))}indicator(){return""}async renderChoice(e,t){let r=await super.renderChoice(e,t);let i=this.symbols.identicalTo+" ";let n=this.index===t&&this.sorting?this.styles.muted(i):" ";if(this.options.drag===false)n="";if(this.options.numbered===true){return n+`${t+1} - `+r}return n+r}get selected(){return this.choices}submit(){this.value=this.choices.map((e=>e.value));return super.submit()}}e.exports=Sort},1991:(e,t,r)=>{"use strict";const i=r(4334);class Survey extends i{constructor(e={}){super(e);this.emptyError=e.emptyError||"No items were selected";this.term=process.env.TERM_PROGRAM;if(!this.options.header){let e=["","4 - Strongly Agree","3 - Agree","2 - Neutral","1 - Disagree","0 - Strongly Disagree",""];e=e.map((e=>this.styles.muted(e)));this.state.header=e.join("\n ")}}async toChoices(...e){if(this.createdScales)return false;this.createdScales=true;let t=await super.toChoices(...e);for(let e of t){e.scale=createScale(5,this.options);e.scaleIdx=2}return t}dispatch(){this.alert()}space(){let e=this.focused;let t=e.scale[e.scaleIdx];let r=t.selected;e.scale.forEach((e=>e.selected=false));t.selected=!r;return this.render()}indicator(){return""}pointer(){return""}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;if(e.scaleIdx>=e.scale.length-1)return this.alert();e.scaleIdx++;return this.render()}left(){let e=this.focused;if(e.scaleIdx<=0)return this.alert();e.scaleIdx--;return this.render()}indent(){return" "}async renderChoice(e,t){await this.onChoice(e,t);let r=this.index===t;let i=this.term==="Hyper";let n=!i?8:9;let s=!i?" ":"";let o=this.symbols.line.repeat(n);let a=" ".repeat(n+(i?0:1));let dot=e=>(e?this.styles.success("◉"):"◯")+s;let l=t+1+".";let u=r?this.styles.heading:this.styles.noop;let h=await this.resolve(e.message,this.state,e,t);let f=this.indent(e);let p=f+e.scale.map(((t,r)=>dot(r===e.scaleIdx))).join(o);let val=t=>t===e.scaleIdx?u(t):t;let d=f+e.scale.map(((e,t)=>val(t))).join(a);let line=()=>[l,h].filter(Boolean).join(" ");let lines=()=>[line(),p,d," "].filter(Boolean).join("\n");if(r){p=this.styles.cyan(p);d=this.styles.cyan(d)}return lines()}async renderChoices(){if(this.state.submitted)return"";let e=this.visible.map((async(e,t)=>await this.renderChoice(e,t)));let t=await Promise.all(e);if(!t.length)t.push(this.styles.danger("No matching choices"));return t.join("\n")}format(){if(this.state.submitted){let e=this.choices.map((e=>this.styles.info(e.scaleIdx)));return e.join(", ")}return""}async render(){let{submitted:e,size:t}=this.state;let r=await this.prefix();let i=await this.separator();let n=await this.message();let s=[r,n,i].filter(Boolean).join(" ");this.state.prompt=s;let o=await this.header();let a=await this.format();let l=await this.error()||await this.hint();let u=await this.renderChoices();let h=await this.footer();if(a||!l)s+=" "+a;if(l&&!s.includes(l))s+=" "+l;if(e&&!a&&!u&&this.multiple&&this.type!=="form"){s+=this.styles.danger(this.emptyError)}this.clear(t);this.write([s,o,u,h].filter(Boolean).join("\n"));this.restore()}submit(){this.value={};for(let e of this.choices){this.value[e.name]=e.scaleIdx}return this.base.submit.call(this)}}function createScale(e,t={}){if(Array.isArray(t.scale)){return t.scale.map((e=>({...e})))}let r=[];for(let t=1;t<e+1;t++)r.push({i:t,selected:false});return r}e.exports=Survey},1102:(e,t,r)=>{e.exports=r(3629)},6217:(e,t,r)=>{"use strict";const i=r(8651);class TogglePrompt extends i{async initialize(){await super.initialize();this.value=this.initial=this.resolve(this.options.initial);this.disabled=this.options.disabled||"no";this.enabled=this.options.enabled||"yes";await this.render()}reset(){this.value=this.initial;this.render()}delete(){this.alert()}toggle(){this.value=!this.value;this.render()}enable(){if(this.value===true)return this.alert();this.value=true;this.render()}disable(){if(this.value===false)return this.alert();this.value=false;this.render()}up(){this.toggle()}down(){this.toggle()}right(){this.toggle()}left(){this.toggle()}next(){this.toggle()}prev(){this.toggle()}dispatch(e="",t){switch(e.toLowerCase()){case" ":return this.toggle();case"1":case"y":case"t":return this.enable();case"0":case"n":case"f":return this.disable();default:{return this.alert()}}}format(){let active=e=>this.styles.primary.underline(e);let e=[this.value?this.disabled:active(this.disabled),this.value?active(this.enabled):this.enabled];return e.join(this.styles.muted(" / "))}async render(){let{size:e}=this.state;let t=await this.header();let r=await this.prefix();let i=await this.separator();let n=await this.message();let s=await this.format();let o=await this.error()||await this.hint();let a=await this.footer();let l=[r,n,i,s].join(" ");this.state.prompt=l;if(o&&!l.includes(o))l+=" "+o;this.clear(e);this.write([t,l,a].filter(Boolean).join("\n"));this.write(this.margin[2]);this.restore()}}e.exports=TogglePrompt},8290:e=>{"use strict";e.exports=class Queue{_queue=[];_executing=false;_jobRunner=null;constructor(e){this._jobRunner=e}enqueue=(...e)=>{this._queue.push(e);this._dequeue()};destroy(){this._queue.length=0;this._jobRunner=null}_dequeue(){if(this._executing||!this._queue.length)return;this._executing=true;this._jobRunner(...this._queue.shift());setTimeout((()=>{this._executing=false;this._dequeue()}))}}},8004:(e,t,r)=>{"use strict";const i=r(6600);const n={default(e,t){return t},checkbox(e,t){throw new Error("checkbox role is not implemented yet")},editable(e,t){throw new Error("editable role is not implemented yet")},expandable(e,t){throw new Error("expandable role is not implemented yet")},heading(e,t){t.disabled="";t.indicator=[t.indicator," "].find((e=>e!=null));t.message=t.message||"";return t},input(e,t){throw new Error("input role is not implemented yet")},option(e,t){return n.default(e,t)},radio(e,t){throw new Error("radio role is not implemented yet")},separator(e,t){t.disabled="";t.indicator=[t.indicator," "].find((e=>e!=null));t.message=t.message||e.symbols.line.repeat(5);return t},spacer(e,t){return t}};e.exports=(e,t={})=>{let r=i.merge({},n,t.roles);return r[e]||r.default}},1600:(e,t,r)=>{"use strict";const{define:i,width:n}=r(6600);class State{constructor(e){let t=e.options;i(this,"_prompt",e);this.type=e.type;this.name=e.name;this.message="";this.header="";this.footer="";this.error="";this.hint="";this.input="";this.cursor=0;this.index=0;this.lines=0;this.tick=0;this.prompt="";this.buffer="";this.width=n(t.stdout||process.stdout);Object.assign(this,t);this.name=this.name||this.message;this.message=this.message||this.name;this.symbols=e.symbols;this.styles=e.styles;this.required=new Set;this.cancelled=false;this.submitted=false}clone(){let e={...this};e.status=this.status;e.buffer=Buffer.from(e.buffer);delete e.clone;return e}set color(e){this._color=e}get color(){let e=this.prompt.styles;if(this.cancelled)return e.cancelled;if(this.submitted)return e.submitted;let t=this._color||e[this.status];return typeof t==="function"?t:e.pending}set loading(e){this._loading=e}get loading(){if(typeof this._loading==="boolean")return this._loading;if(this.loadingChoices)return"choices";return false}get status(){if(this.cancelled)return"cancelled";if(this.submitted)return"submitted";return"pending"}}e.exports=State},5071:(e,t,r)=>{"use strict";const i=r(6600);const n=r(7182);const s={default:n.noop,noop:n.noop,set inverse(e){this._inverse=e},get inverse(){return this._inverse||i.inverse(this.primary)},set complement(e){this._complement=e},get complement(){return this._complement||i.complement(this.primary)},primary:n.cyan,success:n.green,danger:n.magenta,strong:n.bold,warning:n.yellow,muted:n.dim,disabled:n.gray,dark:n.dim.gray,underline:n.underline,set info(e){this._info=e},get info(){return this._info||this.primary},set em(e){this._em=e},get em(){return this._em||this.primary.underline},set heading(e){this._heading=e},get heading(){return this._heading||this.muted.underline},set pending(e){this._pending=e},get pending(){return this._pending||this.primary},set submitted(e){this._submitted=e},get submitted(){return this._submitted||this.success},set cancelled(e){this._cancelled=e},get cancelled(){return this._cancelled||this.danger},set typing(e){this._typing=e},get typing(){return this._typing||this.dim},set placeholder(e){this._placeholder=e},get placeholder(){return this._placeholder||this.primary.dim},set highlight(e){this._highlight=e},get highlight(){return this._highlight||this.inverse}};s.merge=(e={})=>{if(e.styles&&typeof e.styles.enabled==="boolean"){n.enabled=e.styles.enabled}if(e.styles&&typeof e.styles.visible==="boolean"){n.visible=e.styles.visible}let t=i.merge({},s,e.styles);delete t.merge;for(let e of Object.keys(n)){if(!hasOwnProperty.call(t,e)){Reflect.defineProperty(t,e,{get:()=>n[e]})}}for(let e of Object.keys(n.styles)){if(!hasOwnProperty.call(t,e)){Reflect.defineProperty(t,e,{get:()=>n[e]})}}return t};e.exports=s},1620:(e,t,r)=>{"use strict";const i=process.platform==="win32";const n=r(7182);const s=r(6600);const o={...n.symbols,upDownDoubleArrow:"⇕",upDownDoubleArrow2:"⬍",upDownArrow:"↕",asterisk:"*",asterism:"⁂",bulletWhite:"◦",electricArrow:"⌁",ellipsisLarge:"⋯",ellipsisSmall:"…",fullBlock:"█",identicalTo:"≡",indicator:n.symbols.check,leftAngle:"‹",mark:"※",minus:"−",multiplication:"×",obelus:"÷",percent:"%",pilcrow:"¶",pilcrow2:"❡",pencilUpRight:"✐",pencilDownRight:"✎",pencilRight:"✏",plus:"+",plusMinus:"±",pointRight:"☞",rightAngle:"›",section:"§",hexagon:{off:"⬡",on:"⬢",disabled:"⬢"},ballot:{on:"☑",off:"☐",disabled:"☒"},stars:{on:"★",off:"☆",disabled:"☆"},folder:{on:"▼",off:"▶",disabled:"▶"},prefix:{pending:n.symbols.question,submitted:n.symbols.check,cancelled:n.symbols.cross},separator:{pending:n.symbols.pointerSmall,submitted:n.symbols.middot,cancelled:n.symbols.middot},radio:{off:i?"( )":"◯",on:i?"(*)":"◉",disabled:i?"(|)":"Ⓘ"},numbers:["⓪","①","②","③","④","⑤","⑥","⑦","⑧","⑨","⑩","⑪","⑫","⑬","⑭","⑮","⑯","⑰","⑱","⑲","⑳","㉑","㉒","㉓","㉔","㉕","㉖","㉗","㉘","㉙","㉚","㉛","㉜","㉝","㉞","㉟","㊱","㊲","㊳","㊴","㊵","㊶","㊷","㊸","㊹","㊺","㊻","㊼","㊽","㊾","㊿"]};o.merge=e=>{let t=s.merge({},n.symbols,o,e.symbols);delete t.merge;return t};e.exports=o},6868:(e,t,r)=>{"use strict";const i=r(5071);const n=r(1620);const s=r(6600);e.exports=e=>{e.options=s.merge({},e.options.theme,e.options);e.symbols=n.merge(e.options);e.styles=i.merge(e.options)}},8740:e=>{"use strict";e.exports=e=>{e.timers=e.timers||{};let t=e.options.timers;if(!t)return;for(let r of Object.keys(t)){let i=t[r];if(typeof i==="number"){i={interval:i}}create(e,r,i)}};function create(e,t,r={}){let i=e.timers[t]={name:t,start:Date.now(),ms:0,tick:0};let n=r.interval||120;i.frames=r.frames||[];i.loading=true;let s=setInterval((()=>{i.ms=Date.now()-i.start;i.tick++;e.render()}),n);i.stop=()=>{i.loading=false;clearInterval(s)};Reflect.defineProperty(i,"interval",{value:s});e.once("close",(()=>i.stop()));return i.stop}},4334:(e,t,r)=>{"use strict";const i=r(3958);const n=r(379);const s=r(8004);const o=r(6600);const{reorder:a,scrollUp:l,scrollDown:u,isObject:h,swap:f}=o;class ArrayPrompt extends n{constructor(e){super(e);this.cursorHide();this.maxSelected=e.maxSelected||Infinity;this.multiple=e.multiple||false;this.initial=e.initial||0;this.delay=e.delay||0;this.longest=0;this.num=""}async initialize(){if(typeof this.options.initial==="function"){this.initial=await this.options.initial.call(this)}await this.reset(true);await super.initialize()}async reset(){let{choices:e,initial:t,autofocus:r,suggest:i}=this.options;this.state._choices=[];this.state.choices=[];this.choices=await Promise.all(await this.toChoices(e));this.choices.forEach((e=>e.enabled=false));if(typeof i!=="function"&&this.selectable.length===0){throw new Error("At least one choice must be selectable")}if(h(t))t=Object.keys(t);if(Array.isArray(t)){if(r!=null)this.index=this.findIndex(r);t.forEach((e=>this.enable(this.find(e))));await this.render()}else{if(r!=null)t=r;if(typeof t==="string")t=this.findIndex(t);if(typeof t==="number"&&t>-1){this.index=Math.max(0,Math.min(t,this.choices.length));this.enable(this.find(this.index))}}if(this.isDisabled(this.focused)){await this.down()}}async toChoices(e,t){this.state.loadingChoices=true;let r=[];let i=0;let toChoices=async(e,t)=>{if(typeof e==="function")e=await e.call(this);if(e instanceof Promise)e=await e;for(let n=0;n<e.length;n++){let s=e[n]=await this.toChoice(e[n],i++,t);r.push(s);if(s.choices){await toChoices(s.choices,s)}}return r};return toChoices(e,t).then((e=>{this.state.loadingChoices=false;return e}))}async toChoice(e,t,r){if(typeof e==="function")e=await e.call(this,this);if(e instanceof Promise)e=await e;if(typeof e==="string")e={name:e};if(e.normalized)return e;e.normalized=true;let n=e.value;let a=s(e.role,this.options);e=a(this,e);if(typeof e.disabled==="string"&&!e.hint){e.hint=e.disabled;e.disabled=true}if(e.disabled===true&&e.hint==null){e.hint="(disabled)"}if(e.index!=null)return e;e.name=e.name||e.key||e.title||e.value||e.message;e.message=e.message||e.name||"";e.value=[e.value,e.name].find(this.isValue.bind(this));e.input="";e.index=t;e.cursor=0;o.define(e,"parent",r);e.level=r?r.level+1:1;if(e.indent==null){e.indent=r?r.indent+" ":e.indent||""}e.path=r?r.path+"."+e.name:e.name;e.enabled=!!(this.multiple&&!this.isDisabled(e)&&(e.enabled||this.isSelected(e)));if(!this.isDisabled(e)){this.longest=Math.max(this.longest,i(e.message).length)}let l={...e};e.reset=(t=l.input,r=l.value)=>{for(let t of Object.keys(l))e[t]=l[t];e.input=t;e.value=r};if(n==null&&typeof e.initial==="function"){e.input=await e.initial.call(this,this.state,e,t)}return e}async onChoice(e,t){this.emit("choice",e,t,this);if(typeof e.onChoice==="function"){await e.onChoice.call(this,this.state,e,t)}}async addChoice(e,t,r){let i=await this.toChoice(e,t,r);this.choices.push(i);this.index=this.choices.length-1;this.limit=this.choices.length;return i}async newItem(e,t,r){let i={name:"New choice name?",editable:true,newChoice:true,...e};let n=await this.addChoice(i,t,r);n.updateChoice=()=>{delete n.newChoice;n.name=n.message=n.input;n.input="";n.cursor=0};return this.render()}indent(e){if(e.indent==null){return e.level>1?" ".repeat(e.level-1):""}return e.indent}dispatch(e,t){if(this.multiple&&this[t.name])return this[t.name]();this.alert()}focus(e,t){if(typeof t!=="boolean")t=e.enabled;if(t&&!e.enabled&&this.selected.length>=this.maxSelected){return this.alert()}this.index=e.index;e.enabled=t&&!this.isDisabled(e);return e}space(){if(!this.multiple)return this.alert();if(!this.focused)return;this.toggle(this.focused);return this.render()}a(){if(this.maxSelected<this.choices.length)return this.alert();let e=this.selectable.every((e=>e.enabled));this.choices.forEach((t=>t.enabled=!e));return this.render()}i(){if(this.choices.length-this.selected.length>this.maxSelected){return this.alert()}this.choices.forEach((e=>e.enabled=!e.enabled));return this.render()}g(){if(!this.choices.some((e=>!!e.parent)))return this.a();const e=this.focused;this.toggle(e.parent&&!e.choices?e.parent:e);return this.render()}toggle(e,t){if(!e.enabled&&this.selected.length>=this.maxSelected){return this.alert()}if(typeof t!=="boolean")t=!e.enabled;e.enabled=t;if(e.choices){e.choices.forEach((e=>this.toggle(e,t)))}let r=e.parent;while(r){let e=r.choices.filter((e=>this.isDisabled(e)));r.enabled=e.every((e=>e.enabled===true));r=r.parent}reset(this,this.choices);this.emit("toggle",e,this);return e}enable(e){if(this.selected.length>=this.maxSelected)return this.alert();e.enabled=!this.isDisabled(e);e.choices&&e.choices.forEach(this.enable.bind(this));return e}disable(e){e.enabled=false;e.choices&&e.choices.forEach(this.disable.bind(this));return e}number(e){this.num+=e;let number=e=>{let t=Number(e);if(t>this.choices.length-1)return this.alert();let r=this.focused;let i=this.choices.find((e=>t===e.index));if(!i.enabled&&this.selected.length>=this.maxSelected){return this.alert()}if(this.visible.indexOf(i)===-1){let e=a(this.choices);let t=e.indexOf(i);if(r.index>t){let r=e.slice(t,t+this.limit);let i=e.filter((e=>!r.includes(e)));this.choices=r.concat(i)}else{let r=t-this.limit+1;this.choices=e.slice(r).concat(e.slice(0,r))}}this.index=this.choices.indexOf(i);this.toggle(this.focused);return this.render()};clearTimeout(this.numberTimeout);return new Promise((e=>{let t=this.choices.length;let r=this.num;let handle=(t=false,i)=>{clearTimeout(this.numberTimeout);if(t)i=number(r);this.num="";e(i)};if(r==="0"||r.length===1&&Number(r+"0")>t){return handle(true)}if(Number(r)>t){return handle(false,this.alert())}this.numberTimeout=setTimeout((()=>handle(true)),this.delay)}))}home(){this.choices=a(this.choices);this.index=0;return this.render()}end(){let e=this.choices.length-this.limit;let t=a(this.choices);this.choices=t.slice(e).concat(t.slice(0,e));this.index=this.limit-1;return this.render()}first(){this.index=0;return this.render()}last(){this.index=this.visible.length-1;return this.render()}prev(){if(this.visible.length<=1)return this.alert();return this.up()}next(){if(this.visible.length<=1)return this.alert();return this.down()}right(){if(this.cursor>=this.input.length)return this.alert();this.cursor++;return this.render()}left(){if(this.cursor<=0)return this.alert();this.cursor--;return this.render()}up(){let e=this.choices.length;let t=this.visible.length;let r=this.index;if(this.options.scroll===false&&r===0){return this.alert()}if(e>t&&r===0){return this.scrollUp()}this.index=(r-1%e+e)%e;if(this.isDisabled()&&!this.allChoicesAreDisabled()){return this.up()}return this.render()}down(){let e=this.choices.length;let t=this.visible.length;let r=this.index;if(this.options.scroll===false&&r===t-1){return this.alert()}if(e>t&&r===t-1){return this.scrollDown()}this.index=(r+1)%e;if(this.isDisabled()&&!this.allChoicesAreDisabled()){return this.down()}return this.render()}scrollUp(e=0){this.choices=l(this.choices);this.index=e;if(this.isDisabled()){return this.up()}return this.render()}scrollDown(e=this.visible.length-1){this.choices=u(this.choices);this.index=e;if(this.isDisabled()){return this.down()}return this.render()}async shiftUp(){if(this.options.sort===true){this.sorting=true;this.swap(this.index-1);await this.up();this.sorting=false;return}return this.scrollUp(this.index)}async shiftDown(){if(this.options.sort===true){this.sorting=true;this.swap(this.index+1);await this.down();this.sorting=false;return}return this.scrollDown(this.index)}pageUp(){if(this.visible.length<=1)return this.alert();this.limit=Math.max(this.limit-1,0);this.index=Math.min(this.limit-1,this.index);this._limit=this.limit;if(this.isDisabled()){return this.up()}return this.render()}pageDown(){if(this.visible.length>=this.choices.length)return this.alert();this.index=Math.max(0,this.index);this.limit=Math.min(this.limit+1,this.choices.length);this._limit=this.limit;if(this.isDisabled()){return this.down()}return this.render()}swap(e){f(this.choices,this.index,e)}allChoicesAreDisabled(e=this.choices){return e.every((e=>this.isDisabled(e)))}isDisabled(e=this.focused){let t=["disabled","collapsed","hidden","completing","readonly"];if(e&&t.some((t=>e[t]===true))){return true}return e&&e.role==="heading"}isEnabled(e=this.focused){if(Array.isArray(e))return e.every((e=>this.isEnabled(e)));if(e.choices){let t=e.choices.filter((e=>!this.isDisabled(e)));return e.enabled&&t.every((e=>this.isEnabled(e)))}return e.enabled&&!this.isDisabled(e)}isChoice(e,t){return e.name===t||e.index===Number(t)}isSelected(e){if(Array.isArray(this.initial)){return this.initial.some((t=>this.isChoice(e,t)))}return this.isChoice(e,this.initial)}map(e=[],t="value"){return[].concat(e||[]).reduce(((e,r)=>{e[r]=this.find(r,t);return e}),{})}filter(e,t){let isChoice=(t,r)=>[t.name,r].includes(e);let r=typeof e==="function"?e:isChoice;let i=this.options.multiple?this.state._choices:this.choices;let n=i.filter(r);if(t){return n.map((e=>e[t]))}return n}find(e,t){if(h(e))return t?e[t]:e;let isChoice=(t,r)=>[t.name,r].includes(e);let r=typeof e==="function"?e:isChoice;let i=this.choices.find(r);if(i){return t?i[t]:i}}findIndex(e){return this.choices.indexOf(this.find(e))}async submit(){let e=this.focused;if(!e)return this.alert();if(e.newChoice){if(!e.input)return this.alert();e.updateChoice();return this.render()}if(this.choices.some((e=>e.newChoice))){return this.alert()}let{reorder:t,sort:r}=this.options;let i=this.multiple===true;let n=this.selected;if(n===void 0){return this.alert()}if(Array.isArray(n)&&t!==false&&r!==true){n=o.reorder(n)}this.value=i?n.map((e=>e.name)):n.name;return super.submit()}set choices(e=[]){this.state._choices=this.state._choices||[];this.state.choices=e;for(let t of e){if(!this.state._choices.some((e=>e.name===t.name))){this.state._choices.push(t)}}if(!this._initial&&this.options.initial){this._initial=true;let e=this.initial;if(typeof e==="string"||typeof e==="number"){let t=this.find(e);if(t){this.initial=t.index;this.focus(t,true)}}}}get choices(){return reset(this,this.state.choices||[])}set visible(e){this.state.visible=e}get visible(){return(this.state.visible||this.choices).slice(0,this.limit)}set limit(e){this.state.limit=e}get limit(){let{state:e,options:t,choices:r}=this;let i=e.limit||this._limit||t.limit||r.length;return Math.min(i,this.height)}set value(e){super.value=e}get value(){if(typeof super.value!=="string"&&super.value===this.initial){return this.input}return super.value}set index(e){this.state.index=e}get index(){return Math.max(0,this.state?this.state.index:0)}get enabled(){return this.filter(this.isEnabled.bind(this))}get focused(){let e=this.choices[this.index];if(e&&this.state.submitted&&this.multiple!==true){e.enabled=true}return e}get selectable(){return this.choices.filter((e=>!this.isDisabled(e)))}get selected(){return this.multiple?this.enabled:this.focused}}function reset(e,t){if(t instanceof Promise)return t;if(typeof t==="function"){if(o.isAsyncFn(t))return t;t=t.call(e,e)}for(let r of t){if(Array.isArray(r.choices)){let t=r.choices.filter((t=>!e.isDisabled(t)));r.enabled=t.every((e=>e.enabled===true))}if(e.isDisabled(r)===true){delete r.enabled}}return t}e.exports=ArrayPrompt},8401:(e,t,r)=>{"use strict";const i=r(6151);const defaultAuthenticate=()=>{throw new Error("expected prompt to have a custom authenticate method")};const factory=(e=defaultAuthenticate)=>{class AuthPrompt extends i{constructor(e){super(e)}async submit(){this.value=await e.call(this,this.values,this.state);super.base.submit.call(this)}static create(e){return factory(e)}}return AuthPrompt};e.exports=factory()},8651:(e,t,r)=>{"use strict";const i=r(379);const{isPrimitive:n,hasColor:s}=r(6600);class BooleanPrompt extends i{constructor(e){super(e);this.cursorHide()}async initialize(){let e=await this.resolve(this.initial,this.state);this.input=await this.cast(e);await super.initialize()}dispatch(e){if(!this.isValue(e))return this.alert();this.input=e;return this.submit()}format(e){let{styles:t,state:r}=this;return!r.submitted?t.primary(e):t.success(e)}cast(e){return this.isTrue(e)}isTrue(e){return/^[ty1]/i.test(e)}isFalse(e){return/^[fn0]/i.test(e)}isValue(e){return n(e)&&(this.isTrue(e)||this.isFalse(e))}async hint(){if(this.state.status==="pending"){let e=await this.element("hint");if(!s(e)){return this.styles.muted(e)}return e}}async render(){let{input:e,size:t}=this.state;let r=await this.prefix();let i=await this.separator();let n=await this.message();let s=this.styles.muted(this.default);let o=[r,n,s,i].filter(Boolean).join(" ");this.state.prompt=o;let a=await this.header();let l=this.value=this.cast(e);let u=await this.format(l);let h=await this.error()||await this.hint();let f=await this.footer();if(h&&!o.includes(h))u+=" "+h;o+=" "+u;this.clear(t);this.write([a,o,f].filter(Boolean).join("\n"));this.restore()}set value(e){super.value=e}get value(){return this.cast(super.value)}}e.exports=BooleanPrompt},8075:(e,t,r)=>{e.exports={ArrayPrompt:r(4334),AuthPrompt:r(8401),BooleanPrompt:r(8651),NumberPrompt:r(4530),StringPrompt:r(3474)}},4530:(e,t,r)=>{"use strict";const i=r(3474);class NumberPrompt extends i{constructor(e={}){super({style:"number",...e});this.min=this.isValue(e.min)?this.toNumber(e.min):-Infinity;this.max=this.isValue(e.max)?this.toNumber(e.max):Infinity;this.delay=e.delay!=null?e.delay:1e3;this.float=e.float!==false;this.round=e.round===true||e.float===false;this.major=e.major||10;this.minor=e.minor||1;this.initial=e.initial!=null?e.initial:"";this.input=String(this.initial);this.cursor=this.input.length;this.cursorShow()}append(e){if(!/[-+.]/.test(e)||e==="."&&this.input.includes(".")){return this.alert("invalid number")}return super.append(e)}number(e){return super.append(e)}next(){if(this.input&&this.input!==this.initial)return this.alert();if(!this.isValue(this.initial))return this.alert();this.input=this.initial;this.cursor=String(this.initial).length;return this.render()}up(e){let t=e||this.minor;let r=this.toNumber(this.input);if(r>this.max+t)return this.alert();this.input=`${r+t}`;return this.render()}down(e){let t=e||this.minor;let r=this.toNumber(this.input);if(r<this.min-t)return this.alert();this.input=`${r-t}`;return this.render()}shiftDown(){return this.down(this.major)}shiftUp(){return this.up(this.major)}format(e=this.input){if(typeof this.options.format==="function"){return this.options.format.call(this,e)}return this.styles.info(e)}toNumber(e=""){return this.float?+e:Math.round(+e)}isValue(e){return/^[-+]?[0-9]+((\.)|(\.[0-9]+))?$/.test(e)}submit(){let e=[this.input,this.initial].find((e=>this.isValue(e)));this.value=this.toNumber(e||0);return super.submit()}}e.exports=NumberPrompt},3474:(e,t,r)=>{"use strict";const i=r(379);const n=r(3491);const s=r(2768);const{isPrimitive:o}=r(6600);class StringPrompt extends i{constructor(e){super(e);this.initial=o(this.initial)?String(this.initial):"";if(this.initial)this.cursorHide();this.state.prevCursor=0;this.state.clipboard=[];this.keypressTimeout=this.options.keypressTimeout!==undefined?this.options.keypressTimeout:null}async keypress(e,t=(e?n(e,{}):{})){const r=Date.now();const i=r-this.lastKeypress;this.lastKeypress=r;const s=t.name==="return"||t.name==="enter";let o=this.state.prevKeypress;let a;this.state.prevKeypress=t;if(this.keypressTimeout!=null&&s){if(i<this.keypressTimeout){return this.submit()}this.state.multilineBuffer=this.state.multilineBuffer||"";this.state.multilineBuffer+=e;a=true;o=null}if(a||this.options.multiline&&s){if(!o||o.name!=="return"){return this.append("\n",t)}}return super.keypress(e,t)}moveCursor(e){this.cursor+=e}reset(){this.input=this.value="";this.cursor=0;return this.render()}dispatch(e,t){if(!e||t.ctrl||t.code)return this.alert();this.append(e)}append(e){let{cursor:t,input:r}=this.state;this.input=`${r}`.slice(0,t)+e+`${r}`.slice(t);this.moveCursor(String(e).length);this.render()}insert(e){this.append(e)}delete(){let{cursor:e,input:t}=this.state;if(e<=0)return this.alert();this.input=`${t}`.slice(0,e-1)+`${t}`.slice(e);this.moveCursor(-1);this.render()}deleteForward(){let{cursor:e,input:t}=this.state;if(t[e]===void 0)return this.alert();this.input=`${t}`.slice(0,e)+`${t}`.slice(e+1);this.render()}cutForward(){let e=this.cursor;if(this.input.length<=e)return this.alert();this.state.clipboard.push(this.input.slice(e));this.input=this.input.slice(0,e);this.render()}cutLeft(){let e=this.cursor;if(e===0)return this.alert();let t=this.input.slice(0,e);let r=this.input.slice(e);let i=t.split(" ");this.state.clipboard.push(i.pop());this.input=i.join(" ");this.cursor=this.input.length;this.input+=r;this.render()}paste(){if(!this.state.clipboard.length)return this.alert();this.insert(this.state.clipboard.pop());this.render()}toggleCursor(){if(this.state.prevCursor){this.cursor=this.state.prevCursor;this.state.prevCursor=0}else{this.state.prevCursor=this.cursor;this.cursor=0}this.render()}first(){this.cursor=0;this.render()}last(){this.cursor=this.input.length-1;this.render()}next(){let e=this.initial!=null?String(this.initial):"";if(!e||!e.startsWith(this.input))return this.alert();this.input=this.initial;this.cursor=this.initial.length;this.render()}prev(){if(!this.input)return this.alert();this.reset()}backward(){return this.left()}forward(){return this.right()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1);return this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1);return this.render()}isValue(e){return!!e}async format(e=this.value){let t=await this.resolve(this.initial,this.state);if(!this.state.submitted){return s(this,{input:e,initial:t,pos:this.cursor})}return this.styles.submitted(e||t)}async render(){let e=this.state.size;let t=await this.prefix();let r=await this.separator();let i=await this.message();let n=[t,i,r].filter(Boolean).join(" ");this.state.prompt=n;let s=await this.header();let o=await this.format();let a=await this.error()||await this.hint();let l=await this.footer();if(a&&!o.includes(a))o+=" "+a;n+=" "+o;this.clear(e);this.write([s,n,l].filter(Boolean).join("\n"));this.restore()}}e.exports=StringPrompt},6600:(e,t,r)=>{"use strict";const i=Object.prototype.toString;const n=r(7182);let s=false;let o=new Set;const a={yellow:"blue",cyan:"red",green:"magenta",black:"white",blue:"yellow",red:"cyan",magenta:"green",white:"black"};t.longest=(e,t)=>e.reduce(((e,r)=>Math.max(e,t?r[t].length:r.length)),0);t.hasColor=e=>!!e&&n.hasColor(e);const l=t.isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);t.nativeType=e=>i.call(e).slice(8,-1).toLowerCase().replace(/\s/g,"");t.isAsyncFn=e=>t.nativeType(e)==="asyncfunction";t.isPrimitive=e=>e!=null&&typeof e!=="object"&&typeof e!=="function";t.resolve=(e,t,...r)=>{if(typeof t==="function"){return t.call(e,...r)}return t};t.scrollDown=(e=[])=>[...e.slice(1),e[0]];t.scrollUp=(e=[])=>[e.pop(),...e];t.reorder=(e=[])=>{let t=e.slice();t.sort(((e,t)=>{if(e.index>t.index)return 1;if(e.index<t.index)return-1;return 0}));return t};t.swap=(e,t,r)=>{let i=e.length;let n=r===i?0:r<0?i-1:r;let s=e[t];e[t]=e[n];e[n]=s};t.width=(e,t=80)=>{let r=e&&e.columns?e.columns:t;if(e&&typeof e.getWindowSize==="function"){r=e.getWindowSize()[0]}if(process.platform==="win32"){return r-1}return r};t.height=(e,t=20)=>{let r=e&&e.rows?e.rows:t;if(e&&typeof e.getWindowSize==="function"){r=e.getWindowSize()[1]}return r};t.wordWrap=(e,t={})=>{if(!e)return e;if(typeof t==="number"){t={width:t}}let{indent:r="",newline:i="\n"+r,width:n=80}=t;let s=(i+r).match(/[^\S\n]/g)||[];n-=s.length;let o=`.{1,${n}}([\\s\\u200B]+|$)|[^\\s\\u200B]+?([\\s\\u200B]+|$)`;let a=e.trim();let l=new RegExp(o,"g");let u=a.match(l)||[];u=u.map((e=>e.replace(/\n$/,"")));if(t.padEnd)u=u.map((e=>e.padEnd(n," ")));if(t.padStart)u=u.map((e=>e.padStart(n," ")));return r+u.join(i)};t.unmute=e=>{let t=e.stack.find((e=>n.keys.color.includes(e)));if(t){return n[t]}let r=e.stack.find((e=>e.slice(2)==="bg"));if(r){return n[t.slice(2)]}return e=>e};t.pascal=e=>e?e[0].toUpperCase()+e.slice(1):"";t.inverse=e=>{if(!e||!e.stack)return e;let r=e.stack.find((e=>n.keys.color.includes(e)));if(r){let i=n["bg"+t.pascal(r)];return i?i.black:e}let i=e.stack.find((e=>e.slice(0,2)==="bg"));if(i){return n[i.slice(2).toLowerCase()]||e}return n.none};t.complement=e=>{if(!e||!e.stack)return e;let r=e.stack.find((e=>n.keys.color.includes(e)));let i=e.stack.find((e=>e.slice(0,2)==="bg"));if(r&&!i){return n[a[r]||r]}if(i){let r=i.slice(2).toLowerCase();let s=a[r];if(!s)return e;return n["bg"+t.pascal(s)]||e}return n.none};t.meridiem=e=>{let t=e.getHours();let r=e.getMinutes();let i=t>=12?"pm":"am";t=t%12;let n=t===0?12:t;let s=r<10?"0"+r:r;return n+":"+s+" "+i};t.set=(e={},r="",i)=>r.split(".").reduce(((e,r,n,s)=>{let o=s.length-1>n?e[r]||{}:i;if(!t.isObject(o)&&n<s.length-1)o={};return e[r]=o}),e);t.get=(e={},t="",r)=>{let i=e[t]==null?t.split(".").reduce(((e,t)=>e&&e[t]),e):e[t];return i==null?r:i};t.mixin=(e,r)=>{if(!l(e))return r;if(!l(r))return e;for(let i of Object.keys(r)){let n=Object.getOwnPropertyDescriptor(r,i);if(hasOwnProperty.call(n,"value")){if(hasOwnProperty.call(e,i)&&l(n.value)){let s=Object.getOwnPropertyDescriptor(e,i);if(l(s.value)&&s.value!==n.value){e[i]=t.merge({},e[i],r[i])}else{Reflect.defineProperty(e,i,n)}}else{Reflect.defineProperty(e,i,n)}}else{Reflect.defineProperty(e,i,n)}}return e};t.merge=(...e)=>{let r={};for(let i of e)t.mixin(r,i);return r};t.mixinEmitter=(e,r)=>{let i=r.constructor.prototype;for(let n of Object.keys(i)){let s=i[n];if(typeof s==="function"){t.define(e,n,s.bind(r))}else{t.define(e,n,s)}}};const onExit=(e,t)=>{if(s)return;s=true;o.forEach((e=>e()));if(e===true){process.exit(128+t)}};const u=onExit.bind(null,true,15);const h=onExit.bind(null,true,2);t.onExit=e=>{if(o.size===0){process.once("SIGTERM",u);process.once("SIGINT",h);process.once("exit",onExit)}o.add(e);return()=>{o.delete(e);if(o.size===0){process.off("SIGTERM",u);process.off("SIGINT",h);process.off("exit",onExit)}}};t.define=(e,t,r)=>{Reflect.defineProperty(e,t,{value:r})};t.defineExport=(e,t,r)=>{let i;Reflect.defineProperty(e,t,{enumerable:true,configurable:true,set(e){i=e},get(){return i?i():r()}})}},8204:(e,t,r)=>{"use strict";const i=r(6928);const n=r(5317);const s=r(546);const o=r(1414);const a=r(6883);const l=r(9969);const u=r(8650);const h=r(5109);const{spawnedKill:f,spawnedCancel:p,setupTimeout:d,validateTimeout:m,setExitHandler:g}=r(9066);const{handleInput:y,getSpawnedResult:b,makeAllStream:_,validateInputSync:v}=r(7750);const{mergePromise:w,getSpawnedPromise:S}=r(381);const{joinCommand:x,parseCommand:E,getEscapedCommand:A}=r(413);const k=1e3*1e3*100;const getEnv=({env:e,extendEnv:t,preferLocal:r,localDir:i,execPath:n})=>{const s=t?{...process.env,...e}:e;if(r){return a.env({env:s,cwd:i,execPath:n})}return s};const handleArguments=(e,t,r={})=>{const n=s._parse(e,t,r);e=n.command;t=n.args;r=n.options;r={maxBuffer:k,buffer:true,stripFinalNewline:true,extendEnv:true,preferLocal:false,localDir:r.cwd||process.cwd(),execPath:process.execPath,encoding:"utf8",reject:true,cleanup:true,all:false,windowsHide:true,...r};r.env=getEnv(r);r.stdio=h(r);if(process.platform==="win32"&&i.basename(e,".exe")==="cmd"){t.unshift("/q")}return{file:e,args:t,options:r,parsed:n}};const handleOutput=(e,t,r)=>{if(typeof t!=="string"&&!Buffer.isBuffer(t)){return r===undefined?undefined:""}if(e.stripFinalNewline){return o(t)}return t};const execa=(e,t,r)=>{const i=handleArguments(e,t,r);const s=x(e,t);const o=A(e,t);m(i.options);let a;try{a=n.spawn(i.file,i.args,i.options)}catch(e){const t=new n.ChildProcess;const r=Promise.reject(u({error:e,stdout:"",stderr:"",all:"",command:s,escapedCommand:o,parsed:i,timedOut:false,isCanceled:false,killed:false}));return w(t,r)}const h=S(a);const v=d(a,i.options,h);const E=g(a,i.options,v);const k={isCanceled:false};a.kill=f.bind(null,a.kill.bind(a));a.cancel=p.bind(null,a,k);const handlePromise=async()=>{const[{error:e,exitCode:t,signal:r,timedOut:n},l,h,f]=await b(a,i.options,E);const p=handleOutput(i.options,l);const d=handleOutput(i.options,h);const m=handleOutput(i.options,f);if(e||t!==0||r!==null){const l=u({error:e,exitCode:t,signal:r,stdout:p,stderr:d,all:m,command:s,escapedCommand:o,parsed:i,timedOut:n,isCanceled:k.isCanceled,killed:a.killed});if(!i.options.reject){return l}throw l}return{command:s,escapedCommand:o,exitCode:0,stdout:p,stderr:d,all:m,failed:false,timedOut:false,isCanceled:false,killed:false}};const C=l(handlePromise);y(a,i.options.input);a.all=_(a,i.options);return w(a,C)};e.exports=execa;e.exports.sync=(e,t,r)=>{const i=handleArguments(e,t,r);const s=x(e,t);const o=A(e,t);v(i.options);let a;try{a=n.spawnSync(i.file,i.args,i.options)}catch(e){throw u({error:e,stdout:"",stderr:"",all:"",command:s,escapedCommand:o,parsed:i,timedOut:false,isCanceled:false,killed:false})}const l=handleOutput(i.options,a.stdout,a.error);const h=handleOutput(i.options,a.stderr,a.error);if(a.error||a.status!==0||a.signal!==null){const e=u({stdout:l,stderr:h,error:a.error,signal:a.signal,exitCode:a.status,command:s,escapedCommand:o,parsed:i,timedOut:a.error&&a.error.code==="ETIMEDOUT",isCanceled:false,killed:a.signal!==null});if(!i.options.reject){return e}throw e}return{command:s,escapedCommand:o,exitCode:0,stdout:l,stderr:h,failed:false,timedOut:false,isCanceled:false,killed:false}};e.exports.command=(e,t)=>{const[r,...i]=E(e);return execa(r,i,t)};e.exports.commandSync=(e,t)=>{const[r,...i]=E(e);return execa.sync(r,i,t)};e.exports.node=(e,t,r={})=>{if(t&&!Array.isArray(t)&&typeof t==="object"){r=t;t=[]}const i=h.node(r);const n=process.execArgv.filter((e=>!e.startsWith("--inspect")));const{nodePath:s=process.execPath,nodeOptions:o=n}=r;return execa(s,[...o,e,...Array.isArray(t)?t:[]],{...r,stdin:undefined,stdout:undefined,stderr:undefined,stdio:i,shell:false})}},413:e=>{"use strict";const normalizeArgs=(e,t=[])=>{if(!Array.isArray(t)){return[e]}return[e,...t]};const t=/^[\w.-]+$/;const r=/"/g;const escapeArg=e=>{if(typeof e!=="string"||t.test(e)){return e}return`"${e.replace(r,'\\"')}"`};const joinCommand=(e,t)=>normalizeArgs(e,t).join(" ");const getEscapedCommand=(e,t)=>normalizeArgs(e,t).map((e=>escapeArg(e))).join(" ");const i=/ +/g;const parseCommand=e=>{const t=[];for(const r of e.trim().split(i)){const e=t[t.length-1];if(e&&e.endsWith("\\")){t[t.length-1]=`${e.slice(0,-1)} ${r}`}else{t.push(r)}}return t};e.exports={joinCommand:joinCommand,getEscapedCommand:getEscapedCommand,parseCommand:parseCommand}},8650:(e,t,r)=>{"use strict";const{signalsByName:i}=r(4366);const getErrorPrefix=({timedOut:e,timeout:t,errorCode:r,signal:i,signalDescription:n,exitCode:s,isCanceled:o})=>{if(e){return`timed out after ${t} milliseconds`}if(o){return"was canceled"}if(r!==undefined){return`failed with ${r}`}if(i!==undefined){return`was killed with ${i} (${n})`}if(s!==undefined){return`failed with exit code ${s}`}return"failed"};const makeError=({stdout:e,stderr:t,all:r,error:n,signal:s,exitCode:o,command:a,escapedCommand:l,timedOut:u,isCanceled:h,killed:f,parsed:{options:{timeout:p}}})=>{o=o===null?undefined:o;s=s===null?undefined:s;const d=s===undefined?undefined:i[s].description;const m=n&&n.code;const g=getErrorPrefix({timedOut:u,timeout:p,errorCode:m,signal:s,signalDescription:d,exitCode:o,isCanceled:h});const y=`Command ${g}: ${a}`;const b=Object.prototype.toString.call(n)==="[object Error]";const _=b?`${y}\n${n.message}`:y;const v=[_,t,e].filter(Boolean).join("\n");if(b){n.originalMessage=n.message;n.message=v}else{n=new Error(v)}n.shortMessage=_;n.command=a;n.escapedCommand=l;n.exitCode=o;n.signal=s;n.signalDescription=d;n.stdout=e;n.stderr=t;if(r!==undefined){n.all=r}if("bufferedData"in n){delete n.bufferedData}n.failed=true;n.timedOut=Boolean(u);n.isCanceled=h;n.killed=f&&!u;return n};e.exports=makeError},9066:(e,t,r)=>{"use strict";const i=r(857);const n=r(6627);const s=1e3*5;const spawnedKill=(e,t="SIGTERM",r={})=>{const i=e(t);setKillTimeout(e,t,r,i);return i};const setKillTimeout=(e,t,r,i)=>{if(!shouldForceKill(t,r,i)){return}const n=getForceKillAfterTimeout(r);const s=setTimeout((()=>{e("SIGKILL")}),n);if(s.unref){s.unref()}};const shouldForceKill=(e,{forceKillAfterTimeout:t},r)=>isSigterm(e)&&t!==false&&r;const isSigterm=e=>e===i.constants.signals.SIGTERM||typeof e==="string"&&e.toUpperCase()==="SIGTERM";const getForceKillAfterTimeout=({forceKillAfterTimeout:e=true})=>{if(e===true){return s}if(!Number.isFinite(e)||e<0){throw new TypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${e}\` (${typeof e})`)}return e};const spawnedCancel=(e,t)=>{const r=e.kill();if(r){t.isCanceled=true}};const timeoutKill=(e,t,r)=>{e.kill(t);r(Object.assign(new Error("Timed out"),{timedOut:true,signal:t}))};const setupTimeout=(e,{timeout:t,killSignal:r="SIGTERM"},i)=>{if(t===0||t===undefined){return i}let n;const s=new Promise(((i,s)=>{n=setTimeout((()=>{timeoutKill(e,r,s)}),t)}));const o=i.finally((()=>{clearTimeout(n)}));return Promise.race([s,o])};const validateTimeout=({timeout:e})=>{if(e!==undefined&&(!Number.isFinite(e)||e<0)){throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${e}\` (${typeof e})`)}};const setExitHandler=async(e,{cleanup:t,detached:r},i)=>{if(!t||r){return i}const s=n((()=>{e.kill()}));return i.finally((()=>{s()}))};e.exports={spawnedKill:spawnedKill,spawnedCancel:spawnedCancel,setupTimeout:setupTimeout,validateTimeout:validateTimeout,setExitHandler:setExitHandler}},381:e=>{"use strict";const t=(async()=>{})().constructor.prototype;const r=["then","catch","finally"].map((e=>[e,Reflect.getOwnPropertyDescriptor(t,e)]));const mergePromise=(e,t)=>{for(const[i,n]of r){const r=typeof t==="function"?(...e)=>Reflect.apply(n.value,t(),e):n.value.bind(t);Reflect.defineProperty(e,i,{...n,value:r})}return e};const getSpawnedPromise=e=>new Promise(((t,r)=>{e.on("exit",((e,r)=>{t({exitCode:e,signal:r})}));e.on("error",(e=>{r(e)}));if(e.stdin){e.stdin.on("error",(e=>{r(e)}))}}));e.exports={mergePromise:mergePromise,getSpawnedPromise:getSpawnedPromise}},5109:e=>{"use strict";const t=["stdin","stdout","stderr"];const hasAlias=e=>t.some((t=>e[t]!==undefined));const normalizeStdio=e=>{if(!e){return}const{stdio:r}=e;if(r===undefined){return t.map((t=>e[t]))}if(hasAlias(e)){throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${t.map((e=>`\`${e}\``)).join(", ")}`)}if(typeof r==="string"){return r}if(!Array.isArray(r)){throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof r}\``)}const i=Math.max(r.length,t.length);return Array.from({length:i},((e,t)=>r[t]))};e.exports=normalizeStdio;e.exports.node=e=>{const t=normalizeStdio(e);if(t==="ipc"){return"ipc"}if(t===undefined||typeof t==="string"){return[t,t,t,"ipc"]}if(t.includes("ipc")){return t}return[...t,"ipc"]}},7750:(e,t,r)=>{"use strict";const i=r(6543);const n=r(6771);const s=r(8595);const handleInput=(e,t)=>{if(t===undefined||e.stdin===undefined){return}if(i(t)){t.pipe(e.stdin)}else{e.stdin.end(t)}};const makeAllStream=(e,{all:t})=>{if(!t||!e.stdout&&!e.stderr){return}const r=s();if(e.stdout){r.add(e.stdout)}if(e.stderr){r.add(e.stderr)}return r};const getBufferedData=async(e,t)=>{if(!e){return}e.destroy();try{return await t}catch(e){return e.bufferedData}};const getStreamPromise=(e,{encoding:t,buffer:r,maxBuffer:i})=>{if(!e||!r){return}if(t){return n(e,{encoding:t,maxBuffer:i})}return n.buffer(e,{maxBuffer:i})};const getSpawnedResult=async({stdout:e,stderr:t,all:r},{encoding:i,buffer:n,maxBuffer:s},o)=>{const a=getStreamPromise(e,{encoding:i,buffer:n,maxBuffer:s});const l=getStreamPromise(t,{encoding:i,buffer:n,maxBuffer:s});const u=getStreamPromise(r,{encoding:i,buffer:n,maxBuffer:s*2});try{return await Promise.all([o,a,l,u])}catch(i){return Promise.all([{error:i,signal:i.signal,timedOut:i.timedOut},getBufferedData(e,a),getBufferedData(t,l),getBufferedData(r,u)])}};const validateInputSync=({input:e})=>{if(i(e)){throw new TypeError("The `input` option cannot be a stream in sync mode")}};e.exports={handleInput:handleInput,makeAllStream:makeAllStream,getSpawnedResult:getSpawnedResult,validateInputSync:validateInputSync}},8188:(e,t,r)=>{"use strict";var i=r(1925);var n=r(6928).posix.dirname;var s=r(857).platform()==="win32";var o="/";var a=/\\/g;var l=/[\{\[].*[\}\]]$/;var u=/(^|[^\\])([\{\[]|\([^\)]+$)/;var h=/\\([\!\*\?\|\[\]\(\)\{\}])/g;e.exports=function globParent(e,t){var r=Object.assign({flipBackslashes:true},t);if(r.flipBackslashes&&s&&e.indexOf(o)<0){e=e.replace(a,o)}if(l.test(e)){e+=o}e+="a";do{e=n(e)}while(i(e)||u.test(e));return e.replace(h,"$1")}},5648:(e,t,r)=>{"use strict";const i=r(6599);const n=r(645);const s=r(1969);const o=r(5894);const a=r(879);const l=r(6002);async function FastGlob(e,t){assertPatternsInput(e);const r=getWorks(e,n.default,t);const i=await Promise.all(r);return l.array.flatten(i)}(function(e){e.glob=e;e.globSync=sync;e.globStream=stream;e.async=e;function sync(e,t){assertPatternsInput(e);const r=getWorks(e,o.default,t);return l.array.flatten(r)}e.sync=sync;function stream(e,t){assertPatternsInput(e);const r=getWorks(e,s.default,t);return l.stream.merge(r)}e.stream=stream;function generateTasks(e,t){assertPatternsInput(e);const r=[].concat(e);const n=new a.default(t);return i.generate(r,n)}e.generateTasks=generateTasks;function isDynamicPattern(e,t){assertPatternsInput(e);const r=new a.default(t);return l.pattern.isDynamicPattern(e,r)}e.isDynamicPattern=isDynamicPattern;function escapePath(e){assertPatternsInput(e);return l.path.escape(e)}e.escapePath=escapePath;function convertPathToPattern(e){assertPatternsInput(e);return l.path.convertPathToPattern(e)}e.convertPathToPattern=convertPathToPattern;let t;(function(e){function escapePath(e){assertPatternsInput(e);return l.path.escapePosixPath(e)}e.escapePath=escapePath;function convertPathToPattern(e){assertPatternsInput(e);return l.path.convertPosixPathToPattern(e)}e.convertPathToPattern=convertPathToPattern})(t=e.posix||(e.posix={}));let r;(function(e){function escapePath(e){assertPatternsInput(e);return l.path.escapeWindowsPath(e)}e.escapePath=escapePath;function convertPathToPattern(e){assertPatternsInput(e);return l.path.convertWindowsPathToPattern(e)}e.convertPathToPattern=convertPathToPattern})(r=e.win32||(e.win32={}))})(FastGlob||(FastGlob={}));function getWorks(e,t,r){const n=[].concat(e);const s=new a.default(r);const o=i.generate(n,s);const l=new t(s);return o.map(l.read,l)}function assertPatternsInput(e){const t=[].concat(e);const r=t.every((e=>l.string.isString(e)&&!l.string.isEmpty(e)));if(!r){throw new TypeError("Patterns must be a string (non empty) or an array of strings")}}e.exports=FastGlob},6599:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.convertPatternGroupToTask=t.convertPatternGroupsToTasks=t.groupPatternsByBaseDirectory=t.getNegativePatternsAsPositive=t.getPositivePatterns=t.convertPatternsToTasks=t.generate=void 0;const i=r(6002);function generate(e,t){const r=processPatterns(e,t);const n=processPatterns(t.ignore,t);const s=getPositivePatterns(r);const o=getNegativePatternsAsPositive(r,n);const a=s.filter((e=>i.pattern.isStaticPattern(e,t)));const l=s.filter((e=>i.pattern.isDynamicPattern(e,t)));const u=convertPatternsToTasks(a,o,false);const h=convertPatternsToTasks(l,o,true);return u.concat(h)}t.generate=generate;function processPatterns(e,t){let r=e;if(t.braceExpansion){r=i.pattern.expandPatternsWithBraceExpansion(r)}if(t.baseNameMatch){r=r.map((e=>e.includes("/")?e:`**/${e}`))}return r.map((e=>i.pattern.removeDuplicateSlashes(e)))}function convertPatternsToTasks(e,t,r){const n=[];const s=i.pattern.getPatternsOutsideCurrentDirectory(e);const o=i.pattern.getPatternsInsideCurrentDirectory(e);const a=groupPatternsByBaseDirectory(s);const l=groupPatternsByBaseDirectory(o);n.push(...convertPatternGroupsToTasks(a,t,r));if("."in l){n.push(convertPatternGroupToTask(".",o,t,r))}else{n.push(...convertPatternGroupsToTasks(l,t,r))}return n}t.convertPatternsToTasks=convertPatternsToTasks;function getPositivePatterns(e){return i.pattern.getPositivePatterns(e)}t.getPositivePatterns=getPositivePatterns;function getNegativePatternsAsPositive(e,t){const r=i.pattern.getNegativePatterns(e).concat(t);const n=r.map(i.pattern.convertToPositivePattern);return n}t.getNegativePatternsAsPositive=getNegativePatternsAsPositive;function groupPatternsByBaseDirectory(e){const t={};return e.reduce(((e,t)=>{const r=i.pattern.getBaseDirectory(t);if(r in e){e[r].push(t)}else{e[r]=[t]}return e}),t)}t.groupPatternsByBaseDirectory=groupPatternsByBaseDirectory;function convertPatternGroupsToTasks(e,t,r){return Object.keys(e).map((i=>convertPatternGroupToTask(i,e[i],t,r)))}t.convertPatternGroupsToTasks=convertPatternGroupsToTasks;function convertPatternGroupToTask(e,t,r,n){return{dynamic:n,positive:t,negative:r,base:e,patterns:[].concat(t,r.map(i.pattern.convertToNegativePattern))}}t.convertPatternGroupToTask=convertPatternGroupToTask},645:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(2907);const n=r(7792);class ProviderAsync extends n.default{constructor(){super(...arguments);this._reader=new i.default(this._settings)}async read(e){const t=this._getRootDirectory(e);const r=this._getReaderOptions(e);const i=await this.api(t,e,r);return i.map((e=>r.transform(e)))}api(e,t,r){if(t.dynamic){return this._reader.dynamic(e,r)}return this._reader.static(t.patterns,r)}}t["default"]=ProviderAsync},3591:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6002);const n=r(5740);class DeepFilter{constructor(e,t){this._settings=e;this._micromatchOptions=t}getFilter(e,t,r){const i=this._getMatcher(t);const n=this._getNegativePatternsRe(r);return t=>this._filter(e,t,i,n)}_getMatcher(e){return new n.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){const t=e.filter(i.pattern.isAffectDepthOfReadingPattern);return i.pattern.convertPatternsToRe(t,this._micromatchOptions)}_filter(e,t,r,n){if(this._isSkippedByDeep(e,t.path)){return false}if(this._isSkippedSymbolicLink(t)){return false}const s=i.path.removeLeadingDotSegment(t.path);if(this._isSkippedByPositivePatterns(s,r)){return false}return this._isSkippedByNegativePatterns(s,n)}_isSkippedByDeep(e,t){if(this._settings.deep===Infinity){return false}return this._getEntryLevel(e,t)>=this._settings.deep}_getEntryLevel(e,t){const r=t.split("/").length;if(e===""){return r}const i=e.split("/").length;return r-i}_isSkippedSymbolicLink(e){return!this._settings.followSymbolicLinks&&e.dirent.isSymbolicLink()}_isSkippedByPositivePatterns(e,t){return!this._settings.baseNameMatch&&!t.match(e)}_isSkippedByNegativePatterns(e,t){return!i.pattern.matchAny(e,t)}}t["default"]=DeepFilter},4285:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6002);class EntryFilter{constructor(e,t){this._settings=e;this._micromatchOptions=t;this.index=new Map}getFilter(e,t){const r=i.pattern.convertPatternsToRe(e,this._micromatchOptions);const n=i.pattern.convertPatternsToRe(t,Object.assign(Object.assign({},this._micromatchOptions),{dot:true}));return e=>this._filter(e,r,n)}_filter(e,t,r){const n=i.path.removeLeadingDotSegment(e.path);if(this._settings.unique&&this._isDuplicateEntry(n)){return false}if(this._onlyFileFilter(e)||this._onlyDirectoryFilter(e)){return false}if(this._isSkippedByAbsoluteNegativePatterns(n,r)){return false}const s=e.dirent.isDirectory();const o=this._isMatchToPatterns(n,t,s)&&!this._isMatchToPatterns(n,r,s);if(this._settings.unique&&o){this._createIndexRecord(n)}return o}_isDuplicateEntry(e){return this.index.has(e)}_createIndexRecord(e){this.index.set(e,undefined)}_onlyFileFilter(e){return this._settings.onlyFiles&&!e.dirent.isFile()}_onlyDirectoryFilter(e){return this._settings.onlyDirectories&&!e.dirent.isDirectory()}_isSkippedByAbsoluteNegativePatterns(e,t){if(!this._settings.absolute){return false}const r=i.path.makeAbsolute(this._settings.cwd,e);return i.pattern.matchAny(r,t)}_isMatchToPatterns(e,t,r){const n=i.pattern.matchAny(e,t);if(!n&&r){return i.pattern.matchAny(e+"/",t)}return n}}t["default"]=EntryFilter},1587:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6002);class ErrorFilter{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return i.errno.isEnoentCodeError(e)||this._settings.suppressErrors}}t["default"]=ErrorFilter},7827:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6002);class Matcher{constructor(e,t,r){this._patterns=e;this._settings=t;this._micromatchOptions=r;this._storage=[];this._fillStorage()}_fillStorage(){for(const e of this._patterns){const t=this._getPatternSegments(e);const r=this._splitSegmentsIntoSections(t);this._storage.push({complete:r.length<=1,pattern:e,segments:t,sections:r})}}_getPatternSegments(e){const t=i.pattern.getPatternParts(e,this._micromatchOptions);return t.map((e=>{const t=i.pattern.isDynamicPattern(e,this._settings);if(!t){return{dynamic:false,pattern:e}}return{dynamic:true,pattern:e,patternRe:i.pattern.makeRe(e,this._micromatchOptions)}}))}_splitSegmentsIntoSections(e){return i.array.splitWhen(e,(e=>e.dynamic&&i.pattern.hasGlobStar(e.pattern)))}}t["default"]=Matcher},5740:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(7827);class PartialMatcher extends i.default{match(e){const t=e.split("/");const r=t.length;const i=this._storage.filter((e=>!e.complete||e.segments.length>r));for(const e of i){const i=e.sections[0];if(!e.complete&&r>i.length){return true}const n=t.every(((t,r)=>{const i=e.segments[r];if(i.dynamic&&i.patternRe.test(t)){return true}if(!i.dynamic&&i.pattern===t){return true}return false}));if(n){return true}}return false}}t["default"]=PartialMatcher},7792:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6928);const n=r(3591);const s=r(4285);const o=r(1587);const a=r(7094);class Provider{constructor(e){this._settings=e;this.errorFilter=new o.default(this._settings);this.entryFilter=new s.default(this._settings,this._getMicromatchOptions());this.deepFilter=new n.default(this._settings,this._getMicromatchOptions());this.entryTransformer=new a.default(this._settings)}_getRootDirectory(e){return i.resolve(this._settings.cwd,e.base)}_getReaderOptions(e){const t=e.base==="."?"":e.base;return{basePath:t,pathSegmentSeparator:"/",concurrency:this._settings.concurrency,deepFilter:this.deepFilter.getFilter(t,e.positive,e.negative),entryFilter:this.entryFilter.getFilter(e.positive,e.negative),errorFilter:this.errorFilter.getFilter(),followSymbolicLinks:this._settings.followSymbolicLinks,fs:this._settings.fs,stats:this._settings.stats,throwErrorOnBrokenSymbolicLink:this._settings.throwErrorOnBrokenSymbolicLink,transform:this.entryTransformer.getTransformer()}}_getMicromatchOptions(){return{dot:this._settings.dot,matchBase:this._settings.baseNameMatch,nobrace:!this._settings.braceExpansion,nocase:!this._settings.caseSensitiveMatch,noext:!this._settings.extglob,noglobstar:!this._settings.globstar,posix:true,strictSlashes:false}}}t["default"]=Provider},1969:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(2203);const n=r(87);const s=r(7792);class ProviderStream extends s.default{constructor(){super(...arguments);this._reader=new n.default(this._settings)}read(e){const t=this._getRootDirectory(e);const r=this._getReaderOptions(e);const n=this.api(t,e,r);const s=new i.Readable({objectMode:true,read:()=>{}});n.once("error",(e=>s.emit("error",e))).on("data",(e=>s.emit("data",r.transform(e)))).once("end",(()=>s.emit("end")));s.once("close",(()=>n.destroy()));return s}api(e,t,r){if(t.dynamic){return this._reader.dynamic(e,r)}return this._reader.static(t.patterns,r)}}t["default"]=ProviderStream},5894:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(264);const n=r(7792);class ProviderSync extends n.default{constructor(){super(...arguments);this._reader=new i.default(this._settings)}read(e){const t=this._getRootDirectory(e);const r=this._getReaderOptions(e);const i=this.api(t,e,r);return i.map(r.transform)}api(e,t,r){if(t.dynamic){return this._reader.dynamic(e,r)}return this._reader.static(t.patterns,r)}}t["default"]=ProviderSync},7094:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6002);class EntryTransformer{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let t=e.path;if(this._settings.absolute){t=i.path.makeAbsolute(this._settings.cwd,t);t=i.path.unixify(t)}if(this._settings.markDirectories&&e.dirent.isDirectory()){t+="/"}if(!this._settings.objectMode){return t}return Object.assign(Object.assign({},e),{path:t})}}t["default"]=EntryTransformer},2907:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(9337);const n=r(1824);const s=r(87);class ReaderAsync extends n.default{constructor(){super(...arguments);this._walkAsync=i.walk;this._readerStream=new s.default(this._settings)}dynamic(e,t){return new Promise(((r,i)=>{this._walkAsync(e,t,((e,t)=>{if(e===null){r(t)}else{i(e)}}))}))}async static(e,t){const r=[];const i=this._readerStream.static(e,t);return new Promise(((e,t)=>{i.once("error",t);i.on("data",(e=>r.push(e)));i.once("end",(()=>e(r)))}))}}t["default"]=ReaderAsync},1824:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(6928);const n=r(1470);const s=r(6002);class Reader{constructor(e){this._settings=e;this._fsStatSettings=new n.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return i.resolve(this._settings.cwd,e)}_makeEntry(e,t){const r={name:t,path:t,dirent:s.fs.createDirentFromStats(t,e)};if(this._settings.stats){r.stats=e}return r}_isFatalError(e){return!s.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}}t["default"]=Reader},87:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(2203);const n=r(1470);const s=r(9337);const o=r(1824);class ReaderStream extends o.default{constructor(){super(...arguments);this._walkStream=s.walkStream;this._stat=n.stat}dynamic(e,t){return this._walkStream(e,t)}static(e,t){const r=e.map(this._getFullEntryPath,this);const n=new i.PassThrough({objectMode:true});n._write=(i,s,o)=>this._getEntry(r[i],e[i],t).then((e=>{if(e!==null&&t.entryFilter(e)){n.push(e)}if(i===r.length-1){n.end()}o()})).catch(o);for(let e=0;e<r.length;e++){n.write(e)}return n}_getEntry(e,t,r){return this._getStat(e).then((e=>this._makeEntry(e,t))).catch((e=>{if(r.errorFilter(e)){return null}throw e}))}_getStat(e){return new Promise(((t,r)=>{this._stat(e,this._fsStatSettings,((e,i)=>e===null?t(i):r(e)))}))}}t["default"]=ReaderStream},264:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const i=r(1470);const n=r(9337);const s=r(1824);class ReaderSync extends s.default{constructor(){super(...arguments);this._walkSync=n.walkSync;this._statSync=i.statSync}dynamic(e,t){return this._walkSync(e,t)}static(e,t){const r=[];for(const i of e){const e=this._getFullEntryPath(i);const n=this._getEntry(e,i,t);if(n===null||!t.entryFilter(n)){continue}r.push(n)}return r}_getEntry(e,t,r){try{const r=this._getStat(e);return this._makeEntry(r,t)}catch(e){if(r.errorFilter(e)){return null}throw e}}_getStat(e){return this._statSync(e,this._fsStatSettings)}}t["default"]=ReaderSync},879:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DEFAULT_FILE_SYSTEM_ADAPTER=void 0;const i=r(9896);const n=r(857);const s=Math.max(n.cpus().length,1);t.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:i.lstat,lstatSync:i.lstatSync,stat:i.stat,statSync:i.statSync,readdir:i.readdir,readdirSync:i.readdirSync};class Settings{constructor(e={}){this._options=e;this.absolute=this._getValue(this._options.absolute,false);this.baseNameMatch=this._getValue(this._options.baseNameMatch,false);this.braceExpansion=this._getValue(this._options.braceExpansion,true);this.caseSensitiveMatch=this._getValue(this._options.caseSensitiveMatch,true);this.concurrency=this._getValue(this._options.concurrency,s);this.cwd=this._getValue(this._options.cwd,process.cwd());this.deep=this._getValue(this._options.deep,Infinity);this.dot=this._getValue(this._options.dot,false);this.extglob=this._getValue(this._options.extglob,true);this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,true);this.fs=this._getFileSystemMethods(this._options.fs);this.globstar=this._getValue(this._options.globstar,true);this.ignore=this._getValue(this._options.ignore,[]);this.markDirectories=this._getValue(this._options.markDirectories,false);this.objectMode=this._getValue(this._options.objectMode,false);this.onlyDirectories=this._getValue(this._options.onlyDirectories,false);this.onlyFiles=this._getValue(this._options.onlyFiles,true);this.stats=this._getValue(this._options.stats,false);this.suppressErrors=this._getValue(this._options.suppressErrors,false);this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,false);this.unique=this._getValue(this._options.unique,true);if(this.onlyDirectories){this.onlyFiles=false}if(this.stats){this.objectMode=true}this.ignore=[].concat(this.ignore)}_getValue(e,t){return e===undefined?t:e}_getFileSystemMethods(e={}){return Object.assign(Object.assign({},t.DEFAULT_FILE_SYSTEM_ADAPTER),e)}}t["default"]=Settings},5711:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.splitWhen=t.flatten=void 0;function flatten(e){return e.reduce(((e,t)=>[].concat(e,t)),[])}t.flatten=flatten;function splitWhen(e,t){const r=[[]];let i=0;for(const n of e){if(t(n)){i++;r[i]=[]}else{r[i].push(n)}}return r}t.splitWhen=splitWhen},9718:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isEnoentCodeError=void 0;function isEnoentCodeError(e){return e.code==="ENOENT"}t.isEnoentCodeError=isEnoentCodeError},6979:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createDirentFromStats=void 0;class DirentFromStats{constructor(e,t){this.name=e;this.isBlockDevice=t.isBlockDevice.bind(t);this.isCharacterDevice=t.isCharacterDevice.bind(t);this.isDirectory=t.isDirectory.bind(t);this.isFIFO=t.isFIFO.bind(t);this.isFile=t.isFile.bind(t);this.isSocket=t.isSocket.bind(t);this.isSymbolicLink=t.isSymbolicLink.bind(t)}}function createDirentFromStats(e,t){return new DirentFromStats(e,t)}t.createDirentFromStats=createDirentFromStats},6002:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.string=t.stream=t.pattern=t.path=t.fs=t.errno=t.array=void 0;const i=r(5711);t.array=i;const n=r(9718);t.errno=n;const s=r(6979);t.fs=s;const o=r(9283);t.path=o;const a=r(1304);t.pattern=a;const l=r(536);t.stream=l;const u=r(7641);t.string=u},9283:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.convertPosixPathToPattern=t.convertWindowsPathToPattern=t.convertPathToPattern=t.escapePosixPath=t.escapeWindowsPath=t.escape=t.removeLeadingDotSegment=t.makeAbsolute=t.unixify=void 0;const i=r(857);const n=r(6928);const s=i.platform()==="win32";const o=2;const a=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\()|\\(?![!()*+?@[\]{|}]))/g;const l=/(\\?)([()[\]{}]|^!|[!+@](?=\())/g;const u=/^\\\\([.?])/;const h=/\\(?![!()+@[\]{}])/g;function unixify(e){return e.replace(/\\/g,"/")}t.unixify=unixify;function makeAbsolute(e,t){return n.resolve(e,t)}t.makeAbsolute=makeAbsolute;function removeLeadingDotSegment(e){if(e.charAt(0)==="."){const t=e.charAt(1);if(t==="/"||t==="\\"){return e.slice(o)}}return e}t.removeLeadingDotSegment=removeLeadingDotSegment;t.escape=s?escapeWindowsPath:escapePosixPath;function escapeWindowsPath(e){return e.replace(l,"\\$2")}t.escapeWindowsPath=escapeWindowsPath;function escapePosixPath(e){return e.replace(a,"\\$2")}t.escapePosixPath=escapePosixPath;t.convertPathToPattern=s?convertWindowsPathToPattern:convertPosixPathToPattern;function convertWindowsPathToPattern(e){return escapeWindowsPath(e).replace(u,"//$1").replace(h,"/")}t.convertWindowsPathToPattern=convertWindowsPathToPattern;function convertPosixPathToPattern(e){return escapePosixPath(e)}t.convertPosixPathToPattern=convertPosixPathToPattern},1304:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.removeDuplicateSlashes=t.matchAny=t.convertPatternsToRe=t.makeRe=t.getPatternParts=t.expandBraceExpansion=t.expandPatternsWithBraceExpansion=t.isAffectDepthOfReadingPattern=t.endsWithSlashGlobStar=t.hasGlobStar=t.getBaseDirectory=t.isPatternRelatedToParentDirectory=t.getPatternsOutsideCurrentDirectory=t.getPatternsInsideCurrentDirectory=t.getPositivePatterns=t.getNegativePatterns=t.isPositivePattern=t.isNegativePattern=t.convertToNegativePattern=t.convertToPositivePattern=t.isDynamicPattern=t.isStaticPattern=void 0;const i=r(6928);const n=r(8188);const s=r(8785);const o="**";const a="\\";const l=/[*?]|^!/;const u=/\[[^[]*]/;const h=/(?:^|[^!*+?@])\([^(]*\|[^|]*\)/;const f=/[!*+?@]\([^(]*\)/;const p=/,|\.\./;const d=/(?!^)\/{2,}/g;function isStaticPattern(e,t={}){return!isDynamicPattern(e,t)}t.isStaticPattern=isStaticPattern;function isDynamicPattern(e,t={}){if(e===""){return false}if(t.caseSensitiveMatch===false||e.includes(a)){return true}if(l.test(e)||u.test(e)||h.test(e)){return true}if(t.extglob!==false&&f.test(e)){return true}if(t.braceExpansion!==false&&hasBraceExpansion(e)){return true}return false}t.isDynamicPattern=isDynamicPattern;function hasBraceExpansion(e){const t=e.indexOf("{");if(t===-1){return false}const r=e.indexOf("}",t+1);if(r===-1){return false}const i=e.slice(t,r);return p.test(i)}function convertToPositivePattern(e){return isNegativePattern(e)?e.slice(1):e}t.convertToPositivePattern=convertToPositivePattern;function convertToNegativePattern(e){return"!"+e}t.convertToNegativePattern=convertToNegativePattern;function isNegativePattern(e){return e.startsWith("!")&&e[1]!=="("}t.isNegativePattern=isNegativePattern;function isPositivePattern(e){return!isNegativePattern(e)}t.isPositivePattern=isPositivePattern;function getNegativePatterns(e){return e.filter(isNegativePattern)}t.getNegativePatterns=getNegativePatterns;function getPositivePatterns(e){return e.filter(isPositivePattern)}t.getPositivePatterns=getPositivePatterns;function getPatternsInsideCurrentDirectory(e){return e.filter((e=>!isPatternRelatedToParentDirectory(e)))}t.getPatternsInsideCurrentDirectory=getPatternsInsideCurrentDirectory;function getPatternsOutsideCurrentDirectory(e){return e.filter(isPatternRelatedToParentDirectory)}t.getPatternsOutsideCurrentDirectory=getPatternsOutsideCurrentDirectory;function isPatternRelatedToParentDirectory(e){return e.startsWith("..")||e.startsWith("./..")}t.isPatternRelatedToParentDirectory=isPatternRelatedToParentDirectory;function getBaseDirectory(e){return n(e,{flipBackslashes:false})}t.getBaseDirectory=getBaseDirectory;function hasGlobStar(e){return e.includes(o)}t.hasGlobStar=hasGlobStar;function endsWithSlashGlobStar(e){return e.endsWith("/"+o)}t.endsWithSlashGlobStar=endsWithSlashGlobStar;function isAffectDepthOfReadingPattern(e){const t=i.basename(e);return endsWithSlashGlobStar(e)||isStaticPattern(t)}t.isAffectDepthOfReadingPattern=isAffectDepthOfReadingPattern;function expandPatternsWithBraceExpansion(e){return e.reduce(((e,t)=>e.concat(expandBraceExpansion(t))),[])}t.expandPatternsWithBraceExpansion=expandPatternsWithBraceExpansion;function expandBraceExpansion(e){const t=s.braces(e,{expand:true,nodupes:true,keepEscaping:true});t.sort(((e,t)=>e.length-t.length));return t.filter((e=>e!==""))}t.expandBraceExpansion=expandBraceExpansion;function getPatternParts(e,t){let{parts:r}=s.scan(e,Object.assign(Object.assign({},t),{parts:true}));if(r.length===0){r=[e]}if(r[0].startsWith("/")){r[0]=r[0].slice(1);r.unshift("")}return r}t.getPatternParts=getPatternParts;function makeRe(e,t){return s.makeRe(e,t)}t.makeRe=makeRe;function convertPatternsToRe(e,t){return e.map((e=>makeRe(e,t)))}t.convertPatternsToRe=convertPatternsToRe;function matchAny(e,t){return t.some((t=>t.test(e)))}t.matchAny=matchAny;function removeDuplicateSlashes(e){return e.replace(d,"/")}t.removeDuplicateSlashes=removeDuplicateSlashes},536:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.merge=void 0;const i=r(754);function merge(e){const t=i(e);e.forEach((e=>{e.once("error",(e=>t.emit("error",e)))}));t.once("close",(()=>propagateCloseEventToSources(e)));t.once("end",(()=>propagateCloseEventToSources(e)));return t}t.merge=merge;function propagateCloseEventToSources(e){e.forEach((e=>e.emit("close")))}},7641:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isEmpty=t.isString=void 0;function isString(e){return typeof e==="string"}t.isString=isString;function isEmpty(e){return e===""}t.isEmpty=isEmpty},8230:(e,t,r)=>{"use strict";var i=r(844);function fastqueue(e,t,r){if(typeof e==="function"){r=t;t=e;e=null}if(!(r>=1)){throw new Error("fastqueue concurrency must be equal to or greater than 1")}var n=i(Task);var s=null;var o=null;var a=0;var l=null;var u={push:push,drain:noop,saturated:noop,pause:pause,paused:false,get concurrency(){return r},set concurrency(e){if(!(e>=1)){throw new Error("fastqueue concurrency must be equal to or greater than 1")}r=e;if(u.paused)return;for(;s&&a<r;){a++;release()}},running:running,resume:resume,idle:idle,length:length,getQueue:getQueue,unshift:unshift,empty:noop,kill:kill,killAndDrain:killAndDrain,error:error};return u;function running(){return a}function pause(){u.paused=true}function length(){var e=s;var t=0;while(e){e=e.next;t++}return t}function getQueue(){var e=s;var t=[];while(e){t.push(e.value);e=e.next}return t}function resume(){if(!u.paused)return;u.paused=false;if(s===null){a++;release();return}for(;s&&a<r;){a++;release()}}function idle(){return a===0&&u.length()===0}function push(i,h){var f=n.get();f.context=e;f.release=release;f.value=i;f.callback=h||noop;f.errorHandler=l;if(a>=r||u.paused){if(o){o.next=f;o=f}else{s=f;o=f;u.saturated()}}else{a++;t.call(e,f.value,f.worked)}}function unshift(i,h){var f=n.get();f.context=e;f.release=release;f.value=i;f.callback=h||noop;f.errorHandler=l;if(a>=r||u.paused){if(s){f.next=s;s=f}else{s=f;o=f;u.saturated()}}else{a++;t.call(e,f.value,f.worked)}}function release(i){if(i){n.release(i)}var l=s;if(l&&a<=r){if(!u.paused){if(o===s){o=null}s=l.next;l.next=null;t.call(e,l.value,l.worked);if(o===null){u.empty()}}else{a--}}else if(--a===0){u.drain()}}function kill(){s=null;o=null;u.drain=noop}function killAndDrain(){s=null;o=null;u.drain();u.drain=noop}function error(e){l=e}}function noop(){}function Task(){this.value=null;this.callback=noop;this.next=null;this.release=noop;this.context=null;this.errorHandler=null;var e=this;this.worked=function worked(t,r){var i=e.callback;var n=e.errorHandler;var s=e.value;e.value=null;e.callback=noop;if(e.errorHandler){n(t,s)}i.call(e.context,t,r);e.release(e)}}function queueAsPromised(e,t,r){if(typeof e==="function"){r=t;t=e;e=null}function asyncWrapper(e,r){t.call(this,e).then((function(e){r(null,e)}),r)}var i=fastqueue(e,asyncWrapper,r);var n=i.push;var s=i.unshift;i.push=push;i.unshift=unshift;i.drained=drained;return i;function push(e){var t=new Promise((function(t,r){n(e,(function(e,i){if(e){r(e);return}t(i)}))}));t.catch(noop);return t}function unshift(e){var t=new Promise((function(t,r){s(e,(function(e,i){if(e){r(e);return}t(i)}))}));t.catch(noop);return t}function drained(){if(i.idle()){return new Promise((function(e){e()}))}var e=i.drain;var t=new Promise((function(t){i.drain=function(){e();t()}}));return t}}e.exports=fastqueue;e.exports.promise=queueAsPromised},877:(e,t,r)=>{"use strict";
|
|
3
3
|
/*!
|
|
4
4
|
* fill-range <https://github.com/jonschlinkert/fill-range>
|
|
5
5
|
*
|
|
6
6
|
* Copyright (c) 2014-present, Jon Schlinkert.
|
|
7
7
|
* Licensed under the MIT License.
|
|
8
|
-
*/const s=r(3837);const i=r(1861);const isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);const transform=e=>t=>e===true?Number(t):String(t);const isValidValue=e=>typeof e==="number"||typeof e==="string"&&e!=="";const isNumber=e=>Number.isInteger(+e);const zeros=e=>{let t=`${e}`;let r=-1;if(t[0]==="-")t=t.slice(1);if(t==="0")return false;while(t[++r]==="0");return r>0};const stringify=(e,t,r)=>{if(typeof e==="string"||typeof t==="string"){return true}return r.stringify===true};const pad=(e,t,r)=>{if(t>0){let r=e[0]==="-"?"-":"";if(r)e=e.slice(1);e=r+e.padStart(r?t-1:t,"0")}if(r===false){return String(e)}return e};const toMaxLen=(e,t)=>{let r=e[0]==="-"?"-":"";if(r){e=e.slice(1);t--}while(e.length<t)e="0"+e;return r?"-"+e:e};const toSequence=(e,t)=>{e.negatives.sort(((e,t)=>e<t?-1:e>t?1:0));e.positives.sort(((e,t)=>e<t?-1:e>t?1:0));let r=t.capture?"":"?:";let s="";let i="";let n;if(e.positives.length){s=e.positives.join("|")}if(e.negatives.length){i=`-(${r}${e.negatives.join("|")})`}if(s&&i){n=`${s}|${i}`}else{n=s||i}if(t.wrap){return`(${r}${n})`}return n};const toRange=(e,t,r,s)=>{if(r){return i(e,t,{wrap:false,...s})}let n=String.fromCharCode(e);if(e===t)return n;let o=String.fromCharCode(t);return`[${n}-${o}]`};const toRegex=(e,t,r)=>{if(Array.isArray(e)){let t=r.wrap===true;let s=r.capture?"":"?:";return t?`(${s}${e.join("|")})`:e.join("|")}return i(e,t,r)};const rangeError=(...e)=>new RangeError("Invalid range arguments: "+s.inspect(...e));const invalidRange=(e,t,r)=>{if(r.strictRanges===true)throw rangeError([e,t]);return[]};const invalidStep=(e,t)=>{if(t.strictRanges===true){throw new TypeError(`Expected step "${e}" to be a number`)}return[]};const fillNumbers=(e,t,r=1,s={})=>{let i=Number(e);let n=Number(t);if(!Number.isInteger(i)||!Number.isInteger(n)){if(s.strictRanges===true)throw rangeError([e,t]);return[]}if(i===0)i=0;if(n===0)n=0;let o=i>n;let a=String(e);let l=String(t);let u=String(r);r=Math.max(Math.abs(r),1);let h=zeros(a)||zeros(l)||zeros(u);let f=h?Math.max(a.length,l.length,u.length):0;let p=h===false&&stringify(e,t,s)===false;let d=s.transform||transform(p);if(s.toRegex&&r===1){return toRange(toMaxLen(e,f),toMaxLen(t,f),true,s)}let m={negatives:[],positives:[]};let push=e=>m[e<0?"negatives":"positives"].push(Math.abs(e));let g=[];let y=0;while(o?i>=n:i<=n){if(s.toRegex===true&&r>1){push(i)}else{g.push(pad(d(i,y),f,p))}i=o?i-r:i+r;y++}if(s.toRegex===true){return r>1?toSequence(m,s):toRegex(g,null,{wrap:false,...s})}return g};const fillLetters=(e,t,r=1,s={})=>{if(!isNumber(e)&&e.length>1||!isNumber(t)&&t.length>1){return invalidRange(e,t,s)}let i=s.transform||(e=>String.fromCharCode(e));let n=`${e}`.charCodeAt(0);let o=`${t}`.charCodeAt(0);let a=n>o;let l=Math.min(n,o);let u=Math.max(n,o);if(s.toRegex&&r===1){return toRange(l,u,false,s)}let h=[];let f=0;while(a?n>=o:n<=o){h.push(i(n,f));n=a?n-r:n+r;f++}if(s.toRegex===true){return toRegex(h,null,{wrap:false,options:s})}return h};const fill=(e,t,r,s={})=>{if(t==null&&isValidValue(e)){return[e]}if(!isValidValue(e)||!isValidValue(t)){return invalidRange(e,t,s)}if(typeof r==="function"){return fill(e,t,1,{transform:r})}if(isObject(r)){return fill(e,t,0,r)}let i={...s};if(i.capture===true)i.wrap=true;r=r||i.step||1;if(!isNumber(r)){if(r!=null&&!isObject(r))return invalidStep(r,i);return fill(e,t,1,r)}if(isNumber(e)&&isNumber(t)){return fillNumbers(e,t,r,i)}return fillLetters(e,t,Math.max(Math.abs(r),1),i)};e.exports=fill},1585:(e,t,r)=>{"use strict";const{PassThrough:s}=r(2781);e.exports=e=>{e={...e};const{array:t}=e;let{encoding:r}=e;const i=r==="buffer";let n=false;if(t){n=!(r||i)}else{r=r||"utf8"}if(i){r=null}const o=new s({objectMode:n});if(r){o.setEncoding(r)}let a=0;const l=[];o.on("data",(e=>{l.push(e);if(n){a=l.length}else{a+=e.length}}));o.getBufferedValue=()=>{if(t){return l}return i?Buffer.concat(l,a):l.join("")};o.getBufferedLength=()=>a;return o}},1766:(e,t,r)=>{"use strict";const{constants:s}=r(4300);const i=r(2781);const{promisify:n}=r(3837);const o=r(1585);const a=n(i.pipeline);class MaxBufferError extends Error{constructor(){super("maxBuffer exceeded");this.name="MaxBufferError"}}async function getStream(e,t){if(!e){throw new Error("Expected a stream")}t={maxBuffer:Infinity,...t};const{maxBuffer:r}=t;const i=o(t);await new Promise(((t,n)=>{const rejectPromise=e=>{if(e&&i.getBufferedLength()<=s.MAX_LENGTH){e.bufferedData=i.getBufferedValue()}n(e)};(async()=>{try{await a(e,i);t()}catch(e){rejectPromise(e)}})();i.on("data",(()=>{if(i.getBufferedLength()>r){rejectPromise(new MaxBufferError)}}))}));return i.getBufferedValue()}e.exports=getStream;e.exports.buffer=(e,t)=>getStream(e,{...t,encoding:"buffer"});e.exports.array=(e,t)=>getStream(e,{...t,array:true});e.exports.MaxBufferError=MaxBufferError},1621:e=>{"use strict";e.exports=(e,t=process.argv)=>{const r=e.startsWith("-")?"":e.length===1?"-":"--";const s=t.indexOf(r+e);const i=t.indexOf("--");return s!==-1&&(i===-1||s<i)}},8213:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SIGNALS=void 0;const r=[{name:"SIGHUP",number:1,action:"terminate",description:"Terminal closed",standard:"posix"},{name:"SIGINT",number:2,action:"terminate",description:"User interruption with CTRL-C",standard:"ansi"},{name:"SIGQUIT",number:3,action:"core",description:"User interruption with CTRL-\\",standard:"posix"},{name:"SIGILL",number:4,action:"core",description:"Invalid machine instruction",standard:"ansi"},{name:"SIGTRAP",number:5,action:"core",description:"Debugger breakpoint",standard:"posix"},{name:"SIGABRT",number:6,action:"core",description:"Aborted",standard:"ansi"},{name:"SIGIOT",number:6,action:"core",description:"Aborted",standard:"bsd"},{name:"SIGBUS",number:7,action:"core",description:"Bus error due to misaligned, non-existing address or paging error",standard:"bsd"},{name:"SIGEMT",number:7,action:"terminate",description:"Command should be emulated but is not implemented",standard:"other"},{name:"SIGFPE",number:8,action:"core",description:"Floating point arithmetic error",standard:"ansi"},{name:"SIGKILL",number:9,action:"terminate",description:"Forced termination",standard:"posix",forced:true},{name:"SIGUSR1",number:10,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGSEGV",number:11,action:"core",description:"Segmentation fault",standard:"ansi"},{name:"SIGUSR2",number:12,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGPIPE",number:13,action:"terminate",description:"Broken pipe or socket",standard:"posix"},{name:"SIGALRM",number:14,action:"terminate",description:"Timeout or timer",standard:"posix"},{name:"SIGTERM",number:15,action:"terminate",description:"Termination",standard:"ansi"},{name:"SIGSTKFLT",number:16,action:"terminate",description:"Stack is empty or overflowed",standard:"other"},{name:"SIGCHLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"posix"},{name:"SIGCLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"other"},{name:"SIGCONT",number:18,action:"unpause",description:"Unpaused",standard:"posix",forced:true},{name:"SIGSTOP",number:19,action:"pause",description:"Paused",standard:"posix",forced:true},{name:"SIGTSTP",number:20,action:"pause",description:'Paused using CTRL-Z or "suspend"',standard:"posix"},{name:"SIGTTIN",number:21,action:"pause",description:"Background process cannot read terminal input",standard:"posix"},{name:"SIGBREAK",number:21,action:"terminate",description:"User interruption with CTRL-BREAK",standard:"other"},{name:"SIGTTOU",number:22,action:"pause",description:"Background process cannot write to terminal output",standard:"posix"},{name:"SIGURG",number:23,action:"ignore",description:"Socket received out-of-band data",standard:"bsd"},{name:"SIGXCPU",number:24,action:"core",description:"Process timed out",standard:"bsd"},{name:"SIGXFSZ",number:25,action:"core",description:"File too big",standard:"bsd"},{name:"SIGVTALRM",number:26,action:"terminate",description:"Timeout or timer",standard:"bsd"},{name:"SIGPROF",number:27,action:"terminate",description:"Timeout or timer",standard:"bsd"},{name:"SIGWINCH",number:28,action:"ignore",description:"Terminal window size changed",standard:"bsd"},{name:"SIGIO",number:29,action:"terminate",description:"I/O is available",standard:"other"},{name:"SIGPOLL",number:29,action:"terminate",description:"Watched event",standard:"other"},{name:"SIGINFO",number:29,action:"ignore",description:"Request for process information",standard:"other"},{name:"SIGPWR",number:30,action:"terminate",description:"Device running out of power",standard:"systemv"},{name:"SIGSYS",number:31,action:"core",description:"Invalid system call",standard:"other"},{name:"SIGUNUSED",number:31,action:"terminate",description:"Invalid system call",standard:"other"}];t.SIGNALS=r},2779:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.signalsByNumber=t.signalsByName=void 0;var s=r(2037);var i=r(8821);var n=r(1229);const getSignalsByName=function(){const e=(0,i.getSignals)();return e.reduce(getSignalByName,{})};const getSignalByName=function(e,{name:t,number:r,description:s,supported:i,action:n,forced:o,standard:a}){return{...e,[t]:{name:t,number:r,description:s,supported:i,action:n,forced:o,standard:a}}};const o=getSignalsByName();t.signalsByName=o;const getSignalsByNumber=function(){const e=(0,i.getSignals)();const t=n.SIGRTMAX+1;const r=Array.from({length:t},((t,r)=>getSignalByNumber(r,e)));return Object.assign({},...r)};const getSignalByNumber=function(e,t){const r=findSignalByNumber(e,t);if(r===undefined){return{}}const{name:s,description:i,supported:n,action:o,forced:a,standard:l}=r;return{[e]:{name:s,number:e,description:i,supported:n,action:o,forced:a,standard:l}}};const findSignalByNumber=function(e,t){const r=t.find((({name:t})=>s.constants.signals[t]===e));if(r!==undefined){return r}return t.find((t=>t.number===e))};const a=getSignalsByNumber();t.signalsByNumber=a},1229:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SIGRTMAX=t.getRealtimeSignals=void 0;const getRealtimeSignals=function(){const e=s-r+1;return Array.from({length:e},getRealtimeSignal)};t.getRealtimeSignals=getRealtimeSignals;const getRealtimeSignal=function(e,t){return{name:`SIGRT${t+1}`,number:r+t,action:"terminate",description:"Application-specific signal (realtime)",standard:"posix"}};const r=34;const s=64;t.SIGRTMAX=s},8821:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getSignals=void 0;var s=r(2037);var i=r(8213);var n=r(1229);const getSignals=function(){const e=(0,n.getRealtimeSignals)();const t=[...i.SIGNALS,...e].map(normalizeSignal);return t};t.getSignals=getSignals;const normalizeSignal=function({name:e,number:t,description:r,action:i,forced:n=false,standard:o}){const{signals:{[e]:a}}=s.constants;const l=a!==undefined;const u=l?a:t;return{name:e,number:u,description:r,supported:l,action:i,forced:n,standard:o}}},4124:(e,t,r)=>{try{var s=r(3837);if(typeof s.inherits!=="function")throw"";e.exports=s.inherits}catch(t){e.exports=r(8544)}},8544:e=>{if(typeof Object.create==="function"){e.exports=function inherits(e,t){if(t){e.super_=t;e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}}}else{e.exports=function inherits(e,t){if(t){e.super_=t;var TempCtor=function(){};TempCtor.prototype=t.prototype;e.prototype=new TempCtor;e.prototype.constructor=e}}}},6435:e=>{
|
|
8
|
+
*/const i=r(9023);const n=r(7551);const isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);const transform=e=>t=>e===true?Number(t):String(t);const isValidValue=e=>typeof e==="number"||typeof e==="string"&&e!=="";const isNumber=e=>Number.isInteger(+e);const zeros=e=>{let t=`${e}`;let r=-1;if(t[0]==="-")t=t.slice(1);if(t==="0")return false;while(t[++r]==="0");return r>0};const stringify=(e,t,r)=>{if(typeof e==="string"||typeof t==="string"){return true}return r.stringify===true};const pad=(e,t,r)=>{if(t>0){let r=e[0]==="-"?"-":"";if(r)e=e.slice(1);e=r+e.padStart(r?t-1:t,"0")}if(r===false){return String(e)}return e};const toMaxLen=(e,t)=>{let r=e[0]==="-"?"-":"";if(r){e=e.slice(1);t--}while(e.length<t)e="0"+e;return r?"-"+e:e};const toSequence=(e,t,r)=>{e.negatives.sort(((e,t)=>e<t?-1:e>t?1:0));e.positives.sort(((e,t)=>e<t?-1:e>t?1:0));let i=t.capture?"":"?:";let n="";let s="";let o;if(e.positives.length){n=e.positives.map((e=>toMaxLen(String(e),r))).join("|")}if(e.negatives.length){s=`-(${i}${e.negatives.map((e=>toMaxLen(String(e),r))).join("|")})`}if(n&&s){o=`${n}|${s}`}else{o=n||s}if(t.wrap){return`(${i}${o})`}return o};const toRange=(e,t,r,i)=>{if(r){return n(e,t,{wrap:false,...i})}let s=String.fromCharCode(e);if(e===t)return s;let o=String.fromCharCode(t);return`[${s}-${o}]`};const toRegex=(e,t,r)=>{if(Array.isArray(e)){let t=r.wrap===true;let i=r.capture?"":"?:";return t?`(${i}${e.join("|")})`:e.join("|")}return n(e,t,r)};const rangeError=(...e)=>new RangeError("Invalid range arguments: "+i.inspect(...e));const invalidRange=(e,t,r)=>{if(r.strictRanges===true)throw rangeError([e,t]);return[]};const invalidStep=(e,t)=>{if(t.strictRanges===true){throw new TypeError(`Expected step "${e}" to be a number`)}return[]};const fillNumbers=(e,t,r=1,i={})=>{let n=Number(e);let s=Number(t);if(!Number.isInteger(n)||!Number.isInteger(s)){if(i.strictRanges===true)throw rangeError([e,t]);return[]}if(n===0)n=0;if(s===0)s=0;let o=n>s;let a=String(e);let l=String(t);let u=String(r);r=Math.max(Math.abs(r),1);let h=zeros(a)||zeros(l)||zeros(u);let f=h?Math.max(a.length,l.length,u.length):0;let p=h===false&&stringify(e,t,i)===false;let d=i.transform||transform(p);if(i.toRegex&&r===1){return toRange(toMaxLen(e,f),toMaxLen(t,f),true,i)}let m={negatives:[],positives:[]};let push=e=>m[e<0?"negatives":"positives"].push(Math.abs(e));let g=[];let y=0;while(o?n>=s:n<=s){if(i.toRegex===true&&r>1){push(n)}else{g.push(pad(d(n,y),f,p))}n=o?n-r:n+r;y++}if(i.toRegex===true){return r>1?toSequence(m,i,f):toRegex(g,null,{wrap:false,...i})}return g};const fillLetters=(e,t,r=1,i={})=>{if(!isNumber(e)&&e.length>1||!isNumber(t)&&t.length>1){return invalidRange(e,t,i)}let n=i.transform||(e=>String.fromCharCode(e));let s=`${e}`.charCodeAt(0);let o=`${t}`.charCodeAt(0);let a=s>o;let l=Math.min(s,o);let u=Math.max(s,o);if(i.toRegex&&r===1){return toRange(l,u,false,i)}let h=[];let f=0;while(a?s>=o:s<=o){h.push(n(s,f));s=a?s-r:s+r;f++}if(i.toRegex===true){return toRegex(h,null,{wrap:false,options:i})}return h};const fill=(e,t,r,i={})=>{if(t==null&&isValidValue(e)){return[e]}if(!isValidValue(e)||!isValidValue(t)){return invalidRange(e,t,i)}if(typeof r==="function"){return fill(e,t,1,{transform:r})}if(isObject(r)){return fill(e,t,0,r)}let n={...i};if(n.capture===true)n.wrap=true;r=r||n.step||1;if(!isNumber(r)){if(r!=null&&!isObject(r))return invalidStep(r,n);return fill(e,t,1,r)}if(isNumber(e)&&isNumber(t)){return fillNumbers(e,t,r,n)}return fillLetters(e,t,Math.max(Math.abs(r),1),n)};e.exports=fill},7070:(e,t,r)=>{"use strict";const{PassThrough:i}=r(2203);e.exports=e=>{e={...e};const{array:t}=e;let{encoding:r}=e;const n=r==="buffer";let s=false;if(t){s=!(r||n)}else{r=r||"utf8"}if(n){r=null}const o=new i({objectMode:s});if(r){o.setEncoding(r)}let a=0;const l=[];o.on("data",(e=>{l.push(e);if(s){a=l.length}else{a+=e.length}}));o.getBufferedValue=()=>{if(t){return l}return n?Buffer.concat(l,a):l.join("")};o.getBufferedLength=()=>a;return o}},6771:(e,t,r)=>{"use strict";const{constants:i}=r(181);const n=r(2203);const{promisify:s}=r(9023);const o=r(7070);const a=s(n.pipeline);class MaxBufferError extends Error{constructor(){super("maxBuffer exceeded");this.name="MaxBufferError"}}async function getStream(e,t){if(!e){throw new Error("Expected a stream")}t={maxBuffer:Infinity,...t};const{maxBuffer:r}=t;const n=o(t);await new Promise(((t,s)=>{const rejectPromise=e=>{if(e&&n.getBufferedLength()<=i.MAX_LENGTH){e.bufferedData=n.getBufferedValue()}s(e)};(async()=>{try{await a(e,n);t()}catch(e){rejectPromise(e)}})();n.on("data",(()=>{if(n.getBufferedLength()>r){rejectPromise(new MaxBufferError)}}))}));return n.getBufferedValue()}e.exports=getStream;e.exports.buffer=(e,t)=>getStream(e,{...t,encoding:"buffer"});e.exports.array=(e,t)=>getStream(e,{...t,array:true});e.exports.MaxBufferError=MaxBufferError},3813:e=>{"use strict";e.exports=(e,t=process.argv)=>{const r=e.startsWith("-")?"":e.length===1?"-":"--";const i=t.indexOf(r+e);const n=t.indexOf("--");return i!==-1&&(n===-1||i<n)}},1212:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SIGNALS=void 0;const r=[{name:"SIGHUP",number:1,action:"terminate",description:"Terminal closed",standard:"posix"},{name:"SIGINT",number:2,action:"terminate",description:"User interruption with CTRL-C",standard:"ansi"},{name:"SIGQUIT",number:3,action:"core",description:"User interruption with CTRL-\\",standard:"posix"},{name:"SIGILL",number:4,action:"core",description:"Invalid machine instruction",standard:"ansi"},{name:"SIGTRAP",number:5,action:"core",description:"Debugger breakpoint",standard:"posix"},{name:"SIGABRT",number:6,action:"core",description:"Aborted",standard:"ansi"},{name:"SIGIOT",number:6,action:"core",description:"Aborted",standard:"bsd"},{name:"SIGBUS",number:7,action:"core",description:"Bus error due to misaligned, non-existing address or paging error",standard:"bsd"},{name:"SIGEMT",number:7,action:"terminate",description:"Command should be emulated but is not implemented",standard:"other"},{name:"SIGFPE",number:8,action:"core",description:"Floating point arithmetic error",standard:"ansi"},{name:"SIGKILL",number:9,action:"terminate",description:"Forced termination",standard:"posix",forced:true},{name:"SIGUSR1",number:10,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGSEGV",number:11,action:"core",description:"Segmentation fault",standard:"ansi"},{name:"SIGUSR2",number:12,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGPIPE",number:13,action:"terminate",description:"Broken pipe or socket",standard:"posix"},{name:"SIGALRM",number:14,action:"terminate",description:"Timeout or timer",standard:"posix"},{name:"SIGTERM",number:15,action:"terminate",description:"Termination",standard:"ansi"},{name:"SIGSTKFLT",number:16,action:"terminate",description:"Stack is empty or overflowed",standard:"other"},{name:"SIGCHLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"posix"},{name:"SIGCLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"other"},{name:"SIGCONT",number:18,action:"unpause",description:"Unpaused",standard:"posix",forced:true},{name:"SIGSTOP",number:19,action:"pause",description:"Paused",standard:"posix",forced:true},{name:"SIGTSTP",number:20,action:"pause",description:'Paused using CTRL-Z or "suspend"',standard:"posix"},{name:"SIGTTIN",number:21,action:"pause",description:"Background process cannot read terminal input",standard:"posix"},{name:"SIGBREAK",number:21,action:"terminate",description:"User interruption with CTRL-BREAK",standard:"other"},{name:"SIGTTOU",number:22,action:"pause",description:"Background process cannot write to terminal output",standard:"posix"},{name:"SIGURG",number:23,action:"ignore",description:"Socket received out-of-band data",standard:"bsd"},{name:"SIGXCPU",number:24,action:"core",description:"Process timed out",standard:"bsd"},{name:"SIGXFSZ",number:25,action:"core",description:"File too big",standard:"bsd"},{name:"SIGVTALRM",number:26,action:"terminate",description:"Timeout or timer",standard:"bsd"},{name:"SIGPROF",number:27,action:"terminate",description:"Timeout or timer",standard:"bsd"},{name:"SIGWINCH",number:28,action:"ignore",description:"Terminal window size changed",standard:"bsd"},{name:"SIGIO",number:29,action:"terminate",description:"I/O is available",standard:"other"},{name:"SIGPOLL",number:29,action:"terminate",description:"Watched event",standard:"other"},{name:"SIGINFO",number:29,action:"ignore",description:"Request for process information",standard:"other"},{name:"SIGPWR",number:30,action:"terminate",description:"Device running out of power",standard:"systemv"},{name:"SIGSYS",number:31,action:"core",description:"Invalid system call",standard:"other"},{name:"SIGUNUSED",number:31,action:"terminate",description:"Invalid system call",standard:"other"}];t.SIGNALS=r},4366:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.signalsByNumber=t.signalsByName=void 0;var i=r(857);var n=r(8310);var s=r(3782);const getSignalsByName=function(){const e=(0,n.getSignals)();return e.reduce(getSignalByName,{})};const getSignalByName=function(e,{name:t,number:r,description:i,supported:n,action:s,forced:o,standard:a}){return{...e,[t]:{name:t,number:r,description:i,supported:n,action:s,forced:o,standard:a}}};const o=getSignalsByName();t.signalsByName=o;const getSignalsByNumber=function(){const e=(0,n.getSignals)();const t=s.SIGRTMAX+1;const r=Array.from({length:t},((t,r)=>getSignalByNumber(r,e)));return Object.assign({},...r)};const getSignalByNumber=function(e,t){const r=findSignalByNumber(e,t);if(r===undefined){return{}}const{name:i,description:n,supported:s,action:o,forced:a,standard:l}=r;return{[e]:{name:i,number:e,description:n,supported:s,action:o,forced:a,standard:l}}};const findSignalByNumber=function(e,t){const r=t.find((({name:t})=>i.constants.signals[t]===e));if(r!==undefined){return r}return t.find((t=>t.number===e))};const a=getSignalsByNumber();t.signalsByNumber=a},3782:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SIGRTMAX=t.getRealtimeSignals=void 0;const getRealtimeSignals=function(){const e=i-r+1;return Array.from({length:e},getRealtimeSignal)};t.getRealtimeSignals=getRealtimeSignals;const getRealtimeSignal=function(e,t){return{name:`SIGRT${t+1}`,number:r+t,action:"terminate",description:"Application-specific signal (realtime)",standard:"posix"}};const r=34;const i=64;t.SIGRTMAX=i},8310:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getSignals=void 0;var i=r(857);var n=r(1212);var s=r(3782);const getSignals=function(){const e=(0,s.getRealtimeSignals)();const t=[...n.SIGNALS,...e].map(normalizeSignal);return t};t.getSignals=getSignals;const normalizeSignal=function({name:e,number:t,description:r,action:n,forced:s=false,standard:o}){const{signals:{[e]:a}}=i.constants;const l=a!==undefined;const u=l?a:t;return{name:e,number:u,description:r,supported:l,action:n,forced:s,standard:o}}},9598:(e,t,r)=>{try{var i=r(9023);if(typeof i.inherits!=="function")throw"";e.exports=i.inherits}catch(t){e.exports=r(6589)}},6589:e=>{if(typeof Object.create==="function"){e.exports=function inherits(e,t){if(t){e.super_=t;e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}}}else{e.exports=function inherits(e,t){if(t){e.super_=t;var TempCtor=function(){};TempCtor.prototype=t.prototype;e.prototype=new TempCtor;e.prototype.constructor=e}}}},5540:e=>{
|
|
9
9
|
/*!
|
|
10
10
|
* is-extglob <https://github.com/jonschlinkert/is-extglob>
|
|
11
11
|
*
|
|
12
12
|
* Copyright (c) 2014-2016, Jon Schlinkert.
|
|
13
13
|
* Licensed under the MIT License.
|
|
14
14
|
*/
|
|
15
|
-
e.exports=function isExtglob(e){if(typeof e!=="string"||e===""){return false}var t;while(t=/(\\).|([@?!+*]\(.*\))/g.exec(e)){if(t[2])return true;e=e.slice(t.index+t[0].length)}return false}},
|
|
15
|
+
e.exports=function isExtglob(e){if(typeof e!=="string"||e===""){return false}var t;while(t=/(\\).|([@?!+*]\(.*\))/g.exec(e)){if(t[2])return true;e=e.slice(t.index+t[0].length)}return false}},1925:(e,t,r)=>{
|
|
16
16
|
/*!
|
|
17
17
|
* is-glob <https://github.com/jonschlinkert/is-glob>
|
|
18
18
|
*
|
|
19
19
|
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
20
20
|
* Released under the MIT License.
|
|
21
21
|
*/
|
|
22
|
-
var
|
|
22
|
+
var i=r(5540);var n={"{":"}","(":")","[":"]"};var strictCheck=function(e){if(e[0]==="!"){return true}var t=0;var r=-2;var i=-2;var s=-2;var o=-2;var a=-2;while(t<e.length){if(e[t]==="*"){return true}if(e[t+1]==="?"&&/[\].+)]/.test(e[t])){return true}if(i!==-1&&e[t]==="["&&e[t+1]!=="]"){if(i<t){i=e.indexOf("]",t)}if(i>t){if(a===-1||a>i){return true}a=e.indexOf("\\",t);if(a===-1||a>i){return true}}}if(s!==-1&&e[t]==="{"&&e[t+1]!=="}"){s=e.indexOf("}",t);if(s>t){a=e.indexOf("\\",t);if(a===-1||a>s){return true}}}if(o!==-1&&e[t]==="("&&e[t+1]==="?"&&/[:!=]/.test(e[t+2])&&e[t+3]!==")"){o=e.indexOf(")",t);if(o>t){a=e.indexOf("\\",t);if(a===-1||a>o){return true}}}if(r!==-1&&e[t]==="("&&e[t+1]!=="|"){if(r<t){r=e.indexOf("|",t)}if(r!==-1&&e[r+1]!==")"){o=e.indexOf(")",r);if(o>r){a=e.indexOf("\\",r);if(a===-1||a>o){return true}}}}if(e[t]==="\\"){var l=e[t+1];t+=2;var u=n[l];if(u){var h=e.indexOf(u,t);if(h!==-1){t=h+1}}if(e[t]==="!"){return true}}else{t++}}return false};var relaxedCheck=function(e){if(e[0]==="!"){return true}var t=0;while(t<e.length){if(/[*?{}()[\]]/.test(e[t])){return true}if(e[t]==="\\"){var r=e[t+1];t+=2;var i=n[r];if(i){var s=e.indexOf(i,t);if(s!==-1){t=s+1}}if(e[t]==="!"){return true}}else{t++}}return false};e.exports=function isGlob(e,t){if(typeof e!=="string"||e===""){return false}if(i(e)){return true}var r=strictCheck;if(t&&t.strict===false){r=relaxedCheck}return r(e)}},573:e=>{"use strict";e.exports=({stream:e=process.stdout}={})=>Boolean(e&&e.isTTY&&process.env.TERM!=="dumb"&&!("CI"in process.env))},3102:e=>{"use strict";
|
|
23
23
|
/*!
|
|
24
24
|
* is-number <https://github.com/jonschlinkert/is-number>
|
|
25
25
|
*
|
|
26
26
|
* Copyright (c) 2014-present, Jon Schlinkert.
|
|
27
27
|
* Released under the MIT License.
|
|
28
|
-
*/e.exports=function(e){if(typeof e==="number"){return e-e===0}if(typeof e==="string"&&e.trim()!==""){return Number.isFinite?Number.isFinite(+e):isFinite(+e)}return false}},1554:e=>{"use strict";const isStream=e=>e!==null&&typeof e==="object"&&typeof e.pipe==="function";isStream.writable=e=>isStream(e)&&e.writable!==false&&typeof e._write==="function"&&typeof e._writableState==="object";isStream.readable=e=>isStream(e)&&e.readable!==false&&typeof e._read==="function"&&typeof e._readableState==="object";isStream.duplex=e=>isStream.writable(e)&&isStream.readable(e);isStream.transform=e=>isStream.duplex(e)&&typeof e._transform==="function";e.exports=isStream},9228:e=>{"use strict";e.exports=()=>{if(process.platform!=="win32"){return true}return Boolean(process.env.CI)||Boolean(process.env.WT_SESSION)||process.env.TERM_PROGRAM==="vscode"||process.env.TERM==="xterm-256color"||process.env.TERM==="alacritty"}},7126:(e,t,r)=>{var s=r(7147);var i;if(process.platform==="win32"||global.TESTING_WINDOWS){i=r(2001)}else{i=r(9728)}e.exports=isexe;isexe.sync=sync;function isexe(e,t,r){if(typeof t==="function"){r=t;t={}}if(!r){if(typeof Promise!=="function"){throw new TypeError("callback not provided")}return new Promise((function(r,s){isexe(e,t||{},(function(e,t){if(e){s(e)}else{r(t)}}))}))}i(e,t||{},(function(e,s){if(e){if(e.code==="EACCES"||t&&t.ignoreErrors){e=null;s=false}}r(e,s)}))}function sync(e,t){try{return i.sync(e,t||{})}catch(e){if(t&&t.ignoreErrors||e.code==="EACCES"){return false}else{throw e}}}},9728:(e,t,r)=>{e.exports=isexe;isexe.sync=sync;var s=r(7147);function isexe(e,t,r){s.stat(e,(function(e,s){r(e,e?false:checkStat(s,t))}))}function sync(e,t){return checkStat(s.statSync(e),t)}function checkStat(e,t){return e.isFile()&&checkMode(e,t)}function checkMode(e,t){var r=e.mode;var s=e.uid;var i=e.gid;var n=t.uid!==undefined?t.uid:process.getuid&&process.getuid();var o=t.gid!==undefined?t.gid:process.getgid&&process.getgid();var a=parseInt("100",8);var l=parseInt("010",8);var u=parseInt("001",8);var h=a|l;var f=r&u||r&l&&i===o||r&a&&s===n||r&h&&n===0;return f}},2001:(e,t,r)=>{e.exports=isexe;isexe.sync=sync;var s=r(7147);function checkPathExt(e,t){var r=t.pathExt!==undefined?t.pathExt:process.env.PATHEXT;if(!r){return true}r=r.split(";");if(r.indexOf("")!==-1){return true}for(var s=0;s<r.length;s++){var i=r[s].toLowerCase();if(i&&e.substr(-i.length).toLowerCase()===i){return true}}return false}function checkStat(e,t,r){if(!e.isSymbolicLink()&&!e.isFile()){return false}return checkPathExt(t,r)}function isexe(e,t,r){s.stat(e,(function(s,i){r(s,s?false:checkStat(i,e,t))}))}function sync(e,t){return checkStat(s.statSync(e),e,t)}},3479:(e,t,r)=>{"use strict";const s=r(8818);const i=r(9228);const n={info:s.blue("ℹ"),success:s.green("✔"),warning:s.yellow("⚠"),error:s.red("✖")};const o={info:s.blue("i"),success:s.green("√"),warning:s.yellow("‼"),error:s.red("×")};e.exports=i()?n:o},7129:(e,t,r)=>{"use strict";const s=r(665);const i=Symbol("max");const n=Symbol("length");const o=Symbol("lengthCalculator");const a=Symbol("allowStale");const l=Symbol("maxAge");const u=Symbol("dispose");const h=Symbol("noDisposeOnSet");const f=Symbol("lruList");const p=Symbol("cache");const d=Symbol("updateAgeOnGet");const naiveLength=()=>1;class LRUCache{constructor(e){if(typeof e==="number")e={max:e};if(!e)e={};if(e.max&&(typeof e.max!=="number"||e.max<0))throw new TypeError("max must be a non-negative number");const t=this[i]=e.max||Infinity;const r=e.length||naiveLength;this[o]=typeof r!=="function"?naiveLength:r;this[a]=e.stale||false;if(e.maxAge&&typeof e.maxAge!=="number")throw new TypeError("maxAge must be a number");this[l]=e.maxAge||0;this[u]=e.dispose;this[h]=e.noDisposeOnSet||false;this[d]=e.updateAgeOnGet||false;this.reset()}set max(e){if(typeof e!=="number"||e<0)throw new TypeError("max must be a non-negative number");this[i]=e||Infinity;trim(this)}get max(){return this[i]}set allowStale(e){this[a]=!!e}get allowStale(){return this[a]}set maxAge(e){if(typeof e!=="number")throw new TypeError("maxAge must be a non-negative number");this[l]=e;trim(this)}get maxAge(){return this[l]}set lengthCalculator(e){if(typeof e!=="function")e=naiveLength;if(e!==this[o]){this[o]=e;this[n]=0;this[f].forEach((e=>{e.length=this[o](e.value,e.key);this[n]+=e.length}))}trim(this)}get lengthCalculator(){return this[o]}get length(){return this[n]}get itemCount(){return this[f].length}rforEach(e,t){t=t||this;for(let r=this[f].tail;r!==null;){const s=r.prev;forEachStep(this,e,r,t);r=s}}forEach(e,t){t=t||this;for(let r=this[f].head;r!==null;){const s=r.next;forEachStep(this,e,r,t);r=s}}keys(){return this[f].toArray().map((e=>e.key))}values(){return this[f].toArray().map((e=>e.value))}reset(){if(this[u]&&this[f]&&this[f].length){this[f].forEach((e=>this[u](e.key,e.value)))}this[p]=new Map;this[f]=new s;this[n]=0}dump(){return this[f].map((e=>isStale(this,e)?false:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)})).toArray().filter((e=>e))}dumpLru(){return this[f]}set(e,t,r){r=r||this[l];if(r&&typeof r!=="number")throw new TypeError("maxAge must be a number");const s=r?Date.now():0;const a=this[o](t,e);if(this[p].has(e)){if(a>this[i]){del(this,this[p].get(e));return false}const o=this[p].get(e);const l=o.value;if(this[u]){if(!this[h])this[u](e,l.value)}l.now=s;l.maxAge=r;l.value=t;this[n]+=a-l.length;l.length=a;this.get(e);trim(this);return true}const d=new Entry(e,t,a,s,r);if(d.length>this[i]){if(this[u])this[u](e,t);return false}this[n]+=d.length;this[f].unshift(d);this[p].set(e,this[f].head);trim(this);return true}has(e){if(!this[p].has(e))return false;const t=this[p].get(e).value;return!isStale(this,t)}get(e){return get(this,e,true)}peek(e){return get(this,e,false)}pop(){const e=this[f].tail;if(!e)return null;del(this,e);return e.value}del(e){del(this,this[p].get(e))}load(e){this.reset();const t=Date.now();for(let r=e.length-1;r>=0;r--){const s=e[r];const i=s.e||0;if(i===0)this.set(s.k,s.v);else{const e=i-t;if(e>0){this.set(s.k,s.v,e)}}}}prune(){this[p].forEach(((e,t)=>get(this,t,false)))}}const get=(e,t,r)=>{const s=e[p].get(t);if(s){const t=s.value;if(isStale(e,t)){del(e,s);if(!e[a])return undefined}else{if(r){if(e[d])s.value.now=Date.now();e[f].unshiftNode(s)}}return t.value}};const isStale=(e,t)=>{if(!t||!t.maxAge&&!e[l])return false;const r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[l]&&r>e[l]};const trim=e=>{if(e[n]>e[i]){for(let t=e[f].tail;e[n]>e[i]&&t!==null;){const r=t.prev;del(e,t);t=r}}};const del=(e,t)=>{if(t){const r=t.value;if(e[u])e[u](r.key,r.value);e[n]-=r.length;e[p].delete(r.key);e[f].removeNode(t)}};class Entry{constructor(e,t,r,s,i){this.key=e;this.value=t;this.length=r;this.now=s;this.maxAge=i||0}}const forEachStep=(e,t,r,s)=>{let i=r.value;if(isStale(e,i)){del(e,r);if(!e[a])i=undefined}if(i)t.call(s,i.value,i.key,e)};e.exports=LRUCache},2621:(e,t,r)=>{"use strict";const{PassThrough:s}=r(2781);e.exports=function(){var e=[];var t=new s({objectMode:true});t.setMaxListeners(0);t.add=add;t.isEmpty=isEmpty;t.on("unpipe",remove);Array.prototype.slice.call(arguments).forEach(add);return t;function add(r){if(Array.isArray(r)){r.forEach(add);return this}e.push(r);r.once("end",remove.bind(null,r));r.once("error",t.emit.bind(t,"error"));r.pipe(t,{end:false});return this}function isEmpty(){return e.length==0}function remove(r){e=e.filter((function(e){return e!==r}));if(!e.length&&t.readable){t.end()}}}},2578:(e,t,r)=>{"use strict";const s=r(2781);const i=s.PassThrough;const n=Array.prototype.slice;e.exports=merge2;function merge2(){const e=[];const t=n.call(arguments);let r=false;let s=t[t.length-1];if(s&&!Array.isArray(s)&&s.pipe==null){t.pop()}else{s={}}const o=s.end!==false;const a=s.pipeError===true;if(s.objectMode==null){s.objectMode=true}if(s.highWaterMark==null){s.highWaterMark=64*1024}const l=i(s);function addStream(){for(let t=0,r=arguments.length;t<r;t++){e.push(pauseStreams(arguments[t],s))}mergeStream();return this}function mergeStream(){if(r){return}r=true;let t=e.shift();if(!t){process.nextTick(endStream);return}if(!Array.isArray(t)){t=[t]}let s=t.length+1;function next(){if(--s>0){return}r=false;mergeStream()}function pipe(e){function onend(){e.removeListener("merge2UnpipeEnd",onend);e.removeListener("end",onend);if(a){e.removeListener("error",onerror)}next()}function onerror(e){l.emit("error",e)}if(e._readableState.endEmitted){return next()}e.on("merge2UnpipeEnd",onend);e.on("end",onend);if(a){e.on("error",onerror)}e.pipe(l,{end:false});e.resume()}for(let e=0;e<t.length;e++){pipe(t[e])}next()}function endStream(){r=false;l.emit("queueDrain");if(o){l.end()}}l.setMaxListeners(0);l.add=addStream;l.on("unpipe",(function(e){e.emit("merge2UnpipeEnd")}));if(t.length){addStream.apply(null,t)}return l}function pauseStreams(e,t){if(!Array.isArray(e)){if(!e._readableState&&e.pipe){e=e.pipe(i(t))}if(!e._readableState||!e.pause||!e.pipe){throw new Error("Only readable stream can be merged.")}e.pause()}else{for(let r=0,s=e.length;r<s;r++){e[r]=pauseStreams(e[r],t)}}return e}},6228:(e,t,r)=>{"use strict";const s=r(3837);const i=r(610);const n=r(8569);const o=r(479);const isEmptyString=e=>e===""||e==="./";const micromatch=(e,t,r)=>{t=[].concat(t);e=[].concat(e);let s=new Set;let i=new Set;let o=new Set;let a=0;let onResult=e=>{o.add(e.output);if(r&&r.onResult){r.onResult(e)}};for(let o=0;o<t.length;o++){let l=n(String(t[o]),{...r,onResult:onResult},true);let u=l.state.negated||l.state.negatedExtglob;if(u)a++;for(let t of e){let e=l(t,true);let r=u?!e.isMatch:e.isMatch;if(!r)continue;if(u){s.add(e.output)}else{s.delete(e.output);i.add(e.output)}}}let l=a===t.length?[...o]:[...i];let u=l.filter((e=>!s.has(e)));if(r&&u.length===0){if(r.failglob===true){throw new Error(`No matches found for "${t.join(", ")}"`)}if(r.nonull===true||r.nullglob===true){return r.unescape?t.map((e=>e.replace(/\\/g,""))):t}}return u};micromatch.match=micromatch;micromatch.matcher=(e,t)=>n(e,t);micromatch.isMatch=(e,t,r)=>n(t,r)(e);micromatch.any=micromatch.isMatch;micromatch.not=(e,t,r={})=>{t=[].concat(t).map(String);let s=new Set;let i=[];let onResult=e=>{if(r.onResult)r.onResult(e);i.push(e.output)};let n=new Set(micromatch(e,t,{...r,onResult:onResult}));for(let e of i){if(!n.has(e)){s.add(e)}}return[...s]};micromatch.contains=(e,t,r)=>{if(typeof e!=="string"){throw new TypeError(`Expected a string: "${s.inspect(e)}"`)}if(Array.isArray(t)){return t.some((t=>micromatch.contains(e,t,r)))}if(typeof t==="string"){if(isEmptyString(e)||isEmptyString(t)){return false}if(e.includes(t)||e.startsWith("./")&&e.slice(2).includes(t)){return true}}return micromatch.isMatch(e,t,{...r,contains:true})};micromatch.matchKeys=(e,t,r)=>{if(!o.isObject(e)){throw new TypeError("Expected the first argument to be an object")}let s=micromatch(Object.keys(e),t,r);let i={};for(let t of s)i[t]=e[t];return i};micromatch.some=(e,t,r)=>{let s=[].concat(e);for(let e of[].concat(t)){let t=n(String(e),r);if(s.some((e=>t(e)))){return true}}return false};micromatch.every=(e,t,r)=>{let s=[].concat(e);for(let e of[].concat(t)){let t=n(String(e),r);if(!s.every((e=>t(e)))){return false}}return true};micromatch.all=(e,t,r)=>{if(typeof e!=="string"){throw new TypeError(`Expected a string: "${s.inspect(e)}"`)}return[].concat(t).every((t=>n(t,r)(e)))};micromatch.capture=(e,t,r)=>{let s=o.isWindows(r);let i=n.makeRe(String(e),{...r,capture:true});let a=i.exec(s?o.toPosixSlashes(t):t);if(a){return a.slice(1).map((e=>e===void 0?"":e))}};micromatch.makeRe=(...e)=>n.makeRe(...e);micromatch.scan=(...e)=>n.scan(...e);micromatch.parse=(e,t)=>{let r=[];for(let s of[].concat(e||[])){for(let e of i(String(s),t)){r.push(n.parse(e,t))}}return r};micromatch.braces=(e,t)=>{if(typeof e!=="string")throw new TypeError("Expected a string");if(t&&t.nobrace===true||!/\{.*\}/.test(e)){return[e]}return i(e,t)};micromatch.braceExpand=(e,t)=>{if(typeof e!=="string")throw new TypeError("Expected a string");return micromatch.braces(e,{...t,expand:true})};e.exports=micromatch},6047:e=>{"use strict";const mimicFn=(e,t)=>{for(const r of Reflect.ownKeys(t)){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}return e};e.exports=mimicFn;e.exports["default"]=mimicFn},6186:(e,t,r)=>{const s=r(2853);const i=r(2930);const{mkdirpNative:n,mkdirpNativeSync:o}=r(4983);const{mkdirpManual:a,mkdirpManualSync:l}=r(356);const{useNative:u,useNativeSync:h}=r(4518);const mkdirp=(e,t)=>{e=i(e);t=s(t);return u(t)?n(e,t):a(e,t)};const mkdirpSync=(e,t)=>{e=i(e);t=s(t);return h(t)?o(e,t):l(e,t)};mkdirp.sync=mkdirpSync;mkdirp.native=(e,t)=>n(i(e),s(t));mkdirp.manual=(e,t)=>a(i(e),s(t));mkdirp.nativeSync=(e,t)=>o(i(e),s(t));mkdirp.manualSync=(e,t)=>l(i(e),s(t));e.exports=mkdirp},4992:(e,t,r)=>{const{dirname:s}=r(1017);const findMade=(e,t,r=undefined)=>{if(r===t)return Promise.resolve();return e.statAsync(t).then((e=>e.isDirectory()?r:undefined),(r=>r.code==="ENOENT"?findMade(e,s(t),t):undefined))};const findMadeSync=(e,t,r=undefined)=>{if(r===t)return undefined;try{return e.statSync(t).isDirectory()?r:undefined}catch(r){return r.code==="ENOENT"?findMadeSync(e,s(t),t):undefined}};e.exports={findMade:findMade,findMadeSync:findMadeSync}},356:(e,t,r)=>{const{dirname:s}=r(1017);const mkdirpManual=(e,t,r)=>{t.recursive=false;const i=s(e);if(i===e){return t.mkdirAsync(e,t).catch((e=>{if(e.code!=="EISDIR")throw e}))}return t.mkdirAsync(e,t).then((()=>r||e),(s=>{if(s.code==="ENOENT")return mkdirpManual(i,t).then((r=>mkdirpManual(e,t,r)));if(s.code!=="EEXIST"&&s.code!=="EROFS")throw s;return t.statAsync(e).then((e=>{if(e.isDirectory())return r;else throw s}),(()=>{throw s}))}))};const mkdirpManualSync=(e,t,r)=>{const i=s(e);t.recursive=false;if(i===e){try{return t.mkdirSync(e,t)}catch(e){if(e.code!=="EISDIR")throw e;else return}}try{t.mkdirSync(e,t);return r||e}catch(s){if(s.code==="ENOENT")return mkdirpManualSync(e,t,mkdirpManualSync(i,t,r));if(s.code!=="EEXIST"&&s.code!=="EROFS")throw s;try{if(!t.statSync(e).isDirectory())throw s}catch(e){throw s}}};e.exports={mkdirpManual:mkdirpManual,mkdirpManualSync:mkdirpManualSync}},4983:(e,t,r)=>{const{dirname:s}=r(1017);const{findMade:i,findMadeSync:n}=r(4992);const{mkdirpManual:o,mkdirpManualSync:a}=r(356);const mkdirpNative=(e,t)=>{t.recursive=true;const r=s(e);if(r===e)return t.mkdirAsync(e,t);return i(t,e).then((r=>t.mkdirAsync(e,t).then((()=>r)).catch((r=>{if(r.code==="ENOENT")return o(e,t);else throw r}))))};const mkdirpNativeSync=(e,t)=>{t.recursive=true;const r=s(e);if(r===e)return t.mkdirSync(e,t);const i=n(t,e);try{t.mkdirSync(e,t);return i}catch(r){if(r.code==="ENOENT")return a(e,t);else throw r}};e.exports={mkdirpNative:mkdirpNative,mkdirpNativeSync:mkdirpNativeSync}},2853:(e,t,r)=>{const{promisify:s}=r(3837);const i=r(7147);const optsArg=e=>{if(!e)e={mode:511,fs:i};else if(typeof e==="object")e={mode:511,fs:i,...e};else if(typeof e==="number")e={mode:e,fs:i};else if(typeof e==="string")e={mode:parseInt(e,8),fs:i};else throw new TypeError("invalid options argument");e.mkdir=e.mkdir||e.fs.mkdir||i.mkdir;e.mkdirAsync=s(e.mkdir);e.stat=e.stat||e.fs.stat||i.stat;e.statAsync=s(e.stat);e.statSync=e.statSync||e.fs.statSync||i.statSync;e.mkdirSync=e.mkdirSync||e.fs.mkdirSync||i.mkdirSync;return e};e.exports=optsArg},2930:(e,t,r)=>{const s=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform;const{resolve:i,parse:n}=r(1017);const pathArg=e=>{if(/\0/.test(e)){throw Object.assign(new TypeError("path must be a string without null bytes"),{path:e,code:"ERR_INVALID_ARG_VALUE"})}e=i(e);if(s==="win32"){const t=/[*|"<>?:]/;const{root:r}=n(e);if(t.test(e.substr(r.length))){throw Object.assign(new Error("Illegal characters in path."),{path:e,code:"EINVAL"})}}return e};e.exports=pathArg},4518:(e,t,r)=>{const s=r(7147);const i=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version;const n=i.replace(/^v/,"").split(".");const o=+n[0]>10||+n[0]===10&&+n[1]>=12;const a=!o?()=>false:e=>e.mkdir===s.mkdir;const l=!o?()=>false:e=>e.mkdirSync===s.mkdirSync;e.exports={useNative:a,useNativeSync:l}},502:(e,t,r)=>{"use strict";const s=r(1017);const i=r(539);const npmRunPath=e=>{e={cwd:process.cwd(),path:process.env[i()],execPath:process.execPath,...e};let t;let r=s.resolve(e.cwd);const n=[];while(t!==r){n.push(s.join(r,"node_modules/.bin"));t=r;r=s.resolve(r,"..")}const o=s.resolve(e.cwd,e.execPath,"..");n.push(o);return n.concat(e.path).join(s.delimiter)};e.exports=npmRunPath;e.exports["default"]=npmRunPath;e.exports.env=t=>{t={env:process.env,...t};const r={...t.env};const s=i({env:r});t.path=r[s];r[s]=e.exports(t);return r}},9082:(e,t,r)=>{"use strict";const s=r(6047);const i=new WeakMap;const onetime=(e,t={})=>{if(typeof e!=="function"){throw new TypeError("Expected a function")}let r;let n=0;const o=e.displayName||e.name||"<anonymous>";const onetime=function(...s){i.set(onetime,++n);if(n===1){r=e.apply(this,s);e=null}else if(t.throw===true){throw new Error(`Function \`${o}\` can only be called once`)}return r};s(onetime,e);i.set(onetime,n);return onetime};e.exports=onetime;e.exports["default"]=onetime;e.exports.callCount=e=>{if(!i.has(e)){throw new Error(`The given function \`${e.name}\` is not wrapped by the \`onetime\` package`)}return i.get(e)}},970:(e,t,r)=>{"use strict";const s=r(4521);const i=r(8818);const n=r(9482);const o=r(2031);const a=r(3479);const l=r(5591);const u=r(5917);const h=r(284);const f=r(9228);const{BufferListStream:p}=r(336);const d=Symbol("text");const m=Symbol("prefixText");const g=3;class StdinDiscarder{constructor(){this.requests=0;this.mutedStream=new p;this.mutedStream.pipe(process.stdout);const e=this;this.ourEmit=function(t,r,...s){const{stdin:i}=process;if(e.requests>0||i.emit===e.ourEmit){if(t==="keypress"){return}if(t==="data"&&r.includes(g)){process.emit("SIGINT")}Reflect.apply(e.oldEmit,this,[t,r,...s])}else{Reflect.apply(process.stdin.emit,this,[t,r,...s])}}}start(){this.requests++;if(this.requests===1){this.realStart()}}stop(){if(this.requests<=0){throw new Error("`stop` called more times than `start`")}this.requests--;if(this.requests===0){this.realStop()}}realStart(){if(process.platform==="win32"){return}this.rl=s.createInterface({input:process.stdin,output:this.mutedStream});this.rl.on("SIGINT",(()=>{if(process.listenerCount("SIGINT")===0){process.emit("SIGINT")}else{this.rl.close();process.kill(process.pid,"SIGINT")}}))}realStop(){if(process.platform==="win32"){return}this.rl.close();this.rl=undefined}}let y;class Ora{constructor(e){if(!y){y=new StdinDiscarder}if(typeof e==="string"){e={text:e}}this.options={text:"",color:"cyan",stream:process.stderr,discardStdin:true,...e};this.spinner=this.options.spinner;this.color=this.options.color;this.hideCursor=this.options.hideCursor!==false;this.interval=this.options.interval||this.spinner.interval||100;this.stream=this.options.stream;this.id=undefined;this.isEnabled=typeof this.options.isEnabled==="boolean"?this.options.isEnabled:h({stream:this.stream});this.isSilent=typeof this.options.isSilent==="boolean"?this.options.isSilent:false;this.text=this.options.text;this.prefixText=this.options.prefixText;this.linesToClear=0;this.indent=this.options.indent;this.discardStdin=this.options.discardStdin;this.isDiscardingStdin=false}get indent(){return this._indent}set indent(e=0){if(!(e>=0&&Number.isInteger(e))){throw new Error("The `indent` option must be an integer from 0 and up")}this._indent=e}_updateInterval(e){if(e!==undefined){this.interval=e}}get spinner(){return this._spinner}set spinner(e){this.frameIndex=0;if(typeof e==="object"){if(e.frames===undefined){throw new Error("The given spinner must have a `frames` property")}this._spinner=e}else if(!f()){this._spinner=o.line}else if(e===undefined){this._spinner=o.dots}else if(e!=="default"&&o[e]){this._spinner=o[e]}else{throw new Error(`There is no built-in spinner named '${e}'. See https://github.com/sindresorhus/cli-spinners/blob/main/spinners.json for a full list.`)}this._updateInterval(this._spinner.interval)}get text(){return this[d]}set text(e){this[d]=e;this.updateLineCount()}get prefixText(){return this[m]}set prefixText(e){this[m]=e;this.updateLineCount()}get isSpinning(){return this.id!==undefined}getFullPrefixText(e=this[m],t=" "){if(typeof e==="string"){return e+t}if(typeof e==="function"){return e()+t}return""}updateLineCount(){const e=this.stream.columns||80;const t=this.getFullPrefixText(this.prefixText,"-");this.lineCount=0;for(const r of l(t+"--"+this[d]).split("\n")){this.lineCount+=Math.max(1,Math.ceil(u(r)/e))}}get isEnabled(){return this._isEnabled&&!this.isSilent}set isEnabled(e){if(typeof e!=="boolean"){throw new TypeError("The `isEnabled` option must be a boolean")}this._isEnabled=e}get isSilent(){return this._isSilent}set isSilent(e){if(typeof e!=="boolean"){throw new TypeError("The `isSilent` option must be a boolean")}this._isSilent=e}frame(){const{frames:e}=this.spinner;let t=e[this.frameIndex];if(this.color){t=i[this.color](t)}this.frameIndex=++this.frameIndex%e.length;const r=typeof this.prefixText==="string"&&this.prefixText!==""?this.prefixText+" ":"";const s=typeof this.text==="string"?" "+this.text:"";return r+t+s}clear(){if(!this.isEnabled||!this.stream.isTTY){return this}for(let e=0;e<this.linesToClear;e++){if(e>0){this.stream.moveCursor(0,-1)}this.stream.clearLine();this.stream.cursorTo(this.indent)}this.linesToClear=0;return this}render(){if(this.isSilent){return this}this.clear();this.stream.write(this.frame());this.linesToClear=this.lineCount;return this}start(e){if(e){this.text=e}if(this.isSilent){return this}if(!this.isEnabled){if(this.text){this.stream.write(`- ${this.text}\n`)}return this}if(this.isSpinning){return this}if(this.hideCursor){n.hide(this.stream)}if(this.discardStdin&&process.stdin.isTTY){this.isDiscardingStdin=true;y.start()}this.render();this.id=setInterval(this.render.bind(this),this.interval);return this}stop(){if(!this.isEnabled){return this}clearInterval(this.id);this.id=undefined;this.frameIndex=0;this.clear();if(this.hideCursor){n.show(this.stream)}if(this.discardStdin&&process.stdin.isTTY&&this.isDiscardingStdin){y.stop();this.isDiscardingStdin=false}return this}succeed(e){return this.stopAndPersist({symbol:a.success,text:e})}fail(e){return this.stopAndPersist({symbol:a.error,text:e})}warn(e){return this.stopAndPersist({symbol:a.warning,text:e})}info(e){return this.stopAndPersist({symbol:a.info,text:e})}stopAndPersist(e={}){if(this.isSilent){return this}const t=e.prefixText||this.prefixText;const r=e.text||this.text;const s=typeof r==="string"?" "+r:"";this.stop();this.stream.write(`${this.getFullPrefixText(t," ")}${e.symbol||" "}${s}\n`);return this}}const oraFactory=function(e){return new Ora(e)};e.exports=oraFactory;e.exports.promise=(e,t)=>{if(typeof e.then!=="function"){throw new TypeError("Parameter `action` must be a Promise")}const r=new Ora(t);r.start();(async()=>{try{await e;r.succeed()}catch{r.fail()}})();return r}},539:e=>{"use strict";const pathKey=(e={})=>{const t=e.env||process.env;const r=e.platform||process.platform;if(r!=="win32"){return"PATH"}return Object.keys(t).reverse().find((e=>e.toUpperCase()==="PATH"))||"Path"};e.exports=pathKey;e.exports["default"]=pathKey},8569:(e,t,r)=>{"use strict";e.exports=r(3322)},6099:(e,t,r)=>{"use strict";const s=r(1017);const i="\\\\/";const n=`[^${i}]`;const o="\\.";const a="\\+";const l="\\?";const u="\\/";const h="(?=.)";const f="[^/]";const p=`(?:${u}|$)`;const d=`(?:^|${u})`;const m=`${o}{1,2}${p}`;const g=`(?!${o})`;const y=`(?!${d}${m})`;const b=`(?!${o}{0,1}${p})`;const _=`(?!${m})`;const v=`[^.${u}]`;const w=`${f}*?`;const E={DOT_LITERAL:o,PLUS_LITERAL:a,QMARK_LITERAL:l,SLASH_LITERAL:u,ONE_CHAR:h,QMARK:f,END_ANCHOR:p,DOTS_SLASH:m,NO_DOT:g,NO_DOTS:y,NO_DOT_SLASH:b,NO_DOTS_SLASH:_,QMARK_NO_DOT:v,STAR:w,START_ANCHOR:d};const S={...E,SLASH_LITERAL:`[${i}]`,QMARK:n,STAR:`${n}*?`,DOTS_SLASH:`${o}{1,2}(?:[${i}]|$)`,NO_DOT:`(?!${o})`,NO_DOTS:`(?!(?:^|[${i}])${o}{1,2}(?:[${i}]|$))`,NO_DOT_SLASH:`(?!${o}{0,1}(?:[${i}]|$))`,NO_DOTS_SLASH:`(?!${o}{1,2}(?:[${i}]|$))`,QMARK_NO_DOT:`[^.${i}]`,START_ANCHOR:`(?:^|[${i}])`,END_ANCHOR:`(?:[${i}]|$)`};const x={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};e.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:x,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:s.sep,extglobChars(e){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${e.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(e){return e===true?S:E}}},2139:(e,t,r)=>{"use strict";const s=r(6099);const i=r(479);const{MAX_LENGTH:n,POSIX_REGEX_SOURCE:o,REGEX_NON_SPECIAL_CHARS:a,REGEX_SPECIAL_CHARS_BACKREF:l,REPLACEMENTS:u}=s;const expandRange=(e,t)=>{if(typeof t.expandRange==="function"){return t.expandRange(...e,t)}e.sort();const r=`[${e.join("-")}]`;try{new RegExp(r)}catch(t){return e.map((e=>i.escapeRegex(e))).join("..")}return r};const syntaxError=(e,t)=>`Missing ${e}: "${t}" - use "\\\\${t}" to match literal characters`;const parse=(e,t)=>{if(typeof e!=="string"){throw new TypeError("Expected a string")}e=u[e]||e;const r={...t};const h=typeof r.maxLength==="number"?Math.min(n,r.maxLength):n;let f=e.length;if(f>h){throw new SyntaxError(`Input length: ${f}, exceeds maximum allowed length: ${h}`)}const p={type:"bos",value:"",output:r.prepend||""};const d=[p];const m=r.capture?"":"?:";const g=i.isWindows(t);const y=s.globChars(g);const b=s.extglobChars(y);const{DOT_LITERAL:_,PLUS_LITERAL:v,SLASH_LITERAL:w,ONE_CHAR:E,DOTS_SLASH:S,NO_DOT:x,NO_DOT_SLASH:R,NO_DOTS_SLASH:A,QMARK:C,QMARK_NO_DOT:O,STAR:k,START_ANCHOR:T}=y;const globstar=e=>`(${m}(?:(?!${T}${e.dot?S:_}).)*?)`;const P=r.dot?"":x;const I=r.dot?C:O;let $=r.bash===true?globstar(r):k;if(r.capture){$=`(${$})`}if(typeof r.noext==="boolean"){r.noextglob=r.noext}const L={input:e,index:-1,start:0,dot:r.dot===true,consumed:"",output:"",prefix:"",backtrack:false,negated:false,brackets:0,braces:0,parens:0,quotes:0,globstar:false,tokens:d};e=i.removePrefix(e,L);f=e.length;const N=[];const M=[];const D=[];let j=p;let B;const eos=()=>L.index===f-1;const F=L.peek=(t=1)=>e[L.index+t];const H=L.advance=()=>e[++L.index]||"";const remaining=()=>e.slice(L.index+1);const consume=(e="",t=0)=>{L.consumed+=e;L.index+=t};const append=e=>{L.output+=e.output!=null?e.output:e.value;consume(e.value)};const negate=()=>{let e=1;while(F()==="!"&&(F(2)!=="("||F(3)==="?")){H();L.start++;e++}if(e%2===0){return false}L.negated=true;L.start++;return true};const increment=e=>{L[e]++;D.push(e)};const decrement=e=>{L[e]--;D.pop()};const push=e=>{if(j.type==="globstar"){const t=L.braces>0&&(e.type==="comma"||e.type==="brace");const r=e.extglob===true||N.length&&(e.type==="pipe"||e.type==="paren");if(e.type!=="slash"&&e.type!=="paren"&&!t&&!r){L.output=L.output.slice(0,-j.output.length);j.type="star";j.value="*";j.output=$;L.output+=j.output}}if(N.length&&e.type!=="paren"){N[N.length-1].inner+=e.value}if(e.value||e.output)append(e);if(j&&j.type==="text"&&e.type==="text"){j.value+=e.value;j.output=(j.output||"")+e.value;return}e.prev=j;d.push(e);j=e};const extglobOpen=(e,t)=>{const s={...b[t],conditions:1,inner:""};s.prev=j;s.parens=L.parens;s.output=L.output;const i=(r.capture?"(":"")+s.open;increment("parens");push({type:e,value:t,output:L.output?"":E});push({type:"paren",extglob:true,value:H(),output:i});N.push(s)};const extglobClose=e=>{let s=e.close+(r.capture?")":"");let i;if(e.type==="negate"){let n=$;if(e.inner&&e.inner.length>1&&e.inner.includes("/")){n=globstar(r)}if(n!==$||eos()||/^\)+$/.test(remaining())){s=e.close=`)$))${n}`}if(e.inner.includes("*")&&(i=remaining())&&/^\.[^\\/.]+$/.test(i)){const r=parse(i,{...t,fastpaths:false}).output;s=e.close=`)${r})${n})`}if(e.prev.type==="bos"){L.negatedExtglob=true}}push({type:"paren",extglob:true,value:B,output:s});decrement("parens")};if(r.fastpaths!==false&&!/(^[*!]|[/()[\]{}"])/.test(e)){let s=false;let n=e.replace(l,((e,t,r,i,n,o)=>{if(i==="\\"){s=true;return e}if(i==="?"){if(t){return t+i+(n?C.repeat(n.length):"")}if(o===0){return I+(n?C.repeat(n.length):"")}return C.repeat(r.length)}if(i==="."){return _.repeat(r.length)}if(i==="*"){if(t){return t+i+(n?$:"")}return $}return t?e:`\\${e}`}));if(s===true){if(r.unescape===true){n=n.replace(/\\/g,"")}else{n=n.replace(/\\+/g,(e=>e.length%2===0?"\\\\":e?"\\":""))}}if(n===e&&r.contains===true){L.output=e;return L}L.output=i.wrapOutput(n,L,t);return L}while(!eos()){B=H();if(B==="\0"){continue}if(B==="\\"){const e=F();if(e==="/"&&r.bash!==true){continue}if(e==="."||e===";"){continue}if(!e){B+="\\";push({type:"text",value:B});continue}const t=/^\\+/.exec(remaining());let s=0;if(t&&t[0].length>2){s=t[0].length;L.index+=s;if(s%2!==0){B+="\\"}}if(r.unescape===true){B=H()}else{B+=H()}if(L.brackets===0){push({type:"text",value:B});continue}}if(L.brackets>0&&(B!=="]"||j.value==="["||j.value==="[^")){if(r.posix!==false&&B===":"){const e=j.value.slice(1);if(e.includes("[")){j.posix=true;if(e.includes(":")){const e=j.value.lastIndexOf("[");const t=j.value.slice(0,e);const r=j.value.slice(e+2);const s=o[r];if(s){j.value=t+s;L.backtrack=true;H();if(!p.output&&d.indexOf(j)===1){p.output=E}continue}}}}if(B==="["&&F()!==":"||B==="-"&&F()==="]"){B=`\\${B}`}if(B==="]"&&(j.value==="["||j.value==="[^")){B=`\\${B}`}if(r.posix===true&&B==="!"&&j.value==="["){B="^"}j.value+=B;append({value:B});continue}if(L.quotes===1&&B!=='"'){B=i.escapeRegex(B);j.value+=B;append({value:B});continue}if(B==='"'){L.quotes=L.quotes===1?0:1;if(r.keepQuotes===true){push({type:"text",value:B})}continue}if(B==="("){increment("parens");push({type:"paren",value:B});continue}if(B===")"){if(L.parens===0&&r.strictBrackets===true){throw new SyntaxError(syntaxError("opening","("))}const e=N[N.length-1];if(e&&L.parens===e.parens+1){extglobClose(N.pop());continue}push({type:"paren",value:B,output:L.parens?")":"\\)"});decrement("parens");continue}if(B==="["){if(r.nobracket===true||!remaining().includes("]")){if(r.nobracket!==true&&r.strictBrackets===true){throw new SyntaxError(syntaxError("closing","]"))}B=`\\${B}`}else{increment("brackets")}push({type:"bracket",value:B});continue}if(B==="]"){if(r.nobracket===true||j&&j.type==="bracket"&&j.value.length===1){push({type:"text",value:B,output:`\\${B}`});continue}if(L.brackets===0){if(r.strictBrackets===true){throw new SyntaxError(syntaxError("opening","["))}push({type:"text",value:B,output:`\\${B}`});continue}decrement("brackets");const e=j.value.slice(1);if(j.posix!==true&&e[0]==="^"&&!e.includes("/")){B=`/${B}`}j.value+=B;append({value:B});if(r.literalBrackets===false||i.hasRegexChars(e)){continue}const t=i.escapeRegex(j.value);L.output=L.output.slice(0,-j.value.length);if(r.literalBrackets===true){L.output+=t;j.value=t;continue}j.value=`(${m}${t}|${j.value})`;L.output+=j.value;continue}if(B==="{"&&r.nobrace!==true){increment("braces");const e={type:"brace",value:B,output:"(",outputIndex:L.output.length,tokensIndex:L.tokens.length};M.push(e);push(e);continue}if(B==="}"){const e=M[M.length-1];if(r.nobrace===true||!e){push({type:"text",value:B,output:B});continue}let t=")";if(e.dots===true){const e=d.slice();const s=[];for(let t=e.length-1;t>=0;t--){d.pop();if(e[t].type==="brace"){break}if(e[t].type!=="dots"){s.unshift(e[t].value)}}t=expandRange(s,r);L.backtrack=true}if(e.comma!==true&&e.dots!==true){const r=L.output.slice(0,e.outputIndex);const s=L.tokens.slice(e.tokensIndex);e.value=e.output="\\{";B=t="\\}";L.output=r;for(const e of s){L.output+=e.output||e.value}}push({type:"brace",value:B,output:t});decrement("braces");M.pop();continue}if(B==="|"){if(N.length>0){N[N.length-1].conditions++}push({type:"text",value:B});continue}if(B===","){let e=B;const t=M[M.length-1];if(t&&D[D.length-1]==="braces"){t.comma=true;e="|"}push({type:"comma",value:B,output:e});continue}if(B==="/"){if(j.type==="dot"&&L.index===L.start+1){L.start=L.index+1;L.consumed="";L.output="";d.pop();j=p;continue}push({type:"slash",value:B,output:w});continue}if(B==="."){if(L.braces>0&&j.type==="dot"){if(j.value===".")j.output=_;const e=M[M.length-1];j.type="dots";j.output+=B;j.value+=B;e.dots=true;continue}if(L.braces+L.parens===0&&j.type!=="bos"&&j.type!=="slash"){push({type:"text",value:B,output:_});continue}push({type:"dot",value:B,output:_});continue}if(B==="?"){const e=j&&j.value==="(";if(!e&&r.noextglob!==true&&F()==="("&&F(2)!=="?"){extglobOpen("qmark",B);continue}if(j&&j.type==="paren"){const e=F();let t=B;if(e==="<"&&!i.supportsLookbehinds()){throw new Error("Node.js v10 or higher is required for regex lookbehinds")}if(j.value==="("&&!/[!=<:]/.test(e)||e==="<"&&!/<([!=]|\w+>)/.test(remaining())){t=`\\${B}`}push({type:"text",value:B,output:t});continue}if(r.dot!==true&&(j.type==="slash"||j.type==="bos")){push({type:"qmark",value:B,output:O});continue}push({type:"qmark",value:B,output:C});continue}if(B==="!"){if(r.noextglob!==true&&F()==="("){if(F(2)!=="?"||!/[!=<:]/.test(F(3))){extglobOpen("negate",B);continue}}if(r.nonegate!==true&&L.index===0){negate();continue}}if(B==="+"){if(r.noextglob!==true&&F()==="("&&F(2)!=="?"){extglobOpen("plus",B);continue}if(j&&j.value==="("||r.regex===false){push({type:"plus",value:B,output:v});continue}if(j&&(j.type==="bracket"||j.type==="paren"||j.type==="brace")||L.parens>0){push({type:"plus",value:B});continue}push({type:"plus",value:v});continue}if(B==="@"){if(r.noextglob!==true&&F()==="("&&F(2)!=="?"){push({type:"at",extglob:true,value:B,output:""});continue}push({type:"text",value:B});continue}if(B!=="*"){if(B==="$"||B==="^"){B=`\\${B}`}const e=a.exec(remaining());if(e){B+=e[0];L.index+=e[0].length}push({type:"text",value:B});continue}if(j&&(j.type==="globstar"||j.star===true)){j.type="star";j.star=true;j.value+=B;j.output=$;L.backtrack=true;L.globstar=true;consume(B);continue}let t=remaining();if(r.noextglob!==true&&/^\([^?]/.test(t)){extglobOpen("star",B);continue}if(j.type==="star"){if(r.noglobstar===true){consume(B);continue}const s=j.prev;const i=s.prev;const n=s.type==="slash"||s.type==="bos";const o=i&&(i.type==="star"||i.type==="globstar");if(r.bash===true&&(!n||t[0]&&t[0]!=="/")){push({type:"star",value:B,output:""});continue}const a=L.braces>0&&(s.type==="comma"||s.type==="brace");const l=N.length&&(s.type==="pipe"||s.type==="paren");if(!n&&s.type!=="paren"&&!a&&!l){push({type:"star",value:B,output:""});continue}while(t.slice(0,3)==="/**"){const r=e[L.index+4];if(r&&r!=="/"){break}t=t.slice(3);consume("/**",3)}if(s.type==="bos"&&eos()){j.type="globstar";j.value+=B;j.output=globstar(r);L.output=j.output;L.globstar=true;consume(B);continue}if(s.type==="slash"&&s.prev.type!=="bos"&&!o&&eos()){L.output=L.output.slice(0,-(s.output+j.output).length);s.output=`(?:${s.output}`;j.type="globstar";j.output=globstar(r)+(r.strictSlashes?")":"|$)");j.value+=B;L.globstar=true;L.output+=s.output+j.output;consume(B);continue}if(s.type==="slash"&&s.prev.type!=="bos"&&t[0]==="/"){const e=t[1]!==void 0?"|$":"";L.output=L.output.slice(0,-(s.output+j.output).length);s.output=`(?:${s.output}`;j.type="globstar";j.output=`${globstar(r)}${w}|${w}${e})`;j.value+=B;L.output+=s.output+j.output;L.globstar=true;consume(B+H());push({type:"slash",value:"/",output:""});continue}if(s.type==="bos"&&t[0]==="/"){j.type="globstar";j.value+=B;j.output=`(?:^|${w}|${globstar(r)}${w})`;L.output=j.output;L.globstar=true;consume(B+H());push({type:"slash",value:"/",output:""});continue}L.output=L.output.slice(0,-j.output.length);j.type="globstar";j.output=globstar(r);j.value+=B;L.output+=j.output;L.globstar=true;consume(B);continue}const s={type:"star",value:B,output:$};if(r.bash===true){s.output=".*?";if(j.type==="bos"||j.type==="slash"){s.output=P+s.output}push(s);continue}if(j&&(j.type==="bracket"||j.type==="paren")&&r.regex===true){s.output=B;push(s);continue}if(L.index===L.start||j.type==="slash"||j.type==="dot"){if(j.type==="dot"){L.output+=R;j.output+=R}else if(r.dot===true){L.output+=A;j.output+=A}else{L.output+=P;j.output+=P}if(F()!=="*"){L.output+=E;j.output+=E}}push(s)}while(L.brackets>0){if(r.strictBrackets===true)throw new SyntaxError(syntaxError("closing","]"));L.output=i.escapeLast(L.output,"[");decrement("brackets")}while(L.parens>0){if(r.strictBrackets===true)throw new SyntaxError(syntaxError("closing",")"));L.output=i.escapeLast(L.output,"(");decrement("parens")}while(L.braces>0){if(r.strictBrackets===true)throw new SyntaxError(syntaxError("closing","}"));L.output=i.escapeLast(L.output,"{");decrement("braces")}if(r.strictSlashes!==true&&(j.type==="star"||j.type==="bracket")){push({type:"maybe_slash",value:"",output:`${w}?`})}if(L.backtrack===true){L.output="";for(const e of L.tokens){L.output+=e.output!=null?e.output:e.value;if(e.suffix){L.output+=e.suffix}}}return L};parse.fastpaths=(e,t)=>{const r={...t};const o=typeof r.maxLength==="number"?Math.min(n,r.maxLength):n;const a=e.length;if(a>o){throw new SyntaxError(`Input length: ${a}, exceeds maximum allowed length: ${o}`)}e=u[e]||e;const l=i.isWindows(t);const{DOT_LITERAL:h,SLASH_LITERAL:f,ONE_CHAR:p,DOTS_SLASH:d,NO_DOT:m,NO_DOTS:g,NO_DOTS_SLASH:y,STAR:b,START_ANCHOR:_}=s.globChars(l);const v=r.dot?g:m;const w=r.dot?y:m;const E=r.capture?"":"?:";const S={negated:false,prefix:""};let x=r.bash===true?".*?":b;if(r.capture){x=`(${x})`}const globstar=e=>{if(e.noglobstar===true)return x;return`(${E}(?:(?!${_}${e.dot?d:h}).)*?)`};const create=e=>{switch(e){case"*":return`${v}${p}${x}`;case".*":return`${h}${p}${x}`;case"*.*":return`${v}${x}${h}${p}${x}`;case"*/*":return`${v}${x}${f}${p}${w}${x}`;case"**":return v+globstar(r);case"**/*":return`(?:${v}${globstar(r)}${f})?${w}${p}${x}`;case"**/*.*":return`(?:${v}${globstar(r)}${f})?${w}${x}${h}${p}${x}`;case"**/.*":return`(?:${v}${globstar(r)}${f})?${h}${p}${x}`;default:{const t=/^(.*?)\.(\w+)$/.exec(e);if(!t)return;const r=create(t[1]);if(!r)return;return r+h+t[2]}}};const R=i.removePrefix(e,S);let A=create(R);if(A&&r.strictSlashes!==true){A+=`${f}?`}return A};e.exports=parse},3322:(e,t,r)=>{"use strict";const s=r(1017);const i=r(2429);const n=r(2139);const o=r(479);const a=r(6099);const isObject=e=>e&&typeof e==="object"&&!Array.isArray(e);const picomatch=(e,t,r=false)=>{if(Array.isArray(e)){const s=e.map((e=>picomatch(e,t,r)));const arrayMatcher=e=>{for(const t of s){const r=t(e);if(r)return r}return false};return arrayMatcher}const s=isObject(e)&&e.tokens&&e.input;if(e===""||typeof e!=="string"&&!s){throw new TypeError("Expected pattern to be a non-empty string")}const i=t||{};const n=o.isWindows(t);const a=s?picomatch.compileRe(e,t):picomatch.makeRe(e,t,false,true);const l=a.state;delete a.state;let isIgnored=()=>false;if(i.ignore){const e={...t,ignore:null,onMatch:null,onResult:null};isIgnored=picomatch(i.ignore,e,r)}const matcher=(r,s=false)=>{const{isMatch:o,match:u,output:h}=picomatch.test(r,a,t,{glob:e,posix:n});const f={glob:e,state:l,regex:a,posix:n,input:r,output:h,match:u,isMatch:o};if(typeof i.onResult==="function"){i.onResult(f)}if(o===false){f.isMatch=false;return s?f:false}if(isIgnored(r)){if(typeof i.onIgnore==="function"){i.onIgnore(f)}f.isMatch=false;return s?f:false}if(typeof i.onMatch==="function"){i.onMatch(f)}return s?f:true};if(r){matcher.state=l}return matcher};picomatch.test=(e,t,r,{glob:s,posix:i}={})=>{if(typeof e!=="string"){throw new TypeError("Expected input to be a string")}if(e===""){return{isMatch:false,output:""}}const n=r||{};const a=n.format||(i?o.toPosixSlashes:null);let l=e===s;let u=l&&a?a(e):e;if(l===false){u=a?a(e):e;l=u===s}if(l===false||n.capture===true){if(n.matchBase===true||n.basename===true){l=picomatch.matchBase(e,t,r,i)}else{l=t.exec(u)}}return{isMatch:Boolean(l),match:l,output:u}};picomatch.matchBase=(e,t,r,i=o.isWindows(r))=>{const n=t instanceof RegExp?t:picomatch.makeRe(t,r);return n.test(s.basename(e))};picomatch.isMatch=(e,t,r)=>picomatch(t,r)(e);picomatch.parse=(e,t)=>{if(Array.isArray(e))return e.map((e=>picomatch.parse(e,t)));return n(e,{...t,fastpaths:false})};picomatch.scan=(e,t)=>i(e,t);picomatch.compileRe=(e,t,r=false,s=false)=>{if(r===true){return e.output}const i=t||{};const n=i.contains?"":"^";const o=i.contains?"":"$";let a=`${n}(?:${e.output})${o}`;if(e&&e.negated===true){a=`^(?!${a}).*$`}const l=picomatch.toRegex(a,t);if(s===true){l.state=e}return l};picomatch.makeRe=(e,t={},r=false,s=false)=>{if(!e||typeof e!=="string"){throw new TypeError("Expected a non-empty string")}let i={negated:false,fastpaths:true};if(t.fastpaths!==false&&(e[0]==="."||e[0]==="*")){i.output=n.fastpaths(e,t)}if(!i.output){i=n(e,t)}return picomatch.compileRe(i,t,r,s)};picomatch.toRegex=(e,t)=>{try{const r=t||{};return new RegExp(e,r.flags||(r.nocase?"i":""))}catch(e){if(t&&t.debug===true)throw e;return/$^/}};picomatch.constants=a;e.exports=picomatch},2429:(e,t,r)=>{"use strict";const s=r(479);const{CHAR_ASTERISK:i,CHAR_AT:n,CHAR_BACKWARD_SLASH:o,CHAR_COMMA:a,CHAR_DOT:l,CHAR_EXCLAMATION_MARK:u,CHAR_FORWARD_SLASH:h,CHAR_LEFT_CURLY_BRACE:f,CHAR_LEFT_PARENTHESES:p,CHAR_LEFT_SQUARE_BRACKET:d,CHAR_PLUS:m,CHAR_QUESTION_MARK:g,CHAR_RIGHT_CURLY_BRACE:y,CHAR_RIGHT_PARENTHESES:b,CHAR_RIGHT_SQUARE_BRACKET:_}=r(6099);const isPathSeparator=e=>e===h||e===o;const depth=e=>{if(e.isPrefix!==true){e.depth=e.isGlobstar?Infinity:1}};const scan=(e,t)=>{const r=t||{};const v=e.length-1;const w=r.parts===true||r.scanToEnd===true;const E=[];const S=[];const x=[];let R=e;let A=-1;let C=0;let O=0;let k=false;let T=false;let P=false;let I=false;let $=false;let L=false;let N=false;let M=false;let D=false;let j=false;let B=0;let F;let H;let G={value:"",depth:0,isGlob:false};const eos=()=>A>=v;const peek=()=>R.charCodeAt(A+1);const advance=()=>{F=H;return R.charCodeAt(++A)};while(A<v){H=advance();let e;if(H===o){N=G.backslashes=true;H=advance();if(H===f){L=true}continue}if(L===true||H===f){B++;while(eos()!==true&&(H=advance())){if(H===o){N=G.backslashes=true;advance();continue}if(H===f){B++;continue}if(L!==true&&H===l&&(H=advance())===l){k=G.isBrace=true;P=G.isGlob=true;j=true;if(w===true){continue}break}if(L!==true&&H===a){k=G.isBrace=true;P=G.isGlob=true;j=true;if(w===true){continue}break}if(H===y){B--;if(B===0){L=false;k=G.isBrace=true;j=true;break}}}if(w===true){continue}break}if(H===h){E.push(A);S.push(G);G={value:"",depth:0,isGlob:false};if(j===true)continue;if(F===l&&A===C+1){C+=2;continue}O=A+1;continue}if(r.noext!==true){const e=H===m||H===n||H===i||H===g||H===u;if(e===true&&peek()===p){P=G.isGlob=true;I=G.isExtglob=true;j=true;if(H===u&&A===C){D=true}if(w===true){while(eos()!==true&&(H=advance())){if(H===o){N=G.backslashes=true;H=advance();continue}if(H===b){P=G.isGlob=true;j=true;break}}continue}break}}if(H===i){if(F===i)$=G.isGlobstar=true;P=G.isGlob=true;j=true;if(w===true){continue}break}if(H===g){P=G.isGlob=true;j=true;if(w===true){continue}break}if(H===d){while(eos()!==true&&(e=advance())){if(e===o){N=G.backslashes=true;advance();continue}if(e===_){T=G.isBracket=true;P=G.isGlob=true;j=true;break}}if(w===true){continue}break}if(r.nonegate!==true&&H===u&&A===C){M=G.negated=true;C++;continue}if(r.noparen!==true&&H===p){P=G.isGlob=true;if(w===true){while(eos()!==true&&(H=advance())){if(H===p){N=G.backslashes=true;H=advance();continue}if(H===b){j=true;break}}continue}break}if(P===true){j=true;if(w===true){continue}break}}if(r.noext===true){I=false;P=false}let W=R;let U="";let q="";if(C>0){U=R.slice(0,C);R=R.slice(C);O-=C}if(W&&P===true&&O>0){W=R.slice(0,O);q=R.slice(O)}else if(P===true){W="";q=R}else{W=R}if(W&&W!==""&&W!=="/"&&W!==R){if(isPathSeparator(W.charCodeAt(W.length-1))){W=W.slice(0,-1)}}if(r.unescape===true){if(q)q=s.removeBackslashes(q);if(W&&N===true){W=s.removeBackslashes(W)}}const V={prefix:U,input:e,start:C,base:W,glob:q,isBrace:k,isBracket:T,isGlob:P,isExtglob:I,isGlobstar:$,negated:M,negatedExtglob:D};if(r.tokens===true){V.maxDepth=0;if(!isPathSeparator(H)){S.push(G)}V.tokens=S}if(r.parts===true||r.tokens===true){let t;for(let s=0;s<E.length;s++){const i=t?t+1:C;const n=E[s];const o=e.slice(i,n);if(r.tokens){if(s===0&&C!==0){S[s].isPrefix=true;S[s].value=U}else{S[s].value=o}depth(S[s]);V.maxDepth+=S[s].depth}if(s!==0||o!==""){x.push(o)}t=n}if(t&&t+1<e.length){const s=e.slice(t+1);x.push(s);if(r.tokens){S[S.length-1].value=s;depth(S[S.length-1]);V.maxDepth+=S[S.length-1].depth}}V.slashes=E;V.parts=x}return V};e.exports=scan},479:(e,t,r)=>{"use strict";const s=r(1017);const i=process.platform==="win32";const{REGEX_BACKSLASH:n,REGEX_REMOVE_BACKSLASH:o,REGEX_SPECIAL_CHARS:a,REGEX_SPECIAL_CHARS_GLOBAL:l}=r(6099);t.isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);t.hasRegexChars=e=>a.test(e);t.isRegexChar=e=>e.length===1&&t.hasRegexChars(e);t.escapeRegex=e=>e.replace(l,"\\$1");t.toPosixSlashes=e=>e.replace(n,"/");t.removeBackslashes=e=>e.replace(o,(e=>e==="\\"?"":e));t.supportsLookbehinds=()=>{const e=process.version.slice(1).split(".").map(Number);if(e.length===3&&e[0]>=9||e[0]===8&&e[1]>=10){return true}return false};t.isWindows=e=>{if(e&&typeof e.windows==="boolean"){return e.windows}return i===true||s.sep==="\\"};t.escapeLast=(e,r,s)=>{const i=e.lastIndexOf(r,s);if(i===-1)return e;if(e[i-1]==="\\")return t.escapeLast(e,r,i-1);return`${e.slice(0,i)}\\${e.slice(i)}`};t.removePrefix=(e,t={})=>{let r=e;if(r.startsWith("./")){r=r.slice(2);t.prefix="./"}return r};t.wrapOutput=(e,t={},r={})=>{const s=r.contains?"":"^";const i=r.contains?"":"$";let n=`${s}(?:${e})${i}`;if(t.negated===true){n=`(?:^(?!${n}).*$)`}return n}},9795:e=>{
|
|
28
|
+
*/e.exports=function(e){if(typeof e==="number"){return e-e===0}if(typeof e==="string"&&e.trim()!==""){return Number.isFinite?Number.isFinite(+e):isFinite(+e)}return false}},6543:e=>{"use strict";const isStream=e=>e!==null&&typeof e==="object"&&typeof e.pipe==="function";isStream.writable=e=>isStream(e)&&e.writable!==false&&typeof e._write==="function"&&typeof e._writableState==="object";isStream.readable=e=>isStream(e)&&e.readable!==false&&typeof e._read==="function"&&typeof e._readableState==="object";isStream.duplex=e=>isStream.writable(e)&&isStream.readable(e);isStream.transform=e=>isStream.duplex(e)&&typeof e._transform==="function";e.exports=isStream},5557:e=>{"use strict";e.exports=()=>{if(process.platform!=="win32"){return true}return Boolean(process.env.CI)||Boolean(process.env.WT_SESSION)||process.env.TERM_PROGRAM==="vscode"||process.env.TERM==="xterm-256color"||process.env.TERM==="alacritty"}},2940:(e,t,r)=>{var i=r(9896);var n;if(process.platform==="win32"||global.TESTING_WINDOWS){n=r(9225)}else{n=r(1025)}e.exports=isexe;isexe.sync=sync;function isexe(e,t,r){if(typeof t==="function"){r=t;t={}}if(!r){if(typeof Promise!=="function"){throw new TypeError("callback not provided")}return new Promise((function(r,i){isexe(e,t||{},(function(e,t){if(e){i(e)}else{r(t)}}))}))}n(e,t||{},(function(e,i){if(e){if(e.code==="EACCES"||t&&t.ignoreErrors){e=null;i=false}}r(e,i)}))}function sync(e,t){try{return n.sync(e,t||{})}catch(e){if(t&&t.ignoreErrors||e.code==="EACCES"){return false}else{throw e}}}},1025:(e,t,r)=>{e.exports=isexe;isexe.sync=sync;var i=r(9896);function isexe(e,t,r){i.stat(e,(function(e,i){r(e,e?false:checkStat(i,t))}))}function sync(e,t){return checkStat(i.statSync(e),t)}function checkStat(e,t){return e.isFile()&&checkMode(e,t)}function checkMode(e,t){var r=e.mode;var i=e.uid;var n=e.gid;var s=t.uid!==undefined?t.uid:process.getuid&&process.getuid();var o=t.gid!==undefined?t.gid:process.getgid&&process.getgid();var a=parseInt("100",8);var l=parseInt("010",8);var u=parseInt("001",8);var h=a|l;var f=r&u||r&l&&n===o||r&a&&i===s||r&h&&s===0;return f}},9225:(e,t,r)=>{e.exports=isexe;isexe.sync=sync;var i=r(9896);function checkPathExt(e,t){var r=t.pathExt!==undefined?t.pathExt:process.env.PATHEXT;if(!r){return true}r=r.split(";");if(r.indexOf("")!==-1){return true}for(var i=0;i<r.length;i++){var n=r[i].toLowerCase();if(n&&e.substr(-n.length).toLowerCase()===n){return true}}return false}function checkStat(e,t,r){if(!e.isSymbolicLink()&&!e.isFile()){return false}return checkPathExt(t,r)}function isexe(e,t,r){i.stat(e,(function(i,n){r(i,i?false:checkStat(n,e,t))}))}function sync(e,t){return checkStat(i.statSync(e),e,t)}},2270:(e,t,r)=>{"use strict";const i=r(465);const n=r(5557);const s={info:i.blue("ℹ"),success:i.green("✔"),warning:i.yellow("⚠"),error:i.red("✖")};const o={info:i.blue("i"),success:i.green("√"),warning:i.yellow("‼"),error:i.red("×")};e.exports=n()?s:o},8595:(e,t,r)=>{"use strict";const{PassThrough:i}=r(2203);e.exports=function(){var e=[];var t=new i({objectMode:true});t.setMaxListeners(0);t.add=add;t.isEmpty=isEmpty;t.on("unpipe",remove);Array.prototype.slice.call(arguments).forEach(add);return t;function add(r){if(Array.isArray(r)){r.forEach(add);return this}e.push(r);r.once("end",remove.bind(null,r));r.once("error",t.emit.bind(t,"error"));r.pipe(t,{end:false});return this}function isEmpty(){return e.length==0}function remove(r){e=e.filter((function(e){return e!==r}));if(!e.length&&t.readable){t.end()}}}},754:(e,t,r)=>{"use strict";const i=r(2203);const n=i.PassThrough;const s=Array.prototype.slice;e.exports=merge2;function merge2(){const e=[];const t=s.call(arguments);let r=false;let i=t[t.length-1];if(i&&!Array.isArray(i)&&i.pipe==null){t.pop()}else{i={}}const o=i.end!==false;const a=i.pipeError===true;if(i.objectMode==null){i.objectMode=true}if(i.highWaterMark==null){i.highWaterMark=64*1024}const l=n(i);function addStream(){for(let t=0,r=arguments.length;t<r;t++){e.push(pauseStreams(arguments[t],i))}mergeStream();return this}function mergeStream(){if(r){return}r=true;let t=e.shift();if(!t){process.nextTick(endStream);return}if(!Array.isArray(t)){t=[t]}let i=t.length+1;function next(){if(--i>0){return}r=false;mergeStream()}function pipe(e){function onend(){e.removeListener("merge2UnpipeEnd",onend);e.removeListener("end",onend);if(a){e.removeListener("error",onerror)}next()}function onerror(e){l.emit("error",e)}if(e._readableState.endEmitted){return next()}e.on("merge2UnpipeEnd",onend);e.on("end",onend);if(a){e.on("error",onerror)}e.pipe(l,{end:false});e.resume()}for(let e=0;e<t.length;e++){pipe(t[e])}next()}function endStream(){r=false;l.emit("queueDrain");if(o){l.end()}}l.setMaxListeners(0);l.add=addStream;l.on("unpipe",(function(e){e.emit("merge2UnpipeEnd")}));if(t.length){addStream.apply(null,t)}return l}function pauseStreams(e,t){if(!Array.isArray(e)){if(!e._readableState&&e.pipe){e=e.pipe(n(t))}if(!e._readableState||!e.pause||!e.pipe){throw new Error("Only readable stream can be merged.")}e.pause()}else{for(let r=0,i=e.length;r<i;r++){e[r]=pauseStreams(e[r],t)}}return e}},8785:(e,t,r)=>{"use strict";const i=r(9023);const n=r(748);const s=r(4006);const o=r(4059);const isEmptyString=e=>e===""||e==="./";const hasBraces=e=>{const t=e.indexOf("{");return t>-1&&e.indexOf("}",t)>-1};const micromatch=(e,t,r)=>{t=[].concat(t);e=[].concat(e);let i=new Set;let n=new Set;let o=new Set;let a=0;let onResult=e=>{o.add(e.output);if(r&&r.onResult){r.onResult(e)}};for(let o=0;o<t.length;o++){let l=s(String(t[o]),{...r,onResult:onResult},true);let u=l.state.negated||l.state.negatedExtglob;if(u)a++;for(let t of e){let e=l(t,true);let r=u?!e.isMatch:e.isMatch;if(!r)continue;if(u){i.add(e.output)}else{i.delete(e.output);n.add(e.output)}}}let l=a===t.length?[...o]:[...n];let u=l.filter((e=>!i.has(e)));if(r&&u.length===0){if(r.failglob===true){throw new Error(`No matches found for "${t.join(", ")}"`)}if(r.nonull===true||r.nullglob===true){return r.unescape?t.map((e=>e.replace(/\\/g,""))):t}}return u};micromatch.match=micromatch;micromatch.matcher=(e,t)=>s(e,t);micromatch.isMatch=(e,t,r)=>s(t,r)(e);micromatch.any=micromatch.isMatch;micromatch.not=(e,t,r={})=>{t=[].concat(t).map(String);let i=new Set;let n=[];let onResult=e=>{if(r.onResult)r.onResult(e);n.push(e.output)};let s=new Set(micromatch(e,t,{...r,onResult:onResult}));for(let e of n){if(!s.has(e)){i.add(e)}}return[...i]};micromatch.contains=(e,t,r)=>{if(typeof e!=="string"){throw new TypeError(`Expected a string: "${i.inspect(e)}"`)}if(Array.isArray(t)){return t.some((t=>micromatch.contains(e,t,r)))}if(typeof t==="string"){if(isEmptyString(e)||isEmptyString(t)){return false}if(e.includes(t)||e.startsWith("./")&&e.slice(2).includes(t)){return true}}return micromatch.isMatch(e,t,{...r,contains:true})};micromatch.matchKeys=(e,t,r)=>{if(!o.isObject(e)){throw new TypeError("Expected the first argument to be an object")}let i=micromatch(Object.keys(e),t,r);let n={};for(let t of i)n[t]=e[t];return n};micromatch.some=(e,t,r)=>{let i=[].concat(e);for(let e of[].concat(t)){let t=s(String(e),r);if(i.some((e=>t(e)))){return true}}return false};micromatch.every=(e,t,r)=>{let i=[].concat(e);for(let e of[].concat(t)){let t=s(String(e),r);if(!i.every((e=>t(e)))){return false}}return true};micromatch.all=(e,t,r)=>{if(typeof e!=="string"){throw new TypeError(`Expected a string: "${i.inspect(e)}"`)}return[].concat(t).every((t=>s(t,r)(e)))};micromatch.capture=(e,t,r)=>{let i=o.isWindows(r);let n=s.makeRe(String(e),{...r,capture:true});let a=n.exec(i?o.toPosixSlashes(t):t);if(a){return a.slice(1).map((e=>e===void 0?"":e))}};micromatch.makeRe=(...e)=>s.makeRe(...e);micromatch.scan=(...e)=>s.scan(...e);micromatch.parse=(e,t)=>{let r=[];for(let i of[].concat(e||[])){for(let e of n(String(i),t)){r.push(s.parse(e,t))}}return r};micromatch.braces=(e,t)=>{if(typeof e!=="string")throw new TypeError("Expected a string");if(t&&t.nobrace===true||!hasBraces(e)){return[e]}return n(e,t)};micromatch.braceExpand=(e,t)=>{if(typeof e!=="string")throw new TypeError("Expected a string");return micromatch.braces(e,{...t,expand:true})};micromatch.hasBraces=hasBraces;e.exports=micromatch},9384:e=>{"use strict";const mimicFn=(e,t)=>{for(const r of Reflect.ownKeys(t)){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}return e};e.exports=mimicFn;e.exports["default"]=mimicFn},4469:(e,t,r)=>{const i=r(1938);const n=r(8187);const{mkdirpNative:s,mkdirpNativeSync:o}=r(122);const{mkdirpManual:a,mkdirpManualSync:l}=r(999);const{useNative:u,useNativeSync:h}=r(3508);const mkdirp=(e,t)=>{e=n(e);t=i(t);return u(t)?s(e,t):a(e,t)};const mkdirpSync=(e,t)=>{e=n(e);t=i(t);return h(t)?o(e,t):l(e,t)};mkdirp.sync=mkdirpSync;mkdirp.native=(e,t)=>s(n(e),i(t));mkdirp.manual=(e,t)=>a(n(e),i(t));mkdirp.nativeSync=(e,t)=>o(n(e),i(t));mkdirp.manualSync=(e,t)=>l(n(e),i(t));e.exports=mkdirp},2922:(e,t,r)=>{const{dirname:i}=r(6928);const findMade=(e,t,r=undefined)=>{if(r===t)return Promise.resolve();return e.statAsync(t).then((e=>e.isDirectory()?r:undefined),(r=>r.code==="ENOENT"?findMade(e,i(t),t):undefined))};const findMadeSync=(e,t,r=undefined)=>{if(r===t)return undefined;try{return e.statSync(t).isDirectory()?r:undefined}catch(r){return r.code==="ENOENT"?findMadeSync(e,i(t),t):undefined}};e.exports={findMade:findMade,findMadeSync:findMadeSync}},999:(e,t,r)=>{const{dirname:i}=r(6928);const mkdirpManual=(e,t,r)=>{t.recursive=false;const n=i(e);if(n===e){return t.mkdirAsync(e,t).catch((e=>{if(e.code!=="EISDIR")throw e}))}return t.mkdirAsync(e,t).then((()=>r||e),(i=>{if(i.code==="ENOENT")return mkdirpManual(n,t).then((r=>mkdirpManual(e,t,r)));if(i.code!=="EEXIST"&&i.code!=="EROFS")throw i;return t.statAsync(e).then((e=>{if(e.isDirectory())return r;else throw i}),(()=>{throw i}))}))};const mkdirpManualSync=(e,t,r)=>{const n=i(e);t.recursive=false;if(n===e){try{return t.mkdirSync(e,t)}catch(e){if(e.code!=="EISDIR")throw e;else return}}try{t.mkdirSync(e,t);return r||e}catch(i){if(i.code==="ENOENT")return mkdirpManualSync(e,t,mkdirpManualSync(n,t,r));if(i.code!=="EEXIST"&&i.code!=="EROFS")throw i;try{if(!t.statSync(e).isDirectory())throw i}catch(e){throw i}}};e.exports={mkdirpManual:mkdirpManual,mkdirpManualSync:mkdirpManualSync}},122:(e,t,r)=>{const{dirname:i}=r(6928);const{findMade:n,findMadeSync:s}=r(2922);const{mkdirpManual:o,mkdirpManualSync:a}=r(999);const mkdirpNative=(e,t)=>{t.recursive=true;const r=i(e);if(r===e)return t.mkdirAsync(e,t);return n(t,e).then((r=>t.mkdirAsync(e,t).then((()=>r)).catch((r=>{if(r.code==="ENOENT")return o(e,t);else throw r}))))};const mkdirpNativeSync=(e,t)=>{t.recursive=true;const r=i(e);if(r===e)return t.mkdirSync(e,t);const n=s(t,e);try{t.mkdirSync(e,t);return n}catch(r){if(r.code==="ENOENT")return a(e,t);else throw r}};e.exports={mkdirpNative:mkdirpNative,mkdirpNativeSync:mkdirpNativeSync}},1938:(e,t,r)=>{const{promisify:i}=r(9023);const n=r(9896);const optsArg=e=>{if(!e)e={mode:511,fs:n};else if(typeof e==="object")e={mode:511,fs:n,...e};else if(typeof e==="number")e={mode:e,fs:n};else if(typeof e==="string")e={mode:parseInt(e,8),fs:n};else throw new TypeError("invalid options argument");e.mkdir=e.mkdir||e.fs.mkdir||n.mkdir;e.mkdirAsync=i(e.mkdir);e.stat=e.stat||e.fs.stat||n.stat;e.statAsync=i(e.stat);e.statSync=e.statSync||e.fs.statSync||n.statSync;e.mkdirSync=e.mkdirSync||e.fs.mkdirSync||n.mkdirSync;return e};e.exports=optsArg},8187:(e,t,r)=>{const i=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform;const{resolve:n,parse:s}=r(6928);const pathArg=e=>{if(/\0/.test(e)){throw Object.assign(new TypeError("path must be a string without null bytes"),{path:e,code:"ERR_INVALID_ARG_VALUE"})}e=n(e);if(i==="win32"){const t=/[*|"<>?:]/;const{root:r}=s(e);if(t.test(e.substr(r.length))){throw Object.assign(new Error("Illegal characters in path."),{path:e,code:"EINVAL"})}}return e};e.exports=pathArg},3508:(e,t,r)=>{const i=r(9896);const n=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version;const s=n.replace(/^v/,"").split(".");const o=+s[0]>10||+s[0]===10&&+s[1]>=12;const a=!o?()=>false:e=>e.mkdir===i.mkdir;const l=!o?()=>false:e=>e.mkdirSync===i.mkdirSync;e.exports={useNative:a,useNativeSync:l}},6883:(e,t,r)=>{"use strict";const i=r(6928);const n=r(6689);const npmRunPath=e=>{e={cwd:process.cwd(),path:process.env[n()],execPath:process.execPath,...e};let t;let r=i.resolve(e.cwd);const s=[];while(t!==r){s.push(i.join(r,"node_modules/.bin"));t=r;r=i.resolve(r,"..")}const o=i.resolve(e.cwd,e.execPath,"..");s.push(o);return s.concat(e.path).join(i.delimiter)};e.exports=npmRunPath;e.exports["default"]=npmRunPath;e.exports.env=t=>{t={env:process.env,...t};const r={...t.env};const i=n({env:r});t.path=r[i];r[i]=e.exports(t);return r}},9969:(e,t,r)=>{"use strict";const i=r(9384);const n=new WeakMap;const onetime=(e,t={})=>{if(typeof e!=="function"){throw new TypeError("Expected a function")}let r;let s=0;const o=e.displayName||e.name||"<anonymous>";const onetime=function(...i){n.set(onetime,++s);if(s===1){r=e.apply(this,i);e=null}else if(t.throw===true){throw new Error(`Function \`${o}\` can only be called once`)}return r};i(onetime,e);n.set(onetime,s);return onetime};e.exports=onetime;e.exports["default"]=onetime;e.exports.callCount=e=>{if(!n.has(e)){throw new Error(`The given function \`${e.name}\` is not wrapped by the \`onetime\` package`)}return n.get(e)}},5696:(e,t,r)=>{"use strict";const i=r(3785);const n=r(465);const s=r(1687);const o=r(6487);const a=r(2270);const l=r(3958);const u=r(7390);const h=r(573);const f=r(5557);const{BufferListStream:p}=r(794);const d=Symbol("text");const m=Symbol("prefixText");const g=3;class StdinDiscarder{constructor(){this.requests=0;this.mutedStream=new p;this.mutedStream.pipe(process.stdout);const e=this;this.ourEmit=function(t,r,...i){const{stdin:n}=process;if(e.requests>0||n.emit===e.ourEmit){if(t==="keypress"){return}if(t==="data"&&r.includes(g)){process.emit("SIGINT")}Reflect.apply(e.oldEmit,this,[t,r,...i])}else{Reflect.apply(process.stdin.emit,this,[t,r,...i])}}}start(){this.requests++;if(this.requests===1){this.realStart()}}stop(){if(this.requests<=0){throw new Error("`stop` called more times than `start`")}this.requests--;if(this.requests===0){this.realStop()}}realStart(){if(process.platform==="win32"){return}this.rl=i.createInterface({input:process.stdin,output:this.mutedStream});this.rl.on("SIGINT",(()=>{if(process.listenerCount("SIGINT")===0){process.emit("SIGINT")}else{this.rl.close();process.kill(process.pid,"SIGINT")}}))}realStop(){if(process.platform==="win32"){return}this.rl.close();this.rl=undefined}}let y;class Ora{constructor(e){if(!y){y=new StdinDiscarder}if(typeof e==="string"){e={text:e}}this.options={text:"",color:"cyan",stream:process.stderr,discardStdin:true,...e};this.spinner=this.options.spinner;this.color=this.options.color;this.hideCursor=this.options.hideCursor!==false;this.interval=this.options.interval||this.spinner.interval||100;this.stream=this.options.stream;this.id=undefined;this.isEnabled=typeof this.options.isEnabled==="boolean"?this.options.isEnabled:h({stream:this.stream});this.isSilent=typeof this.options.isSilent==="boolean"?this.options.isSilent:false;this.text=this.options.text;this.prefixText=this.options.prefixText;this.linesToClear=0;this.indent=this.options.indent;this.discardStdin=this.options.discardStdin;this.isDiscardingStdin=false}get indent(){return this._indent}set indent(e=0){if(!(e>=0&&Number.isInteger(e))){throw new Error("The `indent` option must be an integer from 0 and up")}this._indent=e}_updateInterval(e){if(e!==undefined){this.interval=e}}get spinner(){return this._spinner}set spinner(e){this.frameIndex=0;if(typeof e==="object"){if(e.frames===undefined){throw new Error("The given spinner must have a `frames` property")}this._spinner=e}else if(!f()){this._spinner=o.line}else if(e===undefined){this._spinner=o.dots}else if(e!=="default"&&o[e]){this._spinner=o[e]}else{throw new Error(`There is no built-in spinner named '${e}'. See https://github.com/sindresorhus/cli-spinners/blob/main/spinners.json for a full list.`)}this._updateInterval(this._spinner.interval)}get text(){return this[d]}set text(e){this[d]=e;this.updateLineCount()}get prefixText(){return this[m]}set prefixText(e){this[m]=e;this.updateLineCount()}get isSpinning(){return this.id!==undefined}getFullPrefixText(e=this[m],t=" "){if(typeof e==="string"){return e+t}if(typeof e==="function"){return e()+t}return""}updateLineCount(){const e=this.stream.columns||80;const t=this.getFullPrefixText(this.prefixText,"-");this.lineCount=0;for(const r of l(t+"--"+this[d]).split("\n")){this.lineCount+=Math.max(1,Math.ceil(u(r)/e))}}get isEnabled(){return this._isEnabled&&!this.isSilent}set isEnabled(e){if(typeof e!=="boolean"){throw new TypeError("The `isEnabled` option must be a boolean")}this._isEnabled=e}get isSilent(){return this._isSilent}set isSilent(e){if(typeof e!=="boolean"){throw new TypeError("The `isSilent` option must be a boolean")}this._isSilent=e}frame(){const{frames:e}=this.spinner;let t=e[this.frameIndex];if(this.color){t=n[this.color](t)}this.frameIndex=++this.frameIndex%e.length;const r=typeof this.prefixText==="string"&&this.prefixText!==""?this.prefixText+" ":"";const i=typeof this.text==="string"?" "+this.text:"";return r+t+i}clear(){if(!this.isEnabled||!this.stream.isTTY){return this}for(let e=0;e<this.linesToClear;e++){if(e>0){this.stream.moveCursor(0,-1)}this.stream.clearLine();this.stream.cursorTo(this.indent)}this.linesToClear=0;return this}render(){if(this.isSilent){return this}this.clear();this.stream.write(this.frame());this.linesToClear=this.lineCount;return this}start(e){if(e){this.text=e}if(this.isSilent){return this}if(!this.isEnabled){if(this.text){this.stream.write(`- ${this.text}\n`)}return this}if(this.isSpinning){return this}if(this.hideCursor){s.hide(this.stream)}if(this.discardStdin&&process.stdin.isTTY){this.isDiscardingStdin=true;y.start()}this.render();this.id=setInterval(this.render.bind(this),this.interval);return this}stop(){if(!this.isEnabled){return this}clearInterval(this.id);this.id=undefined;this.frameIndex=0;this.clear();if(this.hideCursor){s.show(this.stream)}if(this.discardStdin&&process.stdin.isTTY&&this.isDiscardingStdin){y.stop();this.isDiscardingStdin=false}return this}succeed(e){return this.stopAndPersist({symbol:a.success,text:e})}fail(e){return this.stopAndPersist({symbol:a.error,text:e})}warn(e){return this.stopAndPersist({symbol:a.warning,text:e})}info(e){return this.stopAndPersist({symbol:a.info,text:e})}stopAndPersist(e={}){if(this.isSilent){return this}const t=e.prefixText||this.prefixText;const r=e.text||this.text;const i=typeof r==="string"?" "+r:"";this.stop();this.stream.write(`${this.getFullPrefixText(t," ")}${e.symbol||" "}${i}\n`);return this}}const oraFactory=function(e){return new Ora(e)};e.exports=oraFactory;e.exports.promise=(e,t)=>{if(typeof e.then!=="function"){throw new TypeError("Parameter `action` must be a Promise")}const r=new Ora(t);r.start();(async()=>{try{await e;r.succeed()}catch{r.fail()}})();return r}},6689:e=>{"use strict";const pathKey=(e={})=>{const t=e.env||process.env;const r=e.platform||process.platform;if(r!=="win32"){return"PATH"}return Object.keys(t).reverse().find((e=>e.toUpperCase()==="PATH"))||"Path"};e.exports=pathKey;e.exports["default"]=pathKey},4006:(e,t,r)=>{"use strict";e.exports=r(8016)},5595:(e,t,r)=>{"use strict";const i=r(6928);const n="\\\\/";const s=`[^${n}]`;const o="\\.";const a="\\+";const l="\\?";const u="\\/";const h="(?=.)";const f="[^/]";const p=`(?:${u}|$)`;const d=`(?:^|${u})`;const m=`${o}{1,2}${p}`;const g=`(?!${o})`;const y=`(?!${d}${m})`;const b=`(?!${o}{0,1}${p})`;const _=`(?!${m})`;const v=`[^.${u}]`;const w=`${f}*?`;const S={DOT_LITERAL:o,PLUS_LITERAL:a,QMARK_LITERAL:l,SLASH_LITERAL:u,ONE_CHAR:h,QMARK:f,END_ANCHOR:p,DOTS_SLASH:m,NO_DOT:g,NO_DOTS:y,NO_DOT_SLASH:b,NO_DOTS_SLASH:_,QMARK_NO_DOT:v,STAR:w,START_ANCHOR:d};const x={...S,SLASH_LITERAL:`[${n}]`,QMARK:s,STAR:`${s}*?`,DOTS_SLASH:`${o}{1,2}(?:[${n}]|$)`,NO_DOT:`(?!${o})`,NO_DOTS:`(?!(?:^|[${n}])${o}{1,2}(?:[${n}]|$))`,NO_DOT_SLASH:`(?!${o}{0,1}(?:[${n}]|$))`,NO_DOTS_SLASH:`(?!${o}{1,2}(?:[${n}]|$))`,QMARK_NO_DOT:`[^.${n}]`,START_ANCHOR:`(?:^|[${n}])`,END_ANCHOR:`(?:[${n}]|$)`};const E={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};e.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:E,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:i.sep,extglobChars(e){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${e.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(e){return e===true?x:S}}},8265:(e,t,r)=>{"use strict";const i=r(5595);const n=r(4059);const{MAX_LENGTH:s,POSIX_REGEX_SOURCE:o,REGEX_NON_SPECIAL_CHARS:a,REGEX_SPECIAL_CHARS_BACKREF:l,REPLACEMENTS:u}=i;const expandRange=(e,t)=>{if(typeof t.expandRange==="function"){return t.expandRange(...e,t)}e.sort();const r=`[${e.join("-")}]`;try{new RegExp(r)}catch(t){return e.map((e=>n.escapeRegex(e))).join("..")}return r};const syntaxError=(e,t)=>`Missing ${e}: "${t}" - use "\\\\${t}" to match literal characters`;const parse=(e,t)=>{if(typeof e!=="string"){throw new TypeError("Expected a string")}e=u[e]||e;const r={...t};const h=typeof r.maxLength==="number"?Math.min(s,r.maxLength):s;let f=e.length;if(f>h){throw new SyntaxError(`Input length: ${f}, exceeds maximum allowed length: ${h}`)}const p={type:"bos",value:"",output:r.prepend||""};const d=[p];const m=r.capture?"":"?:";const g=n.isWindows(t);const y=i.globChars(g);const b=i.extglobChars(y);const{DOT_LITERAL:_,PLUS_LITERAL:v,SLASH_LITERAL:w,ONE_CHAR:S,DOTS_SLASH:x,NO_DOT:E,NO_DOT_SLASH:A,NO_DOTS_SLASH:k,QMARK:C,QMARK_NO_DOT:R,STAR:P,START_ANCHOR:O}=y;const globstar=e=>`(${m}(?:(?!${O}${e.dot?x:_}).)*?)`;const T=r.dot?"":E;const L=r.dot?C:R;let I=r.bash===true?globstar(r):P;if(r.capture){I=`(${I})`}if(typeof r.noext==="boolean"){r.noextglob=r.noext}const M={input:e,index:-1,start:0,dot:r.dot===true,consumed:"",output:"",prefix:"",backtrack:false,negated:false,brackets:0,braces:0,parens:0,quotes:0,globstar:false,tokens:d};e=n.removePrefix(e,M);f=e.length;const $=[];const j=[];const B=[];let D=p;let N;const eos=()=>M.index===f-1;const H=M.peek=(t=1)=>e[M.index+t];const F=M.advance=()=>e[++M.index]||"";const remaining=()=>e.slice(M.index+1);const consume=(e="",t=0)=>{M.consumed+=e;M.index+=t};const append=e=>{M.output+=e.output!=null?e.output:e.value;consume(e.value)};const negate=()=>{let e=1;while(H()==="!"&&(H(2)!=="("||H(3)==="?")){F();M.start++;e++}if(e%2===0){return false}M.negated=true;M.start++;return true};const increment=e=>{M[e]++;B.push(e)};const decrement=e=>{M[e]--;B.pop()};const push=e=>{if(D.type==="globstar"){const t=M.braces>0&&(e.type==="comma"||e.type==="brace");const r=e.extglob===true||$.length&&(e.type==="pipe"||e.type==="paren");if(e.type!=="slash"&&e.type!=="paren"&&!t&&!r){M.output=M.output.slice(0,-D.output.length);D.type="star";D.value="*";D.output=I;M.output+=D.output}}if($.length&&e.type!=="paren"){$[$.length-1].inner+=e.value}if(e.value||e.output)append(e);if(D&&D.type==="text"&&e.type==="text"){D.value+=e.value;D.output=(D.output||"")+e.value;return}e.prev=D;d.push(e);D=e};const extglobOpen=(e,t)=>{const i={...b[t],conditions:1,inner:""};i.prev=D;i.parens=M.parens;i.output=M.output;const n=(r.capture?"(":"")+i.open;increment("parens");push({type:e,value:t,output:M.output?"":S});push({type:"paren",extglob:true,value:F(),output:n});$.push(i)};const extglobClose=e=>{let i=e.close+(r.capture?")":"");let n;if(e.type==="negate"){let s=I;if(e.inner&&e.inner.length>1&&e.inner.includes("/")){s=globstar(r)}if(s!==I||eos()||/^\)+$/.test(remaining())){i=e.close=`)$))${s}`}if(e.inner.includes("*")&&(n=remaining())&&/^\.[^\\/.]+$/.test(n)){const r=parse(n,{...t,fastpaths:false}).output;i=e.close=`)${r})${s})`}if(e.prev.type==="bos"){M.negatedExtglob=true}}push({type:"paren",extglob:true,value:N,output:i});decrement("parens")};if(r.fastpaths!==false&&!/(^[*!]|[/()[\]{}"])/.test(e)){let i=false;let s=e.replace(l,((e,t,r,n,s,o)=>{if(n==="\\"){i=true;return e}if(n==="?"){if(t){return t+n+(s?C.repeat(s.length):"")}if(o===0){return L+(s?C.repeat(s.length):"")}return C.repeat(r.length)}if(n==="."){return _.repeat(r.length)}if(n==="*"){if(t){return t+n+(s?I:"")}return I}return t?e:`\\${e}`}));if(i===true){if(r.unescape===true){s=s.replace(/\\/g,"")}else{s=s.replace(/\\+/g,(e=>e.length%2===0?"\\\\":e?"\\":""))}}if(s===e&&r.contains===true){M.output=e;return M}M.output=n.wrapOutput(s,M,t);return M}while(!eos()){N=F();if(N==="\0"){continue}if(N==="\\"){const e=H();if(e==="/"&&r.bash!==true){continue}if(e==="."||e===";"){continue}if(!e){N+="\\";push({type:"text",value:N});continue}const t=/^\\+/.exec(remaining());let i=0;if(t&&t[0].length>2){i=t[0].length;M.index+=i;if(i%2!==0){N+="\\"}}if(r.unescape===true){N=F()}else{N+=F()}if(M.brackets===0){push({type:"text",value:N});continue}}if(M.brackets>0&&(N!=="]"||D.value==="["||D.value==="[^")){if(r.posix!==false&&N===":"){const e=D.value.slice(1);if(e.includes("[")){D.posix=true;if(e.includes(":")){const e=D.value.lastIndexOf("[");const t=D.value.slice(0,e);const r=D.value.slice(e+2);const i=o[r];if(i){D.value=t+i;M.backtrack=true;F();if(!p.output&&d.indexOf(D)===1){p.output=S}continue}}}}if(N==="["&&H()!==":"||N==="-"&&H()==="]"){N=`\\${N}`}if(N==="]"&&(D.value==="["||D.value==="[^")){N=`\\${N}`}if(r.posix===true&&N==="!"&&D.value==="["){N="^"}D.value+=N;append({value:N});continue}if(M.quotes===1&&N!=='"'){N=n.escapeRegex(N);D.value+=N;append({value:N});continue}if(N==='"'){M.quotes=M.quotes===1?0:1;if(r.keepQuotes===true){push({type:"text",value:N})}continue}if(N==="("){increment("parens");push({type:"paren",value:N});continue}if(N===")"){if(M.parens===0&&r.strictBrackets===true){throw new SyntaxError(syntaxError("opening","("))}const e=$[$.length-1];if(e&&M.parens===e.parens+1){extglobClose($.pop());continue}push({type:"paren",value:N,output:M.parens?")":"\\)"});decrement("parens");continue}if(N==="["){if(r.nobracket===true||!remaining().includes("]")){if(r.nobracket!==true&&r.strictBrackets===true){throw new SyntaxError(syntaxError("closing","]"))}N=`\\${N}`}else{increment("brackets")}push({type:"bracket",value:N});continue}if(N==="]"){if(r.nobracket===true||D&&D.type==="bracket"&&D.value.length===1){push({type:"text",value:N,output:`\\${N}`});continue}if(M.brackets===0){if(r.strictBrackets===true){throw new SyntaxError(syntaxError("opening","["))}push({type:"text",value:N,output:`\\${N}`});continue}decrement("brackets");const e=D.value.slice(1);if(D.posix!==true&&e[0]==="^"&&!e.includes("/")){N=`/${N}`}D.value+=N;append({value:N});if(r.literalBrackets===false||n.hasRegexChars(e)){continue}const t=n.escapeRegex(D.value);M.output=M.output.slice(0,-D.value.length);if(r.literalBrackets===true){M.output+=t;D.value=t;continue}D.value=`(${m}${t}|${D.value})`;M.output+=D.value;continue}if(N==="{"&&r.nobrace!==true){increment("braces");const e={type:"brace",value:N,output:"(",outputIndex:M.output.length,tokensIndex:M.tokens.length};j.push(e);push(e);continue}if(N==="}"){const e=j[j.length-1];if(r.nobrace===true||!e){push({type:"text",value:N,output:N});continue}let t=")";if(e.dots===true){const e=d.slice();const i=[];for(let t=e.length-1;t>=0;t--){d.pop();if(e[t].type==="brace"){break}if(e[t].type!=="dots"){i.unshift(e[t].value)}}t=expandRange(i,r);M.backtrack=true}if(e.comma!==true&&e.dots!==true){const r=M.output.slice(0,e.outputIndex);const i=M.tokens.slice(e.tokensIndex);e.value=e.output="\\{";N=t="\\}";M.output=r;for(const e of i){M.output+=e.output||e.value}}push({type:"brace",value:N,output:t});decrement("braces");j.pop();continue}if(N==="|"){if($.length>0){$[$.length-1].conditions++}push({type:"text",value:N});continue}if(N===","){let e=N;const t=j[j.length-1];if(t&&B[B.length-1]==="braces"){t.comma=true;e="|"}push({type:"comma",value:N,output:e});continue}if(N==="/"){if(D.type==="dot"&&M.index===M.start+1){M.start=M.index+1;M.consumed="";M.output="";d.pop();D=p;continue}push({type:"slash",value:N,output:w});continue}if(N==="."){if(M.braces>0&&D.type==="dot"){if(D.value===".")D.output=_;const e=j[j.length-1];D.type="dots";D.output+=N;D.value+=N;e.dots=true;continue}if(M.braces+M.parens===0&&D.type!=="bos"&&D.type!=="slash"){push({type:"text",value:N,output:_});continue}push({type:"dot",value:N,output:_});continue}if(N==="?"){const e=D&&D.value==="(";if(!e&&r.noextglob!==true&&H()==="("&&H(2)!=="?"){extglobOpen("qmark",N);continue}if(D&&D.type==="paren"){const e=H();let t=N;if(e==="<"&&!n.supportsLookbehinds()){throw new Error("Node.js v10 or higher is required for regex lookbehinds")}if(D.value==="("&&!/[!=<:]/.test(e)||e==="<"&&!/<([!=]|\w+>)/.test(remaining())){t=`\\${N}`}push({type:"text",value:N,output:t});continue}if(r.dot!==true&&(D.type==="slash"||D.type==="bos")){push({type:"qmark",value:N,output:R});continue}push({type:"qmark",value:N,output:C});continue}if(N==="!"){if(r.noextglob!==true&&H()==="("){if(H(2)!=="?"||!/[!=<:]/.test(H(3))){extglobOpen("negate",N);continue}}if(r.nonegate!==true&&M.index===0){negate();continue}}if(N==="+"){if(r.noextglob!==true&&H()==="("&&H(2)!=="?"){extglobOpen("plus",N);continue}if(D&&D.value==="("||r.regex===false){push({type:"plus",value:N,output:v});continue}if(D&&(D.type==="bracket"||D.type==="paren"||D.type==="brace")||M.parens>0){push({type:"plus",value:N});continue}push({type:"plus",value:v});continue}if(N==="@"){if(r.noextglob!==true&&H()==="("&&H(2)!=="?"){push({type:"at",extglob:true,value:N,output:""});continue}push({type:"text",value:N});continue}if(N!=="*"){if(N==="$"||N==="^"){N=`\\${N}`}const e=a.exec(remaining());if(e){N+=e[0];M.index+=e[0].length}push({type:"text",value:N});continue}if(D&&(D.type==="globstar"||D.star===true)){D.type="star";D.star=true;D.value+=N;D.output=I;M.backtrack=true;M.globstar=true;consume(N);continue}let t=remaining();if(r.noextglob!==true&&/^\([^?]/.test(t)){extglobOpen("star",N);continue}if(D.type==="star"){if(r.noglobstar===true){consume(N);continue}const i=D.prev;const n=i.prev;const s=i.type==="slash"||i.type==="bos";const o=n&&(n.type==="star"||n.type==="globstar");if(r.bash===true&&(!s||t[0]&&t[0]!=="/")){push({type:"star",value:N,output:""});continue}const a=M.braces>0&&(i.type==="comma"||i.type==="brace");const l=$.length&&(i.type==="pipe"||i.type==="paren");if(!s&&i.type!=="paren"&&!a&&!l){push({type:"star",value:N,output:""});continue}while(t.slice(0,3)==="/**"){const r=e[M.index+4];if(r&&r!=="/"){break}t=t.slice(3);consume("/**",3)}if(i.type==="bos"&&eos()){D.type="globstar";D.value+=N;D.output=globstar(r);M.output=D.output;M.globstar=true;consume(N);continue}if(i.type==="slash"&&i.prev.type!=="bos"&&!o&&eos()){M.output=M.output.slice(0,-(i.output+D.output).length);i.output=`(?:${i.output}`;D.type="globstar";D.output=globstar(r)+(r.strictSlashes?")":"|$)");D.value+=N;M.globstar=true;M.output+=i.output+D.output;consume(N);continue}if(i.type==="slash"&&i.prev.type!=="bos"&&t[0]==="/"){const e=t[1]!==void 0?"|$":"";M.output=M.output.slice(0,-(i.output+D.output).length);i.output=`(?:${i.output}`;D.type="globstar";D.output=`${globstar(r)}${w}|${w}${e})`;D.value+=N;M.output+=i.output+D.output;M.globstar=true;consume(N+F());push({type:"slash",value:"/",output:""});continue}if(i.type==="bos"&&t[0]==="/"){D.type="globstar";D.value+=N;D.output=`(?:^|${w}|${globstar(r)}${w})`;M.output=D.output;M.globstar=true;consume(N+F());push({type:"slash",value:"/",output:""});continue}M.output=M.output.slice(0,-D.output.length);D.type="globstar";D.output=globstar(r);D.value+=N;M.output+=D.output;M.globstar=true;consume(N);continue}const i={type:"star",value:N,output:I};if(r.bash===true){i.output=".*?";if(D.type==="bos"||D.type==="slash"){i.output=T+i.output}push(i);continue}if(D&&(D.type==="bracket"||D.type==="paren")&&r.regex===true){i.output=N;push(i);continue}if(M.index===M.start||D.type==="slash"||D.type==="dot"){if(D.type==="dot"){M.output+=A;D.output+=A}else if(r.dot===true){M.output+=k;D.output+=k}else{M.output+=T;D.output+=T}if(H()!=="*"){M.output+=S;D.output+=S}}push(i)}while(M.brackets>0){if(r.strictBrackets===true)throw new SyntaxError(syntaxError("closing","]"));M.output=n.escapeLast(M.output,"[");decrement("brackets")}while(M.parens>0){if(r.strictBrackets===true)throw new SyntaxError(syntaxError("closing",")"));M.output=n.escapeLast(M.output,"(");decrement("parens")}while(M.braces>0){if(r.strictBrackets===true)throw new SyntaxError(syntaxError("closing","}"));M.output=n.escapeLast(M.output,"{");decrement("braces")}if(r.strictSlashes!==true&&(D.type==="star"||D.type==="bracket")){push({type:"maybe_slash",value:"",output:`${w}?`})}if(M.backtrack===true){M.output="";for(const e of M.tokens){M.output+=e.output!=null?e.output:e.value;if(e.suffix){M.output+=e.suffix}}}return M};parse.fastpaths=(e,t)=>{const r={...t};const o=typeof r.maxLength==="number"?Math.min(s,r.maxLength):s;const a=e.length;if(a>o){throw new SyntaxError(`Input length: ${a}, exceeds maximum allowed length: ${o}`)}e=u[e]||e;const l=n.isWindows(t);const{DOT_LITERAL:h,SLASH_LITERAL:f,ONE_CHAR:p,DOTS_SLASH:d,NO_DOT:m,NO_DOTS:g,NO_DOTS_SLASH:y,STAR:b,START_ANCHOR:_}=i.globChars(l);const v=r.dot?g:m;const w=r.dot?y:m;const S=r.capture?"":"?:";const x={negated:false,prefix:""};let E=r.bash===true?".*?":b;if(r.capture){E=`(${E})`}const globstar=e=>{if(e.noglobstar===true)return E;return`(${S}(?:(?!${_}${e.dot?d:h}).)*?)`};const create=e=>{switch(e){case"*":return`${v}${p}${E}`;case".*":return`${h}${p}${E}`;case"*.*":return`${v}${E}${h}${p}${E}`;case"*/*":return`${v}${E}${f}${p}${w}${E}`;case"**":return v+globstar(r);case"**/*":return`(?:${v}${globstar(r)}${f})?${w}${p}${E}`;case"**/*.*":return`(?:${v}${globstar(r)}${f})?${w}${E}${h}${p}${E}`;case"**/.*":return`(?:${v}${globstar(r)}${f})?${h}${p}${E}`;default:{const t=/^(.*?)\.(\w+)$/.exec(e);if(!t)return;const r=create(t[1]);if(!r)return;return r+h+t[2]}}};const A=n.removePrefix(e,x);let k=create(A);if(k&&r.strictSlashes!==true){k+=`${f}?`}return k};e.exports=parse},8016:(e,t,r)=>{"use strict";const i=r(6928);const n=r(1781);const s=r(8265);const o=r(4059);const a=r(5595);const isObject=e=>e&&typeof e==="object"&&!Array.isArray(e);const picomatch=(e,t,r=false)=>{if(Array.isArray(e)){const i=e.map((e=>picomatch(e,t,r)));const arrayMatcher=e=>{for(const t of i){const r=t(e);if(r)return r}return false};return arrayMatcher}const i=isObject(e)&&e.tokens&&e.input;if(e===""||typeof e!=="string"&&!i){throw new TypeError("Expected pattern to be a non-empty string")}const n=t||{};const s=o.isWindows(t);const a=i?picomatch.compileRe(e,t):picomatch.makeRe(e,t,false,true);const l=a.state;delete a.state;let isIgnored=()=>false;if(n.ignore){const e={...t,ignore:null,onMatch:null,onResult:null};isIgnored=picomatch(n.ignore,e,r)}const matcher=(r,i=false)=>{const{isMatch:o,match:u,output:h}=picomatch.test(r,a,t,{glob:e,posix:s});const f={glob:e,state:l,regex:a,posix:s,input:r,output:h,match:u,isMatch:o};if(typeof n.onResult==="function"){n.onResult(f)}if(o===false){f.isMatch=false;return i?f:false}if(isIgnored(r)){if(typeof n.onIgnore==="function"){n.onIgnore(f)}f.isMatch=false;return i?f:false}if(typeof n.onMatch==="function"){n.onMatch(f)}return i?f:true};if(r){matcher.state=l}return matcher};picomatch.test=(e,t,r,{glob:i,posix:n}={})=>{if(typeof e!=="string"){throw new TypeError("Expected input to be a string")}if(e===""){return{isMatch:false,output:""}}const s=r||{};const a=s.format||(n?o.toPosixSlashes:null);let l=e===i;let u=l&&a?a(e):e;if(l===false){u=a?a(e):e;l=u===i}if(l===false||s.capture===true){if(s.matchBase===true||s.basename===true){l=picomatch.matchBase(e,t,r,n)}else{l=t.exec(u)}}return{isMatch:Boolean(l),match:l,output:u}};picomatch.matchBase=(e,t,r,n=o.isWindows(r))=>{const s=t instanceof RegExp?t:picomatch.makeRe(t,r);return s.test(i.basename(e))};picomatch.isMatch=(e,t,r)=>picomatch(t,r)(e);picomatch.parse=(e,t)=>{if(Array.isArray(e))return e.map((e=>picomatch.parse(e,t)));return s(e,{...t,fastpaths:false})};picomatch.scan=(e,t)=>n(e,t);picomatch.compileRe=(e,t,r=false,i=false)=>{if(r===true){return e.output}const n=t||{};const s=n.contains?"":"^";const o=n.contains?"":"$";let a=`${s}(?:${e.output})${o}`;if(e&&e.negated===true){a=`^(?!${a}).*$`}const l=picomatch.toRegex(a,t);if(i===true){l.state=e}return l};picomatch.makeRe=(e,t={},r=false,i=false)=>{if(!e||typeof e!=="string"){throw new TypeError("Expected a non-empty string")}let n={negated:false,fastpaths:true};if(t.fastpaths!==false&&(e[0]==="."||e[0]==="*")){n.output=s.fastpaths(e,t)}if(!n.output){n=s(e,t)}return picomatch.compileRe(n,t,r,i)};picomatch.toRegex=(e,t)=>{try{const r=t||{};return new RegExp(e,r.flags||(r.nocase?"i":""))}catch(e){if(t&&t.debug===true)throw e;return/$^/}};picomatch.constants=a;e.exports=picomatch},1781:(e,t,r)=>{"use strict";const i=r(4059);const{CHAR_ASTERISK:n,CHAR_AT:s,CHAR_BACKWARD_SLASH:o,CHAR_COMMA:a,CHAR_DOT:l,CHAR_EXCLAMATION_MARK:u,CHAR_FORWARD_SLASH:h,CHAR_LEFT_CURLY_BRACE:f,CHAR_LEFT_PARENTHESES:p,CHAR_LEFT_SQUARE_BRACKET:d,CHAR_PLUS:m,CHAR_QUESTION_MARK:g,CHAR_RIGHT_CURLY_BRACE:y,CHAR_RIGHT_PARENTHESES:b,CHAR_RIGHT_SQUARE_BRACKET:_}=r(5595);const isPathSeparator=e=>e===h||e===o;const depth=e=>{if(e.isPrefix!==true){e.depth=e.isGlobstar?Infinity:1}};const scan=(e,t)=>{const r=t||{};const v=e.length-1;const w=r.parts===true||r.scanToEnd===true;const S=[];const x=[];const E=[];let A=e;let k=-1;let C=0;let R=0;let P=false;let O=false;let T=false;let L=false;let I=false;let M=false;let $=false;let j=false;let B=false;let D=false;let N=0;let H;let F;let W={value:"",depth:0,isGlob:false};const eos=()=>k>=v;const peek=()=>A.charCodeAt(k+1);const advance=()=>{H=F;return A.charCodeAt(++k)};while(k<v){F=advance();let e;if(F===o){$=W.backslashes=true;F=advance();if(F===f){M=true}continue}if(M===true||F===f){N++;while(eos()!==true&&(F=advance())){if(F===o){$=W.backslashes=true;advance();continue}if(F===f){N++;continue}if(M!==true&&F===l&&(F=advance())===l){P=W.isBrace=true;T=W.isGlob=true;D=true;if(w===true){continue}break}if(M!==true&&F===a){P=W.isBrace=true;T=W.isGlob=true;D=true;if(w===true){continue}break}if(F===y){N--;if(N===0){M=false;P=W.isBrace=true;D=true;break}}}if(w===true){continue}break}if(F===h){S.push(k);x.push(W);W={value:"",depth:0,isGlob:false};if(D===true)continue;if(H===l&&k===C+1){C+=2;continue}R=k+1;continue}if(r.noext!==true){const e=F===m||F===s||F===n||F===g||F===u;if(e===true&&peek()===p){T=W.isGlob=true;L=W.isExtglob=true;D=true;if(F===u&&k===C){B=true}if(w===true){while(eos()!==true&&(F=advance())){if(F===o){$=W.backslashes=true;F=advance();continue}if(F===b){T=W.isGlob=true;D=true;break}}continue}break}}if(F===n){if(H===n)I=W.isGlobstar=true;T=W.isGlob=true;D=true;if(w===true){continue}break}if(F===g){T=W.isGlob=true;D=true;if(w===true){continue}break}if(F===d){while(eos()!==true&&(e=advance())){if(e===o){$=W.backslashes=true;advance();continue}if(e===_){O=W.isBracket=true;T=W.isGlob=true;D=true;break}}if(w===true){continue}break}if(r.nonegate!==true&&F===u&&k===C){j=W.negated=true;C++;continue}if(r.noparen!==true&&F===p){T=W.isGlob=true;if(w===true){while(eos()!==true&&(F=advance())){if(F===p){$=W.backslashes=true;F=advance();continue}if(F===b){D=true;break}}continue}break}if(T===true){D=true;if(w===true){continue}break}}if(r.noext===true){L=false;T=false}let G=A;let q="";let U="";if(C>0){q=A.slice(0,C);A=A.slice(C);R-=C}if(G&&T===true&&R>0){G=A.slice(0,R);U=A.slice(R)}else if(T===true){G="";U=A}else{G=A}if(G&&G!==""&&G!=="/"&&G!==A){if(isPathSeparator(G.charCodeAt(G.length-1))){G=G.slice(0,-1)}}if(r.unescape===true){if(U)U=i.removeBackslashes(U);if(G&&$===true){G=i.removeBackslashes(G)}}const V={prefix:q,input:e,start:C,base:G,glob:U,isBrace:P,isBracket:O,isGlob:T,isExtglob:L,isGlobstar:I,negated:j,negatedExtglob:B};if(r.tokens===true){V.maxDepth=0;if(!isPathSeparator(F)){x.push(W)}V.tokens=x}if(r.parts===true||r.tokens===true){let t;for(let i=0;i<S.length;i++){const n=t?t+1:C;const s=S[i];const o=e.slice(n,s);if(r.tokens){if(i===0&&C!==0){x[i].isPrefix=true;x[i].value=q}else{x[i].value=o}depth(x[i]);V.maxDepth+=x[i].depth}if(i!==0||o!==""){E.push(o)}t=s}if(t&&t+1<e.length){const i=e.slice(t+1);E.push(i);if(r.tokens){x[x.length-1].value=i;depth(x[x.length-1]);V.maxDepth+=x[x.length-1].depth}}V.slashes=S;V.parts=E}return V};e.exports=scan},4059:(e,t,r)=>{"use strict";const i=r(6928);const n=process.platform==="win32";const{REGEX_BACKSLASH:s,REGEX_REMOVE_BACKSLASH:o,REGEX_SPECIAL_CHARS:a,REGEX_SPECIAL_CHARS_GLOBAL:l}=r(5595);t.isObject=e=>e!==null&&typeof e==="object"&&!Array.isArray(e);t.hasRegexChars=e=>a.test(e);t.isRegexChar=e=>e.length===1&&t.hasRegexChars(e);t.escapeRegex=e=>e.replace(l,"\\$1");t.toPosixSlashes=e=>e.replace(s,"/");t.removeBackslashes=e=>e.replace(o,(e=>e==="\\"?"":e));t.supportsLookbehinds=()=>{const e=process.version.slice(1).split(".").map(Number);if(e.length===3&&e[0]>=9||e[0]===8&&e[1]>=10){return true}return false};t.isWindows=e=>{if(e&&typeof e.windows==="boolean"){return e.windows}return n===true||i.sep==="\\"};t.escapeLast=(e,r,i)=>{const n=e.lastIndexOf(r,i);if(n===-1)return e;if(e[n-1]==="\\")return t.escapeLast(e,r,n-1);return`${e.slice(0,n)}\\${e.slice(n)}`};t.removePrefix=(e,t={})=>{let r=e;if(r.startsWith("./")){r=r.slice(2);t.prefix="./"}return r};t.wrapOutput=(e,t={},r={})=>{const i=r.contains?"":"^";const n=r.contains?"":"$";let s=`${i}(?:${e})${n}`;if(t.negated===true){s=`(?:^(?!${s}).*$)`}return s}},4351:e=>{
|
|
29
29
|
/*! queue-microtask. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
30
|
-
let t;e.exports=typeof queueMicrotask==="function"?queueMicrotask.bind(typeof window!=="undefined"?window:global):e=>(t||(t=Promise.resolve())).then(e).catch((e=>setTimeout((()=>{throw e}),0)))},7214:e=>{"use strict";const t={};function createErrorType(e,r,s){if(!s){s=Error}function getMessage(e,t,s){if(typeof r==="string"){return r}else{return r(e,t,s)}}class NodeError extends s{constructor(e,t,r){super(getMessage(e,t,r))}}NodeError.prototype.name=s.name;NodeError.prototype.code=e;t[e]=NodeError}function oneOf(e,t){if(Array.isArray(e)){const r=e.length;e=e.map((e=>String(e)));if(r>2){return`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]}else if(r===2){return`one of ${t} ${e[0]} or ${e[1]}`}else{return`of ${t} ${e[0]}`}}else{return`of ${t} ${String(e)}`}}function startsWith(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}function endsWith(e,t,r){if(r===undefined||r>e.length){r=e.length}return e.substring(r-t.length,r)===t}function includes(e,t,r){if(typeof r!=="number"){r=0}if(r+t.length>e.length){return false}else{return e.indexOf(t,r)!==-1}}createErrorType("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError);createErrorType("ERR_INVALID_ARG_TYPE",(function(e,t,r){let s;if(typeof t==="string"&&startsWith(t,"not ")){s="must not be";t=t.replace(/^not /,"")}else{s="must be"}let i;if(endsWith(e," argument")){i=`The ${e} ${s} ${oneOf(t,"type")}`}else{const r=includes(e,".")?"property":"argument";i=`The "${e}" ${r} ${s} ${oneOf(t,"type")}`}i+=`. Received type ${typeof r}`;return i}),TypeError);createErrorType("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");createErrorType("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"}));createErrorType("ERR_STREAM_PREMATURE_CLOSE","Premature close");createErrorType("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"}));createErrorType("ERR_MULTIPLE_CALLBACK","Callback called multiple times");createErrorType("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end");createErrorType("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);createErrorType("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError);createErrorType("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");e.exports.q=t},1359:(e,t,r)=>{"use strict";var s=Object.keys||function(e){var t=[];for(var r in e){t.push(r)}return t};e.exports=Duplex;var i=r(1433);var n=r(6993);r(4124)(Duplex,i);{var o=s(n.prototype);for(var a=0;a<o.length;a++){var l=o[a];if(!Duplex.prototype[l])Duplex.prototype[l]=n.prototype[l]}}function Duplex(e){if(!(this instanceof Duplex))return new Duplex(e);i.call(this,e);n.call(this,e);this.allowHalfOpen=true;if(e){if(e.readable===false)this.readable=false;if(e.writable===false)this.writable=false;if(e.allowHalfOpen===false){this.allowHalfOpen=false;this.once("end",onend)}}}Object.defineProperty(Duplex.prototype,"writableHighWaterMark",{enumerable:false,get:function get(){return this._writableState.highWaterMark}});Object.defineProperty(Duplex.prototype,"writableBuffer",{enumerable:false,get:function get(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(Duplex.prototype,"writableLength",{enumerable:false,get:function get(){return this._writableState.length}});function onend(){if(this._writableState.ended)return;process.nextTick(onEndNT,this)}function onEndNT(e){e.end()}Object.defineProperty(Duplex.prototype,"destroyed",{enumerable:false,get:function get(){if(this._readableState===undefined||this._writableState===undefined){return false}return this._readableState.destroyed&&this._writableState.destroyed},set:function set(e){if(this._readableState===undefined||this._writableState===undefined){return}this._readableState.destroyed=e;this._writableState.destroyed=e}})},1542:(e,t,r)=>{"use strict";e.exports=PassThrough;var s=r(4415);r(4124)(PassThrough,s);function PassThrough(e){if(!(this instanceof PassThrough))return new PassThrough(e);s.call(this,e)}PassThrough.prototype._transform=function(e,t,r){r(null,e)}},1433:(e,t,r)=>{"use strict";e.exports=Readable;var s;Readable.ReadableState=ReadableState;var i=r(2361).EventEmitter;var n=function EElistenerCount(e,t){return e.listeners(t).length};var o=r(2387);var a=r(4300).Buffer;var l=global.Uint8Array||function(){};function _uint8ArrayToBuffer(e){return a.from(e)}function _isUint8Array(e){return a.isBuffer(e)||e instanceof l}var u=r(3837);var h;if(u&&u.debuglog){h=u.debuglog("stream")}else{h=function debug(){}}var f=r(6522);var p=r(7049);var d=r(9948),m=d.getHighWaterMark;var g=r(7214).q,y=g.ERR_INVALID_ARG_TYPE,b=g.ERR_STREAM_PUSH_AFTER_EOF,_=g.ERR_METHOD_NOT_IMPLEMENTED,v=g.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;var w;var E;var S;r(4124)(Readable,o);var x=p.errorOrDestroy;var R=["error","close","destroy","pause","resume"];function prependListener(e,t,r){if(typeof e.prependListener==="function")return e.prependListener(t,r);if(!e._events||!e._events[t])e.on(t,r);else if(Array.isArray(e._events[t]))e._events[t].unshift(r);else e._events[t]=[r,e._events[t]]}function ReadableState(e,t,i){s=s||r(1359);e=e||{};if(typeof i!=="boolean")i=t instanceof s;this.objectMode=!!e.objectMode;if(i)this.objectMode=this.objectMode||!!e.readableObjectMode;this.highWaterMark=m(this,e,"readableHighWaterMark",i);this.buffer=new f;this.length=0;this.pipes=null;this.pipesCount=0;this.flowing=null;this.ended=false;this.endEmitted=false;this.reading=false;this.sync=true;this.needReadable=false;this.emittedReadable=false;this.readableListening=false;this.resumeScheduled=false;this.paused=true;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.destroyed=false;this.defaultEncoding=e.defaultEncoding||"utf8";this.awaitDrain=0;this.readingMore=false;this.decoder=null;this.encoding=null;if(e.encoding){if(!w)w=r(4841).s;this.decoder=new w(e.encoding);this.encoding=e.encoding}}function Readable(e){s=s||r(1359);if(!(this instanceof Readable))return new Readable(e);var t=this instanceof s;this._readableState=new ReadableState(e,this,t);this.readable=true;if(e){if(typeof e.read==="function")this._read=e.read;if(typeof e.destroy==="function")this._destroy=e.destroy}o.call(this)}Object.defineProperty(Readable.prototype,"destroyed",{enumerable:false,get:function get(){if(this._readableState===undefined){return false}return this._readableState.destroyed},set:function set(e){if(!this._readableState){return}this._readableState.destroyed=e}});Readable.prototype.destroy=p.destroy;Readable.prototype._undestroy=p.undestroy;Readable.prototype._destroy=function(e,t){t(e)};Readable.prototype.push=function(e,t){var r=this._readableState;var s;if(!r.objectMode){if(typeof e==="string"){t=t||r.defaultEncoding;if(t!==r.encoding){e=a.from(e,t);t=""}s=true}}else{s=true}return readableAddChunk(this,e,t,false,s)};Readable.prototype.unshift=function(e){return readableAddChunk(this,e,null,true,false)};function readableAddChunk(e,t,r,s,i){h("readableAddChunk",t);var n=e._readableState;if(t===null){n.reading=false;onEofChunk(e,n)}else{var o;if(!i)o=chunkInvalid(n,t);if(o){x(e,o)}else if(n.objectMode||t&&t.length>0){if(typeof t!=="string"&&!n.objectMode&&Object.getPrototypeOf(t)!==a.prototype){t=_uint8ArrayToBuffer(t)}if(s){if(n.endEmitted)x(e,new v);else addChunk(e,n,t,true)}else if(n.ended){x(e,new b)}else if(n.destroyed){return false}else{n.reading=false;if(n.decoder&&!r){t=n.decoder.write(t);if(n.objectMode||t.length!==0)addChunk(e,n,t,false);else maybeReadMore(e,n)}else{addChunk(e,n,t,false)}}}else if(!s){n.reading=false;maybeReadMore(e,n)}}return!n.ended&&(n.length<n.highWaterMark||n.length===0)}function addChunk(e,t,r,s){if(t.flowing&&t.length===0&&!t.sync){t.awaitDrain=0;e.emit("data",r)}else{t.length+=t.objectMode?1:r.length;if(s)t.buffer.unshift(r);else t.buffer.push(r);if(t.needReadable)emitReadable(e)}maybeReadMore(e,t)}function chunkInvalid(e,t){var r;if(!_isUint8Array(t)&&typeof t!=="string"&&t!==undefined&&!e.objectMode){r=new y("chunk",["string","Buffer","Uint8Array"],t)}return r}Readable.prototype.isPaused=function(){return this._readableState.flowing===false};Readable.prototype.setEncoding=function(e){if(!w)w=r(4841).s;var t=new w(e);this._readableState.decoder=t;this._readableState.encoding=this._readableState.decoder.encoding;var s=this._readableState.buffer.head;var i="";while(s!==null){i+=t.write(s.data);s=s.next}this._readableState.buffer.clear();if(i!=="")this._readableState.buffer.push(i);this._readableState.length=i.length;return this};var A=1073741824;function computeNewHighWaterMark(e){if(e>=A){e=A}else{e--;e|=e>>>1;e|=e>>>2;e|=e>>>4;e|=e>>>8;e|=e>>>16;e++}return e}function howMuchToRead(e,t){if(e<=0||t.length===0&&t.ended)return 0;if(t.objectMode)return 1;if(e!==e){if(t.flowing&&t.length)return t.buffer.head.data.length;else return t.length}if(e>t.highWaterMark)t.highWaterMark=computeNewHighWaterMark(e);if(e<=t.length)return e;if(!t.ended){t.needReadable=true;return 0}return t.length}Readable.prototype.read=function(e){h("read",e);e=parseInt(e,10);var t=this._readableState;var r=e;if(e!==0)t.emittedReadable=false;if(e===0&&t.needReadable&&((t.highWaterMark!==0?t.length>=t.highWaterMark:t.length>0)||t.ended)){h("read: emitReadable",t.length,t.ended);if(t.length===0&&t.ended)endReadable(this);else emitReadable(this);return null}e=howMuchToRead(e,t);if(e===0&&t.ended){if(t.length===0)endReadable(this);return null}var s=t.needReadable;h("need readable",s);if(t.length===0||t.length-e<t.highWaterMark){s=true;h("length less than watermark",s)}if(t.ended||t.reading){s=false;h("reading or ended",s)}else if(s){h("do read");t.reading=true;t.sync=true;if(t.length===0)t.needReadable=true;this._read(t.highWaterMark);t.sync=false;if(!t.reading)e=howMuchToRead(r,t)}var i;if(e>0)i=fromList(e,t);else i=null;if(i===null){t.needReadable=t.length<=t.highWaterMark;e=0}else{t.length-=e;t.awaitDrain=0}if(t.length===0){if(!t.ended)t.needReadable=true;if(r!==e&&t.ended)endReadable(this)}if(i!==null)this.emit("data",i);return i};function onEofChunk(e,t){h("onEofChunk");if(t.ended)return;if(t.decoder){var r=t.decoder.end();if(r&&r.length){t.buffer.push(r);t.length+=t.objectMode?1:r.length}}t.ended=true;if(t.sync){emitReadable(e)}else{t.needReadable=false;if(!t.emittedReadable){t.emittedReadable=true;emitReadable_(e)}}}function emitReadable(e){var t=e._readableState;h("emitReadable",t.needReadable,t.emittedReadable);t.needReadable=false;if(!t.emittedReadable){h("emitReadable",t.flowing);t.emittedReadable=true;process.nextTick(emitReadable_,e)}}function emitReadable_(e){var t=e._readableState;h("emitReadable_",t.destroyed,t.length,t.ended);if(!t.destroyed&&(t.length||t.ended)){e.emit("readable");t.emittedReadable=false}t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark;flow(e)}function maybeReadMore(e,t){if(!t.readingMore){t.readingMore=true;process.nextTick(maybeReadMore_,e,t)}}function maybeReadMore_(e,t){while(!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&t.length===0)){var r=t.length;h("maybeReadMore read 0");e.read(0);if(r===t.length)break}t.readingMore=false}Readable.prototype._read=function(e){x(this,new _("_read()"))};Readable.prototype.pipe=function(e,t){var r=this;var s=this._readableState;switch(s.pipesCount){case 0:s.pipes=e;break;case 1:s.pipes=[s.pipes,e];break;default:s.pipes.push(e);break}s.pipesCount+=1;h("pipe count=%d opts=%j",s.pipesCount,t);var i=(!t||t.end!==false)&&e!==process.stdout&&e!==process.stderr;var o=i?onend:unpipe;if(s.endEmitted)process.nextTick(o);else r.once("end",o);e.on("unpipe",onunpipe);function onunpipe(e,t){h("onunpipe");if(e===r){if(t&&t.hasUnpiped===false){t.hasUnpiped=true;cleanup()}}}function onend(){h("onend");e.end()}var a=pipeOnDrain(r);e.on("drain",a);var l=false;function cleanup(){h("cleanup");e.removeListener("close",onclose);e.removeListener("finish",onfinish);e.removeListener("drain",a);e.removeListener("error",onerror);e.removeListener("unpipe",onunpipe);r.removeListener("end",onend);r.removeListener("end",unpipe);r.removeListener("data",ondata);l=true;if(s.awaitDrain&&(!e._writableState||e._writableState.needDrain))a()}r.on("data",ondata);function ondata(t){h("ondata");var i=e.write(t);h("dest.write",i);if(i===false){if((s.pipesCount===1&&s.pipes===e||s.pipesCount>1&&indexOf(s.pipes,e)!==-1)&&!l){h("false write response, pause",s.awaitDrain);s.awaitDrain++}r.pause()}}function onerror(t){h("onerror",t);unpipe();e.removeListener("error",onerror);if(n(e,"error")===0)x(e,t)}prependListener(e,"error",onerror);function onclose(){e.removeListener("finish",onfinish);unpipe()}e.once("close",onclose);function onfinish(){h("onfinish");e.removeListener("close",onclose);unpipe()}e.once("finish",onfinish);function unpipe(){h("unpipe");r.unpipe(e)}e.emit("pipe",r);if(!s.flowing){h("pipe resume");r.resume()}return e};function pipeOnDrain(e){return function pipeOnDrainFunctionResult(){var t=e._readableState;h("pipeOnDrain",t.awaitDrain);if(t.awaitDrain)t.awaitDrain--;if(t.awaitDrain===0&&n(e,"data")){t.flowing=true;flow(e)}}}Readable.prototype.unpipe=function(e){var t=this._readableState;var r={hasUnpiped:false};if(t.pipesCount===0)return this;if(t.pipesCount===1){if(e&&e!==t.pipes)return this;if(!e)e=t.pipes;t.pipes=null;t.pipesCount=0;t.flowing=false;if(e)e.emit("unpipe",this,r);return this}if(!e){var s=t.pipes;var i=t.pipesCount;t.pipes=null;t.pipesCount=0;t.flowing=false;for(var n=0;n<i;n++){s[n].emit("unpipe",this,{hasUnpiped:false})}return this}var o=indexOf(t.pipes,e);if(o===-1)return this;t.pipes.splice(o,1);t.pipesCount-=1;if(t.pipesCount===1)t.pipes=t.pipes[0];e.emit("unpipe",this,r);return this};Readable.prototype.on=function(e,t){var r=o.prototype.on.call(this,e,t);var s=this._readableState;if(e==="data"){s.readableListening=this.listenerCount("readable")>0;if(s.flowing!==false)this.resume()}else if(e==="readable"){if(!s.endEmitted&&!s.readableListening){s.readableListening=s.needReadable=true;s.flowing=false;s.emittedReadable=false;h("on readable",s.length,s.reading);if(s.length){emitReadable(this)}else if(!s.reading){process.nextTick(nReadingNextTick,this)}}}return r};Readable.prototype.addListener=Readable.prototype.on;Readable.prototype.removeListener=function(e,t){var r=o.prototype.removeListener.call(this,e,t);if(e==="readable"){process.nextTick(updateReadableListening,this)}return r};Readable.prototype.removeAllListeners=function(e){var t=o.prototype.removeAllListeners.apply(this,arguments);if(e==="readable"||e===undefined){process.nextTick(updateReadableListening,this)}return t};function updateReadableListening(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0;if(t.resumeScheduled&&!t.paused){t.flowing=true}else if(e.listenerCount("data")>0){e.resume()}}function nReadingNextTick(e){h("readable nexttick read 0");e.read(0)}Readable.prototype.resume=function(){var e=this._readableState;if(!e.flowing){h("resume");e.flowing=!e.readableListening;resume(this,e)}e.paused=false;return this};function resume(e,t){if(!t.resumeScheduled){t.resumeScheduled=true;process.nextTick(resume_,e,t)}}function resume_(e,t){h("resume",t.reading);if(!t.reading){e.read(0)}t.resumeScheduled=false;e.emit("resume");flow(e);if(t.flowing&&!t.reading)e.read(0)}Readable.prototype.pause=function(){h("call pause flowing=%j",this._readableState.flowing);if(this._readableState.flowing!==false){h("pause");this._readableState.flowing=false;this.emit("pause")}this._readableState.paused=true;return this};function flow(e){var t=e._readableState;h("flow",t.flowing);while(t.flowing&&e.read()!==null){}}Readable.prototype.wrap=function(e){var t=this;var r=this._readableState;var s=false;e.on("end",(function(){h("wrapped end");if(r.decoder&&!r.ended){var e=r.decoder.end();if(e&&e.length)t.push(e)}t.push(null)}));e.on("data",(function(i){h("wrapped data");if(r.decoder)i=r.decoder.write(i);if(r.objectMode&&(i===null||i===undefined))return;else if(!r.objectMode&&(!i||!i.length))return;var n=t.push(i);if(!n){s=true;e.pause()}}));for(var i in e){if(this[i]===undefined&&typeof e[i]==="function"){this[i]=function methodWrap(t){return function methodWrapReturnFunction(){return e[t].apply(e,arguments)}}(i)}}for(var n=0;n<R.length;n++){e.on(R[n],this.emit.bind(this,R[n]))}this._read=function(t){h("wrapped _read",t);if(s){s=false;e.resume()}};return this};if(typeof Symbol==="function"){Readable.prototype[Symbol.asyncIterator]=function(){if(E===undefined){E=r(3306)}return E(this)}}Object.defineProperty(Readable.prototype,"readableHighWaterMark",{enumerable:false,get:function get(){return this._readableState.highWaterMark}});Object.defineProperty(Readable.prototype,"readableBuffer",{enumerable:false,get:function get(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(Readable.prototype,"readableFlowing",{enumerable:false,get:function get(){return this._readableState.flowing},set:function set(e){if(this._readableState){this._readableState.flowing=e}}});Readable._fromList=fromList;Object.defineProperty(Readable.prototype,"readableLength",{enumerable:false,get:function get(){return this._readableState.length}});function fromList(e,t){if(t.length===0)return null;var r;if(t.objectMode)r=t.buffer.shift();else if(!e||e>=t.length){if(t.decoder)r=t.buffer.join("");else if(t.buffer.length===1)r=t.buffer.first();else r=t.buffer.concat(t.length);t.buffer.clear()}else{r=t.buffer.consume(e,t.decoder)}return r}function endReadable(e){var t=e._readableState;h("endReadable",t.endEmitted);if(!t.endEmitted){t.ended=true;process.nextTick(endReadableNT,t,e)}}function endReadableNT(e,t){h("endReadableNT",e.endEmitted,e.length);if(!e.endEmitted&&e.length===0){e.endEmitted=true;t.readable=false;t.emit("end");if(e.autoDestroy){var r=t._writableState;if(!r||r.autoDestroy&&r.finished){t.destroy()}}}}if(typeof Symbol==="function"){Readable.from=function(e,t){if(S===undefined){S=r(5621)}return S(Readable,e,t)}}function indexOf(e,t){for(var r=0,s=e.length;r<s;r++){if(e[r]===t)return r}return-1}},4415:(e,t,r)=>{"use strict";e.exports=Transform;var s=r(7214).q,i=s.ERR_METHOD_NOT_IMPLEMENTED,n=s.ERR_MULTIPLE_CALLBACK,o=s.ERR_TRANSFORM_ALREADY_TRANSFORMING,a=s.ERR_TRANSFORM_WITH_LENGTH_0;var l=r(1359);r(4124)(Transform,l);function afterTransform(e,t){var r=this._transformState;r.transforming=false;var s=r.writecb;if(s===null){return this.emit("error",new n)}r.writechunk=null;r.writecb=null;if(t!=null)this.push(t);s(e);var i=this._readableState;i.reading=false;if(i.needReadable||i.length<i.highWaterMark){this._read(i.highWaterMark)}}function Transform(e){if(!(this instanceof Transform))return new Transform(e);l.call(this,e);this._transformState={afterTransform:afterTransform.bind(this),needTransform:false,transforming:false,writecb:null,writechunk:null,writeencoding:null};this._readableState.needReadable=true;this._readableState.sync=false;if(e){if(typeof e.transform==="function")this._transform=e.transform;if(typeof e.flush==="function")this._flush=e.flush}this.on("prefinish",prefinish)}function prefinish(){var e=this;if(typeof this._flush==="function"&&!this._readableState.destroyed){this._flush((function(t,r){done(e,t,r)}))}else{done(this,null,null)}}Transform.prototype.push=function(e,t){this._transformState.needTransform=false;return l.prototype.push.call(this,e,t)};Transform.prototype._transform=function(e,t,r){r(new i("_transform()"))};Transform.prototype._write=function(e,t,r){var s=this._transformState;s.writecb=r;s.writechunk=e;s.writeencoding=t;if(!s.transforming){var i=this._readableState;if(s.needTransform||i.needReadable||i.length<i.highWaterMark)this._read(i.highWaterMark)}};Transform.prototype._read=function(e){var t=this._transformState;if(t.writechunk!==null&&!t.transforming){t.transforming=true;this._transform(t.writechunk,t.writeencoding,t.afterTransform)}else{t.needTransform=true}};Transform.prototype._destroy=function(e,t){l.prototype._destroy.call(this,e,(function(e){t(e)}))};function done(e,t,r){if(t)return e.emit("error",t);if(r!=null)e.push(r);if(e._writableState.length)throw new a;if(e._transformState.transforming)throw new o;return e.push(null)}},6993:(e,t,r)=>{"use strict";e.exports=Writable;function WriteReq(e,t,r){this.chunk=e;this.encoding=t;this.callback=r;this.next=null}function CorkedRequest(e){var t=this;this.next=null;this.entry=null;this.finish=function(){onCorkedFinish(t,e)}}var s;Writable.WritableState=WritableState;var i={deprecate:r(5278)};var n=r(2387);var o=r(4300).Buffer;var a=global.Uint8Array||function(){};function _uint8ArrayToBuffer(e){return o.from(e)}function _isUint8Array(e){return o.isBuffer(e)||e instanceof a}var l=r(7049);var u=r(9948),h=u.getHighWaterMark;var f=r(7214).q,p=f.ERR_INVALID_ARG_TYPE,d=f.ERR_METHOD_NOT_IMPLEMENTED,m=f.ERR_MULTIPLE_CALLBACK,g=f.ERR_STREAM_CANNOT_PIPE,y=f.ERR_STREAM_DESTROYED,b=f.ERR_STREAM_NULL_VALUES,_=f.ERR_STREAM_WRITE_AFTER_END,v=f.ERR_UNKNOWN_ENCODING;var w=l.errorOrDestroy;r(4124)(Writable,n);function nop(){}function WritableState(e,t,i){s=s||r(1359);e=e||{};if(typeof i!=="boolean")i=t instanceof s;this.objectMode=!!e.objectMode;if(i)this.objectMode=this.objectMode||!!e.writableObjectMode;this.highWaterMark=h(this,e,"writableHighWaterMark",i);this.finalCalled=false;this.needDrain=false;this.ending=false;this.ended=false;this.finished=false;this.destroyed=false;var n=e.decodeStrings===false;this.decodeStrings=!n;this.defaultEncoding=e.defaultEncoding||"utf8";this.length=0;this.writing=false;this.corked=0;this.sync=true;this.bufferProcessing=false;this.onwrite=function(e){onwrite(t,e)};this.writecb=null;this.writelen=0;this.bufferedRequest=null;this.lastBufferedRequest=null;this.pendingcb=0;this.prefinished=false;this.errorEmitted=false;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.bufferedRequestCount=0;this.corkedRequestsFree=new CorkedRequest(this)}WritableState.prototype.getBuffer=function getBuffer(){var e=this.bufferedRequest;var t=[];while(e){t.push(e);e=e.next}return t};(function(){try{Object.defineProperty(WritableState.prototype,"buffer",{get:i.deprecate((function writableStateBufferGetter(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer "+"instead.","DEP0003")})}catch(e){}})();var E;if(typeof Symbol==="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]==="function"){E=Function.prototype[Symbol.hasInstance];Object.defineProperty(Writable,Symbol.hasInstance,{value:function value(e){if(E.call(this,e))return true;if(this!==Writable)return false;return e&&e._writableState instanceof WritableState}})}else{E=function realHasInstance(e){return e instanceof this}}function Writable(e){s=s||r(1359);var t=this instanceof s;if(!t&&!E.call(Writable,this))return new Writable(e);this._writableState=new WritableState(e,this,t);this.writable=true;if(e){if(typeof e.write==="function")this._write=e.write;if(typeof e.writev==="function")this._writev=e.writev;if(typeof e.destroy==="function")this._destroy=e.destroy;if(typeof e.final==="function")this._final=e.final}n.call(this)}Writable.prototype.pipe=function(){w(this,new g)};function writeAfterEnd(e,t){var r=new _;w(e,r);process.nextTick(t,r)}function validChunk(e,t,r,s){var i;if(r===null){i=new b}else if(typeof r!=="string"&&!t.objectMode){i=new p("chunk",["string","Buffer"],r)}if(i){w(e,i);process.nextTick(s,i);return false}return true}Writable.prototype.write=function(e,t,r){var s=this._writableState;var i=false;var n=!s.objectMode&&_isUint8Array(e);if(n&&!o.isBuffer(e)){e=_uint8ArrayToBuffer(e)}if(typeof t==="function"){r=t;t=null}if(n)t="buffer";else if(!t)t=s.defaultEncoding;if(typeof r!=="function")r=nop;if(s.ending)writeAfterEnd(this,r);else if(n||validChunk(this,s,e,r)){s.pendingcb++;i=writeOrBuffer(this,s,n,e,t,r)}return i};Writable.prototype.cork=function(){this._writableState.corked++};Writable.prototype.uncork=function(){var e=this._writableState;if(e.corked){e.corked--;if(!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest)clearBuffer(this,e)}};Writable.prototype.setDefaultEncoding=function setDefaultEncoding(e){if(typeof e==="string")e=e.toLowerCase();if(!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new v(e);this._writableState.defaultEncoding=e;return this};Object.defineProperty(Writable.prototype,"writableBuffer",{enumerable:false,get:function get(){return this._writableState&&this._writableState.getBuffer()}});function decodeChunk(e,t,r){if(!e.objectMode&&e.decodeStrings!==false&&typeof t==="string"){t=o.from(t,r)}return t}Object.defineProperty(Writable.prototype,"writableHighWaterMark",{enumerable:false,get:function get(){return this._writableState.highWaterMark}});function writeOrBuffer(e,t,r,s,i,n){if(!r){var o=decodeChunk(t,s,i);if(s!==o){r=true;i="buffer";s=o}}var a=t.objectMode?1:s.length;t.length+=a;var l=t.length<t.highWaterMark;if(!l)t.needDrain=true;if(t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:s,encoding:i,isBuf:r,callback:n,next:null};if(u){u.next=t.lastBufferedRequest}else{t.bufferedRequest=t.lastBufferedRequest}t.bufferedRequestCount+=1}else{doWrite(e,t,false,a,s,i,n)}return l}function doWrite(e,t,r,s,i,n,o){t.writelen=s;t.writecb=o;t.writing=true;t.sync=true;if(t.destroyed)t.onwrite(new y("write"));else if(r)e._writev(i,t.onwrite);else e._write(i,n,t.onwrite);t.sync=false}function onwriteError(e,t,r,s,i){--t.pendingcb;if(r){process.nextTick(i,s);process.nextTick(finishMaybe,e,t);e._writableState.errorEmitted=true;w(e,s)}else{i(s);e._writableState.errorEmitted=true;w(e,s);finishMaybe(e,t)}}function onwriteStateUpdate(e){e.writing=false;e.writecb=null;e.length-=e.writelen;e.writelen=0}function onwrite(e,t){var r=e._writableState;var s=r.sync;var i=r.writecb;if(typeof i!=="function")throw new m;onwriteStateUpdate(r);if(t)onwriteError(e,r,s,t,i);else{var n=needFinish(r)||e.destroyed;if(!n&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest){clearBuffer(e,r)}if(s){process.nextTick(afterWrite,e,r,n,i)}else{afterWrite(e,r,n,i)}}}function afterWrite(e,t,r,s){if(!r)onwriteDrain(e,t);t.pendingcb--;s();finishMaybe(e,t)}function onwriteDrain(e,t){if(t.length===0&&t.needDrain){t.needDrain=false;e.emit("drain")}}function clearBuffer(e,t){t.bufferProcessing=true;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var s=t.bufferedRequestCount;var i=new Array(s);var n=t.corkedRequestsFree;n.entry=r;var o=0;var a=true;while(r){i[o]=r;if(!r.isBuf)a=false;r=r.next;o+=1}i.allBuffers=a;doWrite(e,t,true,t.length,i,"",n.finish);t.pendingcb++;t.lastBufferedRequest=null;if(n.next){t.corkedRequestsFree=n.next;n.next=null}else{t.corkedRequestsFree=new CorkedRequest(t)}t.bufferedRequestCount=0}else{while(r){var l=r.chunk;var u=r.encoding;var h=r.callback;var f=t.objectMode?1:l.length;doWrite(e,t,false,f,l,u,h);r=r.next;t.bufferedRequestCount--;if(t.writing){break}}if(r===null)t.lastBufferedRequest=null}t.bufferedRequest=r;t.bufferProcessing=false}Writable.prototype._write=function(e,t,r){r(new d("_write()"))};Writable.prototype._writev=null;Writable.prototype.end=function(e,t,r){var s=this._writableState;if(typeof e==="function"){r=e;e=null;t=null}else if(typeof t==="function"){r=t;t=null}if(e!==null&&e!==undefined)this.write(e,t);if(s.corked){s.corked=1;this.uncork()}if(!s.ending)endWritable(this,s,r);return this};Object.defineProperty(Writable.prototype,"writableLength",{enumerable:false,get:function get(){return this._writableState.length}});function needFinish(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}function callFinal(e,t){e._final((function(r){t.pendingcb--;if(r){w(e,r)}t.prefinished=true;e.emit("prefinish");finishMaybe(e,t)}))}function prefinish(e,t){if(!t.prefinished&&!t.finalCalled){if(typeof e._final==="function"&&!t.destroyed){t.pendingcb++;t.finalCalled=true;process.nextTick(callFinal,e,t)}else{t.prefinished=true;e.emit("prefinish")}}}function finishMaybe(e,t){var r=needFinish(t);if(r){prefinish(e,t);if(t.pendingcb===0){t.finished=true;e.emit("finish");if(t.autoDestroy){var s=e._readableState;if(!s||s.autoDestroy&&s.endEmitted){e.destroy()}}}}return r}function endWritable(e,t,r){t.ending=true;finishMaybe(e,t);if(r){if(t.finished)process.nextTick(r);else e.once("finish",r)}t.ended=true;e.writable=false}function onCorkedFinish(e,t,r){var s=e.entry;e.entry=null;while(s){var i=s.callback;t.pendingcb--;i(r);s=s.next}t.corkedRequestsFree.next=e}Object.defineProperty(Writable.prototype,"destroyed",{enumerable:false,get:function get(){if(this._writableState===undefined){return false}return this._writableState.destroyed},set:function set(e){if(!this._writableState){return}this._writableState.destroyed=e}});Writable.prototype.destroy=l.destroy;Writable.prototype._undestroy=l.undestroy;Writable.prototype._destroy=function(e,t){t(e)}},3306:(e,t,r)=>{"use strict";var s;function _defineProperty(e,t,r){if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}var i=r(6080);var n=Symbol("lastResolve");var o=Symbol("lastReject");var a=Symbol("error");var l=Symbol("ended");var u=Symbol("lastPromise");var h=Symbol("handlePromise");var f=Symbol("stream");function createIterResult(e,t){return{value:e,done:t}}function readAndResolve(e){var t=e[n];if(t!==null){var r=e[f].read();if(r!==null){e[u]=null;e[n]=null;e[o]=null;t(createIterResult(r,false))}}}function onReadable(e){process.nextTick(readAndResolve,e)}function wrapForNext(e,t){return function(r,s){e.then((function(){if(t[l]){r(createIterResult(undefined,true));return}t[h](r,s)}),s)}}var p=Object.getPrototypeOf((function(){}));var d=Object.setPrototypeOf((s={get stream(){return this[f]},next:function next(){var e=this;var t=this[a];if(t!==null){return Promise.reject(t)}if(this[l]){return Promise.resolve(createIterResult(undefined,true))}if(this[f].destroyed){return new Promise((function(t,r){process.nextTick((function(){if(e[a]){r(e[a])}else{t(createIterResult(undefined,true))}}))}))}var r=this[u];var s;if(r){s=new Promise(wrapForNext(r,this))}else{var i=this[f].read();if(i!==null){return Promise.resolve(createIterResult(i,false))}s=new Promise(this[h])}this[u]=s;return s}},_defineProperty(s,Symbol.asyncIterator,(function(){return this})),_defineProperty(s,"return",(function _return(){var e=this;return new Promise((function(t,r){e[f].destroy(null,(function(e){if(e){r(e);return}t(createIterResult(undefined,true))}))}))})),s),p);var m=function createReadableStreamAsyncIterator(e){var t;var r=Object.create(d,(t={},_defineProperty(t,f,{value:e,writable:true}),_defineProperty(t,n,{value:null,writable:true}),_defineProperty(t,o,{value:null,writable:true}),_defineProperty(t,a,{value:null,writable:true}),_defineProperty(t,l,{value:e._readableState.endEmitted,writable:true}),_defineProperty(t,h,{value:function value(e,t){var s=r[f].read();if(s){r[u]=null;r[n]=null;r[o]=null;e(createIterResult(s,false))}else{r[n]=e;r[o]=t}},writable:true}),t));r[u]=null;i(e,(function(e){if(e&&e.code!=="ERR_STREAM_PREMATURE_CLOSE"){var t=r[o];if(t!==null){r[u]=null;r[n]=null;r[o]=null;t(e)}r[a]=e;return}var s=r[n];if(s!==null){r[u]=null;r[n]=null;r[o]=null;s(createIterResult(undefined,true))}r[l]=true}));e.on("readable",onReadable.bind(null,r));return r};e.exports=m},6522:(e,t,r)=>{"use strict";function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(t)s=s.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}));r.push.apply(r,s)}return r}function _objectSpread(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};if(t%2){ownKeys(Object(r),true).forEach((function(t){_defineProperty(e,t,r[t])}))}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(e,Object.getOwnPropertyDescriptors(r))}else{ownKeys(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}}return e}function _defineProperty(e,t,r){if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}function _classCallCheck(e,t){if(!(e instanceof t)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var s=t[r];s.enumerable=s.enumerable||false;s.configurable=true;if("value"in s)s.writable=true;Object.defineProperty(e,s.key,s)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);return e}var s=r(4300),i=s.Buffer;var n=r(3837),o=n.inspect;var a=o&&o.custom||"inspect";function copyBuffer(e,t,r){i.prototype.copy.call(e,t,r)}e.exports=function(){function BufferList(){_classCallCheck(this,BufferList);this.head=null;this.tail=null;this.length=0}_createClass(BufferList,[{key:"push",value:function push(e){var t={data:e,next:null};if(this.length>0)this.tail.next=t;else this.head=t;this.tail=t;++this.length}},{key:"unshift",value:function unshift(e){var t={data:e,next:this.head};if(this.length===0)this.tail=t;this.head=t;++this.length}},{key:"shift",value:function shift(){if(this.length===0)return;var e=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;--this.length;return e}},{key:"clear",value:function clear(){this.head=this.tail=null;this.length=0}},{key:"join",value:function join(e){if(this.length===0)return"";var t=this.head;var r=""+t.data;while(t=t.next){r+=e+t.data}return r}},{key:"concat",value:function concat(e){if(this.length===0)return i.alloc(0);var t=i.allocUnsafe(e>>>0);var r=this.head;var s=0;while(r){copyBuffer(r.data,t,s);s+=r.data.length;r=r.next}return t}},{key:"consume",value:function consume(e,t){var r;if(e<this.head.data.length){r=this.head.data.slice(0,e);this.head.data=this.head.data.slice(e)}else if(e===this.head.data.length){r=this.shift()}else{r=t?this._getString(e):this._getBuffer(e)}return r}},{key:"first",value:function first(){return this.head.data}},{key:"_getString",value:function _getString(e){var t=this.head;var r=1;var s=t.data;e-=s.length;while(t=t.next){var i=t.data;var n=e>i.length?i.length:e;if(n===i.length)s+=i;else s+=i.slice(0,e);e-=n;if(e===0){if(n===i.length){++r;if(t.next)this.head=t.next;else this.head=this.tail=null}else{this.head=t;t.data=i.slice(n)}break}++r}this.length-=r;return s}},{key:"_getBuffer",value:function _getBuffer(e){var t=i.allocUnsafe(e);var r=this.head;var s=1;r.data.copy(t);e-=r.data.length;while(r=r.next){var n=r.data;var o=e>n.length?n.length:e;n.copy(t,t.length-e,0,o);e-=o;if(e===0){if(o===n.length){++s;if(r.next)this.head=r.next;else this.head=this.tail=null}else{this.head=r;r.data=n.slice(o)}break}++s}this.length-=s;return t}},{key:a,value:function value(e,t){return o(this,_objectSpread({},t,{depth:0,customInspect:false}))}}]);return BufferList}()},7049:e=>{"use strict";function destroy(e,t){var r=this;var s=this._readableState&&this._readableState.destroyed;var i=this._writableState&&this._writableState.destroyed;if(s||i){if(t){t(e)}else if(e){if(!this._writableState){process.nextTick(emitErrorNT,this,e)}else if(!this._writableState.errorEmitted){this._writableState.errorEmitted=true;process.nextTick(emitErrorNT,this,e)}}return this}if(this._readableState){this._readableState.destroyed=true}if(this._writableState){this._writableState.destroyed=true}this._destroy(e||null,(function(e){if(!t&&e){if(!r._writableState){process.nextTick(emitErrorAndCloseNT,r,e)}else if(!r._writableState.errorEmitted){r._writableState.errorEmitted=true;process.nextTick(emitErrorAndCloseNT,r,e)}else{process.nextTick(emitCloseNT,r)}}else if(t){process.nextTick(emitCloseNT,r);t(e)}else{process.nextTick(emitCloseNT,r)}}));return this}function emitErrorAndCloseNT(e,t){emitErrorNT(e,t);emitCloseNT(e)}function emitCloseNT(e){if(e._writableState&&!e._writableState.emitClose)return;if(e._readableState&&!e._readableState.emitClose)return;e.emit("close")}function undestroy(){if(this._readableState){this._readableState.destroyed=false;this._readableState.reading=false;this._readableState.ended=false;this._readableState.endEmitted=false}if(this._writableState){this._writableState.destroyed=false;this._writableState.ended=false;this._writableState.ending=false;this._writableState.finalCalled=false;this._writableState.prefinished=false;this._writableState.finished=false;this._writableState.errorEmitted=false}}function emitErrorNT(e,t){e.emit("error",t)}function errorOrDestroy(e,t){var r=e._readableState;var s=e._writableState;if(r&&r.autoDestroy||s&&s.autoDestroy)e.destroy(t);else e.emit("error",t)}e.exports={destroy:destroy,undestroy:undestroy,errorOrDestroy:errorOrDestroy}},6080:(e,t,r)=>{"use strict";var s=r(7214).q.ERR_STREAM_PREMATURE_CLOSE;function once(e){var t=false;return function(){if(t)return;t=true;for(var r=arguments.length,s=new Array(r),i=0;i<r;i++){s[i]=arguments[i]}e.apply(this,s)}}function noop(){}function isRequest(e){return e.setHeader&&typeof e.abort==="function"}function eos(e,t,r){if(typeof t==="function")return eos(e,null,t);if(!t)t={};r=once(r||noop);var i=t.readable||t.readable!==false&&e.readable;var n=t.writable||t.writable!==false&&e.writable;var o=function onlegacyfinish(){if(!e.writable)l()};var a=e._writableState&&e._writableState.finished;var l=function onfinish(){n=false;a=true;if(!i)r.call(e)};var u=e._readableState&&e._readableState.endEmitted;var h=function onend(){i=false;u=true;if(!n)r.call(e)};var f=function onerror(t){r.call(e,t)};var p=function onclose(){var t;if(i&&!u){if(!e._readableState||!e._readableState.ended)t=new s;return r.call(e,t)}if(n&&!a){if(!e._writableState||!e._writableState.ended)t=new s;return r.call(e,t)}};var d=function onrequest(){e.req.on("finish",l)};if(isRequest(e)){e.on("complete",l);e.on("abort",p);if(e.req)d();else e.on("request",d)}else if(n&&!e._writableState){e.on("end",o);e.on("close",o)}e.on("end",h);e.on("finish",l);if(t.error!==false)e.on("error",f);e.on("close",p);return function(){e.removeListener("complete",l);e.removeListener("abort",p);e.removeListener("request",d);if(e.req)e.req.removeListener("finish",l);e.removeListener("end",o);e.removeListener("close",o);e.removeListener("finish",l);e.removeListener("end",h);e.removeListener("error",f);e.removeListener("close",p)}}e.exports=eos},5621:(e,t,r)=>{"use strict";function asyncGeneratorStep(e,t,r,s,i,n,o){try{var a=e[n](o);var l=a.value}catch(e){r(e);return}if(a.done){t(l)}else{Promise.resolve(l).then(s,i)}}function _asyncToGenerator(e){return function(){var t=this,r=arguments;return new Promise((function(s,i){var n=e.apply(t,r);function _next(e){asyncGeneratorStep(n,s,i,_next,_throw,"next",e)}function _throw(e){asyncGeneratorStep(n,s,i,_next,_throw,"throw",e)}_next(undefined)}))}}function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(t)s=s.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}));r.push.apply(r,s)}return r}function _objectSpread(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};if(t%2){ownKeys(Object(r),true).forEach((function(t){_defineProperty(e,t,r[t])}))}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(e,Object.getOwnPropertyDescriptors(r))}else{ownKeys(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}}return e}function _defineProperty(e,t,r){if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}var s=r(7214).q.ERR_INVALID_ARG_TYPE;function from(e,t,r){var i;if(t&&typeof t.next==="function"){i=t}else if(t&&t[Symbol.asyncIterator])i=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])i=t[Symbol.iterator]();else throw new s("iterable",["Iterable"],t);var n=new e(_objectSpread({objectMode:true},r));var o=false;n._read=function(){if(!o){o=true;next()}};function next(){return _next2.apply(this,arguments)}function _next2(){_next2=_asyncToGenerator((function*(){try{var e=yield i.next(),t=e.value,r=e.done;if(r){n.push(null)}else if(n.push(yield t)){next()}else{o=false}}catch(e){n.destroy(e)}}));return _next2.apply(this,arguments)}return n}e.exports=from},6989:(e,t,r)=>{"use strict";var s;function once(e){var t=false;return function(){if(t)return;t=true;e.apply(void 0,arguments)}}var i=r(7214).q,n=i.ERR_MISSING_ARGS,o=i.ERR_STREAM_DESTROYED;function noop(e){if(e)throw e}function isRequest(e){return e.setHeader&&typeof e.abort==="function"}function destroyer(e,t,i,n){n=once(n);var a=false;e.on("close",(function(){a=true}));if(s===undefined)s=r(6080);s(e,{readable:t,writable:i},(function(e){if(e)return n(e);a=true;n()}));var l=false;return function(t){if(a)return;if(l)return;l=true;if(isRequest(e))return e.abort();if(typeof e.destroy==="function")return e.destroy();n(t||new o("pipe"))}}function call(e){e()}function pipe(e,t){return e.pipe(t)}function popCallback(e){if(!e.length)return noop;if(typeof e[e.length-1]!=="function")return noop;return e.pop()}function pipeline(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++){t[r]=arguments[r]}var s=popCallback(t);if(Array.isArray(t[0]))t=t[0];if(t.length<2){throw new n("streams")}var i;var o=t.map((function(e,r){var n=r<t.length-1;var a=r>0;return destroyer(e,n,a,(function(e){if(!i)i=e;if(e)o.forEach(call);if(n)return;o.forEach(call);s(i)}))}));return t.reduce(pipe)}e.exports=pipeline},9948:(e,t,r)=>{"use strict";var s=r(7214).q.ERR_INVALID_OPT_VALUE;function highWaterMarkFrom(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function getHighWaterMark(e,t,r,i){var n=highWaterMarkFrom(t,i,r);if(n!=null){if(!(isFinite(n)&&Math.floor(n)===n)||n<0){var o=i?r:"highWaterMark";throw new s(o,n)}return Math.floor(n)}return e.objectMode?16:16*1024}e.exports={getHighWaterMark:getHighWaterMark}},2387:(e,t,r)=>{e.exports=r(2781)},1642:(e,t,r)=>{var s=r(2781);if(process.env.READABLE_STREAM==="disable"&&s){e.exports=s.Readable;Object.assign(e.exports,s);e.exports.Stream=s}else{t=e.exports=r(1433);t.Stream=s||t;t.Readable=t;t.Writable=r(6993);t.Duplex=r(1359);t.Transform=r(4415);t.PassThrough=r(1542);t.finished=r(6080);t.pipeline=r(6989)}},5847:(e,t,r)=>{"use strict";const s=r(9082);const i=r(4931);e.exports=s((()=>{i((()=>{process.stderr.write("[?25h")}),{alwaysLast:true})}))},2113:e=>{"use strict";function reusify(e){var t=new e;var r=t;function get(){var s=t;if(s.next){t=s.next}else{t=new e;r=t}s.next=null;return s}function release(e){r.next=e;r=e}return{get:get,release:release}}e.exports=reusify},5288:(e,t,r)=>{
|
|
30
|
+
let t;e.exports=typeof queueMicrotask==="function"?queueMicrotask.bind(typeof window!=="undefined"?window:global):e=>(t||(t=Promise.resolve())).then(e).catch((e=>setTimeout((()=>{throw e}),0)))},5500:e=>{"use strict";const t={};function createErrorType(e,r,i){if(!i){i=Error}function getMessage(e,t,i){if(typeof r==="string"){return r}else{return r(e,t,i)}}class NodeError extends i{constructor(e,t,r){super(getMessage(e,t,r))}}NodeError.prototype.name=i.name;NodeError.prototype.code=e;t[e]=NodeError}function oneOf(e,t){if(Array.isArray(e)){const r=e.length;e=e.map((e=>String(e)));if(r>2){return`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]}else if(r===2){return`one of ${t} ${e[0]} or ${e[1]}`}else{return`of ${t} ${e[0]}`}}else{return`of ${t} ${String(e)}`}}function startsWith(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}function endsWith(e,t,r){if(r===undefined||r>e.length){r=e.length}return e.substring(r-t.length,r)===t}function includes(e,t,r){if(typeof r!=="number"){r=0}if(r+t.length>e.length){return false}else{return e.indexOf(t,r)!==-1}}createErrorType("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError);createErrorType("ERR_INVALID_ARG_TYPE",(function(e,t,r){let i;if(typeof t==="string"&&startsWith(t,"not ")){i="must not be";t=t.replace(/^not /,"")}else{i="must be"}let n;if(endsWith(e," argument")){n=`The ${e} ${i} ${oneOf(t,"type")}`}else{const r=includes(e,".")?"property":"argument";n=`The "${e}" ${r} ${i} ${oneOf(t,"type")}`}n+=`. Received type ${typeof r}`;return n}),TypeError);createErrorType("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");createErrorType("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"}));createErrorType("ERR_STREAM_PREMATURE_CLOSE","Premature close");createErrorType("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"}));createErrorType("ERR_MULTIPLE_CALLBACK","Callback called multiple times");createErrorType("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end");createErrorType("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);createErrorType("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError);createErrorType("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");e.exports.F=t},2063:(e,t,r)=>{"use strict";var i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=Duplex;var n=r(6893);var s=r(8797);r(9598)(Duplex,n);{var o=i(s.prototype);for(var a=0;a<o.length;a++){var l=o[a];if(!Duplex.prototype[l])Duplex.prototype[l]=s.prototype[l]}}function Duplex(e){if(!(this instanceof Duplex))return new Duplex(e);n.call(this,e);s.call(this,e);this.allowHalfOpen=true;if(e){if(e.readable===false)this.readable=false;if(e.writable===false)this.writable=false;if(e.allowHalfOpen===false){this.allowHalfOpen=false;this.once("end",onend)}}}Object.defineProperty(Duplex.prototype,"writableHighWaterMark",{enumerable:false,get:function get(){return this._writableState.highWaterMark}});Object.defineProperty(Duplex.prototype,"writableBuffer",{enumerable:false,get:function get(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(Duplex.prototype,"writableLength",{enumerable:false,get:function get(){return this._writableState.length}});function onend(){if(this._writableState.ended)return;process.nextTick(onEndNT,this)}function onEndNT(e){e.end()}Object.defineProperty(Duplex.prototype,"destroyed",{enumerable:false,get:function get(){if(this._readableState===undefined||this._writableState===undefined){return false}return this._readableState.destroyed&&this._writableState.destroyed},set:function set(e){if(this._readableState===undefined||this._writableState===undefined){return}this._readableState.destroyed=e;this._writableState.destroyed=e}})},5283:(e,t,r)=>{"use strict";e.exports=PassThrough;var i=r(2337);r(9598)(PassThrough,i);function PassThrough(e){if(!(this instanceof PassThrough))return new PassThrough(e);i.call(this,e)}PassThrough.prototype._transform=function(e,t,r){r(null,e)}},6893:(e,t,r)=>{"use strict";e.exports=Readable;var i;Readable.ReadableState=ReadableState;var n=r(4434).EventEmitter;var s=function EElistenerCount(e,t){return e.listeners(t).length};var o=r(3283);var a=r(181).Buffer;var l=(typeof global!=="undefined"?global:typeof window!=="undefined"?window:typeof self!=="undefined"?self:{}).Uint8Array||function(){};function _uint8ArrayToBuffer(e){return a.from(e)}function _isUint8Array(e){return a.isBuffer(e)||e instanceof l}var u=r(9023);var h;if(u&&u.debuglog){h=u.debuglog("stream")}else{h=function debug(){}}var f=r(7336);var p=r(5089);var d=r(4874),m=d.getHighWaterMark;var g=r(5500).F,y=g.ERR_INVALID_ARG_TYPE,b=g.ERR_STREAM_PUSH_AFTER_EOF,_=g.ERR_METHOD_NOT_IMPLEMENTED,v=g.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;var w;var S;var x;r(9598)(Readable,o);var E=p.errorOrDestroy;var A=["error","close","destroy","pause","resume"];function prependListener(e,t,r){if(typeof e.prependListener==="function")return e.prependListener(t,r);if(!e._events||!e._events[t])e.on(t,r);else if(Array.isArray(e._events[t]))e._events[t].unshift(r);else e._events[t]=[r,e._events[t]]}function ReadableState(e,t,n){i=i||r(2063);e=e||{};if(typeof n!=="boolean")n=t instanceof i;this.objectMode=!!e.objectMode;if(n)this.objectMode=this.objectMode||!!e.readableObjectMode;this.highWaterMark=m(this,e,"readableHighWaterMark",n);this.buffer=new f;this.length=0;this.pipes=null;this.pipesCount=0;this.flowing=null;this.ended=false;this.endEmitted=false;this.reading=false;this.sync=true;this.needReadable=false;this.emittedReadable=false;this.readableListening=false;this.resumeScheduled=false;this.paused=true;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.destroyed=false;this.defaultEncoding=e.defaultEncoding||"utf8";this.awaitDrain=0;this.readingMore=false;this.decoder=null;this.encoding=null;if(e.encoding){if(!w)w=r(634).I;this.decoder=new w(e.encoding);this.encoding=e.encoding}}function Readable(e){i=i||r(2063);if(!(this instanceof Readable))return new Readable(e);var t=this instanceof i;this._readableState=new ReadableState(e,this,t);this.readable=true;if(e){if(typeof e.read==="function")this._read=e.read;if(typeof e.destroy==="function")this._destroy=e.destroy}o.call(this)}Object.defineProperty(Readable.prototype,"destroyed",{enumerable:false,get:function get(){if(this._readableState===undefined){return false}return this._readableState.destroyed},set:function set(e){if(!this._readableState){return}this._readableState.destroyed=e}});Readable.prototype.destroy=p.destroy;Readable.prototype._undestroy=p.undestroy;Readable.prototype._destroy=function(e,t){t(e)};Readable.prototype.push=function(e,t){var r=this._readableState;var i;if(!r.objectMode){if(typeof e==="string"){t=t||r.defaultEncoding;if(t!==r.encoding){e=a.from(e,t);t=""}i=true}}else{i=true}return readableAddChunk(this,e,t,false,i)};Readable.prototype.unshift=function(e){return readableAddChunk(this,e,null,true,false)};function readableAddChunk(e,t,r,i,n){h("readableAddChunk",t);var s=e._readableState;if(t===null){s.reading=false;onEofChunk(e,s)}else{var o;if(!n)o=chunkInvalid(s,t);if(o){E(e,o)}else if(s.objectMode||t&&t.length>0){if(typeof t!=="string"&&!s.objectMode&&Object.getPrototypeOf(t)!==a.prototype){t=_uint8ArrayToBuffer(t)}if(i){if(s.endEmitted)E(e,new v);else addChunk(e,s,t,true)}else if(s.ended){E(e,new b)}else if(s.destroyed){return false}else{s.reading=false;if(s.decoder&&!r){t=s.decoder.write(t);if(s.objectMode||t.length!==0)addChunk(e,s,t,false);else maybeReadMore(e,s)}else{addChunk(e,s,t,false)}}}else if(!i){s.reading=false;maybeReadMore(e,s)}}return!s.ended&&(s.length<s.highWaterMark||s.length===0)}function addChunk(e,t,r,i){if(t.flowing&&t.length===0&&!t.sync){t.awaitDrain=0;e.emit("data",r)}else{t.length+=t.objectMode?1:r.length;if(i)t.buffer.unshift(r);else t.buffer.push(r);if(t.needReadable)emitReadable(e)}maybeReadMore(e,t)}function chunkInvalid(e,t){var r;if(!_isUint8Array(t)&&typeof t!=="string"&&t!==undefined&&!e.objectMode){r=new y("chunk",["string","Buffer","Uint8Array"],t)}return r}Readable.prototype.isPaused=function(){return this._readableState.flowing===false};Readable.prototype.setEncoding=function(e){if(!w)w=r(634).I;var t=new w(e);this._readableState.decoder=t;this._readableState.encoding=this._readableState.decoder.encoding;var i=this._readableState.buffer.head;var n="";while(i!==null){n+=t.write(i.data);i=i.next}this._readableState.buffer.clear();if(n!=="")this._readableState.buffer.push(n);this._readableState.length=n.length;return this};var k=1073741824;function computeNewHighWaterMark(e){if(e>=k){e=k}else{e--;e|=e>>>1;e|=e>>>2;e|=e>>>4;e|=e>>>8;e|=e>>>16;e++}return e}function howMuchToRead(e,t){if(e<=0||t.length===0&&t.ended)return 0;if(t.objectMode)return 1;if(e!==e){if(t.flowing&&t.length)return t.buffer.head.data.length;else return t.length}if(e>t.highWaterMark)t.highWaterMark=computeNewHighWaterMark(e);if(e<=t.length)return e;if(!t.ended){t.needReadable=true;return 0}return t.length}Readable.prototype.read=function(e){h("read",e);e=parseInt(e,10);var t=this._readableState;var r=e;if(e!==0)t.emittedReadable=false;if(e===0&&t.needReadable&&((t.highWaterMark!==0?t.length>=t.highWaterMark:t.length>0)||t.ended)){h("read: emitReadable",t.length,t.ended);if(t.length===0&&t.ended)endReadable(this);else emitReadable(this);return null}e=howMuchToRead(e,t);if(e===0&&t.ended){if(t.length===0)endReadable(this);return null}var i=t.needReadable;h("need readable",i);if(t.length===0||t.length-e<t.highWaterMark){i=true;h("length less than watermark",i)}if(t.ended||t.reading){i=false;h("reading or ended",i)}else if(i){h("do read");t.reading=true;t.sync=true;if(t.length===0)t.needReadable=true;this._read(t.highWaterMark);t.sync=false;if(!t.reading)e=howMuchToRead(r,t)}var n;if(e>0)n=fromList(e,t);else n=null;if(n===null){t.needReadable=t.length<=t.highWaterMark;e=0}else{t.length-=e;t.awaitDrain=0}if(t.length===0){if(!t.ended)t.needReadable=true;if(r!==e&&t.ended)endReadable(this)}if(n!==null)this.emit("data",n);return n};function onEofChunk(e,t){h("onEofChunk");if(t.ended)return;if(t.decoder){var r=t.decoder.end();if(r&&r.length){t.buffer.push(r);t.length+=t.objectMode?1:r.length}}t.ended=true;if(t.sync){emitReadable(e)}else{t.needReadable=false;if(!t.emittedReadable){t.emittedReadable=true;emitReadable_(e)}}}function emitReadable(e){var t=e._readableState;h("emitReadable",t.needReadable,t.emittedReadable);t.needReadable=false;if(!t.emittedReadable){h("emitReadable",t.flowing);t.emittedReadable=true;process.nextTick(emitReadable_,e)}}function emitReadable_(e){var t=e._readableState;h("emitReadable_",t.destroyed,t.length,t.ended);if(!t.destroyed&&(t.length||t.ended)){e.emit("readable");t.emittedReadable=false}t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark;flow(e)}function maybeReadMore(e,t){if(!t.readingMore){t.readingMore=true;process.nextTick(maybeReadMore_,e,t)}}function maybeReadMore_(e,t){while(!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&t.length===0)){var r=t.length;h("maybeReadMore read 0");e.read(0);if(r===t.length)break}t.readingMore=false}Readable.prototype._read=function(e){E(this,new _("_read()"))};Readable.prototype.pipe=function(e,t){var r=this;var i=this._readableState;switch(i.pipesCount){case 0:i.pipes=e;break;case 1:i.pipes=[i.pipes,e];break;default:i.pipes.push(e);break}i.pipesCount+=1;h("pipe count=%d opts=%j",i.pipesCount,t);var n=(!t||t.end!==false)&&e!==process.stdout&&e!==process.stderr;var o=n?onend:unpipe;if(i.endEmitted)process.nextTick(o);else r.once("end",o);e.on("unpipe",onunpipe);function onunpipe(e,t){h("onunpipe");if(e===r){if(t&&t.hasUnpiped===false){t.hasUnpiped=true;cleanup()}}}function onend(){h("onend");e.end()}var a=pipeOnDrain(r);e.on("drain",a);var l=false;function cleanup(){h("cleanup");e.removeListener("close",onclose);e.removeListener("finish",onfinish);e.removeListener("drain",a);e.removeListener("error",onerror);e.removeListener("unpipe",onunpipe);r.removeListener("end",onend);r.removeListener("end",unpipe);r.removeListener("data",ondata);l=true;if(i.awaitDrain&&(!e._writableState||e._writableState.needDrain))a()}r.on("data",ondata);function ondata(t){h("ondata");var n=e.write(t);h("dest.write",n);if(n===false){if((i.pipesCount===1&&i.pipes===e||i.pipesCount>1&&indexOf(i.pipes,e)!==-1)&&!l){h("false write response, pause",i.awaitDrain);i.awaitDrain++}r.pause()}}function onerror(t){h("onerror",t);unpipe();e.removeListener("error",onerror);if(s(e,"error")===0)E(e,t)}prependListener(e,"error",onerror);function onclose(){e.removeListener("finish",onfinish);unpipe()}e.once("close",onclose);function onfinish(){h("onfinish");e.removeListener("close",onclose);unpipe()}e.once("finish",onfinish);function unpipe(){h("unpipe");r.unpipe(e)}e.emit("pipe",r);if(!i.flowing){h("pipe resume");r.resume()}return e};function pipeOnDrain(e){return function pipeOnDrainFunctionResult(){var t=e._readableState;h("pipeOnDrain",t.awaitDrain);if(t.awaitDrain)t.awaitDrain--;if(t.awaitDrain===0&&s(e,"data")){t.flowing=true;flow(e)}}}Readable.prototype.unpipe=function(e){var t=this._readableState;var r={hasUnpiped:false};if(t.pipesCount===0)return this;if(t.pipesCount===1){if(e&&e!==t.pipes)return this;if(!e)e=t.pipes;t.pipes=null;t.pipesCount=0;t.flowing=false;if(e)e.emit("unpipe",this,r);return this}if(!e){var i=t.pipes;var n=t.pipesCount;t.pipes=null;t.pipesCount=0;t.flowing=false;for(var s=0;s<n;s++)i[s].emit("unpipe",this,{hasUnpiped:false});return this}var o=indexOf(t.pipes,e);if(o===-1)return this;t.pipes.splice(o,1);t.pipesCount-=1;if(t.pipesCount===1)t.pipes=t.pipes[0];e.emit("unpipe",this,r);return this};Readable.prototype.on=function(e,t){var r=o.prototype.on.call(this,e,t);var i=this._readableState;if(e==="data"){i.readableListening=this.listenerCount("readable")>0;if(i.flowing!==false)this.resume()}else if(e==="readable"){if(!i.endEmitted&&!i.readableListening){i.readableListening=i.needReadable=true;i.flowing=false;i.emittedReadable=false;h("on readable",i.length,i.reading);if(i.length){emitReadable(this)}else if(!i.reading){process.nextTick(nReadingNextTick,this)}}}return r};Readable.prototype.addListener=Readable.prototype.on;Readable.prototype.removeListener=function(e,t){var r=o.prototype.removeListener.call(this,e,t);if(e==="readable"){process.nextTick(updateReadableListening,this)}return r};Readable.prototype.removeAllListeners=function(e){var t=o.prototype.removeAllListeners.apply(this,arguments);if(e==="readable"||e===undefined){process.nextTick(updateReadableListening,this)}return t};function updateReadableListening(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0;if(t.resumeScheduled&&!t.paused){t.flowing=true}else if(e.listenerCount("data")>0){e.resume()}}function nReadingNextTick(e){h("readable nexttick read 0");e.read(0)}Readable.prototype.resume=function(){var e=this._readableState;if(!e.flowing){h("resume");e.flowing=!e.readableListening;resume(this,e)}e.paused=false;return this};function resume(e,t){if(!t.resumeScheduled){t.resumeScheduled=true;process.nextTick(resume_,e,t)}}function resume_(e,t){h("resume",t.reading);if(!t.reading){e.read(0)}t.resumeScheduled=false;e.emit("resume");flow(e);if(t.flowing&&!t.reading)e.read(0)}Readable.prototype.pause=function(){h("call pause flowing=%j",this._readableState.flowing);if(this._readableState.flowing!==false){h("pause");this._readableState.flowing=false;this.emit("pause")}this._readableState.paused=true;return this};function flow(e){var t=e._readableState;h("flow",t.flowing);while(t.flowing&&e.read()!==null);}Readable.prototype.wrap=function(e){var t=this;var r=this._readableState;var i=false;e.on("end",(function(){h("wrapped end");if(r.decoder&&!r.ended){var e=r.decoder.end();if(e&&e.length)t.push(e)}t.push(null)}));e.on("data",(function(n){h("wrapped data");if(r.decoder)n=r.decoder.write(n);if(r.objectMode&&(n===null||n===undefined))return;else if(!r.objectMode&&(!n||!n.length))return;var s=t.push(n);if(!s){i=true;e.pause()}}));for(var n in e){if(this[n]===undefined&&typeof e[n]==="function"){this[n]=function methodWrap(t){return function methodWrapReturnFunction(){return e[t].apply(e,arguments)}}(n)}}for(var s=0;s<A.length;s++){e.on(A[s],this.emit.bind(this,A[s]))}this._read=function(t){h("wrapped _read",t);if(i){i=false;e.resume()}};return this};if(typeof Symbol==="function"){Readable.prototype[Symbol.asyncIterator]=function(){if(S===undefined){S=r(4868)}return S(this)}}Object.defineProperty(Readable.prototype,"readableHighWaterMark",{enumerable:false,get:function get(){return this._readableState.highWaterMark}});Object.defineProperty(Readable.prototype,"readableBuffer",{enumerable:false,get:function get(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(Readable.prototype,"readableFlowing",{enumerable:false,get:function get(){return this._readableState.flowing},set:function set(e){if(this._readableState){this._readableState.flowing=e}}});Readable._fromList=fromList;Object.defineProperty(Readable.prototype,"readableLength",{enumerable:false,get:function get(){return this._readableState.length}});function fromList(e,t){if(t.length===0)return null;var r;if(t.objectMode)r=t.buffer.shift();else if(!e||e>=t.length){if(t.decoder)r=t.buffer.join("");else if(t.buffer.length===1)r=t.buffer.first();else r=t.buffer.concat(t.length);t.buffer.clear()}else{r=t.buffer.consume(e,t.decoder)}return r}function endReadable(e){var t=e._readableState;h("endReadable",t.endEmitted);if(!t.endEmitted){t.ended=true;process.nextTick(endReadableNT,t,e)}}function endReadableNT(e,t){h("endReadableNT",e.endEmitted,e.length);if(!e.endEmitted&&e.length===0){e.endEmitted=true;t.readable=false;t.emit("end");if(e.autoDestroy){var r=t._writableState;if(!r||r.autoDestroy&&r.finished){t.destroy()}}}}if(typeof Symbol==="function"){Readable.from=function(e,t){if(x===undefined){x=r(4659)}return x(Readable,e,t)}}function indexOf(e,t){for(var r=0,i=e.length;r<i;r++){if(e[r]===t)return r}return-1}},2337:(e,t,r)=>{"use strict";e.exports=Transform;var i=r(5500).F,n=i.ERR_METHOD_NOT_IMPLEMENTED,s=i.ERR_MULTIPLE_CALLBACK,o=i.ERR_TRANSFORM_ALREADY_TRANSFORMING,a=i.ERR_TRANSFORM_WITH_LENGTH_0;var l=r(2063);r(9598)(Transform,l);function afterTransform(e,t){var r=this._transformState;r.transforming=false;var i=r.writecb;if(i===null){return this.emit("error",new s)}r.writechunk=null;r.writecb=null;if(t!=null)this.push(t);i(e);var n=this._readableState;n.reading=false;if(n.needReadable||n.length<n.highWaterMark){this._read(n.highWaterMark)}}function Transform(e){if(!(this instanceof Transform))return new Transform(e);l.call(this,e);this._transformState={afterTransform:afterTransform.bind(this),needTransform:false,transforming:false,writecb:null,writechunk:null,writeencoding:null};this._readableState.needReadable=true;this._readableState.sync=false;if(e){if(typeof e.transform==="function")this._transform=e.transform;if(typeof e.flush==="function")this._flush=e.flush}this.on("prefinish",prefinish)}function prefinish(){var e=this;if(typeof this._flush==="function"&&!this._readableState.destroyed){this._flush((function(t,r){done(e,t,r)}))}else{done(this,null,null)}}Transform.prototype.push=function(e,t){this._transformState.needTransform=false;return l.prototype.push.call(this,e,t)};Transform.prototype._transform=function(e,t,r){r(new n("_transform()"))};Transform.prototype._write=function(e,t,r){var i=this._transformState;i.writecb=r;i.writechunk=e;i.writeencoding=t;if(!i.transforming){var n=this._readableState;if(i.needTransform||n.needReadable||n.length<n.highWaterMark)this._read(n.highWaterMark)}};Transform.prototype._read=function(e){var t=this._transformState;if(t.writechunk!==null&&!t.transforming){t.transforming=true;this._transform(t.writechunk,t.writeencoding,t.afterTransform)}else{t.needTransform=true}};Transform.prototype._destroy=function(e,t){l.prototype._destroy.call(this,e,(function(e){t(e)}))};function done(e,t,r){if(t)return e.emit("error",t);if(r!=null)e.push(r);if(e._writableState.length)throw new a;if(e._transformState.transforming)throw new o;return e.push(null)}},8797:(e,t,r)=>{"use strict";e.exports=Writable;function WriteReq(e,t,r){this.chunk=e;this.encoding=t;this.callback=r;this.next=null}function CorkedRequest(e){var t=this;this.next=null;this.entry=null;this.finish=function(){onCorkedFinish(t,e)}}var i;Writable.WritableState=WritableState;var n={deprecate:r(4488)};var s=r(3283);var o=r(181).Buffer;var a=(typeof global!=="undefined"?global:typeof window!=="undefined"?window:typeof self!=="undefined"?self:{}).Uint8Array||function(){};function _uint8ArrayToBuffer(e){return o.from(e)}function _isUint8Array(e){return o.isBuffer(e)||e instanceof a}var l=r(5089);var u=r(4874),h=u.getHighWaterMark;var f=r(5500).F,p=f.ERR_INVALID_ARG_TYPE,d=f.ERR_METHOD_NOT_IMPLEMENTED,m=f.ERR_MULTIPLE_CALLBACK,g=f.ERR_STREAM_CANNOT_PIPE,y=f.ERR_STREAM_DESTROYED,b=f.ERR_STREAM_NULL_VALUES,_=f.ERR_STREAM_WRITE_AFTER_END,v=f.ERR_UNKNOWN_ENCODING;var w=l.errorOrDestroy;r(9598)(Writable,s);function nop(){}function WritableState(e,t,n){i=i||r(2063);e=e||{};if(typeof n!=="boolean")n=t instanceof i;this.objectMode=!!e.objectMode;if(n)this.objectMode=this.objectMode||!!e.writableObjectMode;this.highWaterMark=h(this,e,"writableHighWaterMark",n);this.finalCalled=false;this.needDrain=false;this.ending=false;this.ended=false;this.finished=false;this.destroyed=false;var s=e.decodeStrings===false;this.decodeStrings=!s;this.defaultEncoding=e.defaultEncoding||"utf8";this.length=0;this.writing=false;this.corked=0;this.sync=true;this.bufferProcessing=false;this.onwrite=function(e){onwrite(t,e)};this.writecb=null;this.writelen=0;this.bufferedRequest=null;this.lastBufferedRequest=null;this.pendingcb=0;this.prefinished=false;this.errorEmitted=false;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.bufferedRequestCount=0;this.corkedRequestsFree=new CorkedRequest(this)}WritableState.prototype.getBuffer=function getBuffer(){var e=this.bufferedRequest;var t=[];while(e){t.push(e);e=e.next}return t};(function(){try{Object.defineProperty(WritableState.prototype,"buffer",{get:n.deprecate((function writableStateBufferGetter(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer "+"instead.","DEP0003")})}catch(e){}})();var S;if(typeof Symbol==="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]==="function"){S=Function.prototype[Symbol.hasInstance];Object.defineProperty(Writable,Symbol.hasInstance,{value:function value(e){if(S.call(this,e))return true;if(this!==Writable)return false;return e&&e._writableState instanceof WritableState}})}else{S=function realHasInstance(e){return e instanceof this}}function Writable(e){i=i||r(2063);var t=this instanceof i;if(!t&&!S.call(Writable,this))return new Writable(e);this._writableState=new WritableState(e,this,t);this.writable=true;if(e){if(typeof e.write==="function")this._write=e.write;if(typeof e.writev==="function")this._writev=e.writev;if(typeof e.destroy==="function")this._destroy=e.destroy;if(typeof e.final==="function")this._final=e.final}s.call(this)}Writable.prototype.pipe=function(){w(this,new g)};function writeAfterEnd(e,t){var r=new _;w(e,r);process.nextTick(t,r)}function validChunk(e,t,r,i){var n;if(r===null){n=new b}else if(typeof r!=="string"&&!t.objectMode){n=new p("chunk",["string","Buffer"],r)}if(n){w(e,n);process.nextTick(i,n);return false}return true}Writable.prototype.write=function(e,t,r){var i=this._writableState;var n=false;var s=!i.objectMode&&_isUint8Array(e);if(s&&!o.isBuffer(e)){e=_uint8ArrayToBuffer(e)}if(typeof t==="function"){r=t;t=null}if(s)t="buffer";else if(!t)t=i.defaultEncoding;if(typeof r!=="function")r=nop;if(i.ending)writeAfterEnd(this,r);else if(s||validChunk(this,i,e,r)){i.pendingcb++;n=writeOrBuffer(this,i,s,e,t,r)}return n};Writable.prototype.cork=function(){this._writableState.corked++};Writable.prototype.uncork=function(){var e=this._writableState;if(e.corked){e.corked--;if(!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest)clearBuffer(this,e)}};Writable.prototype.setDefaultEncoding=function setDefaultEncoding(e){if(typeof e==="string")e=e.toLowerCase();if(!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new v(e);this._writableState.defaultEncoding=e;return this};Object.defineProperty(Writable.prototype,"writableBuffer",{enumerable:false,get:function get(){return this._writableState&&this._writableState.getBuffer()}});function decodeChunk(e,t,r){if(!e.objectMode&&e.decodeStrings!==false&&typeof t==="string"){t=o.from(t,r)}return t}Object.defineProperty(Writable.prototype,"writableHighWaterMark",{enumerable:false,get:function get(){return this._writableState.highWaterMark}});function writeOrBuffer(e,t,r,i,n,s){if(!r){var o=decodeChunk(t,i,n);if(i!==o){r=true;n="buffer";i=o}}var a=t.objectMode?1:i.length;t.length+=a;var l=t.length<t.highWaterMark;if(!l)t.needDrain=true;if(t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:i,encoding:n,isBuf:r,callback:s,next:null};if(u){u.next=t.lastBufferedRequest}else{t.bufferedRequest=t.lastBufferedRequest}t.bufferedRequestCount+=1}else{doWrite(e,t,false,a,i,n,s)}return l}function doWrite(e,t,r,i,n,s,o){t.writelen=i;t.writecb=o;t.writing=true;t.sync=true;if(t.destroyed)t.onwrite(new y("write"));else if(r)e._writev(n,t.onwrite);else e._write(n,s,t.onwrite);t.sync=false}function onwriteError(e,t,r,i,n){--t.pendingcb;if(r){process.nextTick(n,i);process.nextTick(finishMaybe,e,t);e._writableState.errorEmitted=true;w(e,i)}else{n(i);e._writableState.errorEmitted=true;w(e,i);finishMaybe(e,t)}}function onwriteStateUpdate(e){e.writing=false;e.writecb=null;e.length-=e.writelen;e.writelen=0}function onwrite(e,t){var r=e._writableState;var i=r.sync;var n=r.writecb;if(typeof n!=="function")throw new m;onwriteStateUpdate(r);if(t)onwriteError(e,r,i,t,n);else{var s=needFinish(r)||e.destroyed;if(!s&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest){clearBuffer(e,r)}if(i){process.nextTick(afterWrite,e,r,s,n)}else{afterWrite(e,r,s,n)}}}function afterWrite(e,t,r,i){if(!r)onwriteDrain(e,t);t.pendingcb--;i();finishMaybe(e,t)}function onwriteDrain(e,t){if(t.length===0&&t.needDrain){t.needDrain=false;e.emit("drain")}}function clearBuffer(e,t){t.bufferProcessing=true;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var i=t.bufferedRequestCount;var n=new Array(i);var s=t.corkedRequestsFree;s.entry=r;var o=0;var a=true;while(r){n[o]=r;if(!r.isBuf)a=false;r=r.next;o+=1}n.allBuffers=a;doWrite(e,t,true,t.length,n,"",s.finish);t.pendingcb++;t.lastBufferedRequest=null;if(s.next){t.corkedRequestsFree=s.next;s.next=null}else{t.corkedRequestsFree=new CorkedRequest(t)}t.bufferedRequestCount=0}else{while(r){var l=r.chunk;var u=r.encoding;var h=r.callback;var f=t.objectMode?1:l.length;doWrite(e,t,false,f,l,u,h);r=r.next;t.bufferedRequestCount--;if(t.writing){break}}if(r===null)t.lastBufferedRequest=null}t.bufferedRequest=r;t.bufferProcessing=false}Writable.prototype._write=function(e,t,r){r(new d("_write()"))};Writable.prototype._writev=null;Writable.prototype.end=function(e,t,r){var i=this._writableState;if(typeof e==="function"){r=e;e=null;t=null}else if(typeof t==="function"){r=t;t=null}if(e!==null&&e!==undefined)this.write(e,t);if(i.corked){i.corked=1;this.uncork()}if(!i.ending)endWritable(this,i,r);return this};Object.defineProperty(Writable.prototype,"writableLength",{enumerable:false,get:function get(){return this._writableState.length}});function needFinish(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}function callFinal(e,t){e._final((function(r){t.pendingcb--;if(r){w(e,r)}t.prefinished=true;e.emit("prefinish");finishMaybe(e,t)}))}function prefinish(e,t){if(!t.prefinished&&!t.finalCalled){if(typeof e._final==="function"&&!t.destroyed){t.pendingcb++;t.finalCalled=true;process.nextTick(callFinal,e,t)}else{t.prefinished=true;e.emit("prefinish")}}}function finishMaybe(e,t){var r=needFinish(t);if(r){prefinish(e,t);if(t.pendingcb===0){t.finished=true;e.emit("finish");if(t.autoDestroy){var i=e._readableState;if(!i||i.autoDestroy&&i.endEmitted){e.destroy()}}}}return r}function endWritable(e,t,r){t.ending=true;finishMaybe(e,t);if(r){if(t.finished)process.nextTick(r);else e.once("finish",r)}t.ended=true;e.writable=false}function onCorkedFinish(e,t,r){var i=e.entry;e.entry=null;while(i){var n=i.callback;t.pendingcb--;n(r);i=i.next}t.corkedRequestsFree.next=e}Object.defineProperty(Writable.prototype,"destroyed",{enumerable:false,get:function get(){if(this._writableState===undefined){return false}return this._writableState.destroyed},set:function set(e){if(!this._writableState){return}this._writableState.destroyed=e}});Writable.prototype.destroy=l.destroy;Writable.prototype._undestroy=l.undestroy;Writable.prototype._destroy=function(e,t){t(e)}},4868:(e,t,r)=>{"use strict";var i;function _defineProperty(e,t,r){t=_toPropertyKey(t);if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return typeof t==="symbol"?t:String(t)}function _toPrimitive(e,t){if(typeof e!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==undefined){var i=r.call(e,t||"default");if(typeof i!=="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var n=r(6815);var s=Symbol("lastResolve");var o=Symbol("lastReject");var a=Symbol("error");var l=Symbol("ended");var u=Symbol("lastPromise");var h=Symbol("handlePromise");var f=Symbol("stream");function createIterResult(e,t){return{value:e,done:t}}function readAndResolve(e){var t=e[s];if(t!==null){var r=e[f].read();if(r!==null){e[u]=null;e[s]=null;e[o]=null;t(createIterResult(r,false))}}}function onReadable(e){process.nextTick(readAndResolve,e)}function wrapForNext(e,t){return function(r,i){e.then((function(){if(t[l]){r(createIterResult(undefined,true));return}t[h](r,i)}),i)}}var p=Object.getPrototypeOf((function(){}));var d=Object.setPrototypeOf((i={get stream(){return this[f]},next:function next(){var e=this;var t=this[a];if(t!==null){return Promise.reject(t)}if(this[l]){return Promise.resolve(createIterResult(undefined,true))}if(this[f].destroyed){return new Promise((function(t,r){process.nextTick((function(){if(e[a]){r(e[a])}else{t(createIterResult(undefined,true))}}))}))}var r=this[u];var i;if(r){i=new Promise(wrapForNext(r,this))}else{var n=this[f].read();if(n!==null){return Promise.resolve(createIterResult(n,false))}i=new Promise(this[h])}this[u]=i;return i}},_defineProperty(i,Symbol.asyncIterator,(function(){return this})),_defineProperty(i,"return",(function _return(){var e=this;return new Promise((function(t,r){e[f].destroy(null,(function(e){if(e){r(e);return}t(createIterResult(undefined,true))}))}))})),i),p);var m=function createReadableStreamAsyncIterator(e){var t;var r=Object.create(d,(t={},_defineProperty(t,f,{value:e,writable:true}),_defineProperty(t,s,{value:null,writable:true}),_defineProperty(t,o,{value:null,writable:true}),_defineProperty(t,a,{value:null,writable:true}),_defineProperty(t,l,{value:e._readableState.endEmitted,writable:true}),_defineProperty(t,h,{value:function value(e,t){var i=r[f].read();if(i){r[u]=null;r[s]=null;r[o]=null;e(createIterResult(i,false))}else{r[s]=e;r[o]=t}},writable:true}),t));r[u]=null;n(e,(function(e){if(e&&e.code!=="ERR_STREAM_PREMATURE_CLOSE"){var t=r[o];if(t!==null){r[u]=null;r[s]=null;r[o]=null;t(e)}r[a]=e;return}var i=r[s];if(i!==null){r[u]=null;r[s]=null;r[o]=null;i(createIterResult(undefined,true))}r[l]=true}));e.on("readable",onReadable.bind(null,r));return r};e.exports=m},7336:(e,t,r)=>{"use strict";function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,i)}return r}function _objectSpread(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ownKeys(Object(r),!0).forEach((function(t){_defineProperty(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ownKeys(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function _defineProperty(e,t,r){t=_toPropertyKey(t);if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}function _classCallCheck(e,t){if(!(e instanceof t)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||false;i.configurable=true;if("value"in i)i.writable=true;Object.defineProperty(e,_toPropertyKey(i.key),i)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);Object.defineProperty(e,"prototype",{writable:false});return e}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return typeof t==="symbol"?t:String(t)}function _toPrimitive(e,t){if(typeof e!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==undefined){var i=r.call(e,t||"default");if(typeof i!=="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var i=r(181),n=i.Buffer;var s=r(9023),o=s.inspect;var a=o&&o.custom||"inspect";function copyBuffer(e,t,r){n.prototype.copy.call(e,t,r)}e.exports=function(){function BufferList(){_classCallCheck(this,BufferList);this.head=null;this.tail=null;this.length=0}_createClass(BufferList,[{key:"push",value:function push(e){var t={data:e,next:null};if(this.length>0)this.tail.next=t;else this.head=t;this.tail=t;++this.length}},{key:"unshift",value:function unshift(e){var t={data:e,next:this.head};if(this.length===0)this.tail=t;this.head=t;++this.length}},{key:"shift",value:function shift(){if(this.length===0)return;var e=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;--this.length;return e}},{key:"clear",value:function clear(){this.head=this.tail=null;this.length=0}},{key:"join",value:function join(e){if(this.length===0)return"";var t=this.head;var r=""+t.data;while(t=t.next)r+=e+t.data;return r}},{key:"concat",value:function concat(e){if(this.length===0)return n.alloc(0);var t=n.allocUnsafe(e>>>0);var r=this.head;var i=0;while(r){copyBuffer(r.data,t,i);i+=r.data.length;r=r.next}return t}},{key:"consume",value:function consume(e,t){var r;if(e<this.head.data.length){r=this.head.data.slice(0,e);this.head.data=this.head.data.slice(e)}else if(e===this.head.data.length){r=this.shift()}else{r=t?this._getString(e):this._getBuffer(e)}return r}},{key:"first",value:function first(){return this.head.data}},{key:"_getString",value:function _getString(e){var t=this.head;var r=1;var i=t.data;e-=i.length;while(t=t.next){var n=t.data;var s=e>n.length?n.length:e;if(s===n.length)i+=n;else i+=n.slice(0,e);e-=s;if(e===0){if(s===n.length){++r;if(t.next)this.head=t.next;else this.head=this.tail=null}else{this.head=t;t.data=n.slice(s)}break}++r}this.length-=r;return i}},{key:"_getBuffer",value:function _getBuffer(e){var t=n.allocUnsafe(e);var r=this.head;var i=1;r.data.copy(t);e-=r.data.length;while(r=r.next){var s=r.data;var o=e>s.length?s.length:e;s.copy(t,t.length-e,0,o);e-=o;if(e===0){if(o===s.length){++i;if(r.next)this.head=r.next;else this.head=this.tail=null}else{this.head=r;r.data=s.slice(o)}break}++i}this.length-=i;return t}},{key:a,value:function value(e,t){return o(this,_objectSpread(_objectSpread({},t),{},{depth:0,customInspect:false}))}}]);return BufferList}()},5089:e=>{"use strict";function destroy(e,t){var r=this;var i=this._readableState&&this._readableState.destroyed;var n=this._writableState&&this._writableState.destroyed;if(i||n){if(t){t(e)}else if(e){if(!this._writableState){process.nextTick(emitErrorNT,this,e)}else if(!this._writableState.errorEmitted){this._writableState.errorEmitted=true;process.nextTick(emitErrorNT,this,e)}}return this}if(this._readableState){this._readableState.destroyed=true}if(this._writableState){this._writableState.destroyed=true}this._destroy(e||null,(function(e){if(!t&&e){if(!r._writableState){process.nextTick(emitErrorAndCloseNT,r,e)}else if(!r._writableState.errorEmitted){r._writableState.errorEmitted=true;process.nextTick(emitErrorAndCloseNT,r,e)}else{process.nextTick(emitCloseNT,r)}}else if(t){process.nextTick(emitCloseNT,r);t(e)}else{process.nextTick(emitCloseNT,r)}}));return this}function emitErrorAndCloseNT(e,t){emitErrorNT(e,t);emitCloseNT(e)}function emitCloseNT(e){if(e._writableState&&!e._writableState.emitClose)return;if(e._readableState&&!e._readableState.emitClose)return;e.emit("close")}function undestroy(){if(this._readableState){this._readableState.destroyed=false;this._readableState.reading=false;this._readableState.ended=false;this._readableState.endEmitted=false}if(this._writableState){this._writableState.destroyed=false;this._writableState.ended=false;this._writableState.ending=false;this._writableState.finalCalled=false;this._writableState.prefinished=false;this._writableState.finished=false;this._writableState.errorEmitted=false}}function emitErrorNT(e,t){e.emit("error",t)}function errorOrDestroy(e,t){var r=e._readableState;var i=e._writableState;if(r&&r.autoDestroy||i&&i.autoDestroy)e.destroy(t);else e.emit("error",t)}e.exports={destroy:destroy,undestroy:undestroy,errorOrDestroy:errorOrDestroy}},6815:(e,t,r)=>{"use strict";var i=r(5500).F.ERR_STREAM_PREMATURE_CLOSE;function once(e){var t=false;return function(){if(t)return;t=true;for(var r=arguments.length,i=new Array(r),n=0;n<r;n++){i[n]=arguments[n]}e.apply(this,i)}}function noop(){}function isRequest(e){return e.setHeader&&typeof e.abort==="function"}function eos(e,t,r){if(typeof t==="function")return eos(e,null,t);if(!t)t={};r=once(r||noop);var n=t.readable||t.readable!==false&&e.readable;var s=t.writable||t.writable!==false&&e.writable;var o=function onlegacyfinish(){if(!e.writable)l()};var a=e._writableState&&e._writableState.finished;var l=function onfinish(){s=false;a=true;if(!n)r.call(e)};var u=e._readableState&&e._readableState.endEmitted;var h=function onend(){n=false;u=true;if(!s)r.call(e)};var f=function onerror(t){r.call(e,t)};var p=function onclose(){var t;if(n&&!u){if(!e._readableState||!e._readableState.ended)t=new i;return r.call(e,t)}if(s&&!a){if(!e._writableState||!e._writableState.ended)t=new i;return r.call(e,t)}};var d=function onrequest(){e.req.on("finish",l)};if(isRequest(e)){e.on("complete",l);e.on("abort",p);if(e.req)d();else e.on("request",d)}else if(s&&!e._writableState){e.on("end",o);e.on("close",o)}e.on("end",h);e.on("finish",l);if(t.error!==false)e.on("error",f);e.on("close",p);return function(){e.removeListener("complete",l);e.removeListener("abort",p);e.removeListener("request",d);if(e.req)e.req.removeListener("finish",l);e.removeListener("end",o);e.removeListener("close",o);e.removeListener("finish",l);e.removeListener("end",h);e.removeListener("error",f);e.removeListener("close",p)}}e.exports=eos},4659:(e,t,r)=>{"use strict";function asyncGeneratorStep(e,t,r,i,n,s,o){try{var a=e[s](o);var l=a.value}catch(e){r(e);return}if(a.done){t(l)}else{Promise.resolve(l).then(i,n)}}function _asyncToGenerator(e){return function(){var t=this,r=arguments;return new Promise((function(i,n){var s=e.apply(t,r);function _next(e){asyncGeneratorStep(s,i,n,_next,_throw,"next",e)}function _throw(e){asyncGeneratorStep(s,i,n,_next,_throw,"throw",e)}_next(undefined)}))}}function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,i)}return r}function _objectSpread(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ownKeys(Object(r),!0).forEach((function(t){_defineProperty(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ownKeys(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function _defineProperty(e,t,r){t=_toPropertyKey(t);if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return typeof t==="symbol"?t:String(t)}function _toPrimitive(e,t){if(typeof e!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==undefined){var i=r.call(e,t||"default");if(typeof i!=="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var i=r(5500).F.ERR_INVALID_ARG_TYPE;function from(e,t,r){var n;if(t&&typeof t.next==="function"){n=t}else if(t&&t[Symbol.asyncIterator])n=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])n=t[Symbol.iterator]();else throw new i("iterable",["Iterable"],t);var s=new e(_objectSpread({objectMode:true},r));var o=false;s._read=function(){if(!o){o=true;next()}};function next(){return _next2.apply(this,arguments)}function _next2(){_next2=_asyncToGenerator((function*(){try{var e=yield n.next(),t=e.value,r=e.done;if(r){s.push(null)}else if(s.push(yield t)){next()}else{o=false}}catch(e){s.destroy(e)}}));return _next2.apply(this,arguments)}return s}e.exports=from},6701:(e,t,r)=>{"use strict";var i;function once(e){var t=false;return function(){if(t)return;t=true;e.apply(void 0,arguments)}}var n=r(5500).F,s=n.ERR_MISSING_ARGS,o=n.ERR_STREAM_DESTROYED;function noop(e){if(e)throw e}function isRequest(e){return e.setHeader&&typeof e.abort==="function"}function destroyer(e,t,n,s){s=once(s);var a=false;e.on("close",(function(){a=true}));if(i===undefined)i=r(6815);i(e,{readable:t,writable:n},(function(e){if(e)return s(e);a=true;s()}));var l=false;return function(t){if(a)return;if(l)return;l=true;if(isRequest(e))return e.abort();if(typeof e.destroy==="function")return e.destroy();s(t||new o("pipe"))}}function call(e){e()}function pipe(e,t){return e.pipe(t)}function popCallback(e){if(!e.length)return noop;if(typeof e[e.length-1]!=="function")return noop;return e.pop()}function pipeline(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++){t[r]=arguments[r]}var i=popCallback(t);if(Array.isArray(t[0]))t=t[0];if(t.length<2){throw new s("streams")}var n;var o=t.map((function(e,r){var s=r<t.length-1;var a=r>0;return destroyer(e,s,a,(function(e){if(!n)n=e;if(e)o.forEach(call);if(s)return;o.forEach(call);i(n)}))}));return t.reduce(pipe)}e.exports=pipeline},4874:(e,t,r)=>{"use strict";var i=r(5500).F.ERR_INVALID_OPT_VALUE;function highWaterMarkFrom(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function getHighWaterMark(e,t,r,n){var s=highWaterMarkFrom(t,n,r);if(s!=null){if(!(isFinite(s)&&Math.floor(s)===s)||s<0){var o=n?r:"highWaterMark";throw new i(o,s)}return Math.floor(s)}return e.objectMode?16:16*1024}e.exports={getHighWaterMark:getHighWaterMark}},3283:(e,t,r)=>{e.exports=r(2203)},6131:(e,t,r)=>{var i=r(2203);if(process.env.READABLE_STREAM==="disable"&&i){e.exports=i.Readable;Object.assign(e.exports,i);e.exports.Stream=i}else{t=e.exports=r(6893);t.Stream=i||t;t.Readable=t;t.Writable=r(8797);t.Duplex=r(2063);t.Transform=r(2337);t.PassThrough=r(5283);t.finished=r(6815);t.pipeline=r(6701)}},4023:(e,t,r)=>{"use strict";const i=r(9969);const n=r(6627);e.exports=i((()=>{n((()=>{process.stderr.write("[?25h")}),{alwaysLast:true})}))},844:e=>{"use strict";function reusify(e){var t=new e;var r=t;function get(){var i=t;if(i.next){t=i.next}else{t=new e;r=t}i.next=null;return i}function release(e){r.next=e;r=e}return{get:get,release:release}}e.exports=reusify},2743:(e,t,r)=>{
|
|
31
31
|
/*! run-parallel. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
32
|
-
e.exports=runParallel;const
|
|
32
|
+
e.exports=runParallel;const i=r(4351);function runParallel(e,t){let r,n,s;let o=true;if(Array.isArray(e)){r=[];n=e.length}else{s=Object.keys(e);r={};n=s.length}function done(e){function end(){if(t)t(e,r);t=null}if(o)i(end);else end()}function each(e,t,i){r[e]=i;if(--n===0||t){done(t)}}if(!n){done(null)}else if(s){s.forEach((function(t){e[t]((function(e,r){each(t,e,r)}))}))}else{e.forEach((function(e,t){e((function(e,r){each(t,e,r)}))}))}o=false}},3058:(e,t,r)=>{
|
|
33
33
|
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
34
|
-
var s=r(4300);var i=s.Buffer;function copyProps(e,t){for(var r in e){t[r]=e[r]}}if(i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow){e.exports=s}else{copyProps(s,t);t.Buffer=SafeBuffer}function SafeBuffer(e,t,r){return i(e,t,r)}SafeBuffer.prototype=Object.create(i.prototype);copyProps(i,SafeBuffer);SafeBuffer.from=function(e,t,r){if(typeof e==="number"){throw new TypeError("Argument must not be a number")}return i(e,t,r)};SafeBuffer.alloc=function(e,t,r){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}var s=i(e);if(t!==undefined){if(typeof r==="string"){s.fill(t,r)}else{s.fill(t)}}else{s.fill(0)}return s};SafeBuffer.allocUnsafe=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return i(e)};SafeBuffer.allocUnsafeSlow=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return s.SlowBuffer(e)}},1532:(e,t,r)=>{const s=Symbol("SemVer ANY");class Comparator{static get ANY(){return s}constructor(e,t){t=i(t);if(e instanceof Comparator){if(e.loose===!!t.loose){return e}else{e=e.value}}l("comparator",e,t);this.options=t;this.loose=!!t.loose;this.parse(e);if(this.semver===s){this.value=""}else{this.value=this.operator+this.semver.version}l("comp",this)}parse(e){const t=this.options.loose?n[o.COMPARATORLOOSE]:n[o.COMPARATOR];const r=e.match(t);if(!r){throw new TypeError(`Invalid comparator: ${e}`)}this.operator=r[1]!==undefined?r[1]:"";if(this.operator==="="){this.operator=""}if(!r[2]){this.semver=s}else{this.semver=new u(r[2],this.options.loose)}}toString(){return this.value}test(e){l("Comparator.test",e,this.options.loose);if(this.semver===s||e===s){return true}if(typeof e==="string"){try{e=new u(e,this.options)}catch(e){return false}}return a(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof Comparator)){throw new TypeError("a Comparator is required")}if(!t||typeof t!=="object"){t={loose:!!t,includePrerelease:false}}if(this.operator===""){if(this.value===""){return true}return new h(e.value,t).test(this.value)}else if(e.operator===""){if(e.value===""){return true}return new h(this.value,t).test(e.semver)}const r=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">");const s=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<");const i=this.semver.version===e.semver.version;const n=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<=");const o=a(this.semver,"<",e.semver,t)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<");const l=a(this.semver,">",e.semver,t)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return r||s||i&&n||o||l}}e.exports=Comparator;const i=r(785);const{re:n,t:o}=r(9523);const a=r(5098);const l=r(427);const u=r(8088);const h=r(9828)},9828:(e,t,r)=>{class Range{constructor(e,t){t=n(t);if(e instanceof Range){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease){return e}else{return new Range(e.raw,t)}}if(e instanceof o){this.raw=e.value;this.set=[[e]];this.format();return this}this.options=t;this.loose=!!t.loose;this.includePrerelease=!!t.includePrerelease;this.raw=e;this.set=e.split("||").map((e=>this.parseRange(e.trim()))).filter((e=>e.length));if(!this.set.length){throw new TypeError(`Invalid SemVer Range: ${e}`)}if(this.set.length>1){const e=this.set[0];this.set=this.set.filter((e=>!isNullSet(e[0])));if(this.set.length===0){this.set=[e]}else if(this.set.length>1){for(const e of this.set){if(e.length===1&&isAny(e[0])){this.set=[e];break}}}}this.format()}format(){this.range=this.set.map((e=>e.join(" ").trim())).join("||").trim();return this.range}toString(){return this.range}parseRange(e){e=e.trim();const t=Object.keys(this.options).join(",");const r=`parseRange:${t}:${e}`;const s=i.get(r);if(s){return s}const n=this.options.loose;const l=n?u[h.HYPHENRANGELOOSE]:u[h.HYPHENRANGE];e=e.replace(l,hyphenReplace(this.options.includePrerelease));a("hyphen replace",e);e=e.replace(u[h.COMPARATORTRIM],f);a("comparator trim",e);e=e.replace(u[h.TILDETRIM],p);e=e.replace(u[h.CARETTRIM],d);e=e.split(/\s+/).join(" ");let m=e.split(" ").map((e=>parseComparator(e,this.options))).join(" ").split(/\s+/).map((e=>replaceGTE0(e,this.options)));if(n){m=m.filter((e=>{a("loose invalid filter",e,this.options);return!!e.match(u[h.COMPARATORLOOSE])}))}a("range list",m);const g=new Map;const y=m.map((e=>new o(e,this.options)));for(const e of y){if(isNullSet(e)){return[e]}g.set(e.value,e)}if(g.size>1&&g.has("")){g.delete("")}const b=[...g.values()];i.set(r,b);return b}intersects(e,t){if(!(e instanceof Range)){throw new TypeError("a Range is required")}return this.set.some((r=>isSatisfiable(r,t)&&e.set.some((e=>isSatisfiable(e,t)&&r.every((r=>e.every((e=>r.intersects(e,t)))))))))}test(e){if(!e){return false}if(typeof e==="string"){try{e=new l(e,this.options)}catch(e){return false}}for(let t=0;t<this.set.length;t++){if(testSet(this.set[t],e,this.options)){return true}}return false}}e.exports=Range;const s=r(7129);const i=new s({max:1e3});const n=r(785);const o=r(1532);const a=r(427);const l=r(8088);const{re:u,t:h,comparatorTrimReplace:f,tildeTrimReplace:p,caretTrimReplace:d}=r(9523);const isNullSet=e=>e.value==="<0.0.0-0";const isAny=e=>e.value==="";const isSatisfiable=(e,t)=>{let r=true;const s=e.slice();let i=s.pop();while(r&&s.length){r=s.every((e=>i.intersects(e,t)));i=s.pop()}return r};const parseComparator=(e,t)=>{a("comp",e,t);e=replaceCarets(e,t);a("caret",e);e=replaceTildes(e,t);a("tildes",e);e=replaceXRanges(e,t);a("xrange",e);e=replaceStars(e,t);a("stars",e);return e};const isX=e=>!e||e.toLowerCase()==="x"||e==="*";const replaceTildes=(e,t)=>e.trim().split(/\s+/).map((e=>replaceTilde(e,t))).join(" ");const replaceTilde=(e,t)=>{const r=t.loose?u[h.TILDELOOSE]:u[h.TILDE];return e.replace(r,((t,r,s,i,n)=>{a("tilde",e,t,r,s,i,n);let o;if(isX(r)){o=""}else if(isX(s)){o=`>=${r}.0.0 <${+r+1}.0.0-0`}else if(isX(i)){o=`>=${r}.${s}.0 <${r}.${+s+1}.0-0`}else if(n){a("replaceTilde pr",n);o=`>=${r}.${s}.${i}-${n} <${r}.${+s+1}.0-0`}else{o=`>=${r}.${s}.${i} <${r}.${+s+1}.0-0`}a("tilde return",o);return o}))};const replaceCarets=(e,t)=>e.trim().split(/\s+/).map((e=>replaceCaret(e,t))).join(" ");const replaceCaret=(e,t)=>{a("caret",e,t);const r=t.loose?u[h.CARETLOOSE]:u[h.CARET];const s=t.includePrerelease?"-0":"";return e.replace(r,((t,r,i,n,o)=>{a("caret",e,t,r,i,n,o);let l;if(isX(r)){l=""}else if(isX(i)){l=`>=${r}.0.0${s} <${+r+1}.0.0-0`}else if(isX(n)){if(r==="0"){l=`>=${r}.${i}.0${s} <${r}.${+i+1}.0-0`}else{l=`>=${r}.${i}.0${s} <${+r+1}.0.0-0`}}else if(o){a("replaceCaret pr",o);if(r==="0"){if(i==="0"){l=`>=${r}.${i}.${n}-${o} <${r}.${i}.${+n+1}-0`}else{l=`>=${r}.${i}.${n}-${o} <${r}.${+i+1}.0-0`}}else{l=`>=${r}.${i}.${n}-${o} <${+r+1}.0.0-0`}}else{a("no pr");if(r==="0"){if(i==="0"){l=`>=${r}.${i}.${n}${s} <${r}.${i}.${+n+1}-0`}else{l=`>=${r}.${i}.${n}${s} <${r}.${+i+1}.0-0`}}else{l=`>=${r}.${i}.${n} <${+r+1}.0.0-0`}}a("caret return",l);return l}))};const replaceXRanges=(e,t)=>{a("replaceXRanges",e,t);return e.split(/\s+/).map((e=>replaceXRange(e,t))).join(" ")};const replaceXRange=(e,t)=>{e=e.trim();const r=t.loose?u[h.XRANGELOOSE]:u[h.XRANGE];return e.replace(r,((r,s,i,n,o,l)=>{a("xRange",e,r,s,i,n,o,l);const u=isX(i);const h=u||isX(n);const f=h||isX(o);const p=f;if(s==="="&&p){s=""}l=t.includePrerelease?"-0":"";if(u){if(s===">"||s==="<"){r="<0.0.0-0"}else{r="*"}}else if(s&&p){if(h){n=0}o=0;if(s===">"){s=">=";if(h){i=+i+1;n=0;o=0}else{n=+n+1;o=0}}else if(s==="<="){s="<";if(h){i=+i+1}else{n=+n+1}}if(s==="<"){l="-0"}r=`${s+i}.${n}.${o}${l}`}else if(h){r=`>=${i}.0.0${l} <${+i+1}.0.0-0`}else if(f){r=`>=${i}.${n}.0${l} <${i}.${+n+1}.0-0`}a("xRange return",r);return r}))};const replaceStars=(e,t)=>{a("replaceStars",e,t);return e.trim().replace(u[h.STAR],"")};const replaceGTE0=(e,t)=>{a("replaceGTE0",e,t);return e.trim().replace(u[t.includePrerelease?h.GTE0PRE:h.GTE0],"")};const hyphenReplace=e=>(t,r,s,i,n,o,a,l,u,h,f,p,d)=>{if(isX(s)){r=""}else if(isX(i)){r=`>=${s}.0.0${e?"-0":""}`}else if(isX(n)){r=`>=${s}.${i}.0${e?"-0":""}`}else if(o){r=`>=${r}`}else{r=`>=${r}${e?"-0":""}`}if(isX(u)){l=""}else if(isX(h)){l=`<${+u+1}.0.0-0`}else if(isX(f)){l=`<${u}.${+h+1}.0-0`}else if(p){l=`<=${u}.${h}.${f}-${p}`}else if(e){l=`<${u}.${h}.${+f+1}-0`}else{l=`<=${l}`}return`${r} ${l}`.trim()};const testSet=(e,t,r)=>{for(let r=0;r<e.length;r++){if(!e[r].test(t)){return false}}if(t.prerelease.length&&!r.includePrerelease){for(let r=0;r<e.length;r++){a(e[r].semver);if(e[r].semver===o.ANY){continue}if(e[r].semver.prerelease.length>0){const s=e[r].semver;if(s.major===t.major&&s.minor===t.minor&&s.patch===t.patch){return true}}}return false}return true}},8088:(e,t,r)=>{const s=r(427);const{MAX_LENGTH:i,MAX_SAFE_INTEGER:n}=r(2293);const{re:o,t:a}=r(9523);const l=r(785);const{compareIdentifiers:u}=r(2463);class SemVer{constructor(e,t){t=l(t);if(e instanceof SemVer){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease){return e}else{e=e.version}}else if(typeof e!=="string"){throw new TypeError(`Invalid Version: ${e}`)}if(e.length>i){throw new TypeError(`version is longer than ${i} characters`)}s("SemVer",e,t);this.options=t;this.loose=!!t.loose;this.includePrerelease=!!t.includePrerelease;const r=e.trim().match(t.loose?o[a.LOOSE]:o[a.FULL]);if(!r){throw new TypeError(`Invalid Version: ${e}`)}this.raw=e;this.major=+r[1];this.minor=+r[2];this.patch=+r[3];if(this.major>n||this.major<0){throw new TypeError("Invalid major version")}if(this.minor>n||this.minor<0){throw new TypeError("Invalid minor version")}if(this.patch>n||this.patch<0){throw new TypeError("Invalid patch version")}if(!r[4]){this.prerelease=[]}else{this.prerelease=r[4].split(".").map((e=>{if(/^[0-9]+$/.test(e)){const t=+e;if(t>=0&&t<n){return t}}return e}))}this.build=r[5]?r[5].split("."):[];this.format()}format(){this.version=`${this.major}.${this.minor}.${this.patch}`;if(this.prerelease.length){this.version+=`-${this.prerelease.join(".")}`}return this.version}toString(){return this.version}compare(e){s("SemVer.compare",this.version,this.options,e);if(!(e instanceof SemVer)){if(typeof e==="string"&&e===this.version){return 0}e=new SemVer(e,this.options)}if(e.version===this.version){return 0}return this.compareMain(e)||this.comparePre(e)}compareMain(e){if(!(e instanceof SemVer)){e=new SemVer(e,this.options)}return u(this.major,e.major)||u(this.minor,e.minor)||u(this.patch,e.patch)}comparePre(e){if(!(e instanceof SemVer)){e=new SemVer(e,this.options)}if(this.prerelease.length&&!e.prerelease.length){return-1}else if(!this.prerelease.length&&e.prerelease.length){return 1}else if(!this.prerelease.length&&!e.prerelease.length){return 0}let t=0;do{const r=this.prerelease[t];const i=e.prerelease[t];s("prerelease compare",t,r,i);if(r===undefined&&i===undefined){return 0}else if(i===undefined){return 1}else if(r===undefined){return-1}else if(r===i){continue}else{return u(r,i)}}while(++t)}compareBuild(e){if(!(e instanceof SemVer)){e=new SemVer(e,this.options)}let t=0;do{const r=this.build[t];const i=e.build[t];s("prerelease compare",t,r,i);if(r===undefined&&i===undefined){return 0}else if(i===undefined){return 1}else if(r===undefined){return-1}else if(r===i){continue}else{return u(r,i)}}while(++t)}inc(e,t){switch(e){case"premajor":this.prerelease.length=0;this.patch=0;this.minor=0;this.major++;this.inc("pre",t);break;case"preminor":this.prerelease.length=0;this.patch=0;this.minor++;this.inc("pre",t);break;case"prepatch":this.prerelease.length=0;this.inc("patch",t);this.inc("pre",t);break;case"prerelease":if(this.prerelease.length===0){this.inc("patch",t)}this.inc("pre",t);break;case"major":if(this.minor!==0||this.patch!==0||this.prerelease.length===0){this.major++}this.minor=0;this.patch=0;this.prerelease=[];break;case"minor":if(this.patch!==0||this.prerelease.length===0){this.minor++}this.patch=0;this.prerelease=[];break;case"patch":if(this.prerelease.length===0){this.patch++}this.prerelease=[];break;case"pre":if(this.prerelease.length===0){this.prerelease=[0]}else{let e=this.prerelease.length;while(--e>=0){if(typeof this.prerelease[e]==="number"){this.prerelease[e]++;e=-2}}if(e===-1){this.prerelease.push(0)}}if(t){if(u(this.prerelease[0],t)===0){if(isNaN(this.prerelease[1])){this.prerelease=[t,0]}}else{this.prerelease=[t,0]}}break;default:throw new Error(`invalid increment argument: ${e}`)}this.format();this.raw=this.version;return this}}e.exports=SemVer},8848:(e,t,r)=>{const s=r(5925);const clean=(e,t)=>{const r=s(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null};e.exports=clean},5098:(e,t,r)=>{const s=r(1898);const i=r(6017);const n=r(4123);const o=r(5522);const a=r(194);const l=r(7520);const cmp=(e,t,r,u)=>{switch(t){case"===":if(typeof e==="object"){e=e.version}if(typeof r==="object"){r=r.version}return e===r;case"!==":if(typeof e==="object"){e=e.version}if(typeof r==="object"){r=r.version}return e!==r;case"":case"=":case"==":return s(e,r,u);case"!=":return i(e,r,u);case">":return n(e,r,u);case">=":return o(e,r,u);case"<":return a(e,r,u);case"<=":return l(e,r,u);default:throw new TypeError(`Invalid operator: ${t}`)}};e.exports=cmp},3466:(e,t,r)=>{const s=r(8088);const i=r(5925);const{re:n,t:o}=r(9523);const coerce=(e,t)=>{if(e instanceof s){return e}if(typeof e==="number"){e=String(e)}if(typeof e!=="string"){return null}t=t||{};let r=null;if(!t.rtl){r=e.match(n[o.COERCE])}else{let t;while((t=n[o.COERCERTL].exec(e))&&(!r||r.index+r[0].length!==e.length)){if(!r||t.index+t[0].length!==r.index+r[0].length){r=t}n[o.COERCERTL].lastIndex=t.index+t[1].length+t[2].length}n[o.COERCERTL].lastIndex=-1}if(r===null){return null}return i(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,t)};e.exports=coerce},2156:(e,t,r)=>{const s=r(8088);const compareBuild=(e,t,r)=>{const i=new s(e,r);const n=new s(t,r);return i.compare(n)||i.compareBuild(n)};e.exports=compareBuild},2804:(e,t,r)=>{const s=r(4309);const compareLoose=(e,t)=>s(e,t,true);e.exports=compareLoose},4309:(e,t,r)=>{const s=r(8088);const compare=(e,t,r)=>new s(e,r).compare(new s(t,r));e.exports=compare},4297:(e,t,r)=>{const s=r(5925);const i=r(1898);const diff=(e,t)=>{if(i(e,t)){return null}else{const r=s(e);const i=s(t);const n=r.prerelease.length||i.prerelease.length;const o=n?"pre":"";const a=n?"prerelease":"";for(const e in r){if(e==="major"||e==="minor"||e==="patch"){if(r[e]!==i[e]){return o+e}}}return a}};e.exports=diff},1898:(e,t,r)=>{const s=r(4309);const eq=(e,t,r)=>s(e,t,r)===0;e.exports=eq},4123:(e,t,r)=>{const s=r(4309);const gt=(e,t,r)=>s(e,t,r)>0;e.exports=gt},5522:(e,t,r)=>{const s=r(4309);const gte=(e,t,r)=>s(e,t,r)>=0;e.exports=gte},900:(e,t,r)=>{const s=r(8088);const inc=(e,t,r,i)=>{if(typeof r==="string"){i=r;r=undefined}try{return new s(e instanceof s?e.version:e,r).inc(t,i).version}catch(e){return null}};e.exports=inc},194:(e,t,r)=>{const s=r(4309);const lt=(e,t,r)=>s(e,t,r)<0;e.exports=lt},7520:(e,t,r)=>{const s=r(4309);const lte=(e,t,r)=>s(e,t,r)<=0;e.exports=lte},6688:(e,t,r)=>{const s=r(8088);const major=(e,t)=>new s(e,t).major;e.exports=major},8447:(e,t,r)=>{const s=r(8088);const minor=(e,t)=>new s(e,t).minor;e.exports=minor},6017:(e,t,r)=>{const s=r(4309);const neq=(e,t,r)=>s(e,t,r)!==0;e.exports=neq},5925:(e,t,r)=>{const{MAX_LENGTH:s}=r(2293);const{re:i,t:n}=r(9523);const o=r(8088);const a=r(785);const parse=(e,t)=>{t=a(t);if(e instanceof o){return e}if(typeof e!=="string"){return null}if(e.length>s){return null}const r=t.loose?i[n.LOOSE]:i[n.FULL];if(!r.test(e)){return null}try{return new o(e,t)}catch(e){return null}};e.exports=parse},2866:(e,t,r)=>{const s=r(8088);const patch=(e,t)=>new s(e,t).patch;e.exports=patch},4016:(e,t,r)=>{const s=r(5925);const prerelease=(e,t)=>{const r=s(e,t);return r&&r.prerelease.length?r.prerelease:null};e.exports=prerelease},6417:(e,t,r)=>{const s=r(4309);const rcompare=(e,t,r)=>s(t,e,r);e.exports=rcompare},8701:(e,t,r)=>{const s=r(2156);const rsort=(e,t)=>e.sort(((e,r)=>s(r,e,t)));e.exports=rsort},6055:(e,t,r)=>{const s=r(9828);const satisfies=(e,t,r)=>{try{t=new s(t,r)}catch(e){return false}return t.test(e)};e.exports=satisfies},1426:(e,t,r)=>{const s=r(2156);const sort=(e,t)=>e.sort(((e,r)=>s(e,r,t)));e.exports=sort},9601:(e,t,r)=>{const s=r(5925);const valid=(e,t)=>{const r=s(e,t);return r?r.version:null};e.exports=valid},1383:(e,t,r)=>{const s=r(9523);const i=r(2293);const n=r(8088);const o=r(2463);const a=r(5925);const l=r(9601);const u=r(8848);const h=r(900);const f=r(4297);const p=r(6688);const d=r(8447);const m=r(2866);const g=r(4016);const y=r(4309);const b=r(6417);const _=r(2804);const v=r(2156);const w=r(1426);const E=r(8701);const S=r(4123);const x=r(194);const R=r(1898);const A=r(6017);const C=r(5522);const O=r(7520);const k=r(5098);const T=r(3466);const P=r(1532);const I=r(9828);const $=r(6055);const L=r(2706);const N=r(579);const M=r(832);const D=r(4179);const j=r(2098);const B=r(420);const F=r(9380);const H=r(3323);const G=r(7008);const W=r(5297);const U=r(7863);e.exports={parse:a,valid:l,clean:u,inc:h,diff:f,major:p,minor:d,patch:m,prerelease:g,compare:y,rcompare:b,compareLoose:_,compareBuild:v,sort:w,rsort:E,gt:S,lt:x,eq:R,neq:A,gte:C,lte:O,cmp:k,coerce:T,Comparator:P,Range:I,satisfies:$,toComparators:L,maxSatisfying:N,minSatisfying:M,minVersion:D,validRange:j,outside:B,gtr:F,ltr:H,intersects:G,simplifyRange:W,subset:U,SemVer:n,re:s.re,src:s.src,tokens:s.t,SEMVER_SPEC_VERSION:i.SEMVER_SPEC_VERSION,compareIdentifiers:o.compareIdentifiers,rcompareIdentifiers:o.rcompareIdentifiers}},2293:e=>{const t="2.0.0";const r=256;const s=Number.MAX_SAFE_INTEGER||9007199254740991;const i=16;e.exports={SEMVER_SPEC_VERSION:t,MAX_LENGTH:r,MAX_SAFE_INTEGER:s,MAX_SAFE_COMPONENT_LENGTH:i}},427:e=>{const t=typeof process==="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};e.exports=t},2463:e=>{const t=/^[0-9]+$/;const compareIdentifiers=(e,r)=>{const s=t.test(e);const i=t.test(r);if(s&&i){e=+e;r=+r}return e===r?0:s&&!i?-1:i&&!s?1:e<r?-1:1};const rcompareIdentifiers=(e,t)=>compareIdentifiers(t,e);e.exports={compareIdentifiers:compareIdentifiers,rcompareIdentifiers:rcompareIdentifiers}},785:e=>{const t=["includePrerelease","loose","rtl"];const parseOptions=e=>!e?{}:typeof e!=="object"?{loose:true}:t.filter((t=>e[t])).reduce(((e,t)=>{e[t]=true;return e}),{});e.exports=parseOptions},9523:(e,t,r)=>{const{MAX_SAFE_COMPONENT_LENGTH:s}=r(2293);const i=r(427);t=e.exports={};const n=t.re=[];const o=t.src=[];const a=t.t={};let l=0;const createToken=(e,t,r)=>{const s=l++;i(e,s,t);a[e]=s;o[s]=t;n[s]=new RegExp(t,r?"g":undefined)};createToken("NUMERICIDENTIFIER","0|[1-9]\\d*");createToken("NUMERICIDENTIFIERLOOSE","[0-9]+");createToken("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");createToken("MAINVERSION",`(${o[a.NUMERICIDENTIFIER]})\\.`+`(${o[a.NUMERICIDENTIFIER]})\\.`+`(${o[a.NUMERICIDENTIFIER]})`);createToken("MAINVERSIONLOOSE",`(${o[a.NUMERICIDENTIFIERLOOSE]})\\.`+`(${o[a.NUMERICIDENTIFIERLOOSE]})\\.`+`(${o[a.NUMERICIDENTIFIERLOOSE]})`);createToken("PRERELEASEIDENTIFIER",`(?:${o[a.NUMERICIDENTIFIER]}|${o[a.NONNUMERICIDENTIFIER]})`);createToken("PRERELEASEIDENTIFIERLOOSE",`(?:${o[a.NUMERICIDENTIFIERLOOSE]}|${o[a.NONNUMERICIDENTIFIER]})`);createToken("PRERELEASE",`(?:-(${o[a.PRERELEASEIDENTIFIER]}(?:\\.${o[a.PRERELEASEIDENTIFIER]})*))`);createToken("PRERELEASELOOSE",`(?:-?(${o[a.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${o[a.PRERELEASEIDENTIFIERLOOSE]})*))`);createToken("BUILDIDENTIFIER","[0-9A-Za-z-]+");createToken("BUILD",`(?:\\+(${o[a.BUILDIDENTIFIER]}(?:\\.${o[a.BUILDIDENTIFIER]})*))`);createToken("FULLPLAIN",`v?${o[a.MAINVERSION]}${o[a.PRERELEASE]}?${o[a.BUILD]}?`);createToken("FULL",`^${o[a.FULLPLAIN]}$`);createToken("LOOSEPLAIN",`[v=\\s]*${o[a.MAINVERSIONLOOSE]}${o[a.PRERELEASELOOSE]}?${o[a.BUILD]}?`);createToken("LOOSE",`^${o[a.LOOSEPLAIN]}$`);createToken("GTLT","((?:<|>)?=?)");createToken("XRANGEIDENTIFIERLOOSE",`${o[a.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);createToken("XRANGEIDENTIFIER",`${o[a.NUMERICIDENTIFIER]}|x|X|\\*`);createToken("XRANGEPLAIN",`[v=\\s]*(${o[a.XRANGEIDENTIFIER]})`+`(?:\\.(${o[a.XRANGEIDENTIFIER]})`+`(?:\\.(${o[a.XRANGEIDENTIFIER]})`+`(?:${o[a.PRERELEASE]})?${o[a.BUILD]}?`+`)?)?`);createToken("XRANGEPLAINLOOSE",`[v=\\s]*(${o[a.XRANGEIDENTIFIERLOOSE]})`+`(?:\\.(${o[a.XRANGEIDENTIFIERLOOSE]})`+`(?:\\.(${o[a.XRANGEIDENTIFIERLOOSE]})`+`(?:${o[a.PRERELEASELOOSE]})?${o[a.BUILD]}?`+`)?)?`);createToken("XRANGE",`^${o[a.GTLT]}\\s*${o[a.XRANGEPLAIN]}$`);createToken("XRANGELOOSE",`^${o[a.GTLT]}\\s*${o[a.XRANGEPLAINLOOSE]}$`);createToken("COERCE",`${"(^|[^\\d])"+"(\\d{1,"}${s}})`+`(?:\\.(\\d{1,${s}}))?`+`(?:\\.(\\d{1,${s}}))?`+`(?:$|[^\\d])`);createToken("COERCERTL",o[a.COERCE],true);createToken("LONETILDE","(?:~>?)");createToken("TILDETRIM",`(\\s*)${o[a.LONETILDE]}\\s+`,true);t.tildeTrimReplace="$1~";createToken("TILDE",`^${o[a.LONETILDE]}${o[a.XRANGEPLAIN]}$`);createToken("TILDELOOSE",`^${o[a.LONETILDE]}${o[a.XRANGEPLAINLOOSE]}$`);createToken("LONECARET","(?:\\^)");createToken("CARETTRIM",`(\\s*)${o[a.LONECARET]}\\s+`,true);t.caretTrimReplace="$1^";createToken("CARET",`^${o[a.LONECARET]}${o[a.XRANGEPLAIN]}$`);createToken("CARETLOOSE",`^${o[a.LONECARET]}${o[a.XRANGEPLAINLOOSE]}$`);createToken("COMPARATORLOOSE",`^${o[a.GTLT]}\\s*(${o[a.LOOSEPLAIN]})$|^$`);createToken("COMPARATOR",`^${o[a.GTLT]}\\s*(${o[a.FULLPLAIN]})$|^$`);createToken("COMPARATORTRIM",`(\\s*)${o[a.GTLT]}\\s*(${o[a.LOOSEPLAIN]}|${o[a.XRANGEPLAIN]})`,true);t.comparatorTrimReplace="$1$2$3";createToken("HYPHENRANGE",`^\\s*(${o[a.XRANGEPLAIN]})`+`\\s+-\\s+`+`(${o[a.XRANGEPLAIN]})`+`\\s*$`);createToken("HYPHENRANGELOOSE",`^\\s*(${o[a.XRANGEPLAINLOOSE]})`+`\\s+-\\s+`+`(${o[a.XRANGEPLAINLOOSE]})`+`\\s*$`);createToken("STAR","(<|>)?=?\\s*\\*");createToken("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");createToken("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")},9380:(e,t,r)=>{const s=r(420);const gtr=(e,t,r)=>s(e,t,">",r);e.exports=gtr},7008:(e,t,r)=>{const s=r(9828);const intersects=(e,t,r)=>{e=new s(e,r);t=new s(t,r);return e.intersects(t)};e.exports=intersects},3323:(e,t,r)=>{const s=r(420);const ltr=(e,t,r)=>s(e,t,"<",r);e.exports=ltr},579:(e,t,r)=>{const s=r(8088);const i=r(9828);const maxSatisfying=(e,t,r)=>{let n=null;let o=null;let a=null;try{a=new i(t,r)}catch(e){return null}e.forEach((e=>{if(a.test(e)){if(!n||o.compare(e)===-1){n=e;o=new s(n,r)}}}));return n};e.exports=maxSatisfying},832:(e,t,r)=>{const s=r(8088);const i=r(9828);const minSatisfying=(e,t,r)=>{let n=null;let o=null;let a=null;try{a=new i(t,r)}catch(e){return null}e.forEach((e=>{if(a.test(e)){if(!n||o.compare(e)===1){n=e;o=new s(n,r)}}}));return n};e.exports=minSatisfying},4179:(e,t,r)=>{const s=r(8088);const i=r(9828);const n=r(4123);const minVersion=(e,t)=>{e=new i(e,t);let r=new s("0.0.0");if(e.test(r)){return r}r=new s("0.0.0-0");if(e.test(r)){return r}r=null;for(let t=0;t<e.set.length;++t){const i=e.set[t];let o=null;i.forEach((e=>{const t=new s(e.semver.version);switch(e.operator){case">":if(t.prerelease.length===0){t.patch++}else{t.prerelease.push(0)}t.raw=t.format();case"":case">=":if(!o||n(t,o)){o=t}break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${e.operator}`)}}));if(o&&(!r||n(r,o))){r=o}}if(r&&e.test(r)){return r}return null};e.exports=minVersion},420:(e,t,r)=>{const s=r(8088);const i=r(1532);const{ANY:n}=i;const o=r(9828);const a=r(6055);const l=r(4123);const u=r(194);const h=r(7520);const f=r(5522);const outside=(e,t,r,p)=>{e=new s(e,p);t=new o(t,p);let d,m,g,y,b;switch(r){case">":d=l;m=h;g=u;y=">";b=">=";break;case"<":d=u;m=f;g=l;y="<";b="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(a(e,t,p)){return false}for(let r=0;r<t.set.length;++r){const s=t.set[r];let o=null;let a=null;s.forEach((e=>{if(e.semver===n){e=new i(">=0.0.0")}o=o||e;a=a||e;if(d(e.semver,o.semver,p)){o=e}else if(g(e.semver,a.semver,p)){a=e}}));if(o.operator===y||o.operator===b){return false}if((!a.operator||a.operator===y)&&m(e,a.semver)){return false}else if(a.operator===b&&g(e,a.semver)){return false}}return true};e.exports=outside},5297:(e,t,r)=>{const s=r(6055);const i=r(4309);e.exports=(e,t,r)=>{const n=[];let o=null;let a=null;const l=e.sort(((e,t)=>i(e,t,r)));for(const e of l){const i=s(e,t,r);if(i){a=e;if(!o){o=e}}else{if(a){n.push([o,a])}a=null;o=null}}if(o){n.push([o,null])}const u=[];for(const[e,t]of n){if(e===t){u.push(e)}else if(!t&&e===l[0]){u.push("*")}else if(!t){u.push(`>=${e}`)}else if(e===l[0]){u.push(`<=${t}`)}else{u.push(`${e} - ${t}`)}}const h=u.join(" || ");const f=typeof t.raw==="string"?t.raw:String(t);return h.length<f.length?h:t}},7863:(e,t,r)=>{const s=r(9828);const i=r(1532);const{ANY:n}=i;const o=r(6055);const a=r(4309);const subset=(e,t,r={})=>{if(e===t){return true}e=new s(e,r);t=new s(t,r);let i=false;e:for(const s of e.set){for(const e of t.set){const t=simpleSubset(s,e,r);i=i||t!==null;if(t){continue e}}if(i){return false}}return true};const simpleSubset=(e,t,r)=>{if(e===t){return true}if(e.length===1&&e[0].semver===n){if(t.length===1&&t[0].semver===n){return true}else if(r.includePrerelease){e=[new i(">=0.0.0-0")]}else{e=[new i(">=0.0.0")]}}if(t.length===1&&t[0].semver===n){if(r.includePrerelease){return true}else{t=[new i(">=0.0.0")]}}const s=new Set;let l,u;for(const t of e){if(t.operator===">"||t.operator===">="){l=higherGT(l,t,r)}else if(t.operator==="<"||t.operator==="<="){u=lowerLT(u,t,r)}else{s.add(t.semver)}}if(s.size>1){return null}let h;if(l&&u){h=a(l.semver,u.semver,r);if(h>0){return null}else if(h===0&&(l.operator!==">="||u.operator!=="<=")){return null}}for(const e of s){if(l&&!o(e,String(l),r)){return null}if(u&&!o(e,String(u),r)){return null}for(const s of t){if(!o(e,String(s),r)){return false}}return true}let f,p;let d,m;let g=u&&!r.includePrerelease&&u.semver.prerelease.length?u.semver:false;let y=l&&!r.includePrerelease&&l.semver.prerelease.length?l.semver:false;if(g&&g.prerelease.length===1&&u.operator==="<"&&g.prerelease[0]===0){g=false}for(const e of t){m=m||e.operator===">"||e.operator===">=";d=d||e.operator==="<"||e.operator==="<=";if(l){if(y){if(e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===y.major&&e.semver.minor===y.minor&&e.semver.patch===y.patch){y=false}}if(e.operator===">"||e.operator===">="){f=higherGT(l,e,r);if(f===e&&f!==l){return false}}else if(l.operator===">="&&!o(l.semver,String(e),r)){return false}}if(u){if(g){if(e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===g.major&&e.semver.minor===g.minor&&e.semver.patch===g.patch){g=false}}if(e.operator==="<"||e.operator==="<="){p=lowerLT(u,e,r);if(p===e&&p!==u){return false}}else if(u.operator==="<="&&!o(u.semver,String(e),r)){return false}}if(!e.operator&&(u||l)&&h!==0){return false}}if(l&&d&&!u&&h!==0){return false}if(u&&m&&!l&&h!==0){return false}if(y||g){return false}return true};const higherGT=(e,t,r)=>{if(!e){return t}const s=a(e.semver,t.semver,r);return s>0?e:s<0?t:t.operator===">"&&e.operator===">="?t:e};const lowerLT=(e,t,r)=>{if(!e){return t}const s=a(e.semver,t.semver,r);return s<0?e:s>0?t:t.operator==="<"&&e.operator==="<="?t:e};e.exports=subset},2706:(e,t,r)=>{const s=r(9828);const toComparators=(e,t)=>new s(e,t).set.map((e=>e.map((e=>e.value)).join(" ").trim().split(" ")));e.exports=toComparators},2098:(e,t,r)=>{const s=r(9828);const validRange=(e,t)=>{try{return new s(e,t).range||"*"}catch(e){return null}};e.exports=validRange},7032:(e,t,r)=>{"use strict";const s=r(2638);e.exports=(e="")=>{const t=e.match(s);if(!t){return null}const[r,i]=t[0].replace(/#! ?/,"").split(" ");const n=r.split("/").pop();if(n==="env"){return i}return i?`${n} ${i}`:n}},2638:e=>{"use strict";e.exports=/^#!(.*)/},4931:(e,t,r)=>{var s=global.process;const processOk=function(e){return e&&typeof e==="object"&&typeof e.removeListener==="function"&&typeof e.emit==="function"&&typeof e.reallyExit==="function"&&typeof e.listeners==="function"&&typeof e.kill==="function"&&typeof e.pid==="number"&&typeof e.on==="function"};if(!processOk(s)){e.exports=function(){return function(){}}}else{var i=r(9491);var n=r(3710);var o=/^win/i.test(s.platform);var a=r(2361);if(typeof a!=="function"){a=a.EventEmitter}var l;if(s.__signal_exit_emitter__){l=s.__signal_exit_emitter__}else{l=s.__signal_exit_emitter__=new a;l.count=0;l.emitted={}}if(!l.infinite){l.setMaxListeners(Infinity);l.infinite=true}e.exports=function(e,t){if(!processOk(global.process)){return function(){}}i.equal(typeof e,"function","a callback must be provided for exit handler");if(p===false){d()}var r="exit";if(t&&t.alwaysLast){r="afterexit"}var remove=function(){l.removeListener(r,e);if(l.listeners("exit").length===0&&l.listeners("afterexit").length===0){u()}};l.on(r,e);return remove};var u=function unload(){if(!p||!processOk(global.process)){return}p=false;n.forEach((function(e){try{s.removeListener(e,f[e])}catch(e){}}));s.emit=y;s.reallyExit=m;l.count-=1};e.exports.unload=u;var h=function emit(e,t,r){if(l.emitted[e]){return}l.emitted[e]=true;l.emit(e,t,r)};var f={};n.forEach((function(e){f[e]=function listener(){if(!processOk(global.process)){return}var t=s.listeners(e);if(t.length===l.count){u();h("exit",null,e);h("afterexit",null,e);if(o&&e==="SIGHUP"){e="SIGINT"}s.kill(s.pid,e)}}}));e.exports.signals=function(){return n};var p=false;var d=function load(){if(p||!processOk(global.process)){return}p=true;l.count+=1;n=n.filter((function(e){try{s.on(e,f[e]);return true}catch(e){return false}}));s.emit=b;s.reallyExit=g};e.exports.load=d;var m=s.reallyExit;var g=function processReallyExit(e){if(!processOk(global.process)){return}s.exitCode=e||0;h("exit",s.exitCode,null);h("afterexit",s.exitCode,null);m.call(s,s.exitCode)};var y=s.emit;var b=function processEmit(e,t){if(e==="exit"&&processOk(global.process)){if(t!==undefined){s.exitCode=t}var r=y.apply(this,arguments);h("exit",s.exitCode,null);h("afterexit",s.exitCode,null);return r}else{return y.apply(this,arguments)}}}},3710:e=>{e.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"];if(process.platform!=="win32"){e.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT")}if(process.platform==="linux"){e.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")}},4841:(e,t,r)=>{"use strict";var s=r(1867).Buffer;var i=s.isEncoding||function(e){e=""+e;switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return true;default:return false}};function _normalizeEncoding(e){if(!e)return"utf8";var t;while(true){switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase();t=true}}}function normalizeEncoding(e){var t=_normalizeEncoding(e);if(typeof t!=="string"&&(s.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}t.s=StringDecoder;function StringDecoder(e){this.encoding=normalizeEncoding(e);var t;switch(this.encoding){case"utf16le":this.text=utf16Text;this.end=utf16End;t=4;break;case"utf8":this.fillLast=utf8FillLast;t=4;break;case"base64":this.text=base64Text;this.end=base64End;t=3;break;default:this.write=simpleWrite;this.end=simpleEnd;return}this.lastNeed=0;this.lastTotal=0;this.lastChar=s.allocUnsafe(t)}StringDecoder.prototype.write=function(e){if(e.length===0)return"";var t;var r;if(this.lastNeed){t=this.fillLast(e);if(t===undefined)return"";r=this.lastNeed;this.lastNeed=0}else{r=0}if(r<e.length)return t?t+this.text(e,r):this.text(e,r);return t||""};StringDecoder.prototype.end=utf8End;StringDecoder.prototype.text=utf8Text;StringDecoder.prototype.fillLast=function(e){if(this.lastNeed<=e.length){e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length);this.lastNeed-=e.length};function utf8CheckByte(e){if(e<=127)return 0;else if(e>>5===6)return 2;else if(e>>4===14)return 3;else if(e>>3===30)return 4;return e>>6===2?-1:-2}function utf8CheckIncomplete(e,t,r){var s=t.length-1;if(s<r)return 0;var i=utf8CheckByte(t[s]);if(i>=0){if(i>0)e.lastNeed=i-1;return i}if(--s<r||i===-2)return 0;i=utf8CheckByte(t[s]);if(i>=0){if(i>0)e.lastNeed=i-2;return i}if(--s<r||i===-2)return 0;i=utf8CheckByte(t[s]);if(i>=0){if(i>0){if(i===2)i=0;else e.lastNeed=i-3}return i}return 0}function utf8CheckExtraBytes(e,t,r){if((t[0]&192)!==128){e.lastNeed=0;return"�"}if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128){e.lastNeed=1;return"�"}if(e.lastNeed>2&&t.length>2){if((t[2]&192)!==128){e.lastNeed=2;return"�"}}}}function utf8FillLast(e){var t=this.lastTotal-this.lastNeed;var r=utf8CheckExtraBytes(this,e,t);if(r!==undefined)return r;if(this.lastNeed<=e.length){e.copy(this.lastChar,t,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,t,0,e.length);this.lastNeed-=e.length}function utf8Text(e,t){var r=utf8CheckIncomplete(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var s=e.length-(r-this.lastNeed);e.copy(this.lastChar,0,s);return e.toString("utf8",t,s)}function utf8End(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed)return t+"�";return t}function utf16Text(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var s=r.charCodeAt(r.length-1);if(s>=55296&&s<=56319){this.lastNeed=2;this.lastTotal=4;this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1];return r.slice(0,-1)}}return r}this.lastNeed=1;this.lastTotal=2;this.lastChar[0]=e[e.length-1];return e.toString("utf16le",t,e.length-1)}function utf16End(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function base64Text(e,t){var r=(e.length-t)%3;if(r===0)return e.toString("base64",t);this.lastNeed=3-r;this.lastTotal=3;if(r===1){this.lastChar[0]=e[e.length-1]}else{this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1]}return e.toString("base64",t,e.length-r)}function base64End(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed)return t+this.lastChar.toString("base64",0,3-this.lastNeed);return t}function simpleWrite(e){return e.toString(this.encoding)}function simpleEnd(e){return e&&e.length?this.write(e):""}},5591:(e,t,r)=>{"use strict";const s=r(5063);e.exports=e=>typeof e==="string"?e.replace(s(),""):e},8174:e=>{"use strict";e.exports=e=>{const t=typeof e==="string"?"\n":"\n".charCodeAt();const r=typeof e==="string"?"\r":"\r".charCodeAt();if(e[e.length-1]===t){e=e.slice(0,e.length-1)}if(e[e.length-1]===r){e=e.slice(0,e.length-1)}return e}},9318:(e,t,r)=>{"use strict";const s=r(2037);const i=r(6224);const n=r(1621);const{env:o}=process;let a;if(n("no-color")||n("no-colors")||n("color=false")||n("color=never")){a=0}else if(n("color")||n("colors")||n("color=true")||n("color=always")){a=1}if("FORCE_COLOR"in o){if(o.FORCE_COLOR==="true"){a=1}else if(o.FORCE_COLOR==="false"){a=0}else{a=o.FORCE_COLOR.length===0?1:Math.min(parseInt(o.FORCE_COLOR,10),3)}}function translateLevel(e){if(e===0){return false}return{level:e,hasBasic:true,has256:e>=2,has16m:e>=3}}function supportsColor(e,t){if(a===0){return 0}if(n("color=16m")||n("color=full")||n("color=truecolor")){return 3}if(n("color=256")){return 2}if(e&&!t&&a===undefined){return 0}const r=a||0;if(o.TERM==="dumb"){return r}if(process.platform==="win32"){const e=s.release().split(".");if(Number(e[0])>=10&&Number(e[2])>=10586){return Number(e[2])>=14931?3:2}return 1}if("CI"in o){if(["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((e=>e in o))||o.CI_NAME==="codeship"){return 1}return r}if("TEAMCITY_VERSION"in o){return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(o.TEAMCITY_VERSION)?1:0}if(o.COLORTERM==="truecolor"){return 3}if("TERM_PROGRAM"in o){const e=parseInt((o.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(o.TERM_PROGRAM){case"iTerm.app":return e>=3?3:2;case"Apple_Terminal":return 2}}if(/-256(color)?$/i.test(o.TERM)){return 2}if(/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(o.TERM)){return 1}if("COLORTERM"in o){return 1}return r}function getSupportLevel(e){const t=supportsColor(e,e&&e.isTTY);return translateLevel(t)}e.exports={supportsColor:getSupportLevel,stdout:translateLevel(supportsColor(true,i.isatty(1))),stderr:translateLevel(supportsColor(true,i.isatty(2)))}},1861:(e,t,r)=>{"use strict";
|
|
34
|
+
var i=r(181);var n=i.Buffer;function copyProps(e,t){for(var r in e){t[r]=e[r]}}if(n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow){e.exports=i}else{copyProps(i,t);t.Buffer=SafeBuffer}function SafeBuffer(e,t,r){return n(e,t,r)}SafeBuffer.prototype=Object.create(n.prototype);copyProps(n,SafeBuffer);SafeBuffer.from=function(e,t,r){if(typeof e==="number"){throw new TypeError("Argument must not be a number")}return n(e,t,r)};SafeBuffer.alloc=function(e,t,r){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}var i=n(e);if(t!==undefined){if(typeof r==="string"){i.fill(t,r)}else{i.fill(t)}}else{i.fill(0)}return i};SafeBuffer.allocUnsafe=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return n(e)};SafeBuffer.allocUnsafeSlow=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return i.SlowBuffer(e)}},9152:(e,t,r)=>{"use strict";const i=r(7334);e.exports=(e="")=>{const t=e.match(i);if(!t){return null}const[r,n]=t[0].replace(/#! ?/,"").split(" ");const s=r.split("/").pop();if(s==="env"){return n}return n?`${s} ${n}`:s}},7334:e=>{"use strict";e.exports=/^#!(.*)/},6627:(e,t,r)=>{var i=global.process;const processOk=function(e){return e&&typeof e==="object"&&typeof e.removeListener==="function"&&typeof e.emit==="function"&&typeof e.reallyExit==="function"&&typeof e.listeners==="function"&&typeof e.kill==="function"&&typeof e.pid==="number"&&typeof e.on==="function"};if(!processOk(i)){e.exports=function(){return function(){}}}else{var n=r(2613);var s=r(1430);var o=/^win/i.test(i.platform);var a=r(4434);if(typeof a!=="function"){a=a.EventEmitter}var l;if(i.__signal_exit_emitter__){l=i.__signal_exit_emitter__}else{l=i.__signal_exit_emitter__=new a;l.count=0;l.emitted={}}if(!l.infinite){l.setMaxListeners(Infinity);l.infinite=true}e.exports=function(e,t){if(!processOk(global.process)){return function(){}}n.equal(typeof e,"function","a callback must be provided for exit handler");if(p===false){d()}var r="exit";if(t&&t.alwaysLast){r="afterexit"}var remove=function(){l.removeListener(r,e);if(l.listeners("exit").length===0&&l.listeners("afterexit").length===0){u()}};l.on(r,e);return remove};var u=function unload(){if(!p||!processOk(global.process)){return}p=false;s.forEach((function(e){try{i.removeListener(e,f[e])}catch(e){}}));i.emit=y;i.reallyExit=m;l.count-=1};e.exports.unload=u;var h=function emit(e,t,r){if(l.emitted[e]){return}l.emitted[e]=true;l.emit(e,t,r)};var f={};s.forEach((function(e){f[e]=function listener(){if(!processOk(global.process)){return}var t=i.listeners(e);if(t.length===l.count){u();h("exit",null,e);h("afterexit",null,e);if(o&&e==="SIGHUP"){e="SIGINT"}i.kill(i.pid,e)}}}));e.exports.signals=function(){return s};var p=false;var d=function load(){if(p||!processOk(global.process)){return}p=true;l.count+=1;s=s.filter((function(e){try{i.on(e,f[e]);return true}catch(e){return false}}));i.emit=b;i.reallyExit=g};e.exports.load=d;var m=i.reallyExit;var g=function processReallyExit(e){if(!processOk(global.process)){return}i.exitCode=e||0;h("exit",i.exitCode,null);h("afterexit",i.exitCode,null);m.call(i,i.exitCode)};var y=i.emit;var b=function processEmit(e,t){if(e==="exit"&&processOk(global.process)){if(t!==undefined){i.exitCode=t}var r=y.apply(this,arguments);h("exit",i.exitCode,null);h("afterexit",i.exitCode,null);return r}else{return y.apply(this,arguments)}}}},1430:e=>{e.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"];if(process.platform!=="win32"){e.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT")}if(process.platform==="linux"){e.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")}},634:(e,t,r)=>{"use strict";var i=r(3058).Buffer;var n=i.isEncoding||function(e){e=""+e;switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return true;default:return false}};function _normalizeEncoding(e){if(!e)return"utf8";var t;while(true){switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase();t=true}}}function normalizeEncoding(e){var t=_normalizeEncoding(e);if(typeof t!=="string"&&(i.isEncoding===n||!n(e)))throw new Error("Unknown encoding: "+e);return t||e}t.I=StringDecoder;function StringDecoder(e){this.encoding=normalizeEncoding(e);var t;switch(this.encoding){case"utf16le":this.text=utf16Text;this.end=utf16End;t=4;break;case"utf8":this.fillLast=utf8FillLast;t=4;break;case"base64":this.text=base64Text;this.end=base64End;t=3;break;default:this.write=simpleWrite;this.end=simpleEnd;return}this.lastNeed=0;this.lastTotal=0;this.lastChar=i.allocUnsafe(t)}StringDecoder.prototype.write=function(e){if(e.length===0)return"";var t;var r;if(this.lastNeed){t=this.fillLast(e);if(t===undefined)return"";r=this.lastNeed;this.lastNeed=0}else{r=0}if(r<e.length)return t?t+this.text(e,r):this.text(e,r);return t||""};StringDecoder.prototype.end=utf8End;StringDecoder.prototype.text=utf8Text;StringDecoder.prototype.fillLast=function(e){if(this.lastNeed<=e.length){e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length);this.lastNeed-=e.length};function utf8CheckByte(e){if(e<=127)return 0;else if(e>>5===6)return 2;else if(e>>4===14)return 3;else if(e>>3===30)return 4;return e>>6===2?-1:-2}function utf8CheckIncomplete(e,t,r){var i=t.length-1;if(i<r)return 0;var n=utf8CheckByte(t[i]);if(n>=0){if(n>0)e.lastNeed=n-1;return n}if(--i<r||n===-2)return 0;n=utf8CheckByte(t[i]);if(n>=0){if(n>0)e.lastNeed=n-2;return n}if(--i<r||n===-2)return 0;n=utf8CheckByte(t[i]);if(n>=0){if(n>0){if(n===2)n=0;else e.lastNeed=n-3}return n}return 0}function utf8CheckExtraBytes(e,t,r){if((t[0]&192)!==128){e.lastNeed=0;return"�"}if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128){e.lastNeed=1;return"�"}if(e.lastNeed>2&&t.length>2){if((t[2]&192)!==128){e.lastNeed=2;return"�"}}}}function utf8FillLast(e){var t=this.lastTotal-this.lastNeed;var r=utf8CheckExtraBytes(this,e,t);if(r!==undefined)return r;if(this.lastNeed<=e.length){e.copy(this.lastChar,t,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,t,0,e.length);this.lastNeed-=e.length}function utf8Text(e,t){var r=utf8CheckIncomplete(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var i=e.length-(r-this.lastNeed);e.copy(this.lastChar,0,i);return e.toString("utf8",t,i)}function utf8End(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed)return t+"�";return t}function utf16Text(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319){this.lastNeed=2;this.lastTotal=4;this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1];return r.slice(0,-1)}}return r}this.lastNeed=1;this.lastTotal=2;this.lastChar[0]=e[e.length-1];return e.toString("utf16le",t,e.length-1)}function utf16End(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function base64Text(e,t){var r=(e.length-t)%3;if(r===0)return e.toString("base64",t);this.lastNeed=3-r;this.lastTotal=3;if(r===1){this.lastChar[0]=e[e.length-1]}else{this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1]}return e.toString("base64",t,e.length-r)}function base64End(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed)return t+this.lastChar.toString("base64",0,3-this.lastNeed);return t}function simpleWrite(e){return e.toString(this.encoding)}function simpleEnd(e){return e&&e.length?this.write(e):""}},3958:(e,t,r)=>{"use strict";const i=r(21);e.exports=e=>typeof e==="string"?e.replace(i(),""):e},1414:e=>{"use strict";e.exports=e=>{const t=typeof e==="string"?"\n":"\n".charCodeAt();const r=typeof e==="string"?"\r":"\r".charCodeAt();if(e[e.length-1]===t){e=e.slice(0,e.length-1)}if(e[e.length-1]===r){e=e.slice(0,e.length-1)}return e}},1450:(e,t,r)=>{"use strict";const i=r(857);const n=r(2018);const s=r(3813);const{env:o}=process;let a;if(s("no-color")||s("no-colors")||s("color=false")||s("color=never")){a=0}else if(s("color")||s("colors")||s("color=true")||s("color=always")){a=1}if("FORCE_COLOR"in o){if(o.FORCE_COLOR==="true"){a=1}else if(o.FORCE_COLOR==="false"){a=0}else{a=o.FORCE_COLOR.length===0?1:Math.min(parseInt(o.FORCE_COLOR,10),3)}}function translateLevel(e){if(e===0){return false}return{level:e,hasBasic:true,has256:e>=2,has16m:e>=3}}function supportsColor(e,t){if(a===0){return 0}if(s("color=16m")||s("color=full")||s("color=truecolor")){return 3}if(s("color=256")){return 2}if(e&&!t&&a===undefined){return 0}const r=a||0;if(o.TERM==="dumb"){return r}if(process.platform==="win32"){const e=i.release().split(".");if(Number(e[0])>=10&&Number(e[2])>=10586){return Number(e[2])>=14931?3:2}return 1}if("CI"in o){if(["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((e=>e in o))||o.CI_NAME==="codeship"){return 1}return r}if("TEAMCITY_VERSION"in o){return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(o.TEAMCITY_VERSION)?1:0}if(o.COLORTERM==="truecolor"){return 3}if("TERM_PROGRAM"in o){const e=parseInt((o.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(o.TERM_PROGRAM){case"iTerm.app":return e>=3?3:2;case"Apple_Terminal":return 2}}if(/-256(color)?$/i.test(o.TERM)){return 2}if(/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(o.TERM)){return 1}if("COLORTERM"in o){return 1}return r}function getSupportLevel(e){const t=supportsColor(e,e&&e.isTTY);return translateLevel(t)}e.exports={supportsColor:getSupportLevel,stdout:translateLevel(supportsColor(true,n.isatty(1))),stderr:translateLevel(supportsColor(true,n.isatty(2)))}},7551:(e,t,r)=>{"use strict";
|
|
35
35
|
/*!
|
|
36
36
|
* to-regex-range <https://github.com/micromatch/to-regex-range>
|
|
37
37
|
*
|
|
38
38
|
* Copyright (c) 2015-present, Jon Schlinkert.
|
|
39
39
|
* Released under the MIT License.
|
|
40
|
-
*/const s=r(5680);const toRegexRange=(e,t,r)=>{if(s(e)===false){throw new TypeError("toRegexRange: expected the first argument to be a number")}if(t===void 0||e===t){return String(e)}if(s(t)===false){throw new TypeError("toRegexRange: expected the second argument to be a number.")}let i={relaxZeros:true,...r};if(typeof i.strictZeros==="boolean"){i.relaxZeros=i.strictZeros===false}let n=String(i.relaxZeros);let o=String(i.shorthand);let a=String(i.capture);let l=String(i.wrap);let u=e+":"+t+"="+n+o+a+l;if(toRegexRange.cache.hasOwnProperty(u)){return toRegexRange.cache[u].result}let h=Math.min(e,t);let f=Math.max(e,t);if(Math.abs(h-f)===1){let r=e+"|"+t;if(i.capture){return`(${r})`}if(i.wrap===false){return r}return`(?:${r})`}let p=hasPadding(e)||hasPadding(t);let d={min:e,max:t,a:h,b:f};let m=[];let g=[];if(p){d.isPadded=p;d.maxLen=String(d.max).length}if(h<0){let e=f<0?Math.abs(f):1;g=splitToPatterns(e,Math.abs(h),d,i);h=d.a=0}if(f>=0){m=splitToPatterns(h,f,d,i)}d.negatives=g;d.positives=m;d.result=collatePatterns(g,m,i);if(i.capture===true){d.result=`(${d.result})`}else if(i.wrap!==false&&m.length+g.length>1){d.result=`(?:${d.result})`}toRegexRange.cache[u]=d;return d.result};function collatePatterns(e,t,r){let s=filterPatterns(e,t,"-",false,r)||[];let i=filterPatterns(t,e,"",false,r)||[];let n=filterPatterns(e,t,"-?",true,r)||[];let o=s.concat(n).concat(i);return o.join("|")}function splitToRanges(e,t){let r=1;let s=1;let i=countNines(e,r);let n=new Set([t]);while(e<=i&&i<=t){n.add(i);r+=1;i=countNines(e,r)}i=countZeros(t+1,s)-1;while(e<i&&i<=t){n.add(i);s+=1;i=countZeros(t+1,s)-1}n=[...n];n.sort(compare);return n}function rangeToPattern(e,t,r){if(e===t){return{pattern:e,count:[],digits:0}}let s=zip(e,t);let i=s.length;let n="";let o=0;for(let e=0;e<i;e++){let[t,i]=s[e];if(t===i){n+=t}else if(t!=="0"||i!=="9"){n+=toCharacterClass(t,i,r)}else{o++}}if(o){n+=r.shorthand===true?"\\d":"[0-9]"}return{pattern:n,count:[o],digits:i}}function splitToPatterns(e,t,r,s){let i=splitToRanges(e,t);let n=[];let o=e;let a;for(let e=0;e<i.length;e++){let t=i[e];let l=rangeToPattern(String(o),String(t),s);let u="";if(!r.isPadded&&a&&a.pattern===l.pattern){if(a.count.length>1){a.count.pop()}a.count.push(l.count[0]);a.string=a.pattern+toQuantifier(a.count);o=t+1;continue}if(r.isPadded){u=padZeros(t,r,s)}l.string=u+l.pattern+toQuantifier(l.count);n.push(l);o=t+1;a=l}return n}function filterPatterns(e,t,r,s,i){let n=[];for(let i of e){let{string:e}=i;if(!s&&!contains(t,"string",e)){n.push(r+e)}if(s&&contains(t,"string",e)){n.push(r+e)}}return n}function zip(e,t){let r=[];for(let s=0;s<e.length;s++)r.push([e[s],t[s]]);return r}function compare(e,t){return e>t?1:t>e?-1:0}function contains(e,t,r){return e.some((e=>e[t]===r))}function countNines(e,t){return Number(String(e).slice(0,-t)+"9".repeat(t))}function countZeros(e,t){return e-e%Math.pow(10,t)}function toQuantifier(e){let[t=0,r=""]=e;if(r||t>1){return`{${t+(r?","+r:"")}}`}return""}function toCharacterClass(e,t,r){return`[${e}${t-e===1?"":"-"}${t}]`}function hasPadding(e){return/^-?(0+)\d/.test(e)}function padZeros(e,t,r){if(!t.isPadded){return e}let s=Math.abs(t.maxLen-String(e).length);let i=r.relaxZeros!==false;switch(s){case 0:return"";case 1:return i?"0?":"0";case 2:return i?"0{0,2}":"00";default:{return i?`0{0,${s}}`:`0{${s}}`}}}toRegexRange.cache={};toRegexRange.clearCache=()=>toRegexRange.cache={};e.exports=toRegexRange},5278:(e,t,r)=>{e.exports=r(3837).deprecate},4006:(e,t,r)=>{"use strict";var s=new RegExp("^(?:@([^/]+?)[/])?([^/]+?)$");var i=r(3818);var n=["node_modules","favicon.ico"];function validate(e){var t=[];var r=[];if(e===null){r.push("name cannot be null");return done(t,r)}if(e===undefined){r.push("name cannot be undefined");return done(t,r)}if(typeof e!=="string"){r.push("name must be a string");return done(t,r)}if(!e.length){r.push("name length must be greater than zero")}if(e.match(/^\./)){r.push("name cannot start with a period")}if(e.match(/^_/)){r.push("name cannot start with an underscore")}if(e.trim()!==e){r.push("name cannot contain leading or trailing spaces")}n.forEach((function(t){if(e.toLowerCase()===t){r.push(t+" is a blacklisted name")}}));i({version:"*"}).forEach((function(r){if(e.toLowerCase()===r){t.push(r+" is a core module name")}}));if(e.length>214){t.push("name can no longer contain more than 214 characters")}if(e.toLowerCase()!==e){t.push("name can no longer contain capital letters")}if(/[~'!()*]/.test(e.split("/").slice(-1)[0])){t.push('name can no longer contain special characters ("~\'!()*")')}if(encodeURIComponent(e)!==e){var o=e.match(s);if(o){var a=o[1];var l=o[2];if(encodeURIComponent(a)===a&&encodeURIComponent(l)===l){return done(t,r)}}r.push("name can only contain URL-friendly characters")}return done(t,r)}var done=function(e,t){var r={validForNewPackages:t.length===0&&e.length===0,validForOldPackages:t.length===0,warnings:e,errors:t};if(!r.warnings.length){delete r.warnings}if(!r.errors.length){delete r.errors}return r};e.exports=validate},4383:e=>{e.exports=[[768,879],[1155,1158],[1160,1161],[1425,1469],[1471,1471],[1473,1474],[1476,1477],[1479,1479],[1536,1539],[1552,1557],[1611,1630],[1648,1648],[1750,1764],[1767,1768],[1770,1773],[1807,1807],[1809,1809],[1840,1866],[1958,1968],[2027,2035],[2305,2306],[2364,2364],[2369,2376],[2381,2381],[2385,2388],[2402,2403],[2433,2433],[2492,2492],[2497,2500],[2509,2509],[2530,2531],[2561,2562],[2620,2620],[2625,2626],[2631,2632],[2635,2637],[2672,2673],[2689,2690],[2748,2748],[2753,2757],[2759,2760],[2765,2765],[2786,2787],[2817,2817],[2876,2876],[2879,2879],[2881,2883],[2893,2893],[2902,2902],[2946,2946],[3008,3008],[3021,3021],[3134,3136],[3142,3144],[3146,3149],[3157,3158],[3260,3260],[3263,3263],[3270,3270],[3276,3277],[3298,3299],[3393,3395],[3405,3405],[3530,3530],[3538,3540],[3542,3542],[3633,3633],[3636,3642],[3655,3662],[3761,3761],[3764,3769],[3771,3772],[3784,3789],[3864,3865],[3893,3893],[3895,3895],[3897,3897],[3953,3966],[3968,3972],[3974,3975],[3984,3991],[3993,4028],[4038,4038],[4141,4144],[4146,4146],[4150,4151],[4153,4153],[4184,4185],[4448,4607],[4959,4959],[5906,5908],[5938,5940],[5970,5971],[6002,6003],[6068,6069],[6071,6077],[6086,6086],[6089,6099],[6109,6109],[6155,6157],[6313,6313],[6432,6434],[6439,6440],[6450,6450],[6457,6459],[6679,6680],[6912,6915],[6964,6964],[6966,6970],[6972,6972],[6978,6978],[7019,7027],[7616,7626],[7678,7679],[8203,8207],[8234,8238],[8288,8291],[8298,8303],[8400,8431],[12330,12335],[12441,12442],[43014,43014],[43019,43019],[43045,43046],[64286,64286],[65024,65039],[65056,65059],[65279,65279],[65529,65531],[68097,68099],[68101,68102],[68108,68111],[68152,68154],[68159,68159],[119143,119145],[119155,119170],[119173,119179],[119210,119213],[119362,119364],[917505,917505],[917536,917631],[917760,917999]]},5917:(e,t,r)=>{"use strict";var s=r(732);var i=r(4383);var n={nul:0,control:0};e.exports=function wcwidth(e){return wcswidth(e,n)};e.exports.config=function(e){e=s(e||{},n);return function wcwidth(t){return wcswidth(t,e)}};function wcswidth(e,t){if(typeof e!=="string")return wcwidth(e,t);var r=0;for(var s=0;s<e.length;s++){var i=wcwidth(e.charCodeAt(s),t);if(i<0)return-1;r+=i}return r}function wcwidth(e,t){if(e===0)return t.nul;if(e<32||e>=127&&e<160)return t.control;if(bisearch(e))return 0;return 1+(e>=4352&&(e<=4447||e==9001||e==9002||e>=11904&&e<=42191&&e!=12351||e>=44032&&e<=55203||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65135||e>=65280&&e<=65376||e>=65504&&e<=65510||e>=131072&&e<=196605||e>=196608&&e<=262141))}function bisearch(e){var t=0;var r=i.length-1;var s;if(e<i[0][0]||e>i[r][1])return false;while(r>=t){s=Math.floor((t+r)/2);if(e>i[s][1])t=s+1;else if(e<i[s][0])r=s-1;else return true}return false}},4207:(e,t,r)=>{const s=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys";const i=r(1017);const n=s?";":":";const o=r(7126);const getNotFoundError=e=>Object.assign(new Error(`not found: ${e}`),{code:"ENOENT"});const getPathInfo=(e,t)=>{const r=t.colon||n;const i=e.match(/\//)||s&&e.match(/\\/)?[""]:[...s?[process.cwd()]:[],...(t.path||process.env.PATH||"").split(r)];const o=s?t.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"";const a=s?o.split(r):[""];if(s){if(e.indexOf(".")!==-1&&a[0]!=="")a.unshift("")}return{pathEnv:i,pathExt:a,pathExtExe:o}};const which=(e,t,r)=>{if(typeof t==="function"){r=t;t={}}if(!t)t={};const{pathEnv:s,pathExt:n,pathExtExe:a}=getPathInfo(e,t);const l=[];const step=r=>new Promise(((n,o)=>{if(r===s.length)return t.all&&l.length?n(l):o(getNotFoundError(e));const a=s[r];const u=/^".*"$/.test(a)?a.slice(1,-1):a;const h=i.join(u,e);const f=!u&&/^\.[\\\/]/.test(e)?e.slice(0,2)+h:h;n(subStep(f,r,0))}));const subStep=(e,r,s)=>new Promise(((i,u)=>{if(s===n.length)return i(step(r+1));const h=n[s];o(e+h,{pathExt:a},((n,o)=>{if(!n&&o){if(t.all)l.push(e+h);else return i(e+h)}return i(subStep(e,r,s+1))}))}));return r?step(0).then((e=>r(null,e)),r):step(0)};const whichSync=(e,t)=>{t=t||{};const{pathEnv:r,pathExt:s,pathExtExe:n}=getPathInfo(e,t);const a=[];for(let l=0;l<r.length;l++){const u=r[l];const h=/^".*"$/.test(u)?u.slice(1,-1):u;const f=i.join(h,e);const p=!h&&/^\.[\\\/]/.test(e)?e.slice(0,2)+f:f;for(let e=0;e<s.length;e++){const r=p+s[e];try{const e=o.sync(r,{pathExt:n});if(e){if(t.all)a.push(r);else return r}}catch(e){}}}if(t.all&&a.length)return a;if(t.nothrow)return null;throw getNotFoundError(e)};e.exports=which;which.sync=whichSync},4091:e=>{"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next){yield e.value}}}},665:(e,t,r)=>{"use strict";e.exports=Yallist;Yallist.Node=Node;Yallist.create=Yallist;function Yallist(e){var t=this;if(!(t instanceof Yallist)){t=new Yallist}t.tail=null;t.head=null;t.length=0;if(e&&typeof e.forEach==="function"){e.forEach((function(e){t.push(e)}))}else if(arguments.length>0){for(var r=0,s=arguments.length;r<s;r++){t.push(arguments[r])}}return t}Yallist.prototype.removeNode=function(e){if(e.list!==this){throw new Error("removing node which does not belong to this list")}var t=e.next;var r=e.prev;if(t){t.prev=r}if(r){r.next=t}if(e===this.head){this.head=t}if(e===this.tail){this.tail=r}e.list.length--;e.next=null;e.prev=null;e.list=null;return t};Yallist.prototype.unshiftNode=function(e){if(e===this.head){return}if(e.list){e.list.removeNode(e)}var t=this.head;e.list=this;e.next=t;if(t){t.prev=e}this.head=e;if(!this.tail){this.tail=e}this.length++};Yallist.prototype.pushNode=function(e){if(e===this.tail){return}if(e.list){e.list.removeNode(e)}var t=this.tail;e.list=this;e.prev=t;if(t){t.next=e}this.tail=e;if(!this.head){this.head=e}this.length++};Yallist.prototype.push=function(){for(var e=0,t=arguments.length;e<t;e++){push(this,arguments[e])}return this.length};Yallist.prototype.unshift=function(){for(var e=0,t=arguments.length;e<t;e++){unshift(this,arguments[e])}return this.length};Yallist.prototype.pop=function(){if(!this.tail){return undefined}var e=this.tail.value;this.tail=this.tail.prev;if(this.tail){this.tail.next=null}else{this.head=null}this.length--;return e};Yallist.prototype.shift=function(){if(!this.head){return undefined}var e=this.head.value;this.head=this.head.next;if(this.head){this.head.prev=null}else{this.tail=null}this.length--;return e};Yallist.prototype.forEach=function(e,t){t=t||this;for(var r=this.head,s=0;r!==null;s++){e.call(t,r.value,s,this);r=r.next}};Yallist.prototype.forEachReverse=function(e,t){t=t||this;for(var r=this.tail,s=this.length-1;r!==null;s--){e.call(t,r.value,s,this);r=r.prev}};Yallist.prototype.get=function(e){for(var t=0,r=this.head;r!==null&&t<e;t++){r=r.next}if(t===e&&r!==null){return r.value}};Yallist.prototype.getReverse=function(e){for(var t=0,r=this.tail;r!==null&&t<e;t++){r=r.prev}if(t===e&&r!==null){return r.value}};Yallist.prototype.map=function(e,t){t=t||this;var r=new Yallist;for(var s=this.head;s!==null;){r.push(e.call(t,s.value,this));s=s.next}return r};Yallist.prototype.mapReverse=function(e,t){t=t||this;var r=new Yallist;for(var s=this.tail;s!==null;){r.push(e.call(t,s.value,this));s=s.prev}return r};Yallist.prototype.reduce=function(e,t){var r;var s=this.head;if(arguments.length>1){r=t}else if(this.head){s=this.head.next;r=this.head.value}else{throw new TypeError("Reduce of empty list with no initial value")}for(var i=0;s!==null;i++){r=e(r,s.value,i);s=s.next}return r};Yallist.prototype.reduceReverse=function(e,t){var r;var s=this.tail;if(arguments.length>1){r=t}else if(this.tail){s=this.tail.prev;r=this.tail.value}else{throw new TypeError("Reduce of empty list with no initial value")}for(var i=this.length-1;s!==null;i--){r=e(r,s.value,i);s=s.prev}return r};Yallist.prototype.toArray=function(){var e=new Array(this.length);for(var t=0,r=this.head;r!==null;t++){e[t]=r.value;r=r.next}return e};Yallist.prototype.toArrayReverse=function(){var e=new Array(this.length);for(var t=0,r=this.tail;r!==null;t++){e[t]=r.value;r=r.prev}return e};Yallist.prototype.slice=function(e,t){t=t||this.length;if(t<0){t+=this.length}e=e||0;if(e<0){e+=this.length}var r=new Yallist;if(t<e||t<0){return r}if(e<0){e=0}if(t>this.length){t=this.length}for(var s=0,i=this.head;i!==null&&s<e;s++){i=i.next}for(;i!==null&&s<t;s++,i=i.next){r.push(i.value)}return r};Yallist.prototype.sliceReverse=function(e,t){t=t||this.length;if(t<0){t+=this.length}e=e||0;if(e<0){e+=this.length}var r=new Yallist;if(t<e||t<0){return r}if(e<0){e=0}if(t>this.length){t=this.length}for(var s=this.length,i=this.tail;i!==null&&s>t;s--){i=i.prev}for(;i!==null&&s>e;s--,i=i.prev){r.push(i.value)}return r};Yallist.prototype.splice=function(e,t,...r){if(e>this.length){e=this.length-1}if(e<0){e=this.length+e}for(var s=0,i=this.head;i!==null&&s<e;s++){i=i.next}var n=[];for(var s=0;i&&s<t;s++){n.push(i.value);i=this.removeNode(i)}if(i===null){i=this.tail}if(i!==this.head&&i!==this.tail){i=i.prev}for(var s=0;s<r.length;s++){i=insert(this,i,r[s])}return n};Yallist.prototype.reverse=function(){var e=this.head;var t=this.tail;for(var r=e;r!==null;r=r.prev){var s=r.prev;r.prev=r.next;r.next=s}this.head=t;this.tail=e;return this};function insert(e,t,r){var s=t===e.head?new Node(r,null,t,e):new Node(r,t,t.next,e);if(s.next===null){e.tail=s}if(s.prev===null){e.head=s}e.length++;return s}function push(e,t){e.tail=new Node(t,e.tail,null,e);if(!e.head){e.head=e.tail}e.length++}function unshift(e,t){e.head=new Node(t,null,e.head,e);if(!e.tail){e.tail=e.head}e.length++}function Node(e,t,r,s){if(!(this instanceof Node)){return new Node(e,t,r,s)}this.list=s;this.value=e;if(t){t.next=this;this.prev=t}else{this.prev=null}if(r){r.prev=this;this.next=r}else{this.next=null}}try{r(4091)(Yallist)}catch(e){}},9797:(e,t,r)=>{const s=r(1017);const i=r(6186);const{promisify:n}=r(3837);const o=r(7147);const a=r(3664);const l=n(o.writeFile);const u=n(o.readFile);e.exports=async function copyTemplate({destination:e,templateDir:t,adjustContent:r}){const n=await a("**/*",{cwd:t});const o=n.map((async n=>{let o=await u(s.join(t,n),{encoding:"utf-8"});if(typeof r==="function"){o=r(o)}const a=n.replace("template-gitignore",".gitignore").replace("template-package-redux.json","package.json").replace("template-package.json","package.json");const h=s.join(e,a);await i(s.join(h,".."));await l(h,o)}));await Promise.all(o)}},1397:e=>{const t={page:"A complete page",pagemakerPlugin:"A pagemaker plugin"};const r={v4:"v4 (Javascript api)",v5:"v5 (React api (new))"};const s={Yes:"Yes",No:"No"};e.exports={ProjectTypes:t,ProjectVersions:r,YesOrNo:s}},9515:e=>{e.exports=function mapReplace(e,t){let r=e;for(const[e,s]of Object.entries(t)){r=r.replace(new RegExp(`\\{\\{ ${e} \\}\\}`,"g"),s)}return r}},2324:e=>{e.exports=function toCapitalizedWords(e){var t=e.match(/[A-Za-z][a-z]*/g)||[];return t.map(capitalize).join(" ")};function capitalize(e){return e.charAt(0).toUpperCase()+e.substring(1)}},9491:e=>{"use strict";e.exports=require("assert")},4300:e=>{"use strict";e.exports=require("buffer")},2081:e=>{"use strict";e.exports=require("child_process")},2361:e=>{"use strict";e.exports=require("events")},7147:e=>{"use strict";e.exports=require("fs")},2037:e=>{"use strict";e.exports=require("os")},1017:e=>{"use strict";e.exports=require("path")},7282:e=>{"use strict";e.exports=require("process")},4521:e=>{"use strict";e.exports=require("readline")},2781:e=>{"use strict";e.exports=require("stream")},6224:e=>{"use strict";e.exports=require("tty")},3837:e=>{"use strict";e.exports=require("util")},4379:(e,t,r)=>{const{Argument:s}=r(9414);const{Command:i}=r(552);const{CommanderError:n,InvalidArgumentError:o}=r(2625);const{Help:a}=r(5153);const{Option:l}=r(6558);t=e.exports=new i;t.program=t;t.Argument=s;t.Command=i;t.CommanderError=n;t.Help=a;t.InvalidArgumentError=o;t.InvalidOptionArgumentError=o;t.Option=l},9414:(e,t,r)=>{const{InvalidArgumentError:s}=r(2625);class Argument{constructor(e,t){this.description=t||"";this.variadic=false;this.parseArg=undefined;this.defaultValue=undefined;this.defaultValueDescription=undefined;this.argChoices=undefined;switch(e[0]){case"<":this.required=true;this._name=e.slice(1,-1);break;case"[":this.required=false;this._name=e.slice(1,-1);break;default:this.required=true;this._name=e;break}if(this._name.length>3&&this._name.slice(-3)==="..."){this.variadic=true;this._name=this._name.slice(0,-3)}}name(){return this._name}_concatValue(e,t){if(t===this.defaultValue||!Array.isArray(t)){return[e]}return t.concat(e)}default(e,t){this.defaultValue=e;this.defaultValueDescription=t;return this}argParser(e){this.parseArg=e;return this}choices(e){this.argChoices=e.slice();this.parseArg=(e,t)=>{if(!this.argChoices.includes(e)){throw new s(`Allowed choices are ${this.argChoices.join(", ")}.`)}if(this.variadic){return this._concatValue(e,t)}return e};return this}argRequired(){this.required=true;return this}argOptional(){this.required=false;return this}}function humanReadableArgName(e){const t=e.name()+(e.variadic===true?"...":"");return e.required?"<"+t+">":"["+t+"]"}t.Argument=Argument;t.humanReadableArgName=humanReadableArgName},552:(e,t,r)=>{const s=r(2361).EventEmitter;const i=r(2081);const n=r(1017);const o=r(7147);const a=r(7282);const{Argument:l,humanReadableArgName:u}=r(9414);const{CommanderError:h}=r(2625);const{Help:f}=r(5153);const{Option:p,splitOptionFlags:d,DualOptions:m}=r(6558);const{suggestSimilar:g}=r(2338);class Command extends s{constructor(e){super();this.commands=[];this.options=[];this.parent=null;this._allowUnknownOption=false;this._allowExcessArguments=true;this._args=[];this.args=[];this.rawArgs=[];this.processedArgs=[];this._scriptPath=null;this._name=e||"";this._optionValues={};this._optionValueSources={};this._storeOptionsAsProperties=false;this._actionHandler=null;this._executableHandler=false;this._executableFile=null;this._executableDir=null;this._defaultCommandName=null;this._exitCallback=null;this._aliases=[];this._combineFlagAndOptionalValue=true;this._description="";this._summary="";this._argsDescription=undefined;this._enablePositionalOptions=false;this._passThroughOptions=false;this._lifeCycleHooks={};this._showHelpAfterError=false;this._showSuggestionAfterError=true;this._outputConfiguration={writeOut:e=>a.stdout.write(e),writeErr:e=>a.stderr.write(e),getOutHelpWidth:()=>a.stdout.isTTY?a.stdout.columns:undefined,getErrHelpWidth:()=>a.stderr.isTTY?a.stderr.columns:undefined,outputError:(e,t)=>t(e)};this._hidden=false;this._hasHelpOption=true;this._helpFlags="-h, --help";this._helpDescription="display help for command";this._helpShortFlag="-h";this._helpLongFlag="--help";this._addImplicitHelpCommand=undefined;this._helpCommandName="help";this._helpCommandnameAndArgs="help [command]";this._helpCommandDescription="display help for command";this._helpConfiguration={}}copyInheritedSettings(e){this._outputConfiguration=e._outputConfiguration;this._hasHelpOption=e._hasHelpOption;this._helpFlags=e._helpFlags;this._helpDescription=e._helpDescription;this._helpShortFlag=e._helpShortFlag;this._helpLongFlag=e._helpLongFlag;this._helpCommandName=e._helpCommandName;this._helpCommandnameAndArgs=e._helpCommandnameAndArgs;this._helpCommandDescription=e._helpCommandDescription;this._helpConfiguration=e._helpConfiguration;this._exitCallback=e._exitCallback;this._storeOptionsAsProperties=e._storeOptionsAsProperties;this._combineFlagAndOptionalValue=e._combineFlagAndOptionalValue;this._allowExcessArguments=e._allowExcessArguments;this._enablePositionalOptions=e._enablePositionalOptions;this._showHelpAfterError=e._showHelpAfterError;this._showSuggestionAfterError=e._showSuggestionAfterError;return this}command(e,t,r){let s=t;let i=r;if(typeof s==="object"&&s!==null){i=s;s=null}i=i||{};const[,n,o]=e.match(/([^ ]+) *(.*)/);const a=this.createCommand(n);if(s){a.description(s);a._executableHandler=true}if(i.isDefault)this._defaultCommandName=a._name;a._hidden=!!(i.noHelp||i.hidden);a._executableFile=i.executableFile||null;if(o)a.arguments(o);this.commands.push(a);a.parent=this;a.copyInheritedSettings(this);if(s)return this;return a}createCommand(e){return new Command(e)}createHelp(){return Object.assign(new f,this.configureHelp())}configureHelp(e){if(e===undefined)return this._helpConfiguration;this._helpConfiguration=e;return this}configureOutput(e){if(e===undefined)return this._outputConfiguration;Object.assign(this._outputConfiguration,e);return this}showHelpAfterError(e=true){if(typeof e!=="string")e=!!e;this._showHelpAfterError=e;return this}showSuggestionAfterError(e=true){this._showSuggestionAfterError=!!e;return this}addCommand(e,t){if(!e._name){throw new Error(`Command passed to .addCommand() must have a name\n- specify the name in Command constructor or using .name()`)}t=t||{};if(t.isDefault)this._defaultCommandName=e._name;if(t.noHelp||t.hidden)e._hidden=true;this.commands.push(e);e.parent=this;return this}createArgument(e,t){return new l(e,t)}argument(e,t,r,s){const i=this.createArgument(e,t);if(typeof r==="function"){i.default(s).argParser(r)}else{i.default(r)}this.addArgument(i);return this}arguments(e){e.split(/ +/).forEach((e=>{this.argument(e)}));return this}addArgument(e){const t=this._args.slice(-1)[0];if(t&&t.variadic){throw new Error(`only the last argument can be variadic '${t.name()}'`)}if(e.required&&e.defaultValue!==undefined&&e.parseArg===undefined){throw new Error(`a default value for a required argument is never used: '${e.name()}'`)}this._args.push(e);return this}addHelpCommand(e,t){if(e===false){this._addImplicitHelpCommand=false}else{this._addImplicitHelpCommand=true;if(typeof e==="string"){this._helpCommandName=e.split(" ")[0];this._helpCommandnameAndArgs=e}this._helpCommandDescription=t||this._helpCommandDescription}return this}_hasImplicitHelpCommand(){if(this._addImplicitHelpCommand===undefined){return this.commands.length&&!this._actionHandler&&!this._findCommand("help")}return this._addImplicitHelpCommand}hook(e,t){const r=["preSubcommand","preAction","postAction"];if(!r.includes(e)){throw new Error(`Unexpected value for event passed to hook : '${e}'.\nExpecting one of '${r.join("', '")}'`)}if(this._lifeCycleHooks[e]){this._lifeCycleHooks[e].push(t)}else{this._lifeCycleHooks[e]=[t]}return this}exitOverride(e){if(e){this._exitCallback=e}else{this._exitCallback=e=>{if(e.code!=="commander.executeSubCommandAsync"){throw e}else{}}}return this}_exit(e,t,r){if(this._exitCallback){this._exitCallback(new h(e,t,r))}a.exit(e)}action(e){const listener=t=>{const r=this._args.length;const s=t.slice(0,r);if(this._storeOptionsAsProperties){s[r]=this}else{s[r]=this.opts()}s.push(this);return e.apply(this,s)};this._actionHandler=listener;return this}createOption(e,t){return new p(e,t)}addOption(e){const t=e.name();const r=e.attributeName();if(e.negate){const t=e.long.replace(/^--no-/,"--");if(!this._findOption(t)){this.setOptionValueWithSource(r,e.defaultValue===undefined?true:e.defaultValue,"default")}}else if(e.defaultValue!==undefined){this.setOptionValueWithSource(r,e.defaultValue,"default")}this.options.push(e);const handleOptionValue=(t,s,i)=>{if(t==null&&e.presetArg!==undefined){t=e.presetArg}const n=this.getOptionValue(r);if(t!==null&&e.parseArg){try{t=e.parseArg(t,n)}catch(e){if(e.code==="commander.invalidArgument"){const t=`${s} ${e.message}`;this.error(t,{exitCode:e.exitCode,code:e.code})}throw e}}else if(t!==null&&e.variadic){t=e._concatValue(t,n)}if(t==null){if(e.negate){t=false}else if(e.isBoolean()||e.optional){t=true}else{t=""}}this.setOptionValueWithSource(r,t,i)};this.on("option:"+t,(t=>{const r=`error: option '${e.flags}' argument '${t}' is invalid.`;handleOptionValue(t,r,"cli")}));if(e.envVar){this.on("optionEnv:"+t,(t=>{const r=`error: option '${e.flags}' value '${t}' from env '${e.envVar}' is invalid.`;handleOptionValue(t,r,"env")}))}return this}_optionEx(e,t,r,s,i){if(typeof t==="object"&&t instanceof p){throw new Error("To add an Option object use addOption() instead of option() or requiredOption()")}const n=this.createOption(t,r);n.makeOptionMandatory(!!e.mandatory);if(typeof s==="function"){n.default(i).argParser(s)}else if(s instanceof RegExp){const e=s;s=(t,r)=>{const s=e.exec(t);return s?s[0]:r};n.default(i).argParser(s)}else{n.default(s)}return this.addOption(n)}option(e,t,r,s){return this._optionEx({},e,t,r,s)}requiredOption(e,t,r,s){return this._optionEx({mandatory:true},e,t,r,s)}combineFlagAndOptionalValue(e=true){this._combineFlagAndOptionalValue=!!e;return this}allowUnknownOption(e=true){this._allowUnknownOption=!!e;return this}allowExcessArguments(e=true){this._allowExcessArguments=!!e;return this}enablePositionalOptions(e=true){this._enablePositionalOptions=!!e;return this}passThroughOptions(e=true){this._passThroughOptions=!!e;if(!!this.parent&&e&&!this.parent._enablePositionalOptions){throw new Error("passThroughOptions can not be used without turning on enablePositionalOptions for parent command(s)")}return this}storeOptionsAsProperties(e=true){this._storeOptionsAsProperties=!!e;if(this.options.length){throw new Error("call .storeOptionsAsProperties() before adding options")}return this}getOptionValue(e){if(this._storeOptionsAsProperties){return this[e]}return this._optionValues[e]}setOptionValue(e,t){return this.setOptionValueWithSource(e,t,undefined)}setOptionValueWithSource(e,t,r){if(this._storeOptionsAsProperties){this[e]=t}else{this._optionValues[e]=t}this._optionValueSources[e]=r;return this}getOptionValueSource(e){return this._optionValueSources[e]}_prepareUserArgs(e,t){if(e!==undefined&&!Array.isArray(e)){throw new Error("first parameter to parse must be array or undefined")}t=t||{};if(e===undefined){e=a.argv;if(a.versions&&a.versions.electron){t.from="electron"}}this.rawArgs=e.slice();let r;switch(t.from){case undefined:case"node":this._scriptPath=e[1];r=e.slice(2);break;case"electron":if(a.defaultApp){this._scriptPath=e[1];r=e.slice(2)}else{r=e.slice(1)}break;case"user":r=e.slice(0);break;default:throw new Error(`unexpected parse option { from: '${t.from}' }`)}if(!this._name&&this._scriptPath)this.nameFromFilename(this._scriptPath);this._name=this._name||"program";return r}parse(e,t){const r=this._prepareUserArgs(e,t);this._parseCommand([],r);return this}async parseAsync(e,t){const r=this._prepareUserArgs(e,t);await this._parseCommand([],r);return this}_executeSubCommand(e,t){t=t.slice();let r=false;const s=[".js",".ts",".tsx",".mjs",".cjs"];function findFile(e,t){const r=n.resolve(e,t);if(o.existsSync(r))return r;if(s.includes(n.extname(t)))return undefined;const i=s.find((e=>o.existsSync(`${r}${e}`)));if(i)return`${r}${i}`;return undefined}this._checkForMissingMandatoryOptions();this._checkForConflictingOptions();let l=e._executableFile||`${this._name}-${e._name}`;let u=this._executableDir||"";if(this._scriptPath){let e;try{e=o.realpathSync(this._scriptPath)}catch(t){e=this._scriptPath}u=n.resolve(n.dirname(e),u)}if(u){let t=findFile(u,l);if(!t&&!e._executableFile&&this._scriptPath){const r=n.basename(this._scriptPath,n.extname(this._scriptPath));if(r!==this._name){t=findFile(u,`${r}-${e._name}`)}}l=t||l}r=s.includes(n.extname(l));let f;if(a.platform!=="win32"){if(r){t.unshift(l);t=incrementNodeInspectorPort(a.execArgv).concat(t);f=i.spawn(a.argv[0],t,{stdio:"inherit"})}else{f=i.spawn(l,t,{stdio:"inherit"})}}else{t.unshift(l);t=incrementNodeInspectorPort(a.execArgv).concat(t);f=i.spawn(a.execPath,t,{stdio:"inherit"})}if(!f.killed){const e=["SIGUSR1","SIGUSR2","SIGTERM","SIGINT","SIGHUP"];e.forEach((e=>{a.on(e,(()=>{if(f.killed===false&&f.exitCode===null){f.kill(e)}}))}))}const p=this._exitCallback;if(!p){f.on("close",a.exit.bind(a))}else{f.on("close",(()=>{p(new h(a.exitCode||0,"commander.executeSubCommandAsync","(close)"))}))}f.on("error",(t=>{if(t.code==="ENOENT"){const t=u?`searched for local subcommand relative to directory '${u}'`:"no directory for search for local subcommand, use .executableDir() to supply a custom directory";const r=`'${l}' does not exist\n - if '${e._name}' is not meant to be an executable command, remove description parameter from '.command()' and use '.description()' instead\n - if the default executable name is not suitable, use the executableFile option to supply a custom name or path\n - ${t}`;throw new Error(r)}else if(t.code==="EACCES"){throw new Error(`'${l}' not executable`)}if(!p){a.exit(1)}else{const e=new h(1,"commander.executeSubCommandAsync","(error)");e.nestedError=t;p(e)}}));this.runningCommand=f}_dispatchSubcommand(e,t,r){const s=this._findCommand(e);if(!s)this.help({error:true});let i;i=this._chainOrCallSubCommandHook(i,s,"preSubcommand");i=this._chainOrCall(i,(()=>{if(s._executableHandler){this._executeSubCommand(s,t.concat(r))}else{return s._parseCommand(t,r)}}));return i}_checkNumberOfArguments(){this._args.forEach(((e,t)=>{if(e.required&&this.args[t]==null){this.missingArgument(e.name())}}));if(this._args.length>0&&this._args[this._args.length-1].variadic){return}if(this.args.length>this._args.length){this._excessArguments(this.args)}}_processArguments(){const myParseArg=(e,t,r)=>{let s=t;if(t!==null&&e.parseArg){try{s=e.parseArg(t,r)}catch(r){if(r.code==="commander.invalidArgument"){const s=`error: command-argument value '${t}' is invalid for argument '${e.name()}'. ${r.message}`;this.error(s,{exitCode:r.exitCode,code:r.code})}throw r}}return s};this._checkNumberOfArguments();const e=[];this._args.forEach(((t,r)=>{let s=t.defaultValue;if(t.variadic){if(r<this.args.length){s=this.args.slice(r);if(t.parseArg){s=s.reduce(((e,r)=>myParseArg(t,r,e)),t.defaultValue)}}else if(s===undefined){s=[]}}else if(r<this.args.length){s=this.args[r];if(t.parseArg){s=myParseArg(t,s,t.defaultValue)}}e[r]=s}));this.processedArgs=e}_chainOrCall(e,t){if(e&&e.then&&typeof e.then==="function"){return e.then((()=>t()))}return t()}_chainOrCallHooks(e,t){let r=e;const s=[];getCommandAndParents(this).reverse().filter((e=>e._lifeCycleHooks[t]!==undefined)).forEach((e=>{e._lifeCycleHooks[t].forEach((t=>{s.push({hookedCommand:e,callback:t})}))}));if(t==="postAction"){s.reverse()}s.forEach((e=>{r=this._chainOrCall(r,(()=>e.callback(e.hookedCommand,this)))}));return r}_chainOrCallSubCommandHook(e,t,r){let s=e;if(this._lifeCycleHooks[r]!==undefined){this._lifeCycleHooks[r].forEach((e=>{s=this._chainOrCall(s,(()=>e(this,t)))}))}return s}_parseCommand(e,t){const r=this.parseOptions(t);this._parseOptionsEnv();this._parseOptionsImplied();e=e.concat(r.operands);t=r.unknown;this.args=e.concat(t);if(e&&this._findCommand(e[0])){return this._dispatchSubcommand(e[0],e.slice(1),t)}if(this._hasImplicitHelpCommand()&&e[0]===this._helpCommandName){if(e.length===1){this.help()}return this._dispatchSubcommand(e[1],[],[this._helpLongFlag])}if(this._defaultCommandName){outputHelpIfRequested(this,t);return this._dispatchSubcommand(this._defaultCommandName,e,t)}if(this.commands.length&&this.args.length===0&&!this._actionHandler&&!this._defaultCommandName){this.help({error:true})}outputHelpIfRequested(this,r.unknown);this._checkForMissingMandatoryOptions();this._checkForConflictingOptions();const checkForUnknownOptions=()=>{if(r.unknown.length>0){this.unknownOption(r.unknown[0])}};const s=`command:${this.name()}`;if(this._actionHandler){checkForUnknownOptions();this._processArguments();let r;r=this._chainOrCallHooks(r,"preAction");r=this._chainOrCall(r,(()=>this._actionHandler(this.processedArgs)));if(this.parent){r=this._chainOrCall(r,(()=>{this.parent.emit(s,e,t)}))}r=this._chainOrCallHooks(r,"postAction");return r}if(this.parent&&this.parent.listenerCount(s)){checkForUnknownOptions();this._processArguments();this.parent.emit(s,e,t)}else if(e.length){if(this._findCommand("*")){return this._dispatchSubcommand("*",e,t)}if(this.listenerCount("command:*")){this.emit("command:*",e,t)}else if(this.commands.length){this.unknownCommand()}else{checkForUnknownOptions();this._processArguments()}}else if(this.commands.length){checkForUnknownOptions();this.help({error:true})}else{checkForUnknownOptions();this._processArguments()}}_findCommand(e){if(!e)return undefined;return this.commands.find((t=>t._name===e||t._aliases.includes(e)))}_findOption(e){return this.options.find((t=>t.is(e)))}_checkForMissingMandatoryOptions(){for(let e=this;e;e=e.parent){e.options.forEach((t=>{if(t.mandatory&&e.getOptionValue(t.attributeName())===undefined){e.missingMandatoryOptionValue(t)}}))}}_checkForConflictingLocalOptions(){const e=this.options.filter((e=>{const t=e.attributeName();if(this.getOptionValue(t)===undefined){return false}return this.getOptionValueSource(t)!=="default"}));const t=e.filter((e=>e.conflictsWith.length>0));t.forEach((t=>{const r=e.find((e=>t.conflictsWith.includes(e.attributeName())));if(r){this._conflictingOption(t,r)}}))}_checkForConflictingOptions(){for(let e=this;e;e=e.parent){e._checkForConflictingLocalOptions()}}parseOptions(e){const t=[];const r=[];let s=t;const i=e.slice();function maybeOption(e){return e.length>1&&e[0]==="-"}let n=null;while(i.length){const e=i.shift();if(e==="--"){if(s===r)s.push(e);s.push(...i);break}if(n&&!maybeOption(e)){this.emit(`option:${n.name()}`,e);continue}n=null;if(maybeOption(e)){const t=this._findOption(e);if(t){if(t.required){const e=i.shift();if(e===undefined)this.optionMissingArgument(t);this.emit(`option:${t.name()}`,e)}else if(t.optional){let e=null;if(i.length>0&&!maybeOption(i[0])){e=i.shift()}this.emit(`option:${t.name()}`,e)}else{this.emit(`option:${t.name()}`)}n=t.variadic?t:null;continue}}if(e.length>2&&e[0]==="-"&&e[1]!=="-"){const t=this._findOption(`-${e[1]}`);if(t){if(t.required||t.optional&&this._combineFlagAndOptionalValue){this.emit(`option:${t.name()}`,e.slice(2))}else{this.emit(`option:${t.name()}`);i.unshift(`-${e.slice(2)}`)}continue}}if(/^--[^=]+=/.test(e)){const t=e.indexOf("=");const r=this._findOption(e.slice(0,t));if(r&&(r.required||r.optional)){this.emit(`option:${r.name()}`,e.slice(t+1));continue}}if(maybeOption(e)){s=r}if((this._enablePositionalOptions||this._passThroughOptions)&&t.length===0&&r.length===0){if(this._findCommand(e)){t.push(e);if(i.length>0)r.push(...i);break}else if(e===this._helpCommandName&&this._hasImplicitHelpCommand()){t.push(e);if(i.length>0)t.push(...i);break}else if(this._defaultCommandName){r.push(e);if(i.length>0)r.push(...i);break}}if(this._passThroughOptions){s.push(e);if(i.length>0)s.push(...i);break}s.push(e)}return{operands:t,unknown:r}}opts(){if(this._storeOptionsAsProperties){const e={};const t=this.options.length;for(let r=0;r<t;r++){const t=this.options[r].attributeName();e[t]=t===this._versionOptionName?this._version:this[t]}return e}return this._optionValues}optsWithGlobals(){return getCommandAndParents(this).reduce(((e,t)=>Object.assign(e,t.opts())),{})}error(e,t){this._outputConfiguration.outputError(`${e}\n`,this._outputConfiguration.writeErr);if(typeof this._showHelpAfterError==="string"){this._outputConfiguration.writeErr(`${this._showHelpAfterError}\n`)}else if(this._showHelpAfterError){this._outputConfiguration.writeErr("\n");this.outputHelp({error:true})}const r=t||{};const s=r.exitCode||1;const i=r.code||"commander.error";this._exit(s,i,e)}_parseOptionsEnv(){this.options.forEach((e=>{if(e.envVar&&e.envVar in a.env){const t=e.attributeName();if(this.getOptionValue(t)===undefined||["default","config","env"].includes(this.getOptionValueSource(t))){if(e.required||e.optional){this.emit(`optionEnv:${e.name()}`,a.env[e.envVar])}else{this.emit(`optionEnv:${e.name()}`)}}}}))}_parseOptionsImplied(){const e=new m(this.options);const hasCustomOptionValue=e=>this.getOptionValue(e)!==undefined&&!["default","implied"].includes(this.getOptionValueSource(e));this.options.filter((t=>t.implied!==undefined&&hasCustomOptionValue(t.attributeName())&&e.valueFromOption(this.getOptionValue(t.attributeName()),t))).forEach((e=>{Object.keys(e.implied).filter((e=>!hasCustomOptionValue(e))).forEach((t=>{this.setOptionValueWithSource(t,e.implied[t],"implied")}))}))}missingArgument(e){const t=`error: missing required argument '${e}'`;this.error(t,{code:"commander.missingArgument"})}optionMissingArgument(e){const t=`error: option '${e.flags}' argument missing`;this.error(t,{code:"commander.optionMissingArgument"})}missingMandatoryOptionValue(e){const t=`error: required option '${e.flags}' not specified`;this.error(t,{code:"commander.missingMandatoryOptionValue"})}_conflictingOption(e,t){const findBestOptionFromValue=e=>{const t=e.attributeName();const r=this.getOptionValue(t);const s=this.options.find((e=>e.negate&&t===e.attributeName()));const i=this.options.find((e=>!e.negate&&t===e.attributeName()));if(s&&(s.presetArg===undefined&&r===false||s.presetArg!==undefined&&r===s.presetArg)){return s}return i||e};const getErrorMessage=e=>{const t=findBestOptionFromValue(e);const r=t.attributeName();const s=this.getOptionValueSource(r);if(s==="env"){return`environment variable '${t.envVar}'`}return`option '${t.flags}'`};const r=`error: ${getErrorMessage(e)} cannot be used with ${getErrorMessage(t)}`;this.error(r,{code:"commander.conflictingOption"})}unknownOption(e){if(this._allowUnknownOption)return;let t="";if(e.startsWith("--")&&this._showSuggestionAfterError){let r=[];let s=this;do{const e=s.createHelp().visibleOptions(s).filter((e=>e.long)).map((e=>e.long));r=r.concat(e);s=s.parent}while(s&&!s._enablePositionalOptions);t=g(e,r)}const r=`error: unknown option '${e}'${t}`;this.error(r,{code:"commander.unknownOption"})}_excessArguments(e){if(this._allowExcessArguments)return;const t=this._args.length;const r=t===1?"":"s";const s=this.parent?` for '${this.name()}'`:"";const i=`error: too many arguments${s}. Expected ${t} argument${r} but got ${e.length}.`;this.error(i,{code:"commander.excessArguments"})}unknownCommand(){const e=this.args[0];let t="";if(this._showSuggestionAfterError){const r=[];this.createHelp().visibleCommands(this).forEach((e=>{r.push(e.name());if(e.alias())r.push(e.alias())}));t=g(e,r)}const r=`error: unknown command '${e}'${t}`;this.error(r,{code:"commander.unknownCommand"})}version(e,t,r){if(e===undefined)return this._version;this._version=e;t=t||"-V, --version";r=r||"output the version number";const s=this.createOption(t,r);this._versionOptionName=s.attributeName();this.options.push(s);this.on("option:"+s.name(),(()=>{this._outputConfiguration.writeOut(`${e}\n`);this._exit(0,"commander.version",e)}));return this}description(e,t){if(e===undefined&&t===undefined)return this._description;this._description=e;if(t){this._argsDescription=t}return this}summary(e){if(e===undefined)return this._summary;this._summary=e;return this}alias(e){if(e===undefined)return this._aliases[0];let t=this;if(this.commands.length!==0&&this.commands[this.commands.length-1]._executableHandler){t=this.commands[this.commands.length-1]}if(e===t._name)throw new Error("Command alias can't be the same as its name");t._aliases.push(e);return this}aliases(e){if(e===undefined)return this._aliases;e.forEach((e=>this.alias(e)));return this}usage(e){if(e===undefined){if(this._usage)return this._usage;const e=this._args.map((e=>u(e)));return[].concat(this.options.length||this._hasHelpOption?"[options]":[],this.commands.length?"[command]":[],this._args.length?e:[]).join(" ")}this._usage=e;return this}name(e){if(e===undefined)return this._name;this._name=e;return this}nameFromFilename(e){this._name=n.basename(e,n.extname(e));return this}executableDir(e){if(e===undefined)return this._executableDir;this._executableDir=e;return this}helpInformation(e){const t=this.createHelp();if(t.helpWidth===undefined){t.helpWidth=e&&e.error?this._outputConfiguration.getErrHelpWidth():this._outputConfiguration.getOutHelpWidth()}return t.formatHelp(this,t)}_getHelpContext(e){e=e||{};const t={error:!!e.error};let r;if(t.error){r=e=>this._outputConfiguration.writeErr(e)}else{r=e=>this._outputConfiguration.writeOut(e)}t.write=e.write||r;t.command=this;return t}outputHelp(e){let t;if(typeof e==="function"){t=e;e=undefined}const r=this._getHelpContext(e);getCommandAndParents(this).reverse().forEach((e=>e.emit("beforeAllHelp",r)));this.emit("beforeHelp",r);let s=this.helpInformation(r);if(t){s=t(s);if(typeof s!=="string"&&!Buffer.isBuffer(s)){throw new Error("outputHelp callback must return a string or a Buffer")}}r.write(s);this.emit(this._helpLongFlag);this.emit("afterHelp",r);getCommandAndParents(this).forEach((e=>e.emit("afterAllHelp",r)))}helpOption(e,t){if(typeof e==="boolean"){this._hasHelpOption=e;return this}this._helpFlags=e||this._helpFlags;this._helpDescription=t||this._helpDescription;const r=d(this._helpFlags);this._helpShortFlag=r.shortFlag;this._helpLongFlag=r.longFlag;return this}help(e){this.outputHelp(e);let t=a.exitCode||0;if(t===0&&e&&typeof e!=="function"&&e.error){t=1}this._exit(t,"commander.help","(outputHelp)")}addHelpText(e,t){const r=["beforeAll","before","after","afterAll"];if(!r.includes(e)){throw new Error(`Unexpected value for position to addHelpText.\nExpecting one of '${r.join("', '")}'`)}const s=`${e}Help`;this.on(s,(e=>{let r;if(typeof t==="function"){r=t({error:e.error,command:e.command})}else{r=t}if(r){e.write(`${r}\n`)}}));return this}}function outputHelpIfRequested(e,t){const r=e._hasHelpOption&&t.find((t=>t===e._helpLongFlag||t===e._helpShortFlag));if(r){e.outputHelp();e._exit(0,"commander.helpDisplayed","(outputHelp)")}}function incrementNodeInspectorPort(e){return e.map((e=>{if(!e.startsWith("--inspect")){return e}let t;let r="127.0.0.1";let s="9229";let i;if((i=e.match(/^(--inspect(-brk)?)$/))!==null){t=i[1]}else if((i=e.match(/^(--inspect(-brk|-port)?)=([^:]+)$/))!==null){t=i[1];if(/^\d+$/.test(i[3])){s=i[3]}else{r=i[3]}}else if((i=e.match(/^(--inspect(-brk|-port)?)=([^:]+):(\d+)$/))!==null){t=i[1];r=i[3];s=i[4]}if(t&&s!=="0"){return`${t}=${r}:${parseInt(s)+1}`}return e}))}function getCommandAndParents(e){const t=[];for(let r=e;r;r=r.parent){t.push(r)}return t}t.Command=Command},2625:(e,t)=>{class CommanderError extends Error{constructor(e,t,r){super(r);Error.captureStackTrace(this,this.constructor);this.name=this.constructor.name;this.code=t;this.exitCode=e;this.nestedError=undefined}}class InvalidArgumentError extends CommanderError{constructor(e){super(1,"commander.invalidArgument",e);Error.captureStackTrace(this,this.constructor);this.name=this.constructor.name}}t.CommanderError=CommanderError;t.InvalidArgumentError=InvalidArgumentError},5153:(e,t,r)=>{const{humanReadableArgName:s}=r(9414);class Help{constructor(){this.helpWidth=undefined;this.sortSubcommands=false;this.sortOptions=false}visibleCommands(e){const t=e.commands.filter((e=>!e._hidden));if(e._hasImplicitHelpCommand()){const[,r,s]=e._helpCommandnameAndArgs.match(/([^ ]+) *(.*)/);const i=e.createCommand(r).helpOption(false);i.description(e._helpCommandDescription);if(s)i.arguments(s);t.push(i)}if(this.sortSubcommands){t.sort(((e,t)=>e.name().localeCompare(t.name())))}return t}visibleOptions(e){const t=e.options.filter((e=>!e.hidden));const r=e._hasHelpOption&&e._helpShortFlag&&!e._findOption(e._helpShortFlag);const s=e._hasHelpOption&&!e._findOption(e._helpLongFlag);if(r||s){let i;if(!r){i=e.createOption(e._helpLongFlag,e._helpDescription)}else if(!s){i=e.createOption(e._helpShortFlag,e._helpDescription)}else{i=e.createOption(e._helpFlags,e._helpDescription)}t.push(i)}if(this.sortOptions){const getSortKey=e=>e.short?e.short.replace(/^-/,""):e.long.replace(/^--/,"");t.sort(((e,t)=>getSortKey(e).localeCompare(getSortKey(t))))}return t}visibleArguments(e){if(e._argsDescription){e._args.forEach((t=>{t.description=t.description||e._argsDescription[t.name()]||""}))}if(e._args.find((e=>e.description))){return e._args}return[]}subcommandTerm(e){const t=e._args.map((e=>s(e))).join(" ");return e._name+(e._aliases[0]?"|"+e._aliases[0]:"")+(e.options.length?" [options]":"")+(t?" "+t:"")}optionTerm(e){return e.flags}argumentTerm(e){return e.name()}longestSubcommandTermLength(e,t){return t.visibleCommands(e).reduce(((e,r)=>Math.max(e,t.subcommandTerm(r).length)),0)}longestOptionTermLength(e,t){return t.visibleOptions(e).reduce(((e,r)=>Math.max(e,t.optionTerm(r).length)),0)}longestArgumentTermLength(e,t){return t.visibleArguments(e).reduce(((e,r)=>Math.max(e,t.argumentTerm(r).length)),0)}commandUsage(e){let t=e._name;if(e._aliases[0]){t=t+"|"+e._aliases[0]}let r="";for(let t=e.parent;t;t=t.parent){r=t.name()+" "+r}return r+t+" "+e.usage()}commandDescription(e){return e.description()}subcommandDescription(e){return e.summary()||e.description()}optionDescription(e){const t=[];if(e.argChoices){t.push(`choices: ${e.argChoices.map((e=>JSON.stringify(e))).join(", ")}`)}if(e.defaultValue!==undefined){const r=e.required||e.optional||e.isBoolean()&&typeof e.defaultValue==="boolean";if(r){t.push(`default: ${e.defaultValueDescription||JSON.stringify(e.defaultValue)}`)}}if(e.presetArg!==undefined&&e.optional){t.push(`preset: ${JSON.stringify(e.presetArg)}`)}if(e.envVar!==undefined){t.push(`env: ${e.envVar}`)}if(t.length>0){return`${e.description} (${t.join(", ")})`}return e.description}argumentDescription(e){const t=[];if(e.argChoices){t.push(`choices: ${e.argChoices.map((e=>JSON.stringify(e))).join(", ")}`)}if(e.defaultValue!==undefined){t.push(`default: ${e.defaultValueDescription||JSON.stringify(e.defaultValue)}`)}if(t.length>0){const r=`(${t.join(", ")})`;if(e.description){return`${e.description} ${r}`}return r}return e.description}formatHelp(e,t){const r=t.padWidth(e,t);const s=t.helpWidth||80;const i=2;const n=2;function formatItem(e,o){if(o){const a=`${e.padEnd(r+n)}${o}`;return t.wrap(a,s-i,r+n)}return e}function formatList(e){return e.join("\n").replace(/^/gm," ".repeat(i))}let o=[`Usage: ${t.commandUsage(e)}`,""];const a=t.commandDescription(e);if(a.length>0){o=o.concat([a,""])}const l=t.visibleArguments(e).map((e=>formatItem(t.argumentTerm(e),t.argumentDescription(e))));if(l.length>0){o=o.concat(["Arguments:",formatList(l),""])}const u=t.visibleOptions(e).map((e=>formatItem(t.optionTerm(e),t.optionDescription(e))));if(u.length>0){o=o.concat(["Options:",formatList(u),""])}const h=t.visibleCommands(e).map((e=>formatItem(t.subcommandTerm(e),t.subcommandDescription(e))));if(h.length>0){o=o.concat(["Commands:",formatList(h),""])}return o.join("\n")}padWidth(e,t){return Math.max(t.longestOptionTermLength(e,t),t.longestSubcommandTermLength(e,t),t.longestArgumentTermLength(e,t))}wrap(e,t,r,s=40){if(e.match(/[\n]\s+/))return e;const i=t-r;if(i<s)return e;const n=e.slice(0,r);const o=e.slice(r);const a=" ".repeat(r);const l=new RegExp(".{1,"+(i-1)+"}([\\s]|$)|[^\\s]+?([\\s]|$)","g");const u=o.match(l)||[];return n+u.map(((e,t)=>{if(e.slice(-1)==="\n"){e=e.slice(0,e.length-1)}return(t>0?a:"")+e.trimRight()})).join("\n")}}t.Help=Help},6558:(e,t,r)=>{const{InvalidArgumentError:s}=r(2625);class Option{constructor(e,t){this.flags=e;this.description=t||"";this.required=e.includes("<");this.optional=e.includes("[");this.variadic=/\w\.\.\.[>\]]$/.test(e);this.mandatory=false;const r=splitOptionFlags(e);this.short=r.shortFlag;this.long=r.longFlag;this.negate=false;if(this.long){this.negate=this.long.startsWith("--no-")}this.defaultValue=undefined;this.defaultValueDescription=undefined;this.presetArg=undefined;this.envVar=undefined;this.parseArg=undefined;this.hidden=false;this.argChoices=undefined;this.conflictsWith=[];this.implied=undefined}default(e,t){this.defaultValue=e;this.defaultValueDescription=t;return this}preset(e){this.presetArg=e;return this}conflicts(e){this.conflictsWith=this.conflictsWith.concat(e);return this}implies(e){this.implied=Object.assign(this.implied||{},e);return this}env(e){this.envVar=e;return this}argParser(e){this.parseArg=e;return this}makeOptionMandatory(e=true){this.mandatory=!!e;return this}hideHelp(e=true){this.hidden=!!e;return this}_concatValue(e,t){if(t===this.defaultValue||!Array.isArray(t)){return[e]}return t.concat(e)}choices(e){this.argChoices=e.slice();this.parseArg=(e,t)=>{if(!this.argChoices.includes(e)){throw new s(`Allowed choices are ${this.argChoices.join(", ")}.`)}if(this.variadic){return this._concatValue(e,t)}return e};return this}name(){if(this.long){return this.long.replace(/^--/,"")}return this.short.replace(/^-/,"")}attributeName(){return camelcase(this.name().replace(/^no-/,""))}is(e){return this.short===e||this.long===e}isBoolean(){return!this.required&&!this.optional&&!this.negate}}class DualOptions{constructor(e){this.positiveOptions=new Map;this.negativeOptions=new Map;this.dualOptions=new Set;e.forEach((e=>{if(e.negate){this.negativeOptions.set(e.attributeName(),e)}else{this.positiveOptions.set(e.attributeName(),e)}}));this.negativeOptions.forEach(((e,t)=>{if(this.positiveOptions.has(t)){this.dualOptions.add(t)}}))}valueFromOption(e,t){const r=t.attributeName();if(!this.dualOptions.has(r))return true;const s=this.negativeOptions.get(r).presetArg;const i=s!==undefined?s:false;return t.negate===(i===e)}}function camelcase(e){return e.split("-").reduce(((e,t)=>e+t[0].toUpperCase()+t.slice(1)))}function splitOptionFlags(e){let t;let r;const s=e.split(/[ |,]+/);if(s.length>1&&!/^[[<]/.test(s[1]))t=s.shift();r=s.shift();if(!t&&/^-[^-]$/.test(r)){t=r;r=undefined}return{shortFlag:t,longFlag:r}}t.Option=Option;t.splitOptionFlags=splitOptionFlags;t.DualOptions=DualOptions},2338:(e,t)=>{const r=3;function editDistance(e,t){if(Math.abs(e.length-t.length)>r)return Math.max(e.length,t.length);const s=[];for(let t=0;t<=e.length;t++){s[t]=[t]}for(let e=0;e<=t.length;e++){s[0][e]=e}for(let r=1;r<=t.length;r++){for(let i=1;i<=e.length;i++){let n=1;if(e[i-1]===t[r-1]){n=0}else{n=1}s[i][r]=Math.min(s[i-1][r]+1,s[i][r-1]+1,s[i-1][r-1]+n);if(i>1&&r>1&&e[i-1]===t[r-2]&&e[i-2]===t[r-1]){s[i][r]=Math.min(s[i][r],s[i-2][r-2]+1)}}}return s[e.length][t.length]}function suggestSimilar(e,t){if(!t||t.length===0)return"";t=Array.from(new Set(t));const s=e.startsWith("--");if(s){e=e.slice(2);t=t.map((e=>e.slice(2)))}let i=[];let n=r;const o=.4;t.forEach((t=>{if(t.length<=1)return;const r=editDistance(e,t);const s=Math.max(e.length,t.length);const a=(s-r)/s;if(a>o){if(r<n){n=r;i=[t]}else if(r===n){i.push(t)}}}));i.sort(((e,t)=>e.localeCompare(t)));if(s){i=i.map((e=>`--${e}`))}if(i.length>1){return`\n(Did you mean one of ${i.join(", ")}?)`}if(i.length===1){return`\n(Did you mean ${i[0]}?)`}return""}t.suggestSimilar=suggestSimilar},6374:e=>{"use strict";e.exports=JSON.parse('{"dots":{"interval":80,"frames":["⠋","⠙","⠹","⠸","⠼","⠴","⠦","⠧","⠇","⠏"]},"dots2":{"interval":80,"frames":["⣾","⣽","⣻","⢿","⡿","⣟","⣯","⣷"]},"dots3":{"interval":80,"frames":["⠋","⠙","⠚","⠞","⠖","⠦","⠴","⠲","⠳","⠓"]},"dots4":{"interval":80,"frames":["⠄","⠆","⠇","⠋","⠙","⠸","⠰","⠠","⠰","⠸","⠙","⠋","⠇","⠆"]},"dots5":{"interval":80,"frames":["⠋","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋"]},"dots6":{"interval":80,"frames":["⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠴","⠲","⠒","⠂","⠂","⠒","⠚","⠙","⠉","⠁"]},"dots7":{"interval":80,"frames":["⠈","⠉","⠋","⠓","⠒","⠐","⠐","⠒","⠖","⠦","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈"]},"dots8":{"interval":80,"frames":["⠁","⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈","⠈"]},"dots9":{"interval":80,"frames":["⢹","⢺","⢼","⣸","⣇","⡧","⡗","⡏"]},"dots10":{"interval":80,"frames":["⢄","⢂","⢁","⡁","⡈","⡐","⡠"]},"dots11":{"interval":100,"frames":["⠁","⠂","⠄","⡀","⢀","⠠","⠐","⠈"]},"dots12":{"interval":80,"frames":["⢀⠀","⡀⠀","⠄⠀","⢂⠀","⡂⠀","⠅⠀","⢃⠀","⡃⠀","⠍⠀","⢋⠀","⡋⠀","⠍⠁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⢈⠩","⡀⢙","⠄⡙","⢂⠩","⡂⢘","⠅⡘","⢃⠨","⡃⢐","⠍⡐","⢋⠠","⡋⢀","⠍⡁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⠈⠩","⠀⢙","⠀⡙","⠀⠩","⠀⢘","⠀⡘","⠀⠨","⠀⢐","⠀⡐","⠀⠠","⠀⢀","⠀⡀"]},"dots13":{"interval":80,"frames":["⣼","⣹","⢻","⠿","⡟","⣏","⣧","⣶"]},"dots8Bit":{"interval":80,"frames":["⠀","⠁","⠂","⠃","⠄","⠅","⠆","⠇","⡀","⡁","⡂","⡃","⡄","⡅","⡆","⡇","⠈","⠉","⠊","⠋","⠌","⠍","⠎","⠏","⡈","⡉","⡊","⡋","⡌","⡍","⡎","⡏","⠐","⠑","⠒","⠓","⠔","⠕","⠖","⠗","⡐","⡑","⡒","⡓","⡔","⡕","⡖","⡗","⠘","⠙","⠚","⠛","⠜","⠝","⠞","⠟","⡘","⡙","⡚","⡛","⡜","⡝","⡞","⡟","⠠","⠡","⠢","⠣","⠤","⠥","⠦","⠧","⡠","⡡","⡢","⡣","⡤","⡥","⡦","⡧","⠨","⠩","⠪","⠫","⠬","⠭","⠮","⠯","⡨","⡩","⡪","⡫","⡬","⡭","⡮","⡯","⠰","⠱","⠲","⠳","⠴","⠵","⠶","⠷","⡰","⡱","⡲","⡳","⡴","⡵","⡶","⡷","⠸","⠹","⠺","⠻","⠼","⠽","⠾","⠿","⡸","⡹","⡺","⡻","⡼","⡽","⡾","⡿","⢀","⢁","⢂","⢃","⢄","⢅","⢆","⢇","⣀","⣁","⣂","⣃","⣄","⣅","⣆","⣇","⢈","⢉","⢊","⢋","⢌","⢍","⢎","⢏","⣈","⣉","⣊","⣋","⣌","⣍","⣎","⣏","⢐","⢑","⢒","⢓","⢔","⢕","⢖","⢗","⣐","⣑","⣒","⣓","⣔","⣕","⣖","⣗","⢘","⢙","⢚","⢛","⢜","⢝","⢞","⢟","⣘","⣙","⣚","⣛","⣜","⣝","⣞","⣟","⢠","⢡","⢢","⢣","⢤","⢥","⢦","⢧","⣠","⣡","⣢","⣣","⣤","⣥","⣦","⣧","⢨","⢩","⢪","⢫","⢬","⢭","⢮","⢯","⣨","⣩","⣪","⣫","⣬","⣭","⣮","⣯","⢰","⢱","⢲","⢳","⢴","⢵","⢶","⢷","⣰","⣱","⣲","⣳","⣴","⣵","⣶","⣷","⢸","⢹","⢺","⢻","⢼","⢽","⢾","⢿","⣸","⣹","⣺","⣻","⣼","⣽","⣾","⣿"]},"sand":{"interval":80,"frames":["⠁","⠂","⠄","⡀","⡈","⡐","⡠","⣀","⣁","⣂","⣄","⣌","⣔","⣤","⣥","⣦","⣮","⣶","⣷","⣿","⡿","⠿","⢟","⠟","⡛","⠛","⠫","⢋","⠋","⠍","⡉","⠉","⠑","⠡","⢁"]},"line":{"interval":130,"frames":["-","\\\\","|","/"]},"line2":{"interval":100,"frames":["⠂","-","–","—","–","-"]},"pipe":{"interval":100,"frames":["┤","┘","┴","└","├","┌","┬","┐"]},"simpleDots":{"interval":400,"frames":[". ",".. ","..."," "]},"simpleDotsScrolling":{"interval":200,"frames":[". ",".. ","..."," .."," ."," "]},"star":{"interval":70,"frames":["✶","✸","✹","✺","✹","✷"]},"star2":{"interval":80,"frames":["+","x","*"]},"flip":{"interval":70,"frames":["_","_","_","-","`","`","\'","´","-","_","_","_"]},"hamburger":{"interval":100,"frames":["☱","☲","☴"]},"growVertical":{"interval":120,"frames":["▁","▃","▄","▅","▆","▇","▆","▅","▄","▃"]},"growHorizontal":{"interval":120,"frames":["▏","▎","▍","▌","▋","▊","▉","▊","▋","▌","▍","▎"]},"balloon":{"interval":140,"frames":[" ",".","o","O","@","*"," "]},"balloon2":{"interval":120,"frames":[".","o","O","°","O","o","."]},"noise":{"interval":100,"frames":["▓","▒","░"]},"bounce":{"interval":120,"frames":["⠁","⠂","⠄","⠂"]},"boxBounce":{"interval":120,"frames":["▖","▘","▝","▗"]},"boxBounce2":{"interval":100,"frames":["▌","▀","▐","▄"]},"triangle":{"interval":50,"frames":["◢","◣","◤","◥"]},"arc":{"interval":100,"frames":["◜","◠","◝","◞","◡","◟"]},"circle":{"interval":120,"frames":["◡","⊙","◠"]},"squareCorners":{"interval":180,"frames":["◰","◳","◲","◱"]},"circleQuarters":{"interval":120,"frames":["◴","◷","◶","◵"]},"circleHalves":{"interval":50,"frames":["◐","◓","◑","◒"]},"squish":{"interval":100,"frames":["╫","╪"]},"toggle":{"interval":250,"frames":["⊶","⊷"]},"toggle2":{"interval":80,"frames":["▫","▪"]},"toggle3":{"interval":120,"frames":["□","■"]},"toggle4":{"interval":100,"frames":["■","□","▪","▫"]},"toggle5":{"interval":100,"frames":["▮","▯"]},"toggle6":{"interval":300,"frames":["ဝ","၀"]},"toggle7":{"interval":80,"frames":["⦾","⦿"]},"toggle8":{"interval":100,"frames":["◍","◌"]},"toggle9":{"interval":100,"frames":["◉","◎"]},"toggle10":{"interval":100,"frames":["㊂","㊀","㊁"]},"toggle11":{"interval":50,"frames":["⧇","⧆"]},"toggle12":{"interval":120,"frames":["☗","☖"]},"toggle13":{"interval":80,"frames":["=","*","-"]},"arrow":{"interval":100,"frames":["←","↖","↑","↗","→","↘","↓","↙"]},"arrow2":{"interval":80,"frames":["⬆️ ","↗️ ","➡️ ","↘️ ","⬇️ ","↙️ ","⬅️ ","↖️ "]},"arrow3":{"interval":120,"frames":["▹▹▹▹▹","▸▹▹▹▹","▹▸▹▹▹","▹▹▸▹▹","▹▹▹▸▹","▹▹▹▹▸"]},"bouncingBar":{"interval":80,"frames":["[ ]","[= ]","[== ]","[=== ]","[ ===]","[ ==]","[ =]","[ ]","[ =]","[ ==]","[ ===]","[====]","[=== ]","[== ]","[= ]"]},"bouncingBall":{"interval":80,"frames":["( ● )","( ● )","( ● )","( ● )","( ●)","( ● )","( ● )","( ● )","( ● )","(● )"]},"smiley":{"interval":200,"frames":["😄 ","😝 "]},"monkey":{"interval":300,"frames":["🙈 ","🙈 ","🙉 ","🙊 "]},"hearts":{"interval":100,"frames":["💛 ","💙 ","💜 ","💚 ","❤️ "]},"clock":{"interval":100,"frames":["🕛 ","🕐 ","🕑 ","🕒 ","🕓 ","🕔 ","🕕 ","🕖 ","🕗 ","🕘 ","🕙 ","🕚 "]},"earth":{"interval":180,"frames":["🌍 ","🌎 ","🌏 "]},"material":{"interval":17,"frames":["█▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","███▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","████▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██████▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██████▁▁▁▁▁▁▁▁▁▁▁▁▁▁","███████▁▁▁▁▁▁▁▁▁▁▁▁▁","████████▁▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","██████████▁▁▁▁▁▁▁▁▁▁","███████████▁▁▁▁▁▁▁▁▁","█████████████▁▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁▁██████████████▁▁▁▁","▁▁▁██████████████▁▁▁","▁▁▁▁█████████████▁▁▁","▁▁▁▁██████████████▁▁","▁▁▁▁██████████████▁▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁▁██████████████","▁▁▁▁▁▁██████████████","▁▁▁▁▁▁▁█████████████","▁▁▁▁▁▁▁█████████████","▁▁▁▁▁▁▁▁████████████","▁▁▁▁▁▁▁▁████████████","▁▁▁▁▁▁▁▁▁███████████","▁▁▁▁▁▁▁▁▁███████████","▁▁▁▁▁▁▁▁▁▁██████████","▁▁▁▁▁▁▁▁▁▁██████████","▁▁▁▁▁▁▁▁▁▁▁▁████████","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁██████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","█▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","███▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","████▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","█████▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","█████▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","██████▁▁▁▁▁▁▁▁▁▁▁▁▁█","████████▁▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","███████████▁▁▁▁▁▁▁▁▁","████████████▁▁▁▁▁▁▁▁","████████████▁▁▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁▁▁█████████████▁▁▁▁","▁▁▁▁▁████████████▁▁▁","▁▁▁▁▁████████████▁▁▁","▁▁▁▁▁▁███████████▁▁▁","▁▁▁▁▁▁▁▁█████████▁▁▁","▁▁▁▁▁▁▁▁█████████▁▁▁","▁▁▁▁▁▁▁▁▁█████████▁▁","▁▁▁▁▁▁▁▁▁█████████▁▁","▁▁▁▁▁▁▁▁▁▁█████████▁","▁▁▁▁▁▁▁▁▁▁▁████████▁","▁▁▁▁▁▁▁▁▁▁▁████████▁","▁▁▁▁▁▁▁▁▁▁▁▁███████▁","▁▁▁▁▁▁▁▁▁▁▁▁███████▁","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁"]},"moon":{"interval":80,"frames":["🌑 ","🌒 ","🌓 ","🌔 ","🌕 ","🌖 ","🌗 ","🌘 "]},"runner":{"interval":140,"frames":["🚶 ","🏃 "]},"pong":{"interval":80,"frames":["▐⠂ ▌","▐⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂▌","▐ ⠠▌","▐ ⡀▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐⠠ ▌"]},"shark":{"interval":120,"frames":["▐|\\\\____________▌","▐_|\\\\___________▌","▐__|\\\\__________▌","▐___|\\\\_________▌","▐____|\\\\________▌","▐_____|\\\\_______▌","▐______|\\\\______▌","▐_______|\\\\_____▌","▐________|\\\\____▌","▐_________|\\\\___▌","▐__________|\\\\__▌","▐___________|\\\\_▌","▐____________|\\\\▌","▐____________/|▌","▐___________/|_▌","▐__________/|__▌","▐_________/|___▌","▐________/|____▌","▐_______/|_____▌","▐______/|______▌","▐_____/|_______▌","▐____/|________▌","▐___/|_________▌","▐__/|__________▌","▐_/|___________▌","▐/|____________▌"]},"dqpb":{"interval":100,"frames":["d","q","p","b"]},"weather":{"interval":100,"frames":["☀️ ","☀️ ","☀️ ","🌤 ","⛅️ ","🌥 ","☁️ ","🌧 ","🌨 ","🌧 ","🌨 ","🌧 ","🌨 ","⛈ ","🌨 ","🌧 ","🌨 ","☁️ ","🌥 ","⛅️ ","🌤 ","☀️ ","☀️ "]},"christmas":{"interval":400,"frames":["🌲","🎄"]},"grenade":{"interval":80,"frames":["، ","′ "," ´ "," ‾ "," ⸌"," ⸊"," |"," ⁎"," ⁕"," ෴ "," ⁓"," "," "," "]},"point":{"interval":125,"frames":["∙∙∙","●∙∙","∙●∙","∙∙●","∙∙∙"]},"layer":{"interval":150,"frames":["-","=","≡"]},"betaWave":{"interval":80,"frames":["ρββββββ","βρβββββ","ββρββββ","βββρβββ","ββββρββ","βββββρβ","ββββββρ"]},"fingerDance":{"interval":160,"frames":["🤘 ","🤟 ","🖖 ","✋ ","🤚 ","👆 "]},"fistBump":{"interval":80,"frames":["🤜 🤛 ","🤜 🤛 ","🤜 🤛 "," 🤜 🤛 "," 🤜🤛 "," 🤜✨🤛 ","🤜 ✨ 🤛 "]},"soccerHeader":{"interval":80,"frames":[" 🧑⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 "]},"mindblown":{"interval":160,"frames":["😐 ","😐 ","😮 ","😮 ","😦 ","😦 ","😧 ","😧 ","🤯 ","💥 ","✨ "," "," "," "]},"speaker":{"interval":160,"frames":["🔈 ","🔉 ","🔊 ","🔉 "]},"orangePulse":{"interval":100,"frames":["🔸 ","🔶 ","🟠 ","🟠 ","🔶 "]},"bluePulse":{"interval":100,"frames":["🔹 ","🔷 ","🔵 ","🔵 ","🔷 "]},"orangeBluePulse":{"interval":100,"frames":["🔸 ","🔶 ","🟠 ","🟠 ","🔶 ","🔹 ","🔷 ","🔵 ","🔵 ","🔷 "]},"timeTravel":{"interval":100,"frames":["🕛 ","🕚 ","🕙 ","🕘 ","🕗 ","🕖 ","🕕 ","🕔 ","🕓 ","🕒 ","🕑 ","🕐 "]},"aesthetic":{"interval":80,"frames":["▰▱▱▱▱▱▱","▰▰▱▱▱▱▱","▰▰▰▱▱▱▱","▰▰▰▰▱▱▱","▰▰▰▰▰▱▱","▰▰▰▰▰▰▱","▰▰▰▰▰▰▰","▰▱▱▱▱▱▱"]}}')},2598:e=>{"use strict";e.exports=JSON.parse('{"name":"create-chayns-app","version":"1.1.11","private":false,"description":"Create a new chayns® development project in one command.","keywords":["chayns","react","chayns-toolkit","chayns-components","starter-kit"],"bugs":{"url":"https://github.com/TobitSoftware/create-chayns-app/issues","email":"leonhard.driesch@tobit.com"},"repository":{"type":"git","url":"https://github.com/TobitSoftware/create-chayns-app.git"},"license":"MIT","author":{"name":"Leonhard Driesch","email":"leonhard.driesch@tobit.com"},"main":"index.js","bin":{"create-chayns-app":"dist/index.js"},"scripts":{"build":"ncc build src/index.js -o dist -m","format":"prettier . --ignore-path .gitignore --write","prepublishOnly":"yarn build","start":"node src/index.js"},"devDependencies":{"@reduxjs/toolkit":"^1.9.0","@vercel/ncc":"^0.34.0","chalk":"4.1.2","commander":"^9.4.1","enquirer":"^2.3.6","eslint":"^8.27.0","execa":"5.1.1","fast-glob":"^3.2.12","is-npm":"5.0.0","mkdirp":"^1.0.4","ora":"5.4.1","prettier":"^2.7.1","prettier-plugin-packagejson":"^2.3.0","react-redux":"^8.0.5","validate-npm-package-name":"^5.0.0"},"publishConfig":{"access":"public"}}')}};var t={};function __nccwpck_require__(r){var s=t[r];if(s!==undefined){return s.exports}var i=t[r]={id:r,loaded:false,exports:{}};var n=true;try{e[r](i,i.exports,__nccwpck_require__);n=false}finally{if(n)delete t[r]}i.loaded=true;return i.exports}(()=>{__nccwpck_require__.nmd=e=>{e.paths=[];if(!e.children)e.children=[];return e}})();if(typeof __nccwpck_require__!=="undefined")__nccwpck_require__.ab=__dirname+"/";var r={};(()=>{const{prompt:e}=__nccwpck_require__(6587);const t=__nccwpck_require__(4006);const r=__nccwpck_require__(8818);const s=__nccwpck_require__(9797);const i=__nccwpck_require__(1017);const{isYarn:n}=__nccwpck_require__(7592);const o=__nccwpck_require__(9515);const a=__nccwpck_require__(5447);const{Command:l}=__nccwpck_require__(4379);const u=__nccwpck_require__(2598);const{ProjectTypes:h,ProjectVersions:f,YesOrNo:p}=__nccwpck_require__(1397);const d=__nccwpck_require__(970);const m=__nccwpck_require__(2324);const{promisify:g}=__nccwpck_require__(3837);const y=__nccwpck_require__(7147);const b=g(y.writeFile);const _=g(y.readFile);const{command:v}=a;const w=new l;w.version(u.version).option("-G, --no-git","initialize the project without a git repository").option("-C, --no-initial-commit","don't perform an initial commit").option("-I, --no-install","don't install packages after initialization").option("-M, --module-federation","install to use as module (only internal)").option("-p, --package-manager <manager>","specify the package manager to use (`npm` or `yarn`). Defaults to the one used to execute the command.").action(createChaynsApp).parse(process.argv);async function createChaynsApp({git:l,initialCommit:u,install:g,packageManager:y,moduleFederation:w}){let E;let S;if(!w){({projectVersion:E}=await e({type:"select",name:"projectVersion",message:"What api version do you want to use?",choices:Object.values(f)}));({projectType:S}=await e({type:"select",name:"projectType",message:"What type of project do you want to create?",choices:Object.values(h)}))}let x=false;let R;while(!x){const{packageName:s}=await e([{type:"input",name:"packageName",message:"What should the name of your project be?",initial:"my-awesome-project"}]);const{validForNewPackages:i,errors:n=[],warnings:o=[]}=t(s);if(!i){console.log(`\n${r.hex("#31D1DF")(`\`${s}\``)} is unfortunately not a valid project name, because:`);for(const e of[...n,...o]){console.log(r.hex("#94A3B8")(` - ${e}`))}console.log("")}else{x=true;R=s}}const{summary:A}=await e({type:"input",message:"How would you summarize this project in a few words?",name:"summary"});function fillTemplates(e){return o(e,{"package-name":R,"readable-package-name":m(R),description:A,"install-command":O==="yarn"?"yarn":"npm install","run-command":O==="yarn"?"yarn":"npm run","package-name-underscore":R.replace("-","_")})}const C=i.resolve(R);const O=y||(n?"yarn":"npm");if(E===f.v4){console.log(`\n${r.bold.magentaBright("Awesome!")} Please wait a quick second while we bootstrap your project...\n`);switch(S){case h.page:await s({destination:C,templateDir:i.join(` ${__dirname} `.trim(),"../templates/page"),adjustContent:e=>o(fillTemplates(e),{"tapp-style":""})});break;case h.pagemakerPlugin:await s({destination:C,projectName:R,templateDir:i.join(` ${__dirname} `.trim(),"../templates/page"),adjustContent:e=>o(fillTemplates(e),{"tapp-style":' style="padding: 0 0 16px !important"'})});break}}else{const{chooseRedux:t}=await e({type:"select",name:"chooseRedux",message:"Do you want to add redux-toolkit?",choices:Object.values(p)});const{chooseTypescript:r}=await e({type:"select",name:"chooseTypescript",message:"Do you want to add typescript?",choices:Object.values(p)});const getTemplatePath=e=>i.join(` ${__dirname} `.trim(),e);const copyFile=async(e,t,r)=>{let s=await _(e,{encoding:"utf-8"});if(r){s=o(s,{"package-name":R,"readable-package-name":m(R),description:A,"install-command":O==="yarn"?"yarn":"npm install","run-command":O==="yarn"?"yarn":"npm run"})}await b(t,s)};const handleReplace=e=>o(fillTemplates(e),{"tapp-style":S===h.pagemakerPlugin?' style="padding: 0 0 16px !important"':""});if(t===p.Yes){const e=`../templates/api-v5/shared/${r===p.Yes?"ts":"js"}/src`;await s({destination:C+"/src",projectName:R,templateDir:i.join(` ${__dirname} `.trim(),e)});await copyFile(getTemplatePath(`../templates/api-v5/shared/ts/.eslintrc`),i.join(C,".eslintrc"))}const n=`../templates/api-v5/page${r===p.Yes?"-ts":""}${w?"-module":""}${t===p.Yes?"-redux":""}`;await s({destination:C,projectName:R,templateDir:getTemplatePath(n),adjustContent:handleReplace});const a=i.join(C,"package.json");await copyFile(getTemplatePath(`../templates/api-v5/shared/${r===p.Yes?"ts":"js"}/template-package${t===p.Yes?"-redux":""}.json`),a,true);await copyFile(getTemplatePath(`../templates/shared/README.md`),i.join(C,"README.md"),true);await copyFile(getTemplatePath(`../templates/shared/template-gitignore`),i.join(C,".gitignore"),true);if(r===p.Yes){await copyFile(getTemplatePath(`../templates/api-v5/shared/ts/tsconfig.json`),i.join(C,"tsconfig.json"))}if(w){const e=`toolkit.config-module.js`;const t=i.join(C,"toolkit.config.js");await copyFile(getTemplatePath(`../templates/api-v5/shared/${e}`),t)}}if(l){const e=d("Initializing Git repository").start();try{await v("git init",{cwd:C});e.succeed("Initialized a Git repository")}catch{e.fail(`Failed to initialize a Git repository. You can do this yourself by running ${r.cyanBright(`git init`)}.`)}}if(g){const e=d(`Installing packages using ${r.blueBright(O)}`).start();try{await v(`${O} install`,{cwd:C});e.succeed(`Installed packages with ${r.blueBright(O)}`)}catch{e.fail(`Failed to install packages with ${r.blueBright(O)}. You can do this yourself by running ${r.cyanBright(`${O} install`)}.`)}}if(l&&u){const e=d("Performing an initial commit").start();try{await v("git add .",{cwd:C});await a("git",["commit","-m",":tada: Initial commit"],{cwd:C});e.succeed("Perfomed an initial commit")}catch(t){console.error(t);e.fail("Failed to perform an initial commit.")}}console.log(`\n${r.bold.greenBright("Congrats!")} Your new project is ready to go!`);const k=O==="yarn"?"yarn dev":"npm run dev";console.log(`Open the created ${r.yellowBright(`./${R}/`)} folder in your favorite editor and start ${r.cyanBright("`"+k+"`")}.\n`)}})();module.exports=r})();
|
|
40
|
+
*/const i=r(3102);const toRegexRange=(e,t,r)=>{if(i(e)===false){throw new TypeError("toRegexRange: expected the first argument to be a number")}if(t===void 0||e===t){return String(e)}if(i(t)===false){throw new TypeError("toRegexRange: expected the second argument to be a number.")}let n={relaxZeros:true,...r};if(typeof n.strictZeros==="boolean"){n.relaxZeros=n.strictZeros===false}let s=String(n.relaxZeros);let o=String(n.shorthand);let a=String(n.capture);let l=String(n.wrap);let u=e+":"+t+"="+s+o+a+l;if(toRegexRange.cache.hasOwnProperty(u)){return toRegexRange.cache[u].result}let h=Math.min(e,t);let f=Math.max(e,t);if(Math.abs(h-f)===1){let r=e+"|"+t;if(n.capture){return`(${r})`}if(n.wrap===false){return r}return`(?:${r})`}let p=hasPadding(e)||hasPadding(t);let d={min:e,max:t,a:h,b:f};let m=[];let g=[];if(p){d.isPadded=p;d.maxLen=String(d.max).length}if(h<0){let e=f<0?Math.abs(f):1;g=splitToPatterns(e,Math.abs(h),d,n);h=d.a=0}if(f>=0){m=splitToPatterns(h,f,d,n)}d.negatives=g;d.positives=m;d.result=collatePatterns(g,m,n);if(n.capture===true){d.result=`(${d.result})`}else if(n.wrap!==false&&m.length+g.length>1){d.result=`(?:${d.result})`}toRegexRange.cache[u]=d;return d.result};function collatePatterns(e,t,r){let i=filterPatterns(e,t,"-",false,r)||[];let n=filterPatterns(t,e,"",false,r)||[];let s=filterPatterns(e,t,"-?",true,r)||[];let o=i.concat(s).concat(n);return o.join("|")}function splitToRanges(e,t){let r=1;let i=1;let n=countNines(e,r);let s=new Set([t]);while(e<=n&&n<=t){s.add(n);r+=1;n=countNines(e,r)}n=countZeros(t+1,i)-1;while(e<n&&n<=t){s.add(n);i+=1;n=countZeros(t+1,i)-1}s=[...s];s.sort(compare);return s}function rangeToPattern(e,t,r){if(e===t){return{pattern:e,count:[],digits:0}}let i=zip(e,t);let n=i.length;let s="";let o=0;for(let e=0;e<n;e++){let[t,n]=i[e];if(t===n){s+=t}else if(t!=="0"||n!=="9"){s+=toCharacterClass(t,n,r)}else{o++}}if(o){s+=r.shorthand===true?"\\d":"[0-9]"}return{pattern:s,count:[o],digits:n}}function splitToPatterns(e,t,r,i){let n=splitToRanges(e,t);let s=[];let o=e;let a;for(let e=0;e<n.length;e++){let t=n[e];let l=rangeToPattern(String(o),String(t),i);let u="";if(!r.isPadded&&a&&a.pattern===l.pattern){if(a.count.length>1){a.count.pop()}a.count.push(l.count[0]);a.string=a.pattern+toQuantifier(a.count);o=t+1;continue}if(r.isPadded){u=padZeros(t,r,i)}l.string=u+l.pattern+toQuantifier(l.count);s.push(l);o=t+1;a=l}return s}function filterPatterns(e,t,r,i,n){let s=[];for(let n of e){let{string:e}=n;if(!i&&!contains(t,"string",e)){s.push(r+e)}if(i&&contains(t,"string",e)){s.push(r+e)}}return s}function zip(e,t){let r=[];for(let i=0;i<e.length;i++)r.push([e[i],t[i]]);return r}function compare(e,t){return e>t?1:t>e?-1:0}function contains(e,t,r){return e.some((e=>e[t]===r))}function countNines(e,t){return Number(String(e).slice(0,-t)+"9".repeat(t))}function countZeros(e,t){return e-e%Math.pow(10,t)}function toQuantifier(e){let[t=0,r=""]=e;if(r||t>1){return`{${t+(r?","+r:"")}}`}return""}function toCharacterClass(e,t,r){return`[${e}${t-e===1?"":"-"}${t}]`}function hasPadding(e){return/^-?(0+)\d/.test(e)}function padZeros(e,t,r){if(!t.isPadded){return e}let i=Math.abs(t.maxLen-String(e).length);let n=r.relaxZeros!==false;switch(i){case 0:return"";case 1:return n?"0?":"0";case 2:return n?"0{0,2}":"00";default:{return n?`0{0,${i}}`:`0{${i}}`}}}toRegexRange.cache={};toRegexRange.clearCache=()=>toRegexRange.cache={};e.exports=toRegexRange},4488:(e,t,r)=>{e.exports=r(9023).deprecate},7825:(e,t,r)=>{"use strict";const{builtinModules:i}=r(3339);var n=new RegExp("^(?:@([^/]+?)[/])?([^/]+?)$");var s=["node_modules","favicon.ico"];function validate(e){var t=[];var r=[];if(e===null){r.push("name cannot be null");return done(t,r)}if(e===undefined){r.push("name cannot be undefined");return done(t,r)}if(typeof e!=="string"){r.push("name must be a string");return done(t,r)}if(!e.length){r.push("name length must be greater than zero")}if(e.match(/^\./)){r.push("name cannot start with a period")}if(e.match(/^_/)){r.push("name cannot start with an underscore")}if(e.trim()!==e){r.push("name cannot contain leading or trailing spaces")}s.forEach((function(t){if(e.toLowerCase()===t){r.push(t+" is a blacklisted name")}}));if(i.includes(e.toLowerCase())){t.push(e+" is a core module name")}if(e.length>214){t.push("name can no longer contain more than 214 characters")}if(e.toLowerCase()!==e){t.push("name can no longer contain capital letters")}if(/[~'!()*]/.test(e.split("/").slice(-1)[0])){t.push('name can no longer contain special characters ("~\'!()*")')}if(encodeURIComponent(e)!==e){var o=e.match(n);if(o){var a=o[1];var l=o[2];if(encodeURIComponent(a)===a&&encodeURIComponent(l)===l){return done(t,r)}}r.push("name can only contain URL-friendly characters")}return done(t,r)}var done=function(e,t){var r={validForNewPackages:t.length===0&&e.length===0,validForOldPackages:t.length===0,warnings:e,errors:t};if(!r.warnings.length){delete r.warnings}if(!r.errors.length){delete r.errors}return r};e.exports=validate},9792:e=>{e.exports=[[768,879],[1155,1158],[1160,1161],[1425,1469],[1471,1471],[1473,1474],[1476,1477],[1479,1479],[1536,1539],[1552,1557],[1611,1630],[1648,1648],[1750,1764],[1767,1768],[1770,1773],[1807,1807],[1809,1809],[1840,1866],[1958,1968],[2027,2035],[2305,2306],[2364,2364],[2369,2376],[2381,2381],[2385,2388],[2402,2403],[2433,2433],[2492,2492],[2497,2500],[2509,2509],[2530,2531],[2561,2562],[2620,2620],[2625,2626],[2631,2632],[2635,2637],[2672,2673],[2689,2690],[2748,2748],[2753,2757],[2759,2760],[2765,2765],[2786,2787],[2817,2817],[2876,2876],[2879,2879],[2881,2883],[2893,2893],[2902,2902],[2946,2946],[3008,3008],[3021,3021],[3134,3136],[3142,3144],[3146,3149],[3157,3158],[3260,3260],[3263,3263],[3270,3270],[3276,3277],[3298,3299],[3393,3395],[3405,3405],[3530,3530],[3538,3540],[3542,3542],[3633,3633],[3636,3642],[3655,3662],[3761,3761],[3764,3769],[3771,3772],[3784,3789],[3864,3865],[3893,3893],[3895,3895],[3897,3897],[3953,3966],[3968,3972],[3974,3975],[3984,3991],[3993,4028],[4038,4038],[4141,4144],[4146,4146],[4150,4151],[4153,4153],[4184,4185],[4448,4607],[4959,4959],[5906,5908],[5938,5940],[5970,5971],[6002,6003],[6068,6069],[6071,6077],[6086,6086],[6089,6099],[6109,6109],[6155,6157],[6313,6313],[6432,6434],[6439,6440],[6450,6450],[6457,6459],[6679,6680],[6912,6915],[6964,6964],[6966,6970],[6972,6972],[6978,6978],[7019,7027],[7616,7626],[7678,7679],[8203,8207],[8234,8238],[8288,8291],[8298,8303],[8400,8431],[12330,12335],[12441,12442],[43014,43014],[43019,43019],[43045,43046],[64286,64286],[65024,65039],[65056,65059],[65279,65279],[65529,65531],[68097,68099],[68101,68102],[68108,68111],[68152,68154],[68159,68159],[119143,119145],[119155,119170],[119173,119179],[119210,119213],[119362,119364],[917505,917505],[917536,917631],[917760,917999]]},7390:(e,t,r)=>{"use strict";var i=r(7730);var n=r(9792);var s={nul:0,control:0};e.exports=function wcwidth(e){return wcswidth(e,s)};e.exports.config=function(e){e=i(e||{},s);return function wcwidth(t){return wcswidth(t,e)}};function wcswidth(e,t){if(typeof e!=="string")return wcwidth(e,t);var r=0;for(var i=0;i<e.length;i++){var n=wcwidth(e.charCodeAt(i),t);if(n<0)return-1;r+=n}return r}function wcwidth(e,t){if(e===0)return t.nul;if(e<32||e>=127&&e<160)return t.control;if(bisearch(e))return 0;return 1+(e>=4352&&(e<=4447||e==9001||e==9002||e>=11904&&e<=42191&&e!=12351||e>=44032&&e<=55203||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65135||e>=65280&&e<=65376||e>=65504&&e<=65510||e>=131072&&e<=196605||e>=196608&&e<=262141))}function bisearch(e){var t=0;var r=n.length-1;var i;if(e<n[0][0]||e>n[r][1])return false;while(r>=t){i=Math.floor((t+r)/2);if(e>n[i][1])t=i+1;else if(e<n[i][0])r=i-1;else return true}return false}},6848:(e,t,r)=>{const i=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys";const n=r(6928);const s=i?";":":";const o=r(2940);const getNotFoundError=e=>Object.assign(new Error(`not found: ${e}`),{code:"ENOENT"});const getPathInfo=(e,t)=>{const r=t.colon||s;const n=e.match(/\//)||i&&e.match(/\\/)?[""]:[...i?[process.cwd()]:[],...(t.path||process.env.PATH||"").split(r)];const o=i?t.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"";const a=i?o.split(r):[""];if(i){if(e.indexOf(".")!==-1&&a[0]!=="")a.unshift("")}return{pathEnv:n,pathExt:a,pathExtExe:o}};const which=(e,t,r)=>{if(typeof t==="function"){r=t;t={}}if(!t)t={};const{pathEnv:i,pathExt:s,pathExtExe:a}=getPathInfo(e,t);const l=[];const step=r=>new Promise(((s,o)=>{if(r===i.length)return t.all&&l.length?s(l):o(getNotFoundError(e));const a=i[r];const u=/^".*"$/.test(a)?a.slice(1,-1):a;const h=n.join(u,e);const f=!u&&/^\.[\\\/]/.test(e)?e.slice(0,2)+h:h;s(subStep(f,r,0))}));const subStep=(e,r,i)=>new Promise(((n,u)=>{if(i===s.length)return n(step(r+1));const h=s[i];o(e+h,{pathExt:a},((s,o)=>{if(!s&&o){if(t.all)l.push(e+h);else return n(e+h)}return n(subStep(e,r,i+1))}))}));return r?step(0).then((e=>r(null,e)),r):step(0)};const whichSync=(e,t)=>{t=t||{};const{pathEnv:r,pathExt:i,pathExtExe:s}=getPathInfo(e,t);const a=[];for(let l=0;l<r.length;l++){const u=r[l];const h=/^".*"$/.test(u)?u.slice(1,-1):u;const f=n.join(h,e);const p=!h&&/^\.[\\\/]/.test(e)?e.slice(0,2)+f:f;for(let e=0;e<i.length;e++){const r=p+i[e];try{const e=o.sync(r,{pathExt:s});if(e){if(t.all)a.push(r);else return r}}catch(e){}}}if(t.all&&a.length)return a;if(t.nothrow)return null;throw getNotFoundError(e)};e.exports=which;which.sync=whichSync},6390:(e,t,r)=>{const i=r(6928);const n=r(4469);const{promisify:s}=r(9023);const o=r(9896);const a=r(5648);const l=s(o.writeFile);const u=s(o.readFile);e.exports=async function copyTemplate({destination:e,templateDir:t,adjustContent:r}){const s=await a("**/*",{cwd:t});const o=s.map((async s=>{let o=await u(i.join(t,s),{encoding:"utf-8"});if(typeof r==="function"){o=r(o)}const a=s.replace("template-gitignore",".gitignore").replace("template-package-redux.json","package.json").replace("template-package.json","package.json");const h=i.join(e,a);await n(i.join(h,".."));await l(h,o)}));await Promise.all(o)}},7455:e=>{const t={page:"A complete page",pagemakerPlugin:"A pagemaker plugin"};const r={v4:"v4 (Javascript api)",v5:"v5 (React api (new))"};const i={Yes:"Yes",No:"No"};e.exports={ProjectTypes:t,ProjectVersions:r,YesOrNo:i}},7822:e=>{e.exports=function mapReplace(e,t){let r=e;for(const[e,i]of Object.entries(t)){r=r.replace(new RegExp(`\\{\\{ ${e} \\}\\}`,"g"),i)}return r}},14:e=>{e.exports=function toCapitalizedWords(e){var t=e.match(/[A-Za-z][a-z]*/g)||[];return t.map(capitalize).join(" ")};function capitalize(e){return e.charAt(0).toUpperCase()+e.substring(1)}},2613:e=>{"use strict";e.exports=require("assert")},181:e=>{"use strict";e.exports=require("buffer")},5317:e=>{"use strict";e.exports=require("child_process")},4434:e=>{"use strict";e.exports=require("events")},9896:e=>{"use strict";e.exports=require("fs")},3339:e=>{"use strict";e.exports=require("module")},1421:e=>{"use strict";e.exports=require("node:child_process")},8474:e=>{"use strict";e.exports=require("node:events")},3024:e=>{"use strict";e.exports=require("node:fs")},6760:e=>{"use strict";e.exports=require("node:path")},1708:e=>{"use strict";e.exports=require("node:process")},857:e=>{"use strict";e.exports=require("os")},6928:e=>{"use strict";e.exports=require("path")},3785:e=>{"use strict";e.exports=require("readline")},2203:e=>{"use strict";e.exports=require("stream")},2018:e=>{"use strict";e.exports=require("tty")},9023:e=>{"use strict";e.exports=require("util")},8909:(e,t,r)=>{const{Argument:i}=r(9154);const{Command:n}=r(4348);const{CommanderError:s,InvalidArgumentError:o}=r(1135);const{Help:a}=r(9754);const{Option:l}=r(5240);t.program=new n;t.createCommand=e=>new n(e);t.createOption=(e,t)=>new l(e,t);t.createArgument=(e,t)=>new i(e,t);t.Command=n;t.Option=l;t.Argument=i;t.Help=a;t.CommanderError=s;t.InvalidArgumentError=o;t.InvalidOptionArgumentError=o},9154:(e,t,r)=>{const{InvalidArgumentError:i}=r(1135);class Argument{constructor(e,t){this.description=t||"";this.variadic=false;this.parseArg=undefined;this.defaultValue=undefined;this.defaultValueDescription=undefined;this.argChoices=undefined;switch(e[0]){case"<":this.required=true;this._name=e.slice(1,-1);break;case"[":this.required=false;this._name=e.slice(1,-1);break;default:this.required=true;this._name=e;break}if(this._name.length>3&&this._name.slice(-3)==="..."){this.variadic=true;this._name=this._name.slice(0,-3)}}name(){return this._name}_concatValue(e,t){if(t===this.defaultValue||!Array.isArray(t)){return[e]}return t.concat(e)}default(e,t){this.defaultValue=e;this.defaultValueDescription=t;return this}argParser(e){this.parseArg=e;return this}choices(e){this.argChoices=e.slice();this.parseArg=(e,t)=>{if(!this.argChoices.includes(e)){throw new i(`Allowed choices are ${this.argChoices.join(", ")}.`)}if(this.variadic){return this._concatValue(e,t)}return e};return this}argRequired(){this.required=true;return this}argOptional(){this.required=false;return this}}function humanReadableArgName(e){const t=e.name()+(e.variadic===true?"...":"");return e.required?"<"+t+">":"["+t+"]"}t.Argument=Argument;t.humanReadableArgName=humanReadableArgName},4348:(e,t,r)=>{const i=r(8474).EventEmitter;const n=r(1421);const s=r(6760);const o=r(3024);const a=r(1708);const{Argument:l,humanReadableArgName:u}=r(9154);const{CommanderError:h}=r(1135);const{Help:f}=r(9754);const{Option:p,DualOptions:d}=r(5240);const{suggestSimilar:m}=r(5030);class Command extends i{constructor(e){super();this.commands=[];this.options=[];this.parent=null;this._allowUnknownOption=false;this._allowExcessArguments=true;this.registeredArguments=[];this._args=this.registeredArguments;this.args=[];this.rawArgs=[];this.processedArgs=[];this._scriptPath=null;this._name=e||"";this._optionValues={};this._optionValueSources={};this._storeOptionsAsProperties=false;this._actionHandler=null;this._executableHandler=false;this._executableFile=null;this._executableDir=null;this._defaultCommandName=null;this._exitCallback=null;this._aliases=[];this._combineFlagAndOptionalValue=true;this._description="";this._summary="";this._argsDescription=undefined;this._enablePositionalOptions=false;this._passThroughOptions=false;this._lifeCycleHooks={};this._showHelpAfterError=false;this._showSuggestionAfterError=true;this._outputConfiguration={writeOut:e=>a.stdout.write(e),writeErr:e=>a.stderr.write(e),getOutHelpWidth:()=>a.stdout.isTTY?a.stdout.columns:undefined,getErrHelpWidth:()=>a.stderr.isTTY?a.stderr.columns:undefined,outputError:(e,t)=>t(e)};this._hidden=false;this._helpOption=undefined;this._addImplicitHelpCommand=undefined;this._helpCommand=undefined;this._helpConfiguration={}}copyInheritedSettings(e){this._outputConfiguration=e._outputConfiguration;this._helpOption=e._helpOption;this._helpCommand=e._helpCommand;this._helpConfiguration=e._helpConfiguration;this._exitCallback=e._exitCallback;this._storeOptionsAsProperties=e._storeOptionsAsProperties;this._combineFlagAndOptionalValue=e._combineFlagAndOptionalValue;this._allowExcessArguments=e._allowExcessArguments;this._enablePositionalOptions=e._enablePositionalOptions;this._showHelpAfterError=e._showHelpAfterError;this._showSuggestionAfterError=e._showSuggestionAfterError;return this}_getCommandAndAncestors(){const e=[];for(let t=this;t;t=t.parent){e.push(t)}return e}command(e,t,r){let i=t;let n=r;if(typeof i==="object"&&i!==null){n=i;i=null}n=n||{};const[,s,o]=e.match(/([^ ]+) *(.*)/);const a=this.createCommand(s);if(i){a.description(i);a._executableHandler=true}if(n.isDefault)this._defaultCommandName=a._name;a._hidden=!!(n.noHelp||n.hidden);a._executableFile=n.executableFile||null;if(o)a.arguments(o);this._registerCommand(a);a.parent=this;a.copyInheritedSettings(this);if(i)return this;return a}createCommand(e){return new Command(e)}createHelp(){return Object.assign(new f,this.configureHelp())}configureHelp(e){if(e===undefined)return this._helpConfiguration;this._helpConfiguration=e;return this}configureOutput(e){if(e===undefined)return this._outputConfiguration;Object.assign(this._outputConfiguration,e);return this}showHelpAfterError(e=true){if(typeof e!=="string")e=!!e;this._showHelpAfterError=e;return this}showSuggestionAfterError(e=true){this._showSuggestionAfterError=!!e;return this}addCommand(e,t){if(!e._name){throw new Error(`Command passed to .addCommand() must have a name\n- specify the name in Command constructor or using .name()`)}t=t||{};if(t.isDefault)this._defaultCommandName=e._name;if(t.noHelp||t.hidden)e._hidden=true;this._registerCommand(e);e.parent=this;e._checkForBrokenPassThrough();return this}createArgument(e,t){return new l(e,t)}argument(e,t,r,i){const n=this.createArgument(e,t);if(typeof r==="function"){n.default(i).argParser(r)}else{n.default(r)}this.addArgument(n);return this}arguments(e){e.trim().split(/ +/).forEach((e=>{this.argument(e)}));return this}addArgument(e){const t=this.registeredArguments.slice(-1)[0];if(t&&t.variadic){throw new Error(`only the last argument can be variadic '${t.name()}'`)}if(e.required&&e.defaultValue!==undefined&&e.parseArg===undefined){throw new Error(`a default value for a required argument is never used: '${e.name()}'`)}this.registeredArguments.push(e);return this}helpCommand(e,t){if(typeof e==="boolean"){this._addImplicitHelpCommand=e;return this}e=e??"help [command]";const[,r,i]=e.match(/([^ ]+) *(.*)/);const n=t??"display help for command";const s=this.createCommand(r);s.helpOption(false);if(i)s.arguments(i);if(n)s.description(n);this._addImplicitHelpCommand=true;this._helpCommand=s;return this}addHelpCommand(e,t){if(typeof e!=="object"){this.helpCommand(e,t);return this}this._addImplicitHelpCommand=true;this._helpCommand=e;return this}_getHelpCommand(){const e=this._addImplicitHelpCommand??(this.commands.length&&!this._actionHandler&&!this._findCommand("help"));if(e){if(this._helpCommand===undefined){this.helpCommand(undefined,undefined)}return this._helpCommand}return null}hook(e,t){const r=["preSubcommand","preAction","postAction"];if(!r.includes(e)){throw new Error(`Unexpected value for event passed to hook : '${e}'.\nExpecting one of '${r.join("', '")}'`)}if(this._lifeCycleHooks[e]){this._lifeCycleHooks[e].push(t)}else{this._lifeCycleHooks[e]=[t]}return this}exitOverride(e){if(e){this._exitCallback=e}else{this._exitCallback=e=>{if(e.code!=="commander.executeSubCommandAsync"){throw e}else{}}}return this}_exit(e,t,r){if(this._exitCallback){this._exitCallback(new h(e,t,r))}a.exit(e)}action(e){const listener=t=>{const r=this.registeredArguments.length;const i=t.slice(0,r);if(this._storeOptionsAsProperties){i[r]=this}else{i[r]=this.opts()}i.push(this);return e.apply(this,i)};this._actionHandler=listener;return this}createOption(e,t){return new p(e,t)}_callParseArg(e,t,r,i){try{return e.parseArg(t,r)}catch(e){if(e.code==="commander.invalidArgument"){const t=`${i} ${e.message}`;this.error(t,{exitCode:e.exitCode,code:e.code})}throw e}}_registerOption(e){const t=e.short&&this._findOption(e.short)||e.long&&this._findOption(e.long);if(t){const r=e.long&&this._findOption(e.long)?e.long:e.short;throw new Error(`Cannot add option '${e.flags}'${this._name&&` to command '${this._name}'`} due to conflicting flag '${r}'\n- already used by option '${t.flags}'`)}this.options.push(e)}_registerCommand(e){const knownBy=e=>[e.name()].concat(e.aliases());const t=knownBy(e).find((e=>this._findCommand(e)));if(t){const r=knownBy(this._findCommand(t)).join("|");const i=knownBy(e).join("|");throw new Error(`cannot add command '${i}' as already have command '${r}'`)}this.commands.push(e)}addOption(e){this._registerOption(e);const t=e.name();const r=e.attributeName();if(e.negate){const t=e.long.replace(/^--no-/,"--");if(!this._findOption(t)){this.setOptionValueWithSource(r,e.defaultValue===undefined?true:e.defaultValue,"default")}}else if(e.defaultValue!==undefined){this.setOptionValueWithSource(r,e.defaultValue,"default")}const handleOptionValue=(t,i,n)=>{if(t==null&&e.presetArg!==undefined){t=e.presetArg}const s=this.getOptionValue(r);if(t!==null&&e.parseArg){t=this._callParseArg(e,t,s,i)}else if(t!==null&&e.variadic){t=e._concatValue(t,s)}if(t==null){if(e.negate){t=false}else if(e.isBoolean()||e.optional){t=true}else{t=""}}this.setOptionValueWithSource(r,t,n)};this.on("option:"+t,(t=>{const r=`error: option '${e.flags}' argument '${t}' is invalid.`;handleOptionValue(t,r,"cli")}));if(e.envVar){this.on("optionEnv:"+t,(t=>{const r=`error: option '${e.flags}' value '${t}' from env '${e.envVar}' is invalid.`;handleOptionValue(t,r,"env")}))}return this}_optionEx(e,t,r,i,n){if(typeof t==="object"&&t instanceof p){throw new Error("To add an Option object use addOption() instead of option() or requiredOption()")}const s=this.createOption(t,r);s.makeOptionMandatory(!!e.mandatory);if(typeof i==="function"){s.default(n).argParser(i)}else if(i instanceof RegExp){const e=i;i=(t,r)=>{const i=e.exec(t);return i?i[0]:r};s.default(n).argParser(i)}else{s.default(i)}return this.addOption(s)}option(e,t,r,i){return this._optionEx({},e,t,r,i)}requiredOption(e,t,r,i){return this._optionEx({mandatory:true},e,t,r,i)}combineFlagAndOptionalValue(e=true){this._combineFlagAndOptionalValue=!!e;return this}allowUnknownOption(e=true){this._allowUnknownOption=!!e;return this}allowExcessArguments(e=true){this._allowExcessArguments=!!e;return this}enablePositionalOptions(e=true){this._enablePositionalOptions=!!e;return this}passThroughOptions(e=true){this._passThroughOptions=!!e;this._checkForBrokenPassThrough();return this}_checkForBrokenPassThrough(){if(this.parent&&this._passThroughOptions&&!this.parent._enablePositionalOptions){throw new Error(`passThroughOptions cannot be used for '${this._name}' without turning on enablePositionalOptions for parent command(s)`)}}storeOptionsAsProperties(e=true){if(this.options.length){throw new Error("call .storeOptionsAsProperties() before adding options")}if(Object.keys(this._optionValues).length){throw new Error("call .storeOptionsAsProperties() before setting option values")}this._storeOptionsAsProperties=!!e;return this}getOptionValue(e){if(this._storeOptionsAsProperties){return this[e]}return this._optionValues[e]}setOptionValue(e,t){return this.setOptionValueWithSource(e,t,undefined)}setOptionValueWithSource(e,t,r){if(this._storeOptionsAsProperties){this[e]=t}else{this._optionValues[e]=t}this._optionValueSources[e]=r;return this}getOptionValueSource(e){return this._optionValueSources[e]}getOptionValueSourceWithGlobals(e){let t;this._getCommandAndAncestors().forEach((r=>{if(r.getOptionValueSource(e)!==undefined){t=r.getOptionValueSource(e)}}));return t}_prepareUserArgs(e,t){if(e!==undefined&&!Array.isArray(e)){throw new Error("first parameter to parse must be array or undefined")}t=t||{};if(e===undefined&&t.from===undefined){if(a.versions?.electron){t.from="electron"}const e=a.execArgv??[];if(e.includes("-e")||e.includes("--eval")||e.includes("-p")||e.includes("--print")){t.from="eval"}}if(e===undefined){e=a.argv}this.rawArgs=e.slice();let r;switch(t.from){case undefined:case"node":this._scriptPath=e[1];r=e.slice(2);break;case"electron":if(a.defaultApp){this._scriptPath=e[1];r=e.slice(2)}else{r=e.slice(1)}break;case"user":r=e.slice(0);break;case"eval":r=e.slice(1);break;default:throw new Error(`unexpected parse option { from: '${t.from}' }`)}if(!this._name&&this._scriptPath)this.nameFromFilename(this._scriptPath);this._name=this._name||"program";return r}parse(e,t){const r=this._prepareUserArgs(e,t);this._parseCommand([],r);return this}async parseAsync(e,t){const r=this._prepareUserArgs(e,t);await this._parseCommand([],r);return this}_executeSubCommand(e,t){t=t.slice();let r=false;const i=[".js",".ts",".tsx",".mjs",".cjs"];function findFile(e,t){const r=s.resolve(e,t);if(o.existsSync(r))return r;if(i.includes(s.extname(t)))return undefined;const n=i.find((e=>o.existsSync(`${r}${e}`)));if(n)return`${r}${n}`;return undefined}this._checkForMissingMandatoryOptions();this._checkForConflictingOptions();let l=e._executableFile||`${this._name}-${e._name}`;let u=this._executableDir||"";if(this._scriptPath){let e;try{e=o.realpathSync(this._scriptPath)}catch(t){e=this._scriptPath}u=s.resolve(s.dirname(e),u)}if(u){let t=findFile(u,l);if(!t&&!e._executableFile&&this._scriptPath){const r=s.basename(this._scriptPath,s.extname(this._scriptPath));if(r!==this._name){t=findFile(u,`${r}-${e._name}`)}}l=t||l}r=i.includes(s.extname(l));let f;if(a.platform!=="win32"){if(r){t.unshift(l);t=incrementNodeInspectorPort(a.execArgv).concat(t);f=n.spawn(a.argv[0],t,{stdio:"inherit"})}else{f=n.spawn(l,t,{stdio:"inherit"})}}else{t.unshift(l);t=incrementNodeInspectorPort(a.execArgv).concat(t);f=n.spawn(a.execPath,t,{stdio:"inherit"})}if(!f.killed){const e=["SIGUSR1","SIGUSR2","SIGTERM","SIGINT","SIGHUP"];e.forEach((e=>{a.on(e,(()=>{if(f.killed===false&&f.exitCode===null){f.kill(e)}}))}))}const p=this._exitCallback;f.on("close",(e=>{e=e??1;if(!p){a.exit(e)}else{p(new h(e,"commander.executeSubCommandAsync","(close)"))}}));f.on("error",(t=>{if(t.code==="ENOENT"){const t=u?`searched for local subcommand relative to directory '${u}'`:"no directory for search for local subcommand, use .executableDir() to supply a custom directory";const r=`'${l}' does not exist\n - if '${e._name}' is not meant to be an executable command, remove description parameter from '.command()' and use '.description()' instead\n - if the default executable name is not suitable, use the executableFile option to supply a custom name or path\n - ${t}`;throw new Error(r)}else if(t.code==="EACCES"){throw new Error(`'${l}' not executable`)}if(!p){a.exit(1)}else{const e=new h(1,"commander.executeSubCommandAsync","(error)");e.nestedError=t;p(e)}}));this.runningCommand=f}_dispatchSubcommand(e,t,r){const i=this._findCommand(e);if(!i)this.help({error:true});let n;n=this._chainOrCallSubCommandHook(n,i,"preSubcommand");n=this._chainOrCall(n,(()=>{if(i._executableHandler){this._executeSubCommand(i,t.concat(r))}else{return i._parseCommand(t,r)}}));return n}_dispatchHelpCommand(e){if(!e){this.help()}const t=this._findCommand(e);if(t&&!t._executableHandler){t.help()}return this._dispatchSubcommand(e,[],[this._getHelpOption()?.long??this._getHelpOption()?.short??"--help"])}_checkNumberOfArguments(){this.registeredArguments.forEach(((e,t)=>{if(e.required&&this.args[t]==null){this.missingArgument(e.name())}}));if(this.registeredArguments.length>0&&this.registeredArguments[this.registeredArguments.length-1].variadic){return}if(this.args.length>this.registeredArguments.length){this._excessArguments(this.args)}}_processArguments(){const myParseArg=(e,t,r)=>{let i=t;if(t!==null&&e.parseArg){const n=`error: command-argument value '${t}' is invalid for argument '${e.name()}'.`;i=this._callParseArg(e,t,r,n)}return i};this._checkNumberOfArguments();const e=[];this.registeredArguments.forEach(((t,r)=>{let i=t.defaultValue;if(t.variadic){if(r<this.args.length){i=this.args.slice(r);if(t.parseArg){i=i.reduce(((e,r)=>myParseArg(t,r,e)),t.defaultValue)}}else if(i===undefined){i=[]}}else if(r<this.args.length){i=this.args[r];if(t.parseArg){i=myParseArg(t,i,t.defaultValue)}}e[r]=i}));this.processedArgs=e}_chainOrCall(e,t){if(e&&e.then&&typeof e.then==="function"){return e.then((()=>t()))}return t()}_chainOrCallHooks(e,t){let r=e;const i=[];this._getCommandAndAncestors().reverse().filter((e=>e._lifeCycleHooks[t]!==undefined)).forEach((e=>{e._lifeCycleHooks[t].forEach((t=>{i.push({hookedCommand:e,callback:t})}))}));if(t==="postAction"){i.reverse()}i.forEach((e=>{r=this._chainOrCall(r,(()=>e.callback(e.hookedCommand,this)))}));return r}_chainOrCallSubCommandHook(e,t,r){let i=e;if(this._lifeCycleHooks[r]!==undefined){this._lifeCycleHooks[r].forEach((e=>{i=this._chainOrCall(i,(()=>e(this,t)))}))}return i}_parseCommand(e,t){const r=this.parseOptions(t);this._parseOptionsEnv();this._parseOptionsImplied();e=e.concat(r.operands);t=r.unknown;this.args=e.concat(t);if(e&&this._findCommand(e[0])){return this._dispatchSubcommand(e[0],e.slice(1),t)}if(this._getHelpCommand()&&e[0]===this._getHelpCommand().name()){return this._dispatchHelpCommand(e[1])}if(this._defaultCommandName){this._outputHelpIfRequested(t);return this._dispatchSubcommand(this._defaultCommandName,e,t)}if(this.commands.length&&this.args.length===0&&!this._actionHandler&&!this._defaultCommandName){this.help({error:true})}this._outputHelpIfRequested(r.unknown);this._checkForMissingMandatoryOptions();this._checkForConflictingOptions();const checkForUnknownOptions=()=>{if(r.unknown.length>0){this.unknownOption(r.unknown[0])}};const i=`command:${this.name()}`;if(this._actionHandler){checkForUnknownOptions();this._processArguments();let r;r=this._chainOrCallHooks(r,"preAction");r=this._chainOrCall(r,(()=>this._actionHandler(this.processedArgs)));if(this.parent){r=this._chainOrCall(r,(()=>{this.parent.emit(i,e,t)}))}r=this._chainOrCallHooks(r,"postAction");return r}if(this.parent&&this.parent.listenerCount(i)){checkForUnknownOptions();this._processArguments();this.parent.emit(i,e,t)}else if(e.length){if(this._findCommand("*")){return this._dispatchSubcommand("*",e,t)}if(this.listenerCount("command:*")){this.emit("command:*",e,t)}else if(this.commands.length){this.unknownCommand()}else{checkForUnknownOptions();this._processArguments()}}else if(this.commands.length){checkForUnknownOptions();this.help({error:true})}else{checkForUnknownOptions();this._processArguments()}}_findCommand(e){if(!e)return undefined;return this.commands.find((t=>t._name===e||t._aliases.includes(e)))}_findOption(e){return this.options.find((t=>t.is(e)))}_checkForMissingMandatoryOptions(){this._getCommandAndAncestors().forEach((e=>{e.options.forEach((t=>{if(t.mandatory&&e.getOptionValue(t.attributeName())===undefined){e.missingMandatoryOptionValue(t)}}))}))}_checkForConflictingLocalOptions(){const e=this.options.filter((e=>{const t=e.attributeName();if(this.getOptionValue(t)===undefined){return false}return this.getOptionValueSource(t)!=="default"}));const t=e.filter((e=>e.conflictsWith.length>0));t.forEach((t=>{const r=e.find((e=>t.conflictsWith.includes(e.attributeName())));if(r){this._conflictingOption(t,r)}}))}_checkForConflictingOptions(){this._getCommandAndAncestors().forEach((e=>{e._checkForConflictingLocalOptions()}))}parseOptions(e){const t=[];const r=[];let i=t;const n=e.slice();function maybeOption(e){return e.length>1&&e[0]==="-"}let s=null;while(n.length){const e=n.shift();if(e==="--"){if(i===r)i.push(e);i.push(...n);break}if(s&&!maybeOption(e)){this.emit(`option:${s.name()}`,e);continue}s=null;if(maybeOption(e)){const t=this._findOption(e);if(t){if(t.required){const e=n.shift();if(e===undefined)this.optionMissingArgument(t);this.emit(`option:${t.name()}`,e)}else if(t.optional){let e=null;if(n.length>0&&!maybeOption(n[0])){e=n.shift()}this.emit(`option:${t.name()}`,e)}else{this.emit(`option:${t.name()}`)}s=t.variadic?t:null;continue}}if(e.length>2&&e[0]==="-"&&e[1]!=="-"){const t=this._findOption(`-${e[1]}`);if(t){if(t.required||t.optional&&this._combineFlagAndOptionalValue){this.emit(`option:${t.name()}`,e.slice(2))}else{this.emit(`option:${t.name()}`);n.unshift(`-${e.slice(2)}`)}continue}}if(/^--[^=]+=/.test(e)){const t=e.indexOf("=");const r=this._findOption(e.slice(0,t));if(r&&(r.required||r.optional)){this.emit(`option:${r.name()}`,e.slice(t+1));continue}}if(maybeOption(e)){i=r}if((this._enablePositionalOptions||this._passThroughOptions)&&t.length===0&&r.length===0){if(this._findCommand(e)){t.push(e);if(n.length>0)r.push(...n);break}else if(this._getHelpCommand()&&e===this._getHelpCommand().name()){t.push(e);if(n.length>0)t.push(...n);break}else if(this._defaultCommandName){r.push(e);if(n.length>0)r.push(...n);break}}if(this._passThroughOptions){i.push(e);if(n.length>0)i.push(...n);break}i.push(e)}return{operands:t,unknown:r}}opts(){if(this._storeOptionsAsProperties){const e={};const t=this.options.length;for(let r=0;r<t;r++){const t=this.options[r].attributeName();e[t]=t===this._versionOptionName?this._version:this[t]}return e}return this._optionValues}optsWithGlobals(){return this._getCommandAndAncestors().reduce(((e,t)=>Object.assign(e,t.opts())),{})}error(e,t){this._outputConfiguration.outputError(`${e}\n`,this._outputConfiguration.writeErr);if(typeof this._showHelpAfterError==="string"){this._outputConfiguration.writeErr(`${this._showHelpAfterError}\n`)}else if(this._showHelpAfterError){this._outputConfiguration.writeErr("\n");this.outputHelp({error:true})}const r=t||{};const i=r.exitCode||1;const n=r.code||"commander.error";this._exit(i,n,e)}_parseOptionsEnv(){this.options.forEach((e=>{if(e.envVar&&e.envVar in a.env){const t=e.attributeName();if(this.getOptionValue(t)===undefined||["default","config","env"].includes(this.getOptionValueSource(t))){if(e.required||e.optional){this.emit(`optionEnv:${e.name()}`,a.env[e.envVar])}else{this.emit(`optionEnv:${e.name()}`)}}}}))}_parseOptionsImplied(){const e=new d(this.options);const hasCustomOptionValue=e=>this.getOptionValue(e)!==undefined&&!["default","implied"].includes(this.getOptionValueSource(e));this.options.filter((t=>t.implied!==undefined&&hasCustomOptionValue(t.attributeName())&&e.valueFromOption(this.getOptionValue(t.attributeName()),t))).forEach((e=>{Object.keys(e.implied).filter((e=>!hasCustomOptionValue(e))).forEach((t=>{this.setOptionValueWithSource(t,e.implied[t],"implied")}))}))}missingArgument(e){const t=`error: missing required argument '${e}'`;this.error(t,{code:"commander.missingArgument"})}optionMissingArgument(e){const t=`error: option '${e.flags}' argument missing`;this.error(t,{code:"commander.optionMissingArgument"})}missingMandatoryOptionValue(e){const t=`error: required option '${e.flags}' not specified`;this.error(t,{code:"commander.missingMandatoryOptionValue"})}_conflictingOption(e,t){const findBestOptionFromValue=e=>{const t=e.attributeName();const r=this.getOptionValue(t);const i=this.options.find((e=>e.negate&&t===e.attributeName()));const n=this.options.find((e=>!e.negate&&t===e.attributeName()));if(i&&(i.presetArg===undefined&&r===false||i.presetArg!==undefined&&r===i.presetArg)){return i}return n||e};const getErrorMessage=e=>{const t=findBestOptionFromValue(e);const r=t.attributeName();const i=this.getOptionValueSource(r);if(i==="env"){return`environment variable '${t.envVar}'`}return`option '${t.flags}'`};const r=`error: ${getErrorMessage(e)} cannot be used with ${getErrorMessage(t)}`;this.error(r,{code:"commander.conflictingOption"})}unknownOption(e){if(this._allowUnknownOption)return;let t="";if(e.startsWith("--")&&this._showSuggestionAfterError){let r=[];let i=this;do{const e=i.createHelp().visibleOptions(i).filter((e=>e.long)).map((e=>e.long));r=r.concat(e);i=i.parent}while(i&&!i._enablePositionalOptions);t=m(e,r)}const r=`error: unknown option '${e}'${t}`;this.error(r,{code:"commander.unknownOption"})}_excessArguments(e){if(this._allowExcessArguments)return;const t=this.registeredArguments.length;const r=t===1?"":"s";const i=this.parent?` for '${this.name()}'`:"";const n=`error: too many arguments${i}. Expected ${t} argument${r} but got ${e.length}.`;this.error(n,{code:"commander.excessArguments"})}unknownCommand(){const e=this.args[0];let t="";if(this._showSuggestionAfterError){const r=[];this.createHelp().visibleCommands(this).forEach((e=>{r.push(e.name());if(e.alias())r.push(e.alias())}));t=m(e,r)}const r=`error: unknown command '${e}'${t}`;this.error(r,{code:"commander.unknownCommand"})}version(e,t,r){if(e===undefined)return this._version;this._version=e;t=t||"-V, --version";r=r||"output the version number";const i=this.createOption(t,r);this._versionOptionName=i.attributeName();this._registerOption(i);this.on("option:"+i.name(),(()=>{this._outputConfiguration.writeOut(`${e}\n`);this._exit(0,"commander.version",e)}));return this}description(e,t){if(e===undefined&&t===undefined)return this._description;this._description=e;if(t){this._argsDescription=t}return this}summary(e){if(e===undefined)return this._summary;this._summary=e;return this}alias(e){if(e===undefined)return this._aliases[0];let t=this;if(this.commands.length!==0&&this.commands[this.commands.length-1]._executableHandler){t=this.commands[this.commands.length-1]}if(e===t._name)throw new Error("Command alias can't be the same as its name");const r=this.parent?._findCommand(e);if(r){const t=[r.name()].concat(r.aliases()).join("|");throw new Error(`cannot add alias '${e}' to command '${this.name()}' as already have command '${t}'`)}t._aliases.push(e);return this}aliases(e){if(e===undefined)return this._aliases;e.forEach((e=>this.alias(e)));return this}usage(e){if(e===undefined){if(this._usage)return this._usage;const e=this.registeredArguments.map((e=>u(e)));return[].concat(this.options.length||this._helpOption!==null?"[options]":[],this.commands.length?"[command]":[],this.registeredArguments.length?e:[]).join(" ")}this._usage=e;return this}name(e){if(e===undefined)return this._name;this._name=e;return this}nameFromFilename(e){this._name=s.basename(e,s.extname(e));return this}executableDir(e){if(e===undefined)return this._executableDir;this._executableDir=e;return this}helpInformation(e){const t=this.createHelp();if(t.helpWidth===undefined){t.helpWidth=e&&e.error?this._outputConfiguration.getErrHelpWidth():this._outputConfiguration.getOutHelpWidth()}return t.formatHelp(this,t)}_getHelpContext(e){e=e||{};const t={error:!!e.error};let r;if(t.error){r=e=>this._outputConfiguration.writeErr(e)}else{r=e=>this._outputConfiguration.writeOut(e)}t.write=e.write||r;t.command=this;return t}outputHelp(e){let t;if(typeof e==="function"){t=e;e=undefined}const r=this._getHelpContext(e);this._getCommandAndAncestors().reverse().forEach((e=>e.emit("beforeAllHelp",r)));this.emit("beforeHelp",r);let i=this.helpInformation(r);if(t){i=t(i);if(typeof i!=="string"&&!Buffer.isBuffer(i)){throw new Error("outputHelp callback must return a string or a Buffer")}}r.write(i);if(this._getHelpOption()?.long){this.emit(this._getHelpOption().long)}this.emit("afterHelp",r);this._getCommandAndAncestors().forEach((e=>e.emit("afterAllHelp",r)))}helpOption(e,t){if(typeof e==="boolean"){if(e){this._helpOption=this._helpOption??undefined}else{this._helpOption=null}return this}e=e??"-h, --help";t=t??"display help for command";this._helpOption=this.createOption(e,t);return this}_getHelpOption(){if(this._helpOption===undefined){this.helpOption(undefined,undefined)}return this._helpOption}addHelpOption(e){this._helpOption=e;return this}help(e){this.outputHelp(e);let t=a.exitCode||0;if(t===0&&e&&typeof e!=="function"&&e.error){t=1}this._exit(t,"commander.help","(outputHelp)")}addHelpText(e,t){const r=["beforeAll","before","after","afterAll"];if(!r.includes(e)){throw new Error(`Unexpected value for position to addHelpText.\nExpecting one of '${r.join("', '")}'`)}const i=`${e}Help`;this.on(i,(e=>{let r;if(typeof t==="function"){r=t({error:e.error,command:e.command})}else{r=t}if(r){e.write(`${r}\n`)}}));return this}_outputHelpIfRequested(e){const t=this._getHelpOption();const r=t&&e.find((e=>t.is(e)));if(r){this.outputHelp();this._exit(0,"commander.helpDisplayed","(outputHelp)")}}}function incrementNodeInspectorPort(e){return e.map((e=>{if(!e.startsWith("--inspect")){return e}let t;let r="127.0.0.1";let i="9229";let n;if((n=e.match(/^(--inspect(-brk)?)$/))!==null){t=n[1]}else if((n=e.match(/^(--inspect(-brk|-port)?)=([^:]+)$/))!==null){t=n[1];if(/^\d+$/.test(n[3])){i=n[3]}else{r=n[3]}}else if((n=e.match(/^(--inspect(-brk|-port)?)=([^:]+):(\d+)$/))!==null){t=n[1];r=n[3];i=n[4]}if(t&&i!=="0"){return`${t}=${r}:${parseInt(i)+1}`}return e}))}t.Command=Command},1135:(e,t)=>{class CommanderError extends Error{constructor(e,t,r){super(r);Error.captureStackTrace(this,this.constructor);this.name=this.constructor.name;this.code=t;this.exitCode=e;this.nestedError=undefined}}class InvalidArgumentError extends CommanderError{constructor(e){super(1,"commander.invalidArgument",e);Error.captureStackTrace(this,this.constructor);this.name=this.constructor.name}}t.CommanderError=CommanderError;t.InvalidArgumentError=InvalidArgumentError},9754:(e,t,r)=>{const{humanReadableArgName:i}=r(9154);class Help{constructor(){this.helpWidth=undefined;this.sortSubcommands=false;this.sortOptions=false;this.showGlobalOptions=false}visibleCommands(e){const t=e.commands.filter((e=>!e._hidden));const r=e._getHelpCommand();if(r&&!r._hidden){t.push(r)}if(this.sortSubcommands){t.sort(((e,t)=>e.name().localeCompare(t.name())))}return t}compareOptions(e,t){const getSortKey=e=>e.short?e.short.replace(/^-/,""):e.long.replace(/^--/,"");return getSortKey(e).localeCompare(getSortKey(t))}visibleOptions(e){const t=e.options.filter((e=>!e.hidden));const r=e._getHelpOption();if(r&&!r.hidden){const i=r.short&&e._findOption(r.short);const n=r.long&&e._findOption(r.long);if(!i&&!n){t.push(r)}else if(r.long&&!n){t.push(e.createOption(r.long,r.description))}else if(r.short&&!i){t.push(e.createOption(r.short,r.description))}}if(this.sortOptions){t.sort(this.compareOptions)}return t}visibleGlobalOptions(e){if(!this.showGlobalOptions)return[];const t=[];for(let r=e.parent;r;r=r.parent){const e=r.options.filter((e=>!e.hidden));t.push(...e)}if(this.sortOptions){t.sort(this.compareOptions)}return t}visibleArguments(e){if(e._argsDescription){e.registeredArguments.forEach((t=>{t.description=t.description||e._argsDescription[t.name()]||""}))}if(e.registeredArguments.find((e=>e.description))){return e.registeredArguments}return[]}subcommandTerm(e){const t=e.registeredArguments.map((e=>i(e))).join(" ");return e._name+(e._aliases[0]?"|"+e._aliases[0]:"")+(e.options.length?" [options]":"")+(t?" "+t:"")}optionTerm(e){return e.flags}argumentTerm(e){return e.name()}longestSubcommandTermLength(e,t){return t.visibleCommands(e).reduce(((e,r)=>Math.max(e,t.subcommandTerm(r).length)),0)}longestOptionTermLength(e,t){return t.visibleOptions(e).reduce(((e,r)=>Math.max(e,t.optionTerm(r).length)),0)}longestGlobalOptionTermLength(e,t){return t.visibleGlobalOptions(e).reduce(((e,r)=>Math.max(e,t.optionTerm(r).length)),0)}longestArgumentTermLength(e,t){return t.visibleArguments(e).reduce(((e,r)=>Math.max(e,t.argumentTerm(r).length)),0)}commandUsage(e){let t=e._name;if(e._aliases[0]){t=t+"|"+e._aliases[0]}let r="";for(let t=e.parent;t;t=t.parent){r=t.name()+" "+r}return r+t+" "+e.usage()}commandDescription(e){return e.description()}subcommandDescription(e){return e.summary()||e.description()}optionDescription(e){const t=[];if(e.argChoices){t.push(`choices: ${e.argChoices.map((e=>JSON.stringify(e))).join(", ")}`)}if(e.defaultValue!==undefined){const r=e.required||e.optional||e.isBoolean()&&typeof e.defaultValue==="boolean";if(r){t.push(`default: ${e.defaultValueDescription||JSON.stringify(e.defaultValue)}`)}}if(e.presetArg!==undefined&&e.optional){t.push(`preset: ${JSON.stringify(e.presetArg)}`)}if(e.envVar!==undefined){t.push(`env: ${e.envVar}`)}if(t.length>0){return`${e.description} (${t.join(", ")})`}return e.description}argumentDescription(e){const t=[];if(e.argChoices){t.push(`choices: ${e.argChoices.map((e=>JSON.stringify(e))).join(", ")}`)}if(e.defaultValue!==undefined){t.push(`default: ${e.defaultValueDescription||JSON.stringify(e.defaultValue)}`)}if(t.length>0){const r=`(${t.join(", ")})`;if(e.description){return`${e.description} ${r}`}return r}return e.description}formatHelp(e,t){const r=t.padWidth(e,t);const i=t.helpWidth||80;const n=2;const s=2;function formatItem(e,o){if(o){const a=`${e.padEnd(r+s)}${o}`;return t.wrap(a,i-n,r+s)}return e}function formatList(e){return e.join("\n").replace(/^/gm," ".repeat(n))}let o=[`Usage: ${t.commandUsage(e)}`,""];const a=t.commandDescription(e);if(a.length>0){o=o.concat([t.wrap(a,i,0),""])}const l=t.visibleArguments(e).map((e=>formatItem(t.argumentTerm(e),t.argumentDescription(e))));if(l.length>0){o=o.concat(["Arguments:",formatList(l),""])}const u=t.visibleOptions(e).map((e=>formatItem(t.optionTerm(e),t.optionDescription(e))));if(u.length>0){o=o.concat(["Options:",formatList(u),""])}if(this.showGlobalOptions){const r=t.visibleGlobalOptions(e).map((e=>formatItem(t.optionTerm(e),t.optionDescription(e))));if(r.length>0){o=o.concat(["Global Options:",formatList(r),""])}}const h=t.visibleCommands(e).map((e=>formatItem(t.subcommandTerm(e),t.subcommandDescription(e))));if(h.length>0){o=o.concat(["Commands:",formatList(h),""])}return o.join("\n")}padWidth(e,t){return Math.max(t.longestOptionTermLength(e,t),t.longestGlobalOptionTermLength(e,t),t.longestSubcommandTermLength(e,t),t.longestArgumentTermLength(e,t))}wrap(e,t,r,i=40){const n=" \\f\\t\\v - \ufeff";const s=new RegExp(`[\\n][${n}]+`);if(e.match(s))return e;const o=t-r;if(o<i)return e;const a=e.slice(0,r);const l=e.slice(r).replace("\r\n","\n");const u=" ".repeat(r);const h="";const f=`\\s${h}`;const p=new RegExp(`\n|.{1,${o-1}}([${f}]|$)|[^${f}]+?([${f}]|$)`,"g");const d=l.match(p)||[];return a+d.map(((e,t)=>{if(e==="\n")return"";return(t>0?u:"")+e.trimEnd()})).join("\n")}}t.Help=Help},5240:(e,t,r)=>{const{InvalidArgumentError:i}=r(1135);class Option{constructor(e,t){this.flags=e;this.description=t||"";this.required=e.includes("<");this.optional=e.includes("[");this.variadic=/\w\.\.\.[>\]]$/.test(e);this.mandatory=false;const r=splitOptionFlags(e);this.short=r.shortFlag;this.long=r.longFlag;this.negate=false;if(this.long){this.negate=this.long.startsWith("--no-")}this.defaultValue=undefined;this.defaultValueDescription=undefined;this.presetArg=undefined;this.envVar=undefined;this.parseArg=undefined;this.hidden=false;this.argChoices=undefined;this.conflictsWith=[];this.implied=undefined}default(e,t){this.defaultValue=e;this.defaultValueDescription=t;return this}preset(e){this.presetArg=e;return this}conflicts(e){this.conflictsWith=this.conflictsWith.concat(e);return this}implies(e){let t=e;if(typeof e==="string"){t={[e]:true}}this.implied=Object.assign(this.implied||{},t);return this}env(e){this.envVar=e;return this}argParser(e){this.parseArg=e;return this}makeOptionMandatory(e=true){this.mandatory=!!e;return this}hideHelp(e=true){this.hidden=!!e;return this}_concatValue(e,t){if(t===this.defaultValue||!Array.isArray(t)){return[e]}return t.concat(e)}choices(e){this.argChoices=e.slice();this.parseArg=(e,t)=>{if(!this.argChoices.includes(e)){throw new i(`Allowed choices are ${this.argChoices.join(", ")}.`)}if(this.variadic){return this._concatValue(e,t)}return e};return this}name(){if(this.long){return this.long.replace(/^--/,"")}return this.short.replace(/^-/,"")}attributeName(){return camelcase(this.name().replace(/^no-/,""))}is(e){return this.short===e||this.long===e}isBoolean(){return!this.required&&!this.optional&&!this.negate}}class DualOptions{constructor(e){this.positiveOptions=new Map;this.negativeOptions=new Map;this.dualOptions=new Set;e.forEach((e=>{if(e.negate){this.negativeOptions.set(e.attributeName(),e)}else{this.positiveOptions.set(e.attributeName(),e)}}));this.negativeOptions.forEach(((e,t)=>{if(this.positiveOptions.has(t)){this.dualOptions.add(t)}}))}valueFromOption(e,t){const r=t.attributeName();if(!this.dualOptions.has(r))return true;const i=this.negativeOptions.get(r).presetArg;const n=i!==undefined?i:false;return t.negate===(n===e)}}function camelcase(e){return e.split("-").reduce(((e,t)=>e+t[0].toUpperCase()+t.slice(1)))}function splitOptionFlags(e){let t;let r;const i=e.split(/[ |,]+/);if(i.length>1&&!/^[[<]/.test(i[1]))t=i.shift();r=i.shift();if(!t&&/^-[^-]$/.test(r)){t=r;r=undefined}return{shortFlag:t,longFlag:r}}t.Option=Option;t.DualOptions=DualOptions},5030:(e,t)=>{const r=3;function editDistance(e,t){if(Math.abs(e.length-t.length)>r)return Math.max(e.length,t.length);const i=[];for(let t=0;t<=e.length;t++){i[t]=[t]}for(let e=0;e<=t.length;e++){i[0][e]=e}for(let r=1;r<=t.length;r++){for(let n=1;n<=e.length;n++){let s=1;if(e[n-1]===t[r-1]){s=0}else{s=1}i[n][r]=Math.min(i[n-1][r]+1,i[n][r-1]+1,i[n-1][r-1]+s);if(n>1&&r>1&&e[n-1]===t[r-2]&&e[n-2]===t[r-1]){i[n][r]=Math.min(i[n][r],i[n-2][r-2]+1)}}}return i[e.length][t.length]}function suggestSimilar(e,t){if(!t||t.length===0)return"";t=Array.from(new Set(t));const i=e.startsWith("--");if(i){e=e.slice(2);t=t.map((e=>e.slice(2)))}let n=[];let s=r;const o=.4;t.forEach((t=>{if(t.length<=1)return;const r=editDistance(e,t);const i=Math.max(e.length,t.length);const a=(i-r)/i;if(a>o){if(r<s){s=r;n=[t]}else if(r===s){n.push(t)}}}));n.sort(((e,t)=>e.localeCompare(t)));if(i){n=n.map((e=>`--${e}`))}if(n.length>1){return`\n(Did you mean one of ${n.join(", ")}?)`}if(n.length===1){return`\n(Did you mean ${n[0]}?)`}return""}t.suggestSimilar=suggestSimilar},555:(e,t,r)=>{"use strict";r.r(t);r.d(t,{isNpm:()=>l,isNpmOrYarn:()=>h,isYarn:()=>u});var i=r(1708);const n=i.env.npm_package_json;const s=i.env.npm_config_user_agent;const o=Boolean(s&&s.startsWith("npm"));const a=Boolean(n&&n.endsWith("package.json"));const l=o||a;const u=Boolean(s&&s.startsWith("yarn"));const h=l||u},8629:e=>{"use strict";e.exports=JSON.parse('{"dots":{"interval":80,"frames":["⠋","⠙","⠹","⠸","⠼","⠴","⠦","⠧","⠇","⠏"]},"dots2":{"interval":80,"frames":["⣾","⣽","⣻","⢿","⡿","⣟","⣯","⣷"]},"dots3":{"interval":80,"frames":["⠋","⠙","⠚","⠞","⠖","⠦","⠴","⠲","⠳","⠓"]},"dots4":{"interval":80,"frames":["⠄","⠆","⠇","⠋","⠙","⠸","⠰","⠠","⠰","⠸","⠙","⠋","⠇","⠆"]},"dots5":{"interval":80,"frames":["⠋","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋"]},"dots6":{"interval":80,"frames":["⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠴","⠲","⠒","⠂","⠂","⠒","⠚","⠙","⠉","⠁"]},"dots7":{"interval":80,"frames":["⠈","⠉","⠋","⠓","⠒","⠐","⠐","⠒","⠖","⠦","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈"]},"dots8":{"interval":80,"frames":["⠁","⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈","⠈"]},"dots9":{"interval":80,"frames":["⢹","⢺","⢼","⣸","⣇","⡧","⡗","⡏"]},"dots10":{"interval":80,"frames":["⢄","⢂","⢁","⡁","⡈","⡐","⡠"]},"dots11":{"interval":100,"frames":["⠁","⠂","⠄","⡀","⢀","⠠","⠐","⠈"]},"dots12":{"interval":80,"frames":["⢀⠀","⡀⠀","⠄⠀","⢂⠀","⡂⠀","⠅⠀","⢃⠀","⡃⠀","⠍⠀","⢋⠀","⡋⠀","⠍⠁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⢈⠩","⡀⢙","⠄⡙","⢂⠩","⡂⢘","⠅⡘","⢃⠨","⡃⢐","⠍⡐","⢋⠠","⡋⢀","⠍⡁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⠈⠩","⠀⢙","⠀⡙","⠀⠩","⠀⢘","⠀⡘","⠀⠨","⠀⢐","⠀⡐","⠀⠠","⠀⢀","⠀⡀"]},"dots13":{"interval":80,"frames":["⣼","⣹","⢻","⠿","⡟","⣏","⣧","⣶"]},"dots8Bit":{"interval":80,"frames":["⠀","⠁","⠂","⠃","⠄","⠅","⠆","⠇","⡀","⡁","⡂","⡃","⡄","⡅","⡆","⡇","⠈","⠉","⠊","⠋","⠌","⠍","⠎","⠏","⡈","⡉","⡊","⡋","⡌","⡍","⡎","⡏","⠐","⠑","⠒","⠓","⠔","⠕","⠖","⠗","⡐","⡑","⡒","⡓","⡔","⡕","⡖","⡗","⠘","⠙","⠚","⠛","⠜","⠝","⠞","⠟","⡘","⡙","⡚","⡛","⡜","⡝","⡞","⡟","⠠","⠡","⠢","⠣","⠤","⠥","⠦","⠧","⡠","⡡","⡢","⡣","⡤","⡥","⡦","⡧","⠨","⠩","⠪","⠫","⠬","⠭","⠮","⠯","⡨","⡩","⡪","⡫","⡬","⡭","⡮","⡯","⠰","⠱","⠲","⠳","⠴","⠵","⠶","⠷","⡰","⡱","⡲","⡳","⡴","⡵","⡶","⡷","⠸","⠹","⠺","⠻","⠼","⠽","⠾","⠿","⡸","⡹","⡺","⡻","⡼","⡽","⡾","⡿","⢀","⢁","⢂","⢃","⢄","⢅","⢆","⢇","⣀","⣁","⣂","⣃","⣄","⣅","⣆","⣇","⢈","⢉","⢊","⢋","⢌","⢍","⢎","⢏","⣈","⣉","⣊","⣋","⣌","⣍","⣎","⣏","⢐","⢑","⢒","⢓","⢔","⢕","⢖","⢗","⣐","⣑","⣒","⣓","⣔","⣕","⣖","⣗","⢘","⢙","⢚","⢛","⢜","⢝","⢞","⢟","⣘","⣙","⣚","⣛","⣜","⣝","⣞","⣟","⢠","⢡","⢢","⢣","⢤","⢥","⢦","⢧","⣠","⣡","⣢","⣣","⣤","⣥","⣦","⣧","⢨","⢩","⢪","⢫","⢬","⢭","⢮","⢯","⣨","⣩","⣪","⣫","⣬","⣭","⣮","⣯","⢰","⢱","⢲","⢳","⢴","⢵","⢶","⢷","⣰","⣱","⣲","⣳","⣴","⣵","⣶","⣷","⢸","⢹","⢺","⢻","⢼","⢽","⢾","⢿","⣸","⣹","⣺","⣻","⣼","⣽","⣾","⣿"]},"sand":{"interval":80,"frames":["⠁","⠂","⠄","⡀","⡈","⡐","⡠","⣀","⣁","⣂","⣄","⣌","⣔","⣤","⣥","⣦","⣮","⣶","⣷","⣿","⡿","⠿","⢟","⠟","⡛","⠛","⠫","⢋","⠋","⠍","⡉","⠉","⠑","⠡","⢁"]},"line":{"interval":130,"frames":["-","\\\\","|","/"]},"line2":{"interval":100,"frames":["⠂","-","–","—","–","-"]},"pipe":{"interval":100,"frames":["┤","┘","┴","└","├","┌","┬","┐"]},"simpleDots":{"interval":400,"frames":[". ",".. ","..."," "]},"simpleDotsScrolling":{"interval":200,"frames":[". ",".. ","..."," .."," ."," "]},"star":{"interval":70,"frames":["✶","✸","✹","✺","✹","✷"]},"star2":{"interval":80,"frames":["+","x","*"]},"flip":{"interval":70,"frames":["_","_","_","-","`","`","\'","´","-","_","_","_"]},"hamburger":{"interval":100,"frames":["☱","☲","☴"]},"growVertical":{"interval":120,"frames":["▁","▃","▄","▅","▆","▇","▆","▅","▄","▃"]},"growHorizontal":{"interval":120,"frames":["▏","▎","▍","▌","▋","▊","▉","▊","▋","▌","▍","▎"]},"balloon":{"interval":140,"frames":[" ",".","o","O","@","*"," "]},"balloon2":{"interval":120,"frames":[".","o","O","°","O","o","."]},"noise":{"interval":100,"frames":["▓","▒","░"]},"bounce":{"interval":120,"frames":["⠁","⠂","⠄","⠂"]},"boxBounce":{"interval":120,"frames":["▖","▘","▝","▗"]},"boxBounce2":{"interval":100,"frames":["▌","▀","▐","▄"]},"triangle":{"interval":50,"frames":["◢","◣","◤","◥"]},"binary":{"interval":80,"frames":["010010","001100","100101","111010","111101","010111","101011","111000","110011","110101"]},"arc":{"interval":100,"frames":["◜","◠","◝","◞","◡","◟"]},"circle":{"interval":120,"frames":["◡","⊙","◠"]},"squareCorners":{"interval":180,"frames":["◰","◳","◲","◱"]},"circleQuarters":{"interval":120,"frames":["◴","◷","◶","◵"]},"circleHalves":{"interval":50,"frames":["◐","◓","◑","◒"]},"squish":{"interval":100,"frames":["╫","╪"]},"toggle":{"interval":250,"frames":["⊶","⊷"]},"toggle2":{"interval":80,"frames":["▫","▪"]},"toggle3":{"interval":120,"frames":["□","■"]},"toggle4":{"interval":100,"frames":["■","□","▪","▫"]},"toggle5":{"interval":100,"frames":["▮","▯"]},"toggle6":{"interval":300,"frames":["ဝ","၀"]},"toggle7":{"interval":80,"frames":["⦾","⦿"]},"toggle8":{"interval":100,"frames":["◍","◌"]},"toggle9":{"interval":100,"frames":["◉","◎"]},"toggle10":{"interval":100,"frames":["㊂","㊀","㊁"]},"toggle11":{"interval":50,"frames":["⧇","⧆"]},"toggle12":{"interval":120,"frames":["☗","☖"]},"toggle13":{"interval":80,"frames":["=","*","-"]},"arrow":{"interval":100,"frames":["←","↖","↑","↗","→","↘","↓","↙"]},"arrow2":{"interval":80,"frames":["⬆️ ","↗️ ","➡️ ","↘️ ","⬇️ ","↙️ ","⬅️ ","↖️ "]},"arrow3":{"interval":120,"frames":["▹▹▹▹▹","▸▹▹▹▹","▹▸▹▹▹","▹▹▸▹▹","▹▹▹▸▹","▹▹▹▹▸"]},"bouncingBar":{"interval":80,"frames":["[ ]","[= ]","[== ]","[=== ]","[====]","[ ===]","[ ==]","[ =]","[ ]","[ =]","[ ==]","[ ===]","[====]","[=== ]","[== ]","[= ]"]},"bouncingBall":{"interval":80,"frames":["( ● )","( ● )","( ● )","( ● )","( ●)","( ● )","( ● )","( ● )","( ● )","(● )"]},"smiley":{"interval":200,"frames":["😄 ","😝 "]},"monkey":{"interval":300,"frames":["🙈 ","🙈 ","🙉 ","🙊 "]},"hearts":{"interval":100,"frames":["💛 ","💙 ","💜 ","💚 ","❤️ "]},"clock":{"interval":100,"frames":["🕛 ","🕐 ","🕑 ","🕒 ","🕓 ","🕔 ","🕕 ","🕖 ","🕗 ","🕘 ","🕙 ","🕚 "]},"earth":{"interval":180,"frames":["🌍 ","🌎 ","🌏 "]},"material":{"interval":17,"frames":["█▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","███▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","████▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██████▁▁▁▁▁▁▁▁▁▁▁▁▁▁","██████▁▁▁▁▁▁▁▁▁▁▁▁▁▁","███████▁▁▁▁▁▁▁▁▁▁▁▁▁","████████▁▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","██████████▁▁▁▁▁▁▁▁▁▁","███████████▁▁▁▁▁▁▁▁▁","█████████████▁▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁▁██████████████▁▁▁▁","▁▁▁██████████████▁▁▁","▁▁▁▁█████████████▁▁▁","▁▁▁▁██████████████▁▁","▁▁▁▁██████████████▁▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁██████████████▁","▁▁▁▁▁▁██████████████","▁▁▁▁▁▁██████████████","▁▁▁▁▁▁▁█████████████","▁▁▁▁▁▁▁█████████████","▁▁▁▁▁▁▁▁████████████","▁▁▁▁▁▁▁▁████████████","▁▁▁▁▁▁▁▁▁███████████","▁▁▁▁▁▁▁▁▁███████████","▁▁▁▁▁▁▁▁▁▁██████████","▁▁▁▁▁▁▁▁▁▁██████████","▁▁▁▁▁▁▁▁▁▁▁▁████████","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁██████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","█▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","██▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","███▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","████▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","█████▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","█████▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","██████▁▁▁▁▁▁▁▁▁▁▁▁▁█","████████▁▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","█████████▁▁▁▁▁▁▁▁▁▁▁","███████████▁▁▁▁▁▁▁▁▁","████████████▁▁▁▁▁▁▁▁","████████████▁▁▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","██████████████▁▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁██████████████▁▁▁▁▁","▁▁▁█████████████▁▁▁▁","▁▁▁▁▁████████████▁▁▁","▁▁▁▁▁████████████▁▁▁","▁▁▁▁▁▁███████████▁▁▁","▁▁▁▁▁▁▁▁█████████▁▁▁","▁▁▁▁▁▁▁▁█████████▁▁▁","▁▁▁▁▁▁▁▁▁█████████▁▁","▁▁▁▁▁▁▁▁▁█████████▁▁","▁▁▁▁▁▁▁▁▁▁█████████▁","▁▁▁▁▁▁▁▁▁▁▁████████▁","▁▁▁▁▁▁▁▁▁▁▁████████▁","▁▁▁▁▁▁▁▁▁▁▁▁███████▁","▁▁▁▁▁▁▁▁▁▁▁▁███████▁","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁███████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁████","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁███","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁██","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁█","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁","▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁"]},"moon":{"interval":80,"frames":["🌑 ","🌒 ","🌓 ","🌔 ","🌕 ","🌖 ","🌗 ","🌘 "]},"runner":{"interval":140,"frames":["🚶 ","🏃 "]},"pong":{"interval":80,"frames":["▐⠂ ▌","▐⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂▌","▐ ⠠▌","▐ ⡀▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐⠠ ▌"]},"shark":{"interval":120,"frames":["▐|\\\\____________▌","▐_|\\\\___________▌","▐__|\\\\__________▌","▐___|\\\\_________▌","▐____|\\\\________▌","▐_____|\\\\_______▌","▐______|\\\\______▌","▐_______|\\\\_____▌","▐________|\\\\____▌","▐_________|\\\\___▌","▐__________|\\\\__▌","▐___________|\\\\_▌","▐____________|\\\\▌","▐____________/|▌","▐___________/|_▌","▐__________/|__▌","▐_________/|___▌","▐________/|____▌","▐_______/|_____▌","▐______/|______▌","▐_____/|_______▌","▐____/|________▌","▐___/|_________▌","▐__/|__________▌","▐_/|___________▌","▐/|____________▌"]},"dqpb":{"interval":100,"frames":["d","q","p","b"]},"weather":{"interval":100,"frames":["☀️ ","☀️ ","☀️ ","🌤 ","⛅️ ","🌥 ","☁️ ","🌧 ","🌨 ","🌧 ","🌨 ","🌧 ","🌨 ","⛈ ","🌨 ","🌧 ","🌨 ","☁️ ","🌥 ","⛅️ ","🌤 ","☀️ ","☀️ "]},"christmas":{"interval":400,"frames":["🌲","🎄"]},"grenade":{"interval":80,"frames":["، ","′ "," ´ "," ‾ "," ⸌"," ⸊"," |"," ⁎"," ⁕"," ෴ "," ⁓"," "," "," "]},"point":{"interval":125,"frames":["∙∙∙","●∙∙","∙●∙","∙∙●","∙∙∙"]},"layer":{"interval":150,"frames":["-","=","≡"]},"betaWave":{"interval":80,"frames":["ρββββββ","βρβββββ","ββρββββ","βββρβββ","ββββρββ","βββββρβ","ββββββρ"]},"fingerDance":{"interval":160,"frames":["🤘 ","🤟 ","🖖 ","✋ ","🤚 ","👆 "]},"fistBump":{"interval":80,"frames":["🤜 🤛 ","🤜 🤛 ","🤜 🤛 "," 🤜 🤛 "," 🤜🤛 "," 🤜✨🤛 ","🤜 ✨ 🤛 "]},"soccerHeader":{"interval":80,"frames":[" 🧑⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 ","🧑 ⚽️ 🧑 "]},"mindblown":{"interval":160,"frames":["😐 ","😐 ","😮 ","😮 ","😦 ","😦 ","😧 ","😧 ","🤯 ","💥 ","✨ "," "," "," "]},"speaker":{"interval":160,"frames":["🔈 ","🔉 ","🔊 ","🔉 "]},"orangePulse":{"interval":100,"frames":["🔸 ","🔶 ","🟠 ","🟠 ","🔶 "]},"bluePulse":{"interval":100,"frames":["🔹 ","🔷 ","🔵 ","🔵 ","🔷 "]},"orangeBluePulse":{"interval":100,"frames":["🔸 ","🔶 ","🟠 ","🟠 ","🔶 ","🔹 ","🔷 ","🔵 ","🔵 ","🔷 "]},"timeTravel":{"interval":100,"frames":["🕛 ","🕚 ","🕙 ","🕘 ","🕗 ","🕖 ","🕕 ","🕔 ","🕓 ","🕒 ","🕑 ","🕐 "]},"aesthetic":{"interval":80,"frames":["▰▱▱▱▱▱▱","▰▰▱▱▱▱▱","▰▰▰▱▱▱▱","▰▰▰▰▱▱▱","▰▰▰▰▰▱▱","▰▰▰▰▰▰▱","▰▰▰▰▰▰▰","▰▱▱▱▱▱▱"]},"dwarfFortress":{"interval":80,"frames":[" ██████£££ ","☺██████£££ ","☺██████£££ ","☺▓█████£££ ","☺▓█████£££ ","☺▒█████£££ ","☺▒█████£££ ","☺░█████£££ ","☺░█████£££ ","☺ █████£££ "," ☺█████£££ "," ☺█████£££ "," ☺▓████£££ "," ☺▓████£££ "," ☺▒████£££ "," ☺▒████£££ "," ☺░████£££ "," ☺░████£££ "," ☺ ████£££ "," ☺████£££ "," ☺████£££ "," ☺▓███£££ "," ☺▓███£££ "," ☺▒███£££ "," ☺▒███£££ "," ☺░███£££ "," ☺░███£££ "," ☺ ███£££ "," ☺███£££ "," ☺███£££ "," ☺▓██£££ "," ☺▓██£££ "," ☺▒██£££ "," ☺▒██£££ "," ☺░██£££ "," ☺░██£££ "," ☺ ██£££ "," ☺██£££ "," ☺██£££ "," ☺▓█£££ "," ☺▓█£££ "," ☺▒█£££ "," ☺▒█£££ "," ☺░█£££ "," ☺░█£££ "," ☺ █£££ "," ☺█£££ "," ☺█£££ "," ☺▓£££ "," ☺▓£££ "," ☺▒£££ "," ☺▒£££ "," ☺░£££ "," ☺░£££ "," ☺ £££ "," ☺£££ "," ☺£££ "," ☺▓££ "," ☺▓££ "," ☺▒££ "," ☺▒££ "," ☺░££ "," ☺░££ "," ☺ ££ "," ☺££ "," ☺££ "," ☺▓£ "," ☺▓£ "," ☺▒£ "," ☺▒£ "," ☺░£ "," ☺░£ "," ☺ £ "," ☺£ "," ☺£ "," ☺▓ "," ☺▓ "," ☺▒ "," ☺▒ "," ☺░ "," ☺░ "," ☺ "," ☺ &"," ☺ ☼&"," ☺ ☼ &"," ☺☼ &"," ☺☼ & "," ‼ & "," ☺ & "," ‼ & "," ☺ & "," ‼ & "," ☺ & ","‼ & "," & "," & "," & ░ "," & ▒ "," & ▓ "," & £ "," & ░£ "," & ▒£ "," & ▓£ "," & ££ "," & ░££ "," & ▒££ ","& ▓££ ","& £££ "," ░£££ "," ▒£££ "," ▓£££ "," █£££ "," ░█£££ "," ▒█£££ "," ▓█£££ "," ██£££ "," ░██£££ "," ▒██£££ "," ▓██£££ "," ███£££ "," ░███£££ "," ▒███£££ "," ▓███£££ "," ████£££ "," ░████£££ "," ▒████£££ "," ▓████£££ "," █████£££ "," ░█████£££ "," ▒█████£££ "," ▓█████£££ "," ██████£££ "," ██████£££ "]}}')},8330:e=>{"use strict";e.exports=JSON.parse('{"name":"create-chayns-app","version":"1.1.12","private":false,"description":"Create a new chayns® development project in one command.","keywords":["chayns","react","chayns-toolkit","chayns-components","starter-kit"],"bugs":{"url":"https://github.com/TobitSoftware/create-chayns-app/issues","email":"leonhard.driesch@tobit.com"},"repository":{"type":"git","url":"https://github.com/TobitSoftware/create-chayns-app.git"},"license":"MIT","author":{"name":"Leonhard Driesch","email":"leonhard.driesch@tobit.com"},"main":"index.js","bin":{"create-chayns-app":"dist/index.js"},"scripts":{"build":"ncc build src/index.js -o dist -m","format":"prettier . --ignore-path .gitignore --write","prepublishOnly":"yarn build","start":"node src/index.js"},"devDependencies":{"@vercel/ncc":"^0.38.2","chalk":"4.1.2","commander":"12.1.0","enquirer":"^2.4.1","eslint":"^9.14.0","execa":"5.1.1","fast-glob":"^3.3.2","is-npm":"6.0.0","mkdirp":"1.0.4","ora":"5.4.1","prettier":"^3.3.3","prettier-plugin-packagejson":"^2.5.3","react-redux":"^9.1.2","validate-npm-package-name":"^6.0.0"},"publishConfig":{"access":"public"}}')}};var t={};function __nccwpck_require__(r){var i=t[r];if(i!==undefined){return i.exports}var n=t[r]={id:r,loaded:false,exports:{}};var s=true;try{e[r](n,n.exports,__nccwpck_require__);s=false}finally{if(s)delete t[r]}n.loaded=true;return n.exports}(()=>{__nccwpck_require__.d=(e,t)=>{for(var r in t){if(__nccwpck_require__.o(t,r)&&!__nccwpck_require__.o(e,r)){Object.defineProperty(e,r,{enumerable:true,get:t[r]})}}}})();(()=>{__nccwpck_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t)})();(()=>{__nccwpck_require__.r=e=>{if(typeof Symbol!=="undefined"&&Symbol.toStringTag){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})}Object.defineProperty(e,"__esModule",{value:true})}})();(()=>{__nccwpck_require__.nmd=e=>{e.paths=[];if(!e.children)e.children=[];return e}})();if(typeof __nccwpck_require__!=="undefined")__nccwpck_require__.ab=__dirname+"/";var r={};const{prompt:i}=__nccwpck_require__(9973);const n=__nccwpck_require__(7825);const s=__nccwpck_require__(465);const o=__nccwpck_require__(6390);const a=__nccwpck_require__(6928);const{isYarn:l}=__nccwpck_require__(555);const u=__nccwpck_require__(7822);const h=__nccwpck_require__(8204);const{Command:f}=__nccwpck_require__(8909);const p=__nccwpck_require__(8330);const{ProjectTypes:d,ProjectVersions:m,YesOrNo:g}=__nccwpck_require__(7455);const y=__nccwpck_require__(5696);const b=__nccwpck_require__(14);const{promisify:_}=__nccwpck_require__(9023);const v=__nccwpck_require__(9896);const w=_(v.writeFile);const S=_(v.readFile);const x=h.command;const E=new f;E.version(p.version).option("-G, --no-git","initialize the project without a git repository").option("-C, --no-initial-commit","don't perform an initial commit").option("-I, --no-install","don't install packages after initialization").option("-M, --module-federation","install to use as module (only internal)").option("-p, --package-manager <manager>","specify the package manager to use (`npm` or `yarn`). Defaults to the one used to execute the command.").action(createChaynsApp).parse(process.argv);async function createChaynsApp({git:e,initialCommit:t,install:r,packageManager:f,moduleFederation:p}){let _;let v;if(!p){({projectVersion:_}=await i({type:"select",name:"projectVersion",message:"What api version do you want to use?",choices:Object.values(m)}));({projectType:v}=await i({type:"select",name:"projectType",message:"What type of project do you want to create?",choices:Object.values(d)}))}let E=false;let A;while(!E){const{packageName:e}=await i([{type:"input",name:"packageName",message:"What should the name of your project be?",initial:"my-awesome-project"}]);const{validForNewPackages:t,errors:r=[],warnings:o=[]}=n(e);if(!t){console.log(`\n${s.hex("#31D1DF")(`\`${e}\``)} is unfortunately not a valid project name, because:`);for(const e of[...r,...o]){console.log(s.hex("#94A3B8")(` - ${e}`))}console.log("")}else{E=true;A=e}}const{summary:k}=await i({type:"input",message:"How would you summarize this project in a few words?",name:"summary"});function fillTemplates(e){return u(e,{"package-name":A,"readable-package-name":b(A),description:k,"install-command":R==="yarn"?"yarn":"npm install","run-command":R==="yarn"?"yarn":"npm run","package-name-underscore":A.replace("-","_")})}const C=a.resolve(A);const R=f||(l?"yarn":"npm");if(_===m.v4){console.log(`\n${s.bold.magentaBright("Awesome!")} Please wait a quick second while we bootstrap your project...\n`);switch(v){case d.page:await o({destination:C,templateDir:a.join(` ${__dirname} `.trim(),"../templates/page"),adjustContent:e=>u(fillTemplates(e),{"tapp-style":""})});break;case d.pagemakerPlugin:await o({destination:C,projectName:A,templateDir:a.join(` ${__dirname} `.trim(),"../templates/page"),adjustContent:e=>u(fillTemplates(e),{"tapp-style":' style="padding: 0 0 16px !important"'})});break}}else{const{chooseRedux:e}=await i({type:"select",name:"chooseRedux",message:"Do you want to add redux-toolkit?",choices:Object.values(g)});const{chooseTypescript:t}=await i({type:"select",name:"chooseTypescript",message:"Do you want to add typescript?",choices:Object.values(g)});const getTemplatePath=e=>a.join(` ${__dirname} `.trim(),e);const copyFile=async(e,t,r)=>{let i=await S(e,{encoding:"utf-8"});if(r){i=u(i,{"package-name":A,"readable-package-name":b(A),description:k,"install-command":R==="yarn"?"yarn":"npm install","run-command":R==="yarn"?"yarn":"npm run"})}await w(t,i)};const handleReplace=e=>u(fillTemplates(e),{"tapp-style":v===d.pagemakerPlugin?' style="padding: 0 0 16px !important"':""});if(e===g.Yes){const e=`../templates/api-v5/shared/${t===g.Yes?"ts":"js"}/src`;await o({destination:C+"/src",projectName:A,templateDir:a.join(` ${__dirname} `.trim(),e)});await copyFile(getTemplatePath(`../templates/api-v5/shared/ts/.eslintrc`),a.join(C,".eslintrc"))}const r=`../templates/api-v5/page${t===g.Yes?"-ts":""}${p?"-module":""}${e===g.Yes?"-redux":""}`;await o({destination:C,projectName:A,templateDir:getTemplatePath(r),adjustContent:handleReplace});const n=a.join(C,"package.json");await copyFile(getTemplatePath(`../templates/api-v5/shared/${t===g.Yes?"ts":"js"}/template-package${e===g.Yes?"-redux":""}.json`),n,true);await copyFile(getTemplatePath(`../templates/shared/README.md`),a.join(C,"README.md"),true);await copyFile(getTemplatePath(`../templates/shared/template-gitignore`),a.join(C,".gitignore"),true);if(t===g.Yes){await copyFile(getTemplatePath(`../templates/api-v5/shared/ts/tsconfig.json`),a.join(C,"tsconfig.json"))}const s=a.join(C,"toolkit.config.js");if(p){const e=`toolkit.config-module.js`;await copyFile(getTemplatePath(`../templates/api-v5/shared/${e}`),s)}else{await copyFile(getTemplatePath(`../templates/api-v5/shared/toolkit.config.js`),s)}}if(e){const e=y("Initializing Git repository").start();try{await x("git init",{cwd:C});e.succeed("Initialized a Git repository")}catch(t){throw t;e.fail(`Failed to initialize a Git repository. You can do this yourself by running ${s.cyanBright(`git init`)}.`)}}if(r){const e=y(`Installing packages using ${s.blueBright(R)}`).start();try{await x(`${R} install`,{cwd:C});e.succeed(`Installed packages with ${s.blueBright(R)}`)}catch{e.fail(`Failed to install packages with ${s.blueBright(R)}. You can do this yourself by running ${s.cyanBright(`${R} install`)}.`)}}if(e&&t){const e=y("Performing an initial commit").start();try{await x("git add .",{cwd:C});await h("git",["commit","-m",":tada: Initial commit"],{cwd:C});e.succeed("Perfomed an initial commit")}catch(t){console.error(t);e.fail("Failed to perform an initial commit.")}}console.log(`\n${s.bold.greenBright("Congrats!")} Your new project is ready to go!`);const P=R==="yarn"?"yarn dev":"npm run dev";console.log(`Open the created ${s.yellowBright(`./${A}/`)} folder in your favorite editor and start ${s.cyanBright("`"+P+"`")}.\n`)}module.exports=r})();
|