UNPKG

@servant/servant-cli

Version:

Servant builder for node modules. Cli client fro servant.

2 lines 169 kB
#!/usr/bin/env node !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("assert"),require("envfull"),require("events"),require("fs"),require("ink"),require("ink-select-input"),require("ink-spinner"),require("path"),require("util"),require("@servant/servant"),require("@servant/servant-development"),require("@servant/servant-generators"),require("react")):"function"==typeof define&&define.amd?define("@servant/servant-cli",["assert","envfull","events","fs","ink","ink-select-input","ink-spinner","path","util","@servant/servant","@servant/servant-development","@servant/servant-generators","react"],t):"object"==typeof exports?exports["@servant/servant-cli"]=t(require("assert"),require("envfull"),require("events"),require("fs"),require("ink"),require("ink-select-input"),require("ink-spinner"),require("path"),require("util"),require("@servant/servant"),require("@servant/servant-development"),require("@servant/servant-generators"),require("react")):e["@servant/servant-cli"]=t(e.assert,e.envfull,e.events,e.fs,e.ink,e["ink-select-input"],e["ink-spinner"],e.path,e.util,e["@servant/servant"],e["@servant/servant-development"],e["@servant/servant-generators"],e.React)}(this,((e,t,r,n,o,l,a,i,c,s,m,u,d)=>(()=>{var E={5911:function(e,t,r){var n,o,l;e.exports=(n=r(5400),o=r(3707),l=r(3056),(()=>{"use strict";var e={837:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.collectTS=t.collectJS=t.patterns=t.getMimeType=t.matchedOne=t.resolveAll=t.resolve=t.filter=t.matched=t.create=t.replaceAll=t.replace=void 0;const n=r(56),o=r(928),l=r(354),a=r(165),i=r(770),c=r(717),s=r(781),m=r(906),u=r(582),d=r(258),E=r(926),g=r(883);function h(e,t){const r=n.basename(e,n.extname(e))+x(t);return(0,l.normalize)(n.join(n.dirname(e),r))}function x(e){return"."===e[0]?e:`.${e}`}function f(e,t,r){const o=[];return n.extname(t)?o.push((0,l.normalize)(n.join(e,t))):r.forEach((r=>{o.push((0,l.normalize)(n.join(e,`${t}${x(r)}`)))})),o}t.replace=h,t.replaceAll=function(e,t){return t.map((t=>h(e,t)))},t.create=x,t.matched=function(e,r){return o(e,t.patterns.all(r))},t.filter=function(e,t){return e.filter((e=>{const r=n.extname(e),o=n.basename(e),l=t.some((e=>o.toLowerCase().endsWith(x(e.toLowerCase()))));return r&&l}))},t.resolve=f,t.resolveAll=function(e,r){const o=[];return r.forEach((r=>{o.push((0,l.normalize)(n.join(e,t.patterns.all(r))))})),o},t.matchedOne=function(e,t){return!!t.find((t=>{const r=x(t);return e.indexOf(r)===e.length-r.length}))},t.getMimeType=function(e){const t="."===e[0]?e.slice(1):e;return a.CONTENT_TYPE[t]||s.CONTENT_TYPE[t]||m.CONTENT_TYPE[t]||u.CONTENT_TYPE[t]||d.CONTENT_TYPE[t]||E.CONTENT_TYPE[t]||i.CONTENT_TYPE[t]||c.CONTENT_TYPE[t]||g.CONTENT_TYPE},t.patterns={all:e=>(0,l.normalize)(`**/*${x(e)}`)},t.collectJS=function(e){const t=[];return e.forEach((e=>{const r=f(n.dirname(e),n.basename(e),m.EXT);t.push(...r.map((e=>E.isTS(e)?m.toJS(e):E.isTSX(e)?m.toJSX(e):(0,l.normalize)(e))))})),[...new Set([...t])]},t.collectTS=function(e){const t=[];return e.forEach((e=>{const r=f(n.dirname(e),n.basename(e),E.EXT);t.push(...r.map((e=>(0,l.normalize)(e))))})),t}},354:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.patterns=t.directory=t.join=t.matchedOne=t.matched=t.normalize=void 0;const n=r(928),o=r(56),l=r(484);function a(e){return e.replace(/\\/g,"/")}t.normalize=a,t.matched=function(e,t){return n(e,a(t))},t.matchedOne=function(e,t){return t.some((t=>n(e,a(t))))},t.join=function(e,t){return t.map((t=>a(o.join(e,t))))},t.directory=function(e,t){const r=a(t).split("/"),n=[];for(;r.length>0;){const e=r.shift();if(l.hasMagic(e))break;e&&n.push(e)}return a(o.join(e,n.join("/")))},t.patterns={all:e=>a(o.join(e,"**/*")),everywhere:e=>a(o.join("**",e))}},165:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isCSS=t.only=t.toCSS=t.CONTENT_TYPE=t.MAIN=t.REGEX=t.EXT=void 0;const n=r(837),o=["css"];t.EXT=o,t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.MAIN=o[0],t.CONTENT_TYPE={css:"text/css"},t.toCSS=function(e){return(0,n.replace)(e,(0,n.create)(o[0]))},t.only=function(e){return(0,n.filter)(e,o)},t.isCSS=function(e){return(0,n.matched)(e,o[0])}},781:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.toHTML=t.CONTENT_TYPE=t.MAIN=t.REGEX=t.EXT=void 0;const n=r(837),o=["html"];t.EXT=o,t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.MAIN=o[0],t.CONTENT_TYPE={html:"text/html"},t.toHTML=function(e){return(0,n.replace)(e,(0,n.create)(o[0]))}},906:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isJavascript=t.only=t.isMJS=t.isJSX=t.isJS=t.toMJS=t.toJSX=t.toJS=t.CONTENT_TYPE=t.MAIN=t.REGEX=t.EXT=void 0;const n=r(837),o=["js","jsx","mjs"];function l(e){return(0,n.matched)(e,o[0])}function a(e){return(0,n.matched)(e,o[1])}function i(e){return(0,n.matched)(e,o[2])}t.EXT=o,t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.MAIN=o[0],t.CONTENT_TYPE={js:"text/javascript",jsx:"text/javascript",mjs:"text/javascript"},t.toJS=function(e){return(0,n.replace)(e,(0,n.create)(o[0]))},t.toJSX=function(e){return(0,n.replace)(e,(0,n.create)(o[1]))},t.toMJS=function(e){return(0,n.replace)(e,(0,n.create)(o[2]))},t.isJS=l,t.isJSX=a,t.isMJS=i,t.only=function(e){return(0,n.filter)(e,o)},t.isJavascript=function(e){return l(e)||a(e)||i(e)}},582:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.toJSON=t.CONTENT_TYPE=t.MAIN=t.REGEX=t.EXT=void 0;const n=r(837),o=["json"];t.EXT=o,t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.MAIN=o[0],t.CONTENT_TYPE={json:"application/json"},t.toJSON=function(e){return(0,n.replace)(e,(0,n.create)(o[0]))}},770:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.only=t.isLESS=t.toLESS=t.fromCss=t.CONTENT_TYPE=t.MAIN=t.REGEX=t.EXT=void 0;const n=r(837),o=r(165),l=["less"];function a(e){return(0,n.replace)(e,(0,n.create)(l[0]))}t.EXT=l,t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.MAIN=l[0],t.CONTENT_TYPE={less:"plain/text"},t.fromCss=function(e){return o.isCSS(e)?a(e):null},t.toLESS=a,t.isLESS=function(e){return(0,n.matched)(e,l[0])},t.only=function(e){return(0,n.filter)(e,l)}},258:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CONTENT_TYPE=t.REGEX=t.EXT=void 0,t.EXT=["png","jpg","gif","svg","eot","ttf","woff","woff2","ico","webp"],t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.CONTENT_TYPE={png:"image/png",jpg:"image/jpeg",gif:"image/gif",svg:"image/svg+xml",eot:"application/vnd.ms-fontobject",ttf:"font/ttf",woff:"font/woff",woff2:"font/woff2",ico:"image/x-icon",webp:"image/webp"}},717:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.only=t.isSASS=t.toSASS=t.fromCss=t.CONTENT_TYPE=t.MAIN=t.REGEX=t.EXT=void 0;const n=r(837),o=r(165),l=["scss"];function a(e){return(0,n.replace)(e,(0,n.create)(l[0]))}t.EXT=l,t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.MAIN=l[0],t.CONTENT_TYPE={scss:"plain/text"},t.fromCss=function(e){return o.isCSS(e)?a(e):null},t.toSASS=a,t.isSASS=function(e){return(0,n.matched)(e,l[0])},t.only=function(e){return(0,n.filter)(e,l)}},926:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isTypescript=t.toJS=t.isMAP=t.isDTS=t.isTSX=t.isTS=t.toDTS=t.toTSX=t.toTS=t.fromDTS=t.fromJs=t.only=t.CONTENT_TYPE=t.MAP=t.DECLARATION=t.MAIN=t.REGEX=t.EXT=void 0;const n=r(837),o=r(906),l=["ts","tsx"],a="d.ts",i="js.map";function c(e){return(0,n.replace)(e,(0,n.create)(l[0]))}function s(e){return(0,n.replace)(e,(0,n.create)(l[1]))}function m(e){return(0,n.matched)(e,l[0])}function u(e){return(0,n.matched)(e,l[1])}function d(e){const t=(0,n.create)(a);return(0,n.matched)(e,l[0])&&e.indexOf(t)===e.length-t.length}t.EXT=l,t.REGEX=new RegExp("\\.("+t.EXT.join("|")+")$"),t.MAIN=l[0],t.DECLARATION=a,t.MAP=i,t.CONTENT_TYPE={ts:"text/x.typescript",tsx:"text/x.typescript"},t.only=function(e){return(0,n.filter)(e,l)},t.fromJs=function(e){return o.isJS(e)||o.isJSX(e)?[c(e),s(e)]:null},t.fromDTS=function(e){return d(e)?l.map((t=>e.replace((0,n.create)(a),(0,n.create)(t)))):null},t.toTS=c,t.toTSX=s,t.toDTS=function(e){return d(e)?e:(0,n.replace)(e,(0,n.create)(a))},t.isTS=m,t.isTSX=u,t.isDTS=d,t.isMAP=function(e){const t=(0,n.create)(i);return e.indexOf(t)===e.length-t.length},t.toJS=function(e){return(0,n.create)(e)===(0,n.create)(l[0])?(0,n.create)(o.EXT[0]):(0,n.create)(e)===(0,n.create)(l[1])?(0,n.create)(o.EXT[1]):null},t.isTypescript=function(e){return m(e)||u(e)}},883:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CONTENT_TYPE=t.MAIN=t.REGEX=t.EXT=void 0;const r=["*"];t.EXT=r,t.REGEX=new RegExp("\\."+t.EXT.join("|")+"$"),t.MAIN=r[0],t.CONTENT_TYPE="application/octet-stream"},484:e=>{e.exports=n},928:e=>{e.exports=o},56:e=>{e.exports=l}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var l=t[n]={exports:{}};return e[n](l,l.exports,r),l.exports}var a={};return(()=>{var e=a;Object.defineProperty(e,"__esModule",{value:!0}),e.UNKNOWN=e.SASS=e.LESS=e.HTML=e.JSON=e.JS=e.TS=e.CSS=e.RESOURCES=e.Extensions=e.Path=void 0;const t=r(837);e.Extensions=t;const n=r(354);e.Path=n;const o=r(165);e.CSS=o;const l=r(926);e.TS=l;const i=r(906);e.JS=i;const c=r(258);e.RESOURCES=c;const s=r(582);e.JSON=s;const m=r(781);e.HTML=m;const u=r(770);e.LESS=u;const d=r(717);e.SASS=d;const E=r(883);e.UNKNOWN=E})(),a})())},838:e=>{"use strict";function t(e,t,o){e instanceof RegExp&&(e=r(e,o)),t instanceof RegExp&&(t=r(t,o));var l=n(e,t,o);return l&&{start:l[0],end:l[1],pre:o.slice(0,l[0]),body:o.slice(l[0]+e.length,l[1]),post:o.slice(l[1]+t.length)}}function r(e,t){var r=t.match(e);return r?r[0]:null}function n(e,t,r){var n,o,l,a,i,c=r.indexOf(e),s=r.indexOf(t,c+1),m=c;if(c>=0&&s>0){if(e===t)return[c,s];for(n=[],l=r.length;m>=0&&!i;)m==c?(n.push(m),c=r.indexOf(e,m+1)):1==n.length?i=[n.pop(),s]:((o=n.pop())<l&&(l=o,a=s),s=r.indexOf(t,m+1)),m=c<s&&c>=0?c:s;n.length&&(i=[l,a])}return i}e.exports=t,t.range=n},5457:(e,t,r)=>{var n=r(838);e.exports=function(e){return e?("{}"===e.substr(0,2)&&(e="\\{\\}"+e.substr(2)),x(function(e){return e.split("\\\\").join(o).split("\\{").join(l).split("\\}").join(a).split("\\,").join(i).split("\\.").join(c)}(e),!0).map(m)):[]};var o="\0SLASH"+Math.random()+"\0",l="\0OPEN"+Math.random()+"\0",a="\0CLOSE"+Math.random()+"\0",i="\0COMMA"+Math.random()+"\0",c="\0PERIOD"+Math.random()+"\0";function s(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function m(e){return e.split(o).join("\\").split(l).join("{").split(a).join("}").split(i).join(",").split(c).join(".")}function u(e){if(!e)return[""];var t=[],r=n("{","}",e);if(!r)return e.split(",");var o=r.pre,l=r.body,a=r.post,i=o.split(",");i[i.length-1]+="{"+l+"}";var c=u(a);return a.length&&(i[i.length-1]+=c.shift(),i.push.apply(i,c)),t.push.apply(t,i),t}function d(e){return"{"+e+"}"}function E(e){return/^-?0\d/.test(e)}function g(e,t){return e<=t}function h(e,t){return e>=t}function x(e,t){var r=[],o=n("{","}",e);if(!o)return[e];var l=o.pre,i=o.post.length?x(o.post,!1):[""];if(/\$$/.test(o.pre))for(var c=0;c<i.length;c++){var m=l+"{"+o.body+"}"+i[c];r.push(m)}else{var f,p,T=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(o.body),b=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(o.body),y=T||b,v=o.body.indexOf(",")>=0;if(!y&&!v)return o.post.match(/,.*\}/)?x(e=o.pre+"{"+o.body+a+o.post):[e];if(y)f=o.body.split(/\.\./);else if(1===(f=u(o.body)).length&&1===(f=x(f[0],!1).map(d)).length)return i.map((function(e){return o.pre+f[0]+e}));if(y){var B=s(f[0]),w=s(f[1]),O=Math.max(f[0].length,f[1].length),D=3==f.length?Math.abs(s(f[2])):1,S=g;w<B&&(D*=-1,S=h);var j=f.some(E);p=[];for(var _=B;S(_,w);_+=D){var k;if(b)"\\"===(k=String.fromCharCode(_))&&(k="");else if(k=String(_),j){var M=O-k.length;if(M>0){var C=new Array(M+1).join("0");k=_<0?"-"+C+k.slice(1):C+k}}p.push(k)}}else{p=[];for(var L=0;L<f.length;L++)p.push.apply(p,x(f[L],!1))}for(L=0;L<p.length;L++)for(c=0;c<i.length;c++)m=l+p[L]+i[c],(!t||y||m)&&r.push(m)}return r}},2008:(e,t,r)=>{e.exports=m,m.realpath=m,m.sync=u,m.realpathSync=u,m.monkeypatch=function(){n.realpath=m,n.realpathSync=u},m.unmonkeypatch=function(){n.realpath=o,n.realpathSync=l};var n=r(2089),o=n.realpath,l=n.realpathSync,a=process.version,i=/^v[0-5]\./.test(a),c=r(184);function s(e){return e&&"realpath"===e.syscall&&("ELOOP"===e.code||"ENOMEM"===e.code||"ENAMETOOLONG"===e.code)}function m(e,t,r){if(i)return o(e,t,r);"function"==typeof t&&(r=t,t=null),o(e,t,(function(n,o){s(n)?c.realpath(e,t,r):r(n,o)}))}function u(e,t){if(i)return l(e,t);try{return l(e,t)}catch(r){if(s(r))return c.realpathSync(e,t);throw r}}},184:(e,t,r)=>{var n=r(3056),o="win32"===process.platform,l=r(2089),a=process.env.NODE_DEBUG&&/fs/.test(process.env.NODE_DEBUG);if(n.normalize,o)var i=/(.*?)(?:[\/\\]+|$)/g;else i=/(.*?)(?:[\/]+|$)/g;if(o)var c=/^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/;else c=/^[\/]*/;t.realpathSync=function(e,t){if(e=n.resolve(e),t&&Object.prototype.hasOwnProperty.call(t,e))return t[e];var r,a,s,m,u=e,d={},E={};function g(){var t=c.exec(e);r=t[0].length,a=t[0],s=t[0],m="",o&&!E[s]&&(l.lstatSync(s),E[s]=!0)}for(g();r<e.length;){i.lastIndex=r;var h=i.exec(e);if(m=a,a+=h[0],s=m+h[1],r=i.lastIndex,!(E[s]||t&&t[s]===s)){var x;if(t&&Object.prototype.hasOwnProperty.call(t,s))x=t[s];else{var f=l.lstatSync(s);if(!f.isSymbolicLink()){E[s]=!0,t&&(t[s]=s);continue}var p=null;if(!o){var T=f.dev.toString(32)+":"+f.ino.toString(32);d.hasOwnProperty(T)&&(p=d[T])}null===p&&(l.statSync(s),p=l.readlinkSync(s)),x=n.resolve(m,p),t&&(t[s]=x),o||(d[T]=p)}e=n.resolve(x,e.slice(r)),g()}}return t&&(t[u]=e),e},t.realpath=function(e,t,r){if("function"!=typeof r&&(r=function(e){return"function"==typeof e?e:function(){var e;if(a){var t=new Error;e=function(e){e&&(t.message=e.message,r(e=t))}}else e=r;return e;function r(e){if(e){if(process.throwDeprecation)throw e;if(!process.noDeprecation){var t="fs: missing callback "+(e.stack||e.message);process.traceDeprecation?console.trace(t):console.error(t)}}}}()}(t),t=null),e=n.resolve(e),t&&Object.prototype.hasOwnProperty.call(t,e))return process.nextTick(r.bind(null,null,t[e]));var s,m,u,d,E=e,g={},h={};function x(){var t=c.exec(e);s=t[0].length,m=t[0],u=t[0],d="",o&&!h[u]?l.lstat(u,(function(e){if(e)return r(e);h[u]=!0,f()})):process.nextTick(f)}function f(){if(s>=e.length)return t&&(t[E]=e),r(null,e);i.lastIndex=s;var n=i.exec(e);return d=m,m+=n[0],u=d+n[1],s=i.lastIndex,h[u]||t&&t[u]===u?process.nextTick(f):t&&Object.prototype.hasOwnProperty.call(t,u)?b(t[u]):l.lstat(u,p)}function p(e,n){if(e)return r(e);if(!n.isSymbolicLink())return h[u]=!0,t&&(t[u]=u),process.nextTick(f);if(!o){var a=n.dev.toString(32)+":"+n.ino.toString(32);if(g.hasOwnProperty(a))return T(null,g[a],u)}l.stat(u,(function(e){if(e)return r(e);l.readlink(u,(function(e,t){o||(g[a]=t),T(e,t)}))}))}function T(e,o,l){if(e)return r(e);var a=n.resolve(d,o);t&&(t[l]=a),b(a)}function b(t){e=n.resolve(t,e.slice(s)),x()}x()}},846:(e,t,r)=>{function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.setopts=function(e,t,r){if(r||(r={}),r.matchBase&&-1===t.indexOf("/")){if(r.noglobstar)throw new Error("base matching requires globstar");t="**/"+t}e.windowsPathsNoEscape=!!r.windowsPathsNoEscape||!1===r.allowWindowsEscape,e.windowsPathsNoEscape&&(t=t.replace(/\\/g,"/")),e.silent=!!r.silent,e.pattern=t,e.strict=!1!==r.strict,e.realpath=!!r.realpath,e.realpathCache=r.realpathCache||Object.create(null),e.follow=!!r.follow,e.dot=!!r.dot,e.mark=!!r.mark,e.nodir=!!r.nodir,e.nodir&&(e.mark=!0),e.sync=!!r.sync,e.nounique=!!r.nounique,e.nonull=!!r.nonull,e.nosort=!!r.nosort,e.nocase=!!r.nocase,e.stat=!!r.stat,e.noprocess=!!r.noprocess,e.absolute=!!r.absolute,e.fs=r.fs||o,e.maxLength=r.maxLength||1/0,e.cache=r.cache||Object.create(null),e.statCache=r.statCache||Object.create(null),e.symlinks=r.symlinks||Object.create(null),function(e,t){e.ignore=t.ignore||[],Array.isArray(e.ignore)||(e.ignore=[e.ignore]),e.ignore.length&&(e.ignore=e.ignore.map(m))}(e,r),e.changedCwd=!1;var a=process.cwd();n(r,"cwd")?(e.cwd=l.resolve(r.cwd),e.changedCwd=e.cwd!==a):e.cwd=l.resolve(a),e.root=r.root||l.resolve(e.cwd,"/"),e.root=l.resolve(e.root),e.cwdAbs=i(e.cwd)?e.cwd:u(e,e.cwd),e.nomount=!!r.nomount,"win32"===process.platform&&(e.root=e.root.replace(/\\/g,"/"),e.cwd=e.cwd.replace(/\\/g,"/"),e.cwdAbs=e.cwdAbs.replace(/\\/g,"/")),r.nonegate=!0,r.nocomment=!0,e.minimatch=new c(t,r),e.options=e.minimatch.options},t.ownProp=n,t.makeAbs=u,t.finish=function(e){for(var t=e.nounique,r=t?[]:Object.create(null),n=0,o=e.matches.length;n<o;n++){var l=e.matches[n];if(l&&0!==Object.keys(l).length){var a=Object.keys(l);t?r.push.apply(r,a):a.forEach((function(e){r[e]=!0}))}else if(e.nonull){var i=e.minimatch.globSet[n];t?r.push(i):r[i]=!0}}if(t||(r=Object.keys(r)),e.nosort||(r=r.sort(s)),e.mark){for(n=0;n<r.length;n++)r[n]=e._mark(r[n]);e.nodir&&(r=r.filter((function(t){var r=!/\/$/.test(t),n=e.cache[t]||e.cache[u(e,t)];return r&&n&&(r="DIR"!==n&&!Array.isArray(n)),r})))}e.ignore.length&&(r=r.filter((function(t){return!d(e,t)}))),e.found=r},t.mark=function(e,t){var r=u(e,t),n=e.cache[r],o=t;if(n){var l="DIR"===n||Array.isArray(n),a="/"===t.slice(-1);if(l&&!a?o+="/":!l&&a&&(o=o.slice(0,-1)),o!==t){var i=u(e,o);e.statCache[i]=e.statCache[r],e.cache[i]=e.cache[r]}}return o},t.isIgnored=d,t.childrenIgnored=function(e,t){return!!e.ignore.length&&e.ignore.some((function(e){return!(!e.gmatcher||!e.gmatcher.match(t))}))};var o=r(2089),l=r(3056),a=r(3707),i=r(3056).isAbsolute,c=a.Minimatch;function s(e,t){return e.localeCompare(t,"en")}function m(e){var t=null;if("/**"===e.slice(-3)){var r=e.replace(/(\/\*\*)+$/,"");t=new c(r,{dot:!0})}return{matcher:new c(e,{dot:!0}),gmatcher:t}}function u(e,t){var r=t;return r="/"===t.charAt(0)?l.join(e.root,t):i(t)||""===t?t:e.changedCwd?l.resolve(e.cwd,t):l.resolve(t),"win32"===process.platform&&(r=r.replace(/\\/g,"/")),r}function d(e,t){return!!e.ignore.length&&e.ignore.some((function(e){return e.matcher.match(t)||!(!e.gmatcher||!e.gmatcher.match(t))}))}},5400:(e,t,r)=>{e.exports=p;var n=r(2008),o=r(3707),l=(o.Minimatch,r(87)),a=r(3735).EventEmitter,i=r(3056),c=r(9249),s=r(3056).isAbsolute,m=r(6306),u=r(846),d=u.setopts,E=u.ownProp,g=r(1656),h=(r(4269),u.childrenIgnored),x=u.isIgnored,f=r(4132);function p(e,t,r){if("function"==typeof t&&(r=t,t={}),t||(t={}),t.sync){if(r)throw new TypeError("callback provided to sync glob");return m(e,t)}return new b(e,t,r)}p.sync=m;var T=p.GlobSync=m.GlobSync;function b(e,t,r){if("function"==typeof t&&(r=t,t=null),t&&t.sync){if(r)throw new TypeError("callback provided to sync glob");return new T(e,t)}if(!(this instanceof b))return new b(e,t,r);d(this,e,t),this._didRealPath=!1;var n=this.minimatch.set.length;this.matches=new Array(n),"function"==typeof r&&(r=f(r),this.on("error",r),this.on("end",(function(e){r(null,e)})));var o=this;if(this._processing=0,this._emitQueue=[],this._processQueue=[],this.paused=!1,this.noprocess)return this;if(0===n)return i();for(var l=!0,a=0;a<n;a++)this._process(this.minimatch.set[a],a,!1,i);function i(){--o._processing,o._processing<=0&&(l?process.nextTick((function(){o._finish()})):o._finish())}l=!1}p.glob=p,p.hasMagic=function(e,t){var r=function(e,t){if(null===t||"object"!=typeof t)return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}({},t);r.noprocess=!0;var n=new b(e,r).minimatch.set;if(!e)return!1;if(n.length>1)return!0;for(var o=0;o<n[0].length;o++)if("string"!=typeof n[0][o])return!0;return!1},p.Glob=b,l(b,a),b.prototype._finish=function(){if(c(this instanceof b),!this.aborted){if(this.realpath&&!this._didRealpath)return this._realpath();u.finish(this),this.emit("end",this.found)}},b.prototype._realpath=function(){if(!this._didRealpath){this._didRealpath=!0;var e=this.matches.length;if(0===e)return this._finish();for(var t=this,r=0;r<this.matches.length;r++)this._realpathSet(r,n)}function n(){0==--e&&t._finish()}},b.prototype._realpathSet=function(e,t){var r=this.matches[e];if(!r)return t();var o=Object.keys(r),l=this,a=o.length;if(0===a)return t();var i=this.matches[e]=Object.create(null);o.forEach((function(r,o){r=l._makeAbs(r),n.realpath(r,l.realpathCache,(function(n,o){n?"stat"===n.syscall?i[r]=!0:l.emit("error",n):i[o]=!0,0==--a&&(l.matches[e]=i,t())}))}))},b.prototype._mark=function(e){return u.mark(this,e)},b.prototype._makeAbs=function(e){return u.makeAbs(this,e)},b.prototype.abort=function(){this.aborted=!0,this.emit("abort")},b.prototype.pause=function(){this.paused||(this.paused=!0,this.emit("pause"))},b.prototype.resume=function(){if(this.paused){if(this.emit("resume"),this.paused=!1,this._emitQueue.length){var e=this._emitQueue.slice(0);this._emitQueue.length=0;for(var t=0;t<e.length;t++){var r=e[t];this._emitMatch(r[0],r[1])}}if(this._processQueue.length){var n=this._processQueue.slice(0);for(this._processQueue.length=0,t=0;t<n.length;t++){var o=n[t];this._processing--,this._process(o[0],o[1],o[2],o[3])}}}},b.prototype._process=function(e,t,r,n){if(c(this instanceof b),c("function"==typeof n),!this.aborted)if(this._processing++,this.paused)this._processQueue.push([e,t,r,n]);else{for(var l,a=0;"string"==typeof e[a];)a++;switch(a){case e.length:return void this._processSimple(e.join("/"),t,n);case 0:l=null;break;default:l=e.slice(0,a).join("/")}var i,m=e.slice(a);null===l?i=".":s(l)||s(e.map((function(e){return"string"==typeof e?e:"[*]"})).join("/"))?(l&&s(l)||(l="/"+l),i=l):i=l;var u=this._makeAbs(i);if(h(this,i))return n();m[0]===o.GLOBSTAR?this._processGlobStar(l,i,u,m,t,r,n):this._processReaddir(l,i,u,m,t,r,n)}},b.prototype._processReaddir=function(e,t,r,n,o,l,a){var i=this;this._readdir(r,l,(function(c,s){return i._processReaddir2(e,t,r,n,o,l,s,a)}))},b.prototype._processReaddir2=function(e,t,r,n,o,l,a,c){if(!a)return c();for(var s=n[0],m=!!this.minimatch.negate,u=s._glob,d=this.dot||"."===u.charAt(0),E=[],g=0;g<a.length;g++)("."!==(x=a[g]).charAt(0)||d)&&(m&&!e?!x.match(s):x.match(s))&&E.push(x);var h=E.length;if(0===h)return c();if(1===n.length&&!this.mark&&!this.stat){for(this.matches[o]||(this.matches[o]=Object.create(null)),g=0;g<h;g++){var x=E[g];e&&(x="/"!==e?e+"/"+x:e+x),"/"!==x.charAt(0)||this.nomount||(x=i.join(this.root,x)),this._emitMatch(o,x)}return c()}for(n.shift(),g=0;g<h;g++)x=E[g],e&&(x="/"!==e?e+"/"+x:e+x),this._process([x].concat(n),o,l,c);c()},b.prototype._emitMatch=function(e,t){if(!this.aborted&&!x(this,t))if(this.paused)this._emitQueue.push([e,t]);else{var r=s(t)?t:this._makeAbs(t);if(this.mark&&(t=this._mark(t)),this.absolute&&(t=r),!this.matches[e][t]){if(this.nodir){var n=this.cache[r];if("DIR"===n||Array.isArray(n))return}this.matches[e][t]=!0;var o=this.statCache[r];o&&this.emit("stat",t,o),this.emit("match",t)}}},b.prototype._readdirInGlobStar=function(e,t){if(!this.aborted){if(this.follow)return this._readdir(e,!1,t);var r=this,n=g("lstat\0"+e,(function(n,o){if(n&&"ENOENT"===n.code)return t();var l=o&&o.isSymbolicLink();r.symlinks[e]=l,l||!o||o.isDirectory()?r._readdir(e,!1,t):(r.cache[e]="FILE",t())}));n&&r.fs.lstat(e,n)}},b.prototype._readdir=function(e,t,r){if(!this.aborted&&(r=g("readdir\0"+e+"\0"+t,r))){if(t&&!E(this.symlinks,e))return this._readdirInGlobStar(e,r);if(E(this.cache,e)){var n=this.cache[e];if(!n||"FILE"===n)return r();if(Array.isArray(n))return r(null,n)}this.fs.readdir(e,function(e,t,r){return function(n,o){n?e._readdirError(t,n,r):e._readdirEntries(t,o,r)}}(this,e,r))}},b.prototype._readdirEntries=function(e,t,r){if(!this.aborted){if(!this.mark&&!this.stat)for(var n=0;n<t.length;n++){var o=t[n];o="/"===e?e+o:e+"/"+o,this.cache[o]=!0}return this.cache[e]=t,r(null,t)}},b.prototype._readdirError=function(e,t,r){if(!this.aborted){switch(t.code){case"ENOTSUP":case"ENOTDIR":var n=this._makeAbs(e);if(this.cache[n]="FILE",n===this.cwdAbs){var o=new Error(t.code+" invalid cwd "+this.cwd);o.path=this.cwd,o.code=t.code,this.emit("error",o),this.abort()}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(e)]=!1;break;default:this.cache[this._makeAbs(e)]=!1,this.strict&&(this.emit("error",t),this.abort()),this.silent||console.error("glob error",t)}return r()}},b.prototype._processGlobStar=function(e,t,r,n,o,l,a){var i=this;this._readdir(r,l,(function(c,s){i._processGlobStar2(e,t,r,n,o,l,s,a)}))},b.prototype._processGlobStar2=function(e,t,r,n,o,l,a,i){if(!a)return i();var c=n.slice(1),s=e?[e]:[],m=s.concat(c);this._process(m,o,!1,i);var u=this.symlinks[r],d=a.length;if(u&&l)return i();for(var E=0;E<d;E++)if("."!==a[E].charAt(0)||this.dot){var g=s.concat(a[E],c);this._process(g,o,!0,i);var h=s.concat(a[E],n);this._process(h,o,!0,i)}i()},b.prototype._processSimple=function(e,t,r){var n=this;this._stat(e,(function(o,l){n._processSimple2(e,t,o,l,r)}))},b.prototype._processSimple2=function(e,t,r,n,o){if(this.matches[t]||(this.matches[t]=Object.create(null)),!n)return o();if(e&&s(e)&&!this.nomount){var l=/[\/\\]$/.test(e);"/"===e.charAt(0)?e=i.join(this.root,e):(e=i.resolve(this.root,e),l&&(e+="/"))}"win32"===process.platform&&(e=e.replace(/\\/g,"/")),this._emitMatch(t,e),o()},b.prototype._stat=function(e,t){var r=this._makeAbs(e),n="/"===e.slice(-1);if(e.length>this.maxLength)return t();if(!this.stat&&E(this.cache,r)){var o=this.cache[r];if(Array.isArray(o)&&(o="DIR"),!n||"DIR"===o)return t(null,o);if(n&&"FILE"===o)return t()}var l=this.statCache[r];if(void 0!==l){if(!1===l)return t(null,l);var a=l.isDirectory()?"DIR":"FILE";return n&&"FILE"===a?t():t(null,a,l)}var i=this,c=g("stat\0"+r,(function(n,o){if(o&&o.isSymbolicLink())return i.fs.stat(r,(function(n,l){n?i._stat2(e,r,null,o,t):i._stat2(e,r,n,l,t)}));i._stat2(e,r,n,o,t)}));c&&i.fs.lstat(r,c)},b.prototype._stat2=function(e,t,r,n,o){if(r&&("ENOENT"===r.code||"ENOTDIR"===r.code))return this.statCache[t]=!1,o();var l="/"===e.slice(-1);if(this.statCache[t]=n,"/"===t.slice(-1)&&n&&!n.isDirectory())return o(null,!1,n);var a=!0;return n&&(a=n.isDirectory()?"DIR":"FILE"),this.cache[t]=this.cache[t]||a,l&&"FILE"===a?o():o(null,a,n)}},6306:(e,t,r)=>{e.exports=E,E.GlobSync=g;var n=r(2008),o=r(3707),l=(o.Minimatch,r(5400).Glob,r(4269),r(3056)),a=r(9249),i=r(3056).isAbsolute,c=r(846),s=c.setopts,m=c.ownProp,u=c.childrenIgnored,d=c.isIgnored;function E(e,t){if("function"==typeof t||3===arguments.length)throw new TypeError("callback provided to sync glob\nSee: https://github.com/isaacs/node-glob/issues/167");return new g(e,t).found}function g(e,t){if(!e)throw new Error("must provide pattern");if("function"==typeof t||3===arguments.length)throw new TypeError("callback provided to sync glob\nSee: https://github.com/isaacs/node-glob/issues/167");if(!(this instanceof g))return new g(e,t);if(s(this,e,t),this.noprocess)return this;var r=this.minimatch.set.length;this.matches=new Array(r);for(var n=0;n<r;n++)this._process(this.minimatch.set[n],n,!1);this._finish()}g.prototype._finish=function(){if(a.ok(this instanceof g),this.realpath){var e=this;this.matches.forEach((function(t,r){var o=e.matches[r]=Object.create(null);for(var l in t)try{l=e._makeAbs(l),o[n.realpathSync(l,e.realpathCache)]=!0}catch(t){if("stat"!==t.syscall)throw t;o[e._makeAbs(l)]=!0}}))}c.finish(this)},g.prototype._process=function(e,t,r){a.ok(this instanceof g);for(var n,l=0;"string"==typeof e[l];)l++;switch(l){case e.length:return void this._processSimple(e.join("/"),t);case 0:n=null;break;default:n=e.slice(0,l).join("/")}var c,s=e.slice(l);null===n?c=".":i(n)||i(e.map((function(e){return"string"==typeof e?e:"[*]"})).join("/"))?(n&&i(n)||(n="/"+n),c=n):c=n;var m=this._makeAbs(c);u(this,c)||(s[0]===o.GLOBSTAR?this._processGlobStar(n,c,m,s,t,r):this._processReaddir(n,c,m,s,t,r))},g.prototype._processReaddir=function(e,t,r,n,o,a){var i=this._readdir(r,a);if(i){for(var c=n[0],s=!!this.minimatch.negate,m=c._glob,u=this.dot||"."===m.charAt(0),d=[],E=0;E<i.length;E++)("."!==(x=i[E]).charAt(0)||u)&&(s&&!e?!x.match(c):x.match(c))&&d.push(x);var g=d.length;if(0!==g)if(1!==n.length||this.mark||this.stat)for(n.shift(),E=0;E<g;E++){var h;x=d[E],h=e?[e,x]:[x],this._process(h.concat(n),o,a)}else{this.matches[o]||(this.matches[o]=Object.create(null));for(E=0;E<g;E++){var x=d[E];e&&(x="/"!==e.slice(-1)?e+"/"+x:e+x),"/"!==x.charAt(0)||this.nomount||(x=l.join(this.root,x)),this._emitMatch(o,x)}}}},g.prototype._emitMatch=function(e,t){if(!d(this,t)){var r=this._makeAbs(t);if(this.mark&&(t=this._mark(t)),this.absolute&&(t=r),!this.matches[e][t]){if(this.nodir){var n=this.cache[r];if("DIR"===n||Array.isArray(n))return}this.matches[e][t]=!0,this.stat&&this._stat(t)}}},g.prototype._readdirInGlobStar=function(e){if(this.follow)return this._readdir(e,!1);var t,r;try{r=this.fs.lstatSync(e)}catch(e){if("ENOENT"===e.code)return null}var n=r&&r.isSymbolicLink();return this.symlinks[e]=n,n||!r||r.isDirectory()?t=this._readdir(e,!1):this.cache[e]="FILE",t},g.prototype._readdir=function(e,t){if(t&&!m(this.symlinks,e))return this._readdirInGlobStar(e);if(m(this.cache,e)){var r=this.cache[e];if(!r||"FILE"===r)return null;if(Array.isArray(r))return r}try{return this._readdirEntries(e,this.fs.readdirSync(e))}catch(t){return this._readdirError(e,t),null}},g.prototype._readdirEntries=function(e,t){if(!this.mark&&!this.stat)for(var r=0;r<t.length;r++){var n=t[r];n="/"===e?e+n:e+"/"+n,this.cache[n]=!0}return this.cache[e]=t,t},g.prototype._readdirError=function(e,t){switch(t.code){case"ENOTSUP":case"ENOTDIR":var r=this._makeAbs(e);if(this.cache[r]="FILE",r===this.cwdAbs){var n=new Error(t.code+" invalid cwd "+this.cwd);throw n.path=this.cwd,n.code=t.code,n}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(e)]=!1;break;default:if(this.cache[this._makeAbs(e)]=!1,this.strict)throw t;this.silent||console.error("glob error",t)}},g.prototype._processGlobStar=function(e,t,r,n,o,l){var a=this._readdir(r,l);if(a){var i=n.slice(1),c=e?[e]:[],s=c.concat(i);this._process(s,o,!1);var m=a.length;if(!this.symlinks[r]||!l)for(var u=0;u<m;u++)if("."!==a[u].charAt(0)||this.dot){var d=c.concat(a[u],i);this._process(d,o,!0);var E=c.concat(a[u],n);this._process(E,o,!0)}}},g.prototype._processSimple=function(e,t){var r=this._stat(e);if(this.matches[t]||(this.matches[t]=Object.create(null)),r){if(e&&i(e)&&!this.nomount){var n=/[\/\\]$/.test(e);"/"===e.charAt(0)?e=l.join(this.root,e):(e=l.resolve(this.root,e),n&&(e+="/"))}"win32"===process.platform&&(e=e.replace(/\\/g,"/")),this._emitMatch(t,e)}},g.prototype._stat=function(e){var t=this._makeAbs(e),r="/"===e.slice(-1);if(e.length>this.maxLength)return!1;if(!this.stat&&m(this.cache,t)){var n=this.cache[t];if(Array.isArray(n)&&(n="DIR"),!r||"DIR"===n)return n;if(r&&"FILE"===n)return!1}var o=this.statCache[t];if(!o){var l;try{l=this.fs.lstatSync(t)}catch(e){if(e&&("ENOENT"===e.code||"ENOTDIR"===e.code))return this.statCache[t]=!1,!1}if(l&&l.isSymbolicLink())try{o=this.fs.statSync(t)}catch(e){o=l}else o=l}return this.statCache[t]=o,n=!0,o&&(n=o.isDirectory()?"DIR":"FILE"),this.cache[t]=this.cache[t]||n,(!r||"FILE"!==n)&&n},g.prototype._mark=function(e){return c.mark(this,e)},g.prototype._makeAbs=function(e){return c.makeAbs(this,e)}},1656:(e,t,r)=>{var n=r(7477),o=Object.create(null),l=r(4132);e.exports=n((function(e,t){return o[e]?(o[e].push(t),null):(o[e]=[t],function(e){return l((function t(){var r=o[e],n=r.length,l=function(e){for(var t=e.length,r=[],n=0;n<t;n++)r[n]=e[n];return r}(arguments);try{for(var a=0;a<n;a++)r[a].apply(null,l)}finally{r.length>n?(r.splice(0,n),process.nextTick((function(){t.apply(null,l)}))):delete o[e]}}))}(e))}))},87:e=>{"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},9121:e=>{const t="object"==typeof process&&process&&"win32"===process.platform;e.exports=t?{sep:"\\"}:{sep:"/"}},3707:(e,t,r)=>{const n=e.exports=(e,t,r={})=>(x(t),!(!r.nocomment&&"#"===t.charAt(0))&&new p(t,r).match(e));e.exports=n;const o=r(9121);n.sep=o.sep;const l=Symbol("globstar **");n.GLOBSTAR=l;const a=r(5457),i={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}},c="[^/]",s=c+"*?",m=e=>e.split("").reduce(((e,t)=>(e[t]=!0,e)),{}),u=m("().*{}+?[]^$\\!"),d=m("[.("),E=/\/+/;n.filter=(e,t={})=>(r,o,l)=>n(r,e,t);const g=(e,t={})=>{const r={};return Object.keys(e).forEach((t=>r[t]=e[t])),Object.keys(t).forEach((e=>r[e]=t[e])),r};n.defaults=e=>{if(!e||"object"!=typeof e||!Object.keys(e).length)return n;const t=n,r=(r,n,o)=>t(r,n,g(e,o));return(r.Minimatch=class extends t.Minimatch{constructor(t,r){super(t,g(e,r))}}).defaults=r=>t.defaults(g(e,r)).Minimatch,r.filter=(r,n)=>t.filter(r,g(e,n)),r.defaults=r=>t.defaults(g(e,r)),r.makeRe=(r,n)=>t.makeRe(r,g(e,n)),r.braceExpand=(r,n)=>t.braceExpand(r,g(e,n)),r.match=(r,n,o)=>t.match(r,n,g(e,o)),r},n.braceExpand=(e,t)=>h(e,t);const h=(e,t={})=>(x(e),t.nobrace||!/\{(?:(?!\{).)*\}/.test(e)?[e]:a(e)),x=e=>{if("string"!=typeof e)throw new TypeError("invalid pattern");if(e.length>65536)throw new TypeError("pattern is too long")},f=Symbol("subparse");n.makeRe=(e,t)=>new p(e,t||{}).makeRe(),n.match=(e,t,r={})=>{const n=new p(t,r);return e=e.filter((e=>n.match(e))),n.options.nonull&&!e.length&&e.push(t),e};class p{constructor(e,t){x(e),t||(t={}),this.options=t,this.set=[],this.pattern=e,this.windowsPathsNoEscape=!!t.windowsPathsNoEscape||!1===t.allowWindowsEscape,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.regexp=null,this.negate=!1,this.comment=!1,this.empty=!1,this.partial=!!t.partial,this.make()}debug(){}make(){const e=this.pattern,t=this.options;if(!t.nocomment&&"#"===e.charAt(0))return void(this.comment=!0);if(!e)return void(this.empty=!0);this.parseNegate();let r=this.globSet=this.braceExpand();t.debug&&(this.debug=(...e)=>console.error(...e)),this.debug(this.pattern,r),r=this.globParts=r.map((e=>e.split(E))),this.debug(this.pattern,r),r=r.map(((e,t,r)=>e.map(this.parse,this))),this.debug(this.pattern,r),r=r.filter((e=>-1===e.indexOf(!1))),this.debug(this.pattern,r),this.set=r}parseNegate(){if(this.options.nonegate)return;const e=this.pattern;let t=!1,r=0;for(let n=0;n<e.length&&"!"===e.charAt(n);n++)t=!t,r++;r&&(this.pattern=e.slice(r)),this.negate=t}matchOne(e,t,r){var n=this.options;this.debug("matchOne",{this:this,file:e,pattern:t}),this.debug("matchOne",e.length,t.length);for(var o=0,a=0,i=e.length,c=t.length;o<i&&a<c;o++,a++){this.debug("matchOne loop");var s,m=t[a],u=e[o];if(this.debug(t,m,u),!1===m)return!1;if(m===l){this.debug("GLOBSTAR",[t,m,u]);var d=o,E=a+1;if(E===c){for(this.debug("** at the end");o<i;o++)if("."===e[o]||".."===e[o]||!n.dot&&"."===e[o].charAt(0))return!1;return!0}for(;d<i;){var g=e[d];if(this.debug("\nglobstar while",e,d,t,E,g),this.matchOne(e.slice(d),t.slice(E),r))return this.debug("globstar found match!",d,i,g),!0;if("."===g||".."===g||!n.dot&&"."===g.charAt(0)){this.debug("dot detected!",e,d,t,E);break}this.debug("globstar swallow a segment, and continue"),d++}return!(!r||(this.debug("\n>>> no match, partial?",e,d,t,E),d!==i))}if("string"==typeof m?(s=u===m,this.debug("string match",m,u,s)):(s=u.match(m),this.debug("pattern match",m,u,s)),!s)return!1}if(o===i&&a===c)return!0;if(o===i)return r;if(a===c)return o===i-1&&""===e[o];throw new Error("wtf?")}braceExpand(){return h(this.pattern,this.options)}parse(e,t){x(e);const r=this.options;if("**"===e){if(!r.noglobstar)return l;e="*"}if(""===e)return"";let n="",o=!1,a=!1;const m=[],E=[];let g,h,p,T,b=!1,y=-1,v=-1,B="."===e.charAt(0),w=r.dot||B;const O=e=>"."===e.charAt(0)?"":r.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",D=()=>{if(g){switch(g){case"*":n+=s,o=!0;break;case"?":n+=c,o=!0;break;default:n+="\\"+g}this.debug("clearStateChar %j %j",g,n),g=!1}};for(let t,l=0;l<e.length&&(t=e.charAt(l));l++)if(this.debug("%s\t%s %s %j",e,l,n,t),a){if("/"===t)return!1;u[t]&&(n+="\\"),n+=t,a=!1}else switch(t){case"/":return!1;case"\\":if(b&&"-"===e.charAt(l+1)){n+=t;continue}D(),a=!0;continue;case"?":case"*":case"+":case"@":case"!":if(this.debug("%s\t%s %s %j <-- stateChar",e,l,n,t),b){this.debug(" in class"),"!"===t&&l===v+1&&(t="^"),n+=t;continue}this.debug("call clearStateChar %j",g),D(),g=t,r.noext&&D();continue;case"(":{if(b){n+="(";continue}if(!g){n+="\\(";continue}const t={type:g,start:l-1,reStart:n.length,open:i[g].open,close:i[g].close};this.debug(this.pattern,"\t",t),m.push(t),n+=t.open,0===t.start&&"!"!==t.type&&(B=!0,n+=O(e.slice(l+1))),this.debug("plType %j %j",g,n),g=!1;continue}case")":{const e=m[m.length-1];if(b||!e){n+="\\)";continue}m.pop(),D(),o=!0,p=e,n+=p.close,"!"===p.type&&E.push(Object.assign(p,{reEnd:n.length}));continue}case"|":{const t=m[m.length-1];if(b||!t){n+="\\|";continue}D(),n+="|",0===t.start&&"!"!==t.type&&(B=!0,n+=O(e.slice(l+1)));continue}case"[":if(D(),b){n+="\\"+t;continue}b=!0,v=l,y=n.length,n+=t;continue;case"]":if(l===v+1||!b){n+="\\"+t;continue}h=e.substring(v+1,l);try{RegExp("["+(h.replace(/\\([^-\]])/g,"$1").replace(/[[\]\\]/g,"\\$&")+"]")),n+=t}catch(e){n=n.substring(0,y)+"(?:$.)"}o=!0,b=!1;continue;default:D(),!u[t]||"^"===t&&b||(n+="\\"),n+=t}for(b&&(h=e.slice(v+1),T=this.parse(h,f),n=n.substring(0,y)+"\\["+T[0],o=o||T[1]),p=m.pop();p;p=m.pop()){let e;e=n.slice(p.reStart+p.open.length),this.debug("setting tail",n,p),e=e.replace(/((?:\\{2}){0,64})(\\?)\|/g,((e,t,r)=>(r||(r="\\"),t+t+r+"|"))),this.debug("tail=%j\n %s",e,e,p,n);const t="*"===p.type?s:"?"===p.type?c:"\\"+p.type;o=!0,n=n.slice(0,p.reStart)+t+"\\("+e}D(),a&&(n+="\\\\");const S=d[n.charAt(0)];for(let e=E.length-1;e>-1;e--){const r=E[e],o=n.slice(0,r.reStart),l=n.slice(r.reStart,r.reEnd-8);let a=n.slice(r.reEnd);const i=n.slice(r.reEnd-8,r.reEnd)+a,c=o.split(")").length,s=o.split("(").length-c;let m=a;for(let e=0;e<s;e++)m=m.replace(/\)[+*?]?/,"");a=m,n=o+l+a+(""===a&&t!==f?"(?:$|\\/)":"")+i}if(""!==n&&o&&(n="(?=.)"+n),S&&(n=(B?"":w?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)")+n),t===f)return[n,o];if(r.nocase&&!o&&(o=e.toUpperCase()!==e.toLowerCase()),!o)return(e=>e.replace(/\\(.)/g,"$1"))(e);const j=r.nocase?"i":"";try{return Object.assign(new RegExp("^"+n+"$",j),{_glob:e,_src:n})}catch(e){return new RegExp("$.")}}makeRe(){if(this.regexp||!1===this.regexp)return this.regexp;const e=this.set;if(!e.length)return this.regexp=!1,this.regexp;const t=this.options,r=t.noglobstar?s:t.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",n=t.nocase?"i":"";let o=e.map((e=>(e=e.map((e=>"string"==typeof e?e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):e===l?l:e._src)).reduce(((e,t)=>(e[e.length-1]===l&&t===l||e.push(t),e)),[]),e.forEach(((t,n)=>{t===l&&e[n-1]!==l&&(0===n?e.length>1?e[n+1]="(?:\\/|"+r+"\\/)?"+e[n+1]:e[n]=r:n===e.length-1?e[n-1]+="(?:\\/|"+r+")?":(e[n-1]+="(?:\\/|\\/"+r+"\\/)"+e[n+1],e[n+1]=l))})),e.filter((e=>e!==l)).join("/")))).join("|");o="^(?:"+o+")$",this.negate&&(o="^(?!"+o+").*$");try{this.regexp=new RegExp(o,n)}catch(e){this.regexp=!1}return this.regexp}match(e,t=this.partial){if(this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return""===e;if("/"===e&&t)return!0;const r=this.options;"/"!==o.sep&&(e=e.split(o.sep).join("/")),e=e.split(E),this.debug(this.pattern,"split",e);const n=this.set;let l;this.debug(this.pattern,"set",n);for(let t=e.length-1;t>=0&&(l=e[t],!l);t--);for(let o=0;o<n.length;o++){const a=n[o];let i=e;if(r.matchBase&&1===a.length&&(i=[l]),this.matchOne(i,a,t))return!!r.flipNegate||!this.negate}return!r.flipNegate&&this.negate}static defaults(e){return n.defaults(e).Minimatch}}n.Minimatch=p},4132:(e,t,r)=>{var n=r(7477);function o(e){var t=function(){return t.called?t.value:(t.called=!0,t.value=e.apply(this,arguments))};return t.called=!1,t}function l(e){var t=function(){if(t.called)throw new Error(t.onceError);return t.called=!0,t.value=e.apply(this,arguments)},r=e.name||"Function wrapped with `once`";return t.onceError=r+" shouldn't be called more than once",t.called=!1,t}e.exports=n(o),e.exports.strict=n(l),o.proto=o((function(){Object.defineProperty(Function.prototype,"once",{value:function(){return o(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return l(this)},configurable:!0})}))},5027:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VALIDATE_FIRST_COLUMN=t.UNIFY_SECOND_COLUMN=t.UNIFY_FIRST_COLUMN=t.SECOND_COLUMN=t.FIRST_COLUMN=t.MODULE_COLUMN=t.INDEX_COLUMN=void 0,t.INDEX_COLUMN=3,t.MODULE_COLUMN=40,t.FIRST_COLUMN=20,t.SECOND_COLUMN=15,t.UNIFY_FIRST_COLUMN=50,t.UNIFY_SECOND_COLUMN=30,t.VALIDATE_FIRST_COLUMN=50},7567:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.processShared=t.processChanges=t.processClients=t.processServers=t.Server=void 0;const n=r(3536);Object.defineProperty(t,"Server",{enumerable:!0,get:function(){return n.Server}});const o=r(5019);Object.defineProperty(t,"processServers",{enumerable:!0,get:function(){return o.processServers}}),Object.defineProperty(t,"processClients",{enumerable:!0,get:function(){return o.processClients}}),Object.defineProperty(t,"processChanges",{enumerable:!0,get:function(){return o.processChanges}}),Object.defineProperty(t,"processShared",{enumerable:!0,get:function(){return o.processShared}})},5019:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.processShared=t.processChanges=t.processClients=t.processServers=void 0;const n=r(7955);t.processServers=function(e,t){if(!n.isServantServerDevLog(t))return e;const{module:r,pid:o,status:l,stdoutCount:a,stderrCount:i,error:c}=t,s=e[r]||{};return e[r]=Object.assign(Object.assign({},s),{status:l,pid:o,error:c,stderrCount:i,stdoutCount:a}),e},t.processClients=function(e,t){if(!n.isServantClientDevLog(t))return e;const{module:r,status:o,error:l}=t,a=e[r]||{};return e[r]=Object.assign(Object.assign({},a),{status:o,error:l}),e},t.processChanges=function(e,t){if(!n.isServantChangesDevLog(t))return e;const{files:r,modules:o,errors:l,time:a,date:i}=t;return 0===o.length||e.push({errors:l,changed:{modules:o.slice(0),files:r.map((([e])=>e))},date:i,time:a}),e},t.processShared=function(e,t){if(!n.isServantSharedDevLog(t))return e;const{id:r,error:o,status:l}=t,a=e[r]||{};return e[r]=Object.assign(Object.assign({},a),{status:l,error:o}),e}},6184:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Generate=void 0;const n=r(1789);Object.defineProperty(t,"Generate",{enumerable:!0,get:function(){return n.Generate}})},9480:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Help=void 0;const n=r(9661);Object.defineProperty(t,"Help",{enumerable:!0,get:function(){return n.Help}})},4903:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InitInstall=t.Init=void 0;const n=r(2405);Object.defineProperty(t,"Init",{enumerable:!0,get:function(){return n.Init}});const o=r(211);Object.defineProperty(t,"InitInstall",{enumerable:!0,get:function(){return o.InitInstall}})},9985:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Unify=void 0;const n=r(6340);Object.defineProperty(t,"Unify",{enumerable:!0,get:function(){return n.Unify}})},5309:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.deferred=void 0,t.deferred=function(){let e,t;const r=new Promise(((r,n)=>{e=r,t=n}));return r.resolve=e,r.reject=t,r}},4837:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Analyzer=t.Analyze=void 0;const n=r(9949);Object.defineProperty(t,"Analyze",{enumerable:!0,get:function(){return n.Analyze}});const o=r(7463);Object.defineProperty(t,"Analyzer",{enumerable:!0,get:function(){return o.Analyzer}})},5393:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BuildError=t.BuildWarning=t.Build=void 0;const n=r(7531);Object.defineProperty(t,"Build",{enumerable:!0,get:function(){return n.Build}});const o=r(2087);Object.defineProperty(t,"BuildError",{enumerable:!0,get:function(){return o.BuildError}});const l=r(5591);Object.defineProperty(t,"BuildWarning",{enumerable:!0,get:function(){return l.BuildWarning}})},2720:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Clean=void 0;const n=r(5647);Object.defineProperty(t,"Clean",{enumerable:!0,get:function(){return n.Clean}})},5825:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Footer=void 0;const n=r(7599);Object.defineProperty(t,"Footer",{enumerable:!0,get:function(){return n.Footer}})},6988:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FlagHeader=t.Header=void 0;const n=r(8263);Object.defineProperty(t,"FlagHeader",{enumerable:!0,get:function(){return n.FlagHeader}});const o=r(4392);Object.defineProperty(t,"Header",{enumerable:!0,get:function(){return o.Header}})},5:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mergeBugs=t.AnalyzerStatus=t.GenerateAction=t.UnifyAction=t.InitAction=t.Analyzer=t.Warning=t.Error=t.DotResult=t.Result=t.Command=t.Modules=t.Footer=t.Header=void 0;const n=r(4942);Object.defineProperty(t,"Error",{enumerable:!0,get:function(){return n.Error}});const o=r(1949);Object.defineProperty(t,"Modules",{enumerable:!0,get:function(){return o.Modules}}),Object.defineProperty(t,"Command",{enumerable:!0,get:function(){return o.Command}});const l=r(7610);Object.defineProperty(t,"Result",{enumerable:!0,get:function(){return l.Result}}),Object.defineProperty(t,"DotResult",{enumerable:!0,get:function(){return l.DotResult}});const a=r(1165);Object.defineProperty(t,"Warning",{enumerable:!0,get:function(){return a.Warning}});const i=r(447);Object.defineProperty(t,"mergeBugs",{enumerable:!0,get:function(){return i.mergeBugs}});const c=r(6988);Object.defineProperty(t,"Header",{enumerable:!0,get:function(){return c.Header}});const s=r(5825);Object.defineProperty(t,"Footer",{enumerable:!0,get:function(){return s.Footer}});const m=r(4837);Object.defineProperty(t,"Analyzer",{enumerable:!0,get:function(){return m.Analyzer}});const u=r(5335);Object.defineProperty(t,"UnifyAction",{enumerable:!0,get:function(){return u.UnifyAction}}),Object.defineProperty(t,"InitAction",{enumerable:!0,get:function(){return u.InitAction}}),Object.defineProperty(t,"GenerateAction",{enumerable:!0,get:function(){return u.GenerateAction}});const d=r(2543);Object.defineProperty(t,"AnalyzerStatus",{enumerable:!0,get:function(){return d.AnalyzerStatus}})},3074:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Install=void 0;const n=r(2787);Object.defineProperty(t,"Install",{enumerable:!0,get:function(){return n.Install}})},6410:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PublishWarning=t.PublishNonProductionWarning=t.Publish=void 0;const n=r(3948);Object.defineProperty(t,"Publish",{enumerable:!0,get:function(){return n.Publish}});const o=r(6961);Object.defineProperty(t,"PublishWarning",{enumerable:!0,get:function(){return o.PublishWarning}}),Object.defineProperty(t,"PublishNonProductionWarning",{enumerable:!0,get:function(){return o.PublishNonProductionWarning}})},3365:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SharedError=t.SharedOk=t.Shared=void 0;const n=r(4605);Object.defineProperty(t,"Shared",{enumerable:!0,get:function(){return n.Shared}});const o=r(1096);Object.defineProperty(t,"SharedError",{enumerable:!0,get:function(){return o.SharedError}});const l=r(5966);Object.defineProperty(t,"SharedOk",{enumerable:!0,get:function(){return l.SharedOk}})},447:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mergeBugs=t.TestsIssuesReport=t.TestsError=t.Tests=void 0;const n=r(1721);Object.defineProperty(t,"Tests",{enumerable:!0,get:function(){return n.Tests}});const o=r(7570);Object.defineProperty(t,"TestsError",{enumerable:!0,get:function(){return o.TestsError}});const l=r(9155);Object.defineProperty(t,"TestsIssuesReport",{enumerable:!0,get:function(){return l.TestsIssuesReport}}),Object.defineProperty(t,"mergeBugs",{enumerable:!0,get:function(){return l.mergeBugs}})},5747:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Unify=void 0;const n=r(5338);Object.defineProperty(t,"Unify",{enumerable:!0,get:function(){return n.Unify}})},6701:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Update=void 0;const n=r(8408);Object.defineProperty(t,"Update",{enumerable:!0,get:function(){return n.Update}})},1281:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.groupValidationResults=t.getValidationResultsStatus=t.collectMissingPackages=t.mergeValidationResults=void 0;const n=r(7359);t.mergeValidationResults=function(e){const t=e.filter(Boolean),r={results:{files:{},errors:[]},fix:!1,type:n.Module.ValidationDoneType.OK,available:!1};return t.forEach((e=>{var t,n;Object.values(e.results.files).forEach((e=>{const t=r.results.files[e.file];t?(t.fixed=t.fixed||e.fixed,t.messages=[...t.messages,...e.messages]):r.results.files[e.file]={fixed:e.fixed,file:e.file,messages:[...e.messages]}})),r.results.errors.push(...e.results.errors),r.fix=r.fix||e.fix,r.available=r.available||e.available,r.type=(t=r.type,n=e.type,o.indexOf(t)<o.indexOf(n)?t:n)})),r};const o=[n.Module.ValidationDoneType.FAIL,n.Module.ValidationDoneType.ERROR,n.Module.ValidationDoneType.WARNING,n.Module.ValidationDoneType.OK];function l(e){return e.reduce(((e,t)=>(t.fixable&&e.fixable.push(t),t.severity===n.Module.ValidationUniversalSeverity.ERROR?(e.errors.push(t),e):t.severity===n.Module.ValidationUniversalSeverity.WARNING?(e.warnings.push(t),e):t.severity===n.Module.ValidationUniversalSeverity.INFO?(e.infos.push(t),e):(e.suppressed.push(t),e))),{errors:[],warnings:[],infos:[],suppressed:[],fixable:[]})}function a(e,t,r){const o=r[t.engine]||(r[t.engine]={}),l=o[t.ruleId]||(o[t.ruleId]={}),a=l[t.message]||(l[t.message]=[]),i=a.find((t=>e&&t.file===n.Files.Path.normalize(e.file))),c=function(e){return void 0!==e.line&&void 0!==e.column?`${e.line}:${e.column}`:null}(t);i?i.pointers.push(...c?[c]:[]):a.push({engine:t.engine,id:t.ruleI