nw-builder 3.7.4 → 3.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1 +1,6 @@
1
- var Cr=Object.create;var k=Object.defineProperty;var Gr=Object.getOwnPropertyDescriptor;var br=Object.getOwnPropertyNames;var Dr=Object.getPrototypeOf,Xr=Object.prototype.hasOwnProperty;var p=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),jr=(t,e)=>{for(var r in e)k(t,r,{get:e[r],enumerable:!0})},Pe=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of br(e))!Xr.call(t,i)&&i!==r&&k(t,i,{get:()=>e[i],enumerable:!(s=Gr(e,i))||s.enumerable});return t};var Ee=(t,e,r)=>(r=t!=null?Cr(Dr(t)):{},Pe(e||!t||!t.__esModule?k(r,"default",{value:t,enumerable:!0}):r,t)),Fr=t=>Pe(k({},"__esModule",{value:!0}),t);var H=p((Qi,Ge)=>{var Ur="2.0.0",_r=Number.MAX_SAFE_INTEGER||9007199254740991,Vr=16;Ge.exports={SEMVER_SPEC_VERSION:Ur,MAX_LENGTH:256,MAX_SAFE_INTEGER:_r,MAX_SAFE_COMPONENT_LENGTH:Vr}});var B=p((ki,be)=>{var Hr=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};be.exports=Hr});var C=p((P,De)=>{var{MAX_SAFE_COMPONENT_LENGTH:me}=H(),Br=B();P=De.exports={};var Mr=P.re=[],a=P.src=[],o=P.t={},zr=0,E=(t,e,r)=>{let s=zr++;Br(t,s,e),o[t]=s,a[s]=e,Mr[s]=new RegExp(e,r?"g":void 0)};E("NUMERICIDENTIFIER","0|[1-9]\\d*");E("NUMERICIDENTIFIERLOOSE","[0-9]+");E("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");E("MAINVERSION",`(${a[o.NUMERICIDENTIFIER]})\\.(${a[o.NUMERICIDENTIFIER]})\\.(${a[o.NUMERICIDENTIFIER]})`);E("MAINVERSIONLOOSE",`(${a[o.NUMERICIDENTIFIERLOOSE]})\\.(${a[o.NUMERICIDENTIFIERLOOSE]})\\.(${a[o.NUMERICIDENTIFIERLOOSE]})`);E("PRERELEASEIDENTIFIER",`(?:${a[o.NUMERICIDENTIFIER]}|${a[o.NONNUMERICIDENTIFIER]})`);E("PRERELEASEIDENTIFIERLOOSE",`(?:${a[o.NUMERICIDENTIFIERLOOSE]}|${a[o.NONNUMERICIDENTIFIER]})`);E("PRERELEASE",`(?:-(${a[o.PRERELEASEIDENTIFIER]}(?:\\.${a[o.PRERELEASEIDENTIFIER]})*))`);E("PRERELEASELOOSE",`(?:-?(${a[o.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${a[o.PRERELEASEIDENTIFIERLOOSE]})*))`);E("BUILDIDENTIFIER","[0-9A-Za-z-]+");E("BUILD",`(?:\\+(${a[o.BUILDIDENTIFIER]}(?:\\.${a[o.BUILDIDENTIFIER]})*))`);E("FULLPLAIN",`v?${a[o.MAINVERSION]}${a[o.PRERELEASE]}?${a[o.BUILD]}?`);E("FULL",`^${a[o.FULLPLAIN]}$`);E("LOOSEPLAIN",`[v=\\s]*${a[o.MAINVERSIONLOOSE]}${a[o.PRERELEASELOOSE]}?${a[o.BUILD]}?`);E("LOOSE",`^${a[o.LOOSEPLAIN]}$`);E("GTLT","((?:<|>)?=?)");E("XRANGEIDENTIFIERLOOSE",`${a[o.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);E("XRANGEIDENTIFIER",`${a[o.NUMERICIDENTIFIER]}|x|X|\\*`);E("XRANGEPLAIN",`[v=\\s]*(${a[o.XRANGEIDENTIFIER]})(?:\\.(${a[o.XRANGEIDENTIFIER]})(?:\\.(${a[o.XRANGEIDENTIFIER]})(?:${a[o.PRERELEASE]})?${a[o.BUILD]}?)?)?`);E("XRANGEPLAINLOOSE",`[v=\\s]*(${a[o.XRANGEIDENTIFIERLOOSE]})(?:\\.(${a[o.XRANGEIDENTIFIERLOOSE]})(?:\\.(${a[o.XRANGEIDENTIFIERLOOSE]})(?:${a[o.PRERELEASELOOSE]})?${a[o.BUILD]}?)?)?`);E("XRANGE",`^${a[o.GTLT]}\\s*${a[o.XRANGEPLAIN]}$`);E("XRANGELOOSE",`^${a[o.GTLT]}\\s*${a[o.XRANGEPLAINLOOSE]}$`);E("COERCE",`(^|[^\\d])(\\d{1,${me}})(?:\\.(\\d{1,${me}}))?(?:\\.(\\d{1,${me}}))?(?:$|[^\\d])`);E("COERCERTL",a[o.COERCE],!0);E("LONETILDE","(?:~>?)");E("TILDETRIM",`(\\s*)${a[o.LONETILDE]}\\s+`,!0);P.tildeTrimReplace="$1~";E("TILDE",`^${a[o.LONETILDE]}${a[o.XRANGEPLAIN]}$`);E("TILDELOOSE",`^${a[o.LONETILDE]}${a[o.XRANGEPLAINLOOSE]}$`);E("LONECARET","(?:\\^)");E("CARETTRIM",`(\\s*)${a[o.LONECARET]}\\s+`,!0);P.caretTrimReplace="$1^";E("CARET",`^${a[o.LONECARET]}${a[o.XRANGEPLAIN]}$`);E("CARETLOOSE",`^${a[o.LONECARET]}${a[o.XRANGEPLAINLOOSE]}$`);E("COMPARATORLOOSE",`^${a[o.GTLT]}\\s*(${a[o.LOOSEPLAIN]})$|^$`);E("COMPARATOR",`^${a[o.GTLT]}\\s*(${a[o.FULLPLAIN]})$|^$`);E("COMPARATORTRIM",`(\\s*)${a[o.GTLT]}\\s*(${a[o.LOOSEPLAIN]}|${a[o.XRANGEPLAIN]})`,!0);P.comparatorTrimReplace="$1$2$3";E("HYPHENRANGE",`^\\s*(${a[o.XRANGEPLAIN]})\\s+-\\s+(${a[o.XRANGEPLAIN]})\\s*$`);E("HYPHENRANGELOOSE",`^\\s*(${a[o.XRANGEPLAINLOOSE]})\\s+-\\s+(${a[o.XRANGEPLAINLOOSE]})\\s*$`);E("STAR","(<|>)?=?\\s*\\*");E("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");E("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var M=p((en,Xe)=>{var Yr=["includePrerelease","loose","rtl"],Zr=t=>t?typeof t!="object"?{loose:!0}:Yr.filter(e=>t[e]).reduce((e,r)=>(e[r]=!0,e),{}):{};Xe.exports=Zr});var ee=p((tn,Ue)=>{var je=/^[0-9]+$/,Fe=(t,e)=>{let r=je.test(t),s=je.test(e);return r&&s&&(t=+t,e=+e),t===e?0:r&&!s?-1:s&&!r?1:t<e?-1:1},Wr=(t,e)=>Fe(e,t);Ue.exports={compareIdentifiers:Fe,rcompareIdentifiers:Wr}});var I=p((rn,Be)=>{var te=B(),{MAX_LENGTH:_e,MAX_SAFE_INTEGER:re}=H(),{re:Ve,t:He}=C(),Kr=M(),{compareIdentifiers:F}=ee(),x=class{constructor(e,r){if(r=Kr(r),e instanceof x){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid Version: ${e}`);if(e.length>_e)throw new TypeError(`version is longer than ${_e} characters`);te("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let s=e.trim().match(r.loose?Ve[He.LOOSE]:Ve[He.FULL]);if(!s)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>re||this.major<0)throw new TypeError("Invalid major version");if(this.minor>re||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>re||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map(i=>{if(/^[0-9]+$/.test(i)){let n=+i;if(n>=0&&n<re)return n}return i}):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(te("SemVer.compare",this.version,this.options,e),!(e instanceof x)){if(typeof e=="string"&&e===this.version)return 0;e=new x(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof x||(e=new x(e,this.options)),F(this.major,e.major)||F(this.minor,e.minor)||F(this.patch,e.patch)}comparePre(e){if(e instanceof x||(e=new x(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let s=this.prerelease[r],i=e.prerelease[r];if(te("prerelease compare",r,s,i),s===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(s===void 0)return-1;if(s===i)continue;return F(s,i)}while(++r)}compareBuild(e){e instanceof x||(e=new x(e,this.options));let r=0;do{let s=this.build[r],i=e.build[r];if(te("prerelease compare",r,s,i),s===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(s===void 0)return-1;if(s===i)continue;return F(s,i)}while(++r)}inc(e,r){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r),this.inc("pre",r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r),this.inc("pre",r);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let s=this.prerelease.length;for(;--s>=0;)typeof this.prerelease[s]=="number"&&(this.prerelease[s]++,s=-2);s===-1&&this.prerelease.push(0)}r&&(F(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error(`invalid increment argument: ${e}`)}return this.format(),this.raw=this.version,this}};Be.exports=x});var G=p((sn,Ze)=>{var{MAX_LENGTH:Jr}=H(),{re:Me,t:ze}=C(),Ye=I(),Qr=M(),kr=(t,e)=>{if(e=Qr(e),t instanceof Ye)return t;if(typeof t!="string"||t.length>Jr||!(e.loose?Me[ze.LOOSE]:Me[ze.FULL]).test(t))return null;try{return new Ye(t,e)}catch{return null}};Ze.exports=kr});var Ke=p((nn,We)=>{var es=G(),ts=(t,e)=>{let r=es(t,e);return r?r.version:null};We.exports=ts});var Qe=p((ln,Je)=>{var rs=G(),ss=(t,e)=>{let r=rs(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};Je.exports=ss});var tt=p((an,et)=>{var ke=I(),is=(t,e,r,s)=>{typeof r=="string"&&(s=r,r=void 0);try{return new ke(t instanceof ke?t.version:t,r).inc(e,s).version}catch{return null}};et.exports=is});var S=p((on,st)=>{var rt=I(),ns=(t,e,r)=>new rt(t,r).compare(new rt(e,r));st.exports=ns});var se=p((un,it)=>{var ls=S(),as=(t,e,r)=>ls(t,e,r)===0;it.exports=as});var at=p((cn,lt)=>{var nt=G(),os=se(),us=(t,e)=>{if(os(t,e))return null;{let r=nt(t),s=nt(e),i=r.prerelease.length||s.prerelease.length,n=i?"pre":"",l=i?"prerelease":"";for(let u in r)if((u==="major"||u==="minor"||u==="patch")&&r[u]!==s[u])return n+u;return l}};lt.exports=us});var ut=p((hn,ot)=>{var cs=I(),hs=(t,e)=>new cs(t,e).major;ot.exports=hs});var ht=p((fn,ct)=>{var fs=I(),ps=(t,e)=>new fs(t,e).minor;ct.exports=ps});var pt=p((pn,ft)=>{var Es=I(),ms=(t,e)=>new Es(t,e).patch;ft.exports=ms});var mt=p((En,Et)=>{var vs=G(),ds=(t,e)=>{let r=vs(t,e);return r&&r.prerelease.length?r.prerelease:null};Et.exports=ds});var dt=p((mn,vt)=>{var $s=S(),Rs=(t,e,r)=>$s(e,t,r);vt.exports=Rs});var Rt=p((vn,$t)=>{var gs=S(),Is=(t,e)=>gs(t,e,!0);$t.exports=Is});var ie=p((dn,It)=>{var gt=I(),Ns=(t,e,r)=>{let s=new gt(t,r),i=new gt(e,r);return s.compare(i)||s.compareBuild(i)};It.exports=Ns});var Ot=p(($n,Nt)=>{var Os=ie(),Ls=(t,e)=>t.sort((r,s)=>Os(r,s,e));Nt.exports=Ls});var xt=p((Rn,Lt)=>{var xs=ie(),Ss=(t,e)=>t.sort((r,s)=>xs(s,r,e));Lt.exports=Ss});var z=p((gn,St)=>{var Ts=S(),As=(t,e,r)=>Ts(t,e,r)>0;St.exports=As});var ne=p((In,Tt)=>{var ws=S(),qs=(t,e,r)=>ws(t,e,r)<0;Tt.exports=qs});var ve=p((Nn,At)=>{var ys=S(),Ps=(t,e,r)=>ys(t,e,r)!==0;At.exports=Ps});var le=p((On,wt)=>{var Cs=S(),Gs=(t,e,r)=>Cs(t,e,r)>=0;wt.exports=Gs});var ae=p((Ln,qt)=>{var bs=S(),Ds=(t,e,r)=>bs(t,e,r)<=0;qt.exports=Ds});var de=p((xn,yt)=>{var Xs=se(),js=ve(),Fs=z(),Us=le(),_s=ne(),Vs=ae(),Hs=(t,e,r,s)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return Xs(t,r,s);case"!=":return js(t,r,s);case">":return Fs(t,r,s);case">=":return Us(t,r,s);case"<":return _s(t,r,s);case"<=":return Vs(t,r,s);default:throw new TypeError(`Invalid operator: ${e}`)}};yt.exports=Hs});var Ct=p((Sn,Pt)=>{var Bs=I(),Ms=G(),{re:oe,t:ue}=C(),zs=(t,e)=>{if(t instanceof Bs)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(oe[ue.COERCE]);else{let s;for(;(s=oe[ue.COERCERTL].exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||s.index+s[0].length!==r.index+r[0].length)&&(r=s),oe[ue.COERCERTL].lastIndex=s.index+s[1].length+s[2].length;oe[ue.COERCERTL].lastIndex=-1}return r===null?null:Ms(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,e)};Pt.exports=zs});var bt=p((Tn,Gt)=>{"use strict";Gt.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Xt=p((An,Dt)=>{"use strict";Dt.exports=d;d.Node=b;d.create=d;function d(t){var e=this;if(e instanceof d||(e=new d),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(i){e.push(i)});else if(arguments.length>0)for(var r=0,s=arguments.length;r<s;r++)e.push(arguments[r]);return e}d.prototype.removeNode=function(t){if(t.list!==this)throw new Error("removing node which does not belong to this list");var e=t.next,r=t.prev;return e&&(e.prev=r),r&&(r.next=e),t===this.head&&(this.head=e),t===this.tail&&(this.tail=r),t.list.length--,t.next=null,t.prev=null,t.list=null,e};d.prototype.unshiftNode=function(t){if(t!==this.head){t.list&&t.list.removeNode(t);var e=this.head;t.list=this,t.next=e,e&&(e.prev=t),this.head=t,this.tail||(this.tail=t),this.length++}};d.prototype.pushNode=function(t){if(t!==this.tail){t.list&&t.list.removeNode(t);var e=this.tail;t.list=this,t.prev=e,e&&(e.next=t),this.tail=t,this.head||(this.head=t),this.length++}};d.prototype.push=function(){for(var t=0,e=arguments.length;t<e;t++)Zs(this,arguments[t]);return this.length};d.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)Ws(this,arguments[t]);return this.length};d.prototype.pop=function(){if(!!this.tail){var t=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,t}};d.prototype.shift=function(){if(!!this.head){var t=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,t}};d.prototype.forEach=function(t,e){e=e||this;for(var r=this.head,s=0;r!==null;s++)t.call(e,r.value,s,this),r=r.next};d.prototype.forEachReverse=function(t,e){e=e||this;for(var r=this.tail,s=this.length-1;r!==null;s--)t.call(e,r.value,s,this),r=r.prev};d.prototype.get=function(t){for(var e=0,r=this.head;r!==null&&e<t;e++)r=r.next;if(e===t&&r!==null)return r.value};d.prototype.getReverse=function(t){for(var e=0,r=this.tail;r!==null&&e<t;e++)r=r.prev;if(e===t&&r!==null)return r.value};d.prototype.map=function(t,e){e=e||this;for(var r=new d,s=this.head;s!==null;)r.push(t.call(e,s.value,this)),s=s.next;return r};d.prototype.mapReverse=function(t,e){e=e||this;for(var r=new d,s=this.tail;s!==null;)r.push(t.call(e,s.value,this)),s=s.prev;return r};d.prototype.reduce=function(t,e){var r,s=this.head;if(arguments.length>1)r=e;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=t(r,s.value,i),s=s.next;return r};d.prototype.reduceReverse=function(t,e){var r,s=this.tail;if(arguments.length>1)r=e;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=t(r,s.value,i),s=s.prev;return r};d.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};d.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};d.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new d;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var s=0,i=this.head;i!==null&&s<t;s++)i=i.next;for(;i!==null&&s<e;s++,i=i.next)r.push(i.value);return r};d.prototype.sliceReverse=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new d;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var s=this.length,i=this.tail;i!==null&&s>e;s--)i=i.prev;for(;i!==null&&s>t;s--,i=i.prev)r.push(i.value);return r};d.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var s=0,i=this.head;i!==null&&s<t;s++)i=i.next;for(var n=[],s=0;i&&s<e;s++)n.push(i.value),i=this.removeNode(i);i===null&&(i=this.tail),i!==this.head&&i!==this.tail&&(i=i.prev);for(var s=0;s<r.length;s++)i=Ys(this,i,r[s]);return n};d.prototype.reverse=function(){for(var t=this.head,e=this.tail,r=t;r!==null;r=r.prev){var s=r.prev;r.prev=r.next,r.next=s}return this.head=e,this.tail=t,this};function Ys(t,e,r){var s=e===t.head?new b(r,null,e,t):new b(r,e,e.next,t);return s.next===null&&(t.tail=s),s.prev===null&&(t.head=s),t.length++,s}function Zs(t,e){t.tail=new b(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function Ws(t,e){t.head=new b(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function b(t,e,r,s){if(!(this instanceof b))return new b(t,e,r,s);this.list=s,this.value=t,e?(e.next=this,this.prev=e):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{bt()(d)}catch{}});var Vt=p((wn,_t)=>{"use strict";var Ks=Xt(),D=Symbol("max"),y=Symbol("length"),U=Symbol("lengthCalculator"),Z=Symbol("allowStale"),X=Symbol("maxAge"),q=Symbol("dispose"),jt=Symbol("noDisposeOnSet"),g=Symbol("lruList"),A=Symbol("cache"),Ut=Symbol("updateAgeOnGet"),$e=()=>1,ge=class{constructor(e){if(typeof e=="number"&&(e={max:e}),e||(e={}),e.max&&(typeof e.max!="number"||e.max<0))throw new TypeError("max must be a non-negative number");let r=this[D]=e.max||1/0,s=e.length||$e;if(this[U]=typeof s!="function"?$e:s,this[Z]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[X]=e.maxAge||0,this[q]=e.dispose,this[jt]=e.noDisposeOnSet||!1,this[Ut]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!="number"||e<0)throw new TypeError("max must be a non-negative number");this[D]=e||1/0,Y(this)}get max(){return this[D]}set allowStale(e){this[Z]=!!e}get allowStale(){return this[Z]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[X]=e,Y(this)}get maxAge(){return this[X]}set lengthCalculator(e){typeof e!="function"&&(e=$e),e!==this[U]&&(this[U]=e,this[y]=0,this[g].forEach(r=>{r.length=this[U](r.value,r.key),this[y]+=r.length})),Y(this)}get lengthCalculator(){return this[U]}get length(){return this[y]}get itemCount(){return this[g].length}rforEach(e,r){r=r||this;for(let s=this[g].tail;s!==null;){let i=s.prev;Ft(this,e,s,r),s=i}}forEach(e,r){r=r||this;for(let s=this[g].head;s!==null;){let i=s.next;Ft(this,e,s,r),s=i}}keys(){return this[g].toArray().map(e=>e.key)}values(){return this[g].toArray().map(e=>e.value)}reset(){this[q]&&this[g]&&this[g].length&&this[g].forEach(e=>this[q](e.key,e.value)),this[A]=new Map,this[g]=new Ks,this[y]=0}dump(){return this[g].map(e=>ce(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[g]}set(e,r,s){if(s=s||this[X],s&&typeof s!="number")throw new TypeError("maxAge must be a number");let i=s?Date.now():0,n=this[U](r,e);if(this[A].has(e)){if(n>this[D])return _(this,this[A].get(e)),!1;let c=this[A].get(e).value;return this[q]&&(this[jt]||this[q](e,c.value)),c.now=i,c.maxAge=s,c.value=r,this[y]+=n-c.length,c.length=n,this.get(e),Y(this),!0}let l=new Ie(e,r,n,i,s);return l.length>this[D]?(this[q]&&this[q](e,r),!1):(this[y]+=l.length,this[g].unshift(l),this[A].set(e,this[g].head),Y(this),!0)}has(e){if(!this[A].has(e))return!1;let r=this[A].get(e).value;return!ce(this,r)}get(e){return Re(this,e,!0)}peek(e){return Re(this,e,!1)}pop(){let e=this[g].tail;return e?(_(this,e),e.value):null}del(e){_(this,this[A].get(e))}load(e){this.reset();let r=Date.now();for(let s=e.length-1;s>=0;s--){let i=e[s],n=i.e||0;if(n===0)this.set(i.k,i.v);else{let l=n-r;l>0&&this.set(i.k,i.v,l)}}}prune(){this[A].forEach((e,r)=>Re(this,r,!1))}},Re=(t,e,r)=>{let s=t[A].get(e);if(s){let i=s.value;if(ce(t,i)){if(_(t,s),!t[Z])return}else r&&(t[Ut]&&(s.value.now=Date.now()),t[g].unshiftNode(s));return i.value}},ce=(t,e)=>{if(!e||!e.maxAge&&!t[X])return!1;let r=Date.now()-e.now;return e.maxAge?r>e.maxAge:t[X]&&r>t[X]},Y=t=>{if(t[y]>t[D])for(let e=t[g].tail;t[y]>t[D]&&e!==null;){let r=e.prev;_(t,e),e=r}},_=(t,e)=>{if(e){let r=e.value;t[q]&&t[q](r.key,r.value),t[y]-=r.length,t[A].delete(r.key),t[g].removeNode(e)}},Ie=class{constructor(e,r,s,i,n){this.key=e,this.value=r,this.length=s,this.now=i,this.maxAge=n||0}},Ft=(t,e,r,s)=>{let i=r.value;ce(t,i)&&(_(t,r),t[Z]||(i=void 0)),i&&e.call(s,i.value,i.key,t)};_t.exports=ge});var T=p((qn,zt)=>{var j=class{constructor(e,r){if(r=Qs(r),e instanceof j)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new j(e.raw,r);if(e instanceof Ne)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e,this.set=e.split("||").map(s=>this.parseRange(s.trim())).filter(s=>s.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${e}`);if(this.set.length>1){let s=this.set[0];if(this.set=this.set.filter(i=>!Bt(i[0])),this.set.length===0)this.set=[s];else if(this.set.length>1){for(let i of this.set)if(i.length===1&&si(i[0])){this.set=[i];break}}}this.format()}format(){return this.range=this.set.map(e=>e.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();let s=`parseRange:${Object.keys(this.options).join(",")}:${e}`,i=Ht.get(s);if(i)return i;let n=this.options.loose,l=n?L[N.HYPHENRANGELOOSE]:L[N.HYPHENRANGE];e=e.replace(l,pi(this.options.includePrerelease)),$("hyphen replace",e),e=e.replace(L[N.COMPARATORTRIM],ei),$("comparator trim",e),e=e.replace(L[N.TILDETRIM],ti),e=e.replace(L[N.CARETTRIM],ri),e=e.split(/\s+/).join(" ");let u=e.split(" ").map(h=>ii(h,this.options)).join(" ").split(/\s+/).map(h=>fi(h,this.options));n&&(u=u.filter(h=>($("loose invalid filter",h,this.options),!!h.match(L[N.COMPARATORLOOSE])))),$("range list",u);let c=new Map,m=u.map(h=>new Ne(h,this.options));for(let h of m){if(Bt(h))return[h];c.set(h.value,h)}c.size>1&&c.has("")&&c.delete("");let v=[...c.values()];return Ht.set(s,v),v}intersects(e,r){if(!(e instanceof j))throw new TypeError("a Range is required");return this.set.some(s=>Mt(s,r)&&e.set.some(i=>Mt(i,r)&&s.every(n=>i.every(l=>n.intersects(l,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new ks(e,this.options)}catch{return!1}for(let r=0;r<this.set.length;r++)if(Ei(this.set[r],e,this.options))return!0;return!1}};zt.exports=j;var Js=Vt(),Ht=new Js({max:1e3}),Qs=M(),Ne=W(),$=B(),ks=I(),{re:L,t:N,comparatorTrimReplace:ei,tildeTrimReplace:ti,caretTrimReplace:ri}=C(),Bt=t=>t.value==="<0.0.0-0",si=t=>t.value==="",Mt=(t,e)=>{let r=!0,s=t.slice(),i=s.pop();for(;r&&s.length;)r=s.every(n=>i.intersects(n,e)),i=s.pop();return r},ii=(t,e)=>($("comp",t,e),t=ai(t,e),$("caret",t),t=ni(t,e),$("tildes",t),t=ui(t,e),$("xrange",t),t=hi(t,e),$("stars",t),t),O=t=>!t||t.toLowerCase()==="x"||t==="*",ni=(t,e)=>t.trim().split(/\s+/).map(r=>li(r,e)).join(" "),li=(t,e)=>{let r=e.loose?L[N.TILDELOOSE]:L[N.TILDE];return t.replace(r,(s,i,n,l,u)=>{$("tilde",t,s,i,n,l,u);let c;return O(i)?c="":O(n)?c=`>=${i}.0.0 <${+i+1}.0.0-0`:O(l)?c=`>=${i}.${n}.0 <${i}.${+n+1}.0-0`:u?($("replaceTilde pr",u),c=`>=${i}.${n}.${l}-${u} <${i}.${+n+1}.0-0`):c=`>=${i}.${n}.${l} <${i}.${+n+1}.0-0`,$("tilde return",c),c})},ai=(t,e)=>t.trim().split(/\s+/).map(r=>oi(r,e)).join(" "),oi=(t,e)=>{$("caret",t,e);let r=e.loose?L[N.CARETLOOSE]:L[N.CARET],s=e.includePrerelease?"-0":"";return t.replace(r,(i,n,l,u,c)=>{$("caret",t,i,n,l,u,c);let m;return O(n)?m="":O(l)?m=`>=${n}.0.0${s} <${+n+1}.0.0-0`:O(u)?n==="0"?m=`>=${n}.${l}.0${s} <${n}.${+l+1}.0-0`:m=`>=${n}.${l}.0${s} <${+n+1}.0.0-0`:c?($("replaceCaret pr",c),n==="0"?l==="0"?m=`>=${n}.${l}.${u}-${c} <${n}.${l}.${+u+1}-0`:m=`>=${n}.${l}.${u}-${c} <${n}.${+l+1}.0-0`:m=`>=${n}.${l}.${u}-${c} <${+n+1}.0.0-0`):($("no pr"),n==="0"?l==="0"?m=`>=${n}.${l}.${u}${s} <${n}.${l}.${+u+1}-0`:m=`>=${n}.${l}.${u}${s} <${n}.${+l+1}.0-0`:m=`>=${n}.${l}.${u} <${+n+1}.0.0-0`),$("caret return",m),m})},ui=(t,e)=>($("replaceXRanges",t,e),t.split(/\s+/).map(r=>ci(r,e)).join(" ")),ci=(t,e)=>{t=t.trim();let r=e.loose?L[N.XRANGELOOSE]:L[N.XRANGE];return t.replace(r,(s,i,n,l,u,c)=>{$("xRange",t,s,i,n,l,u,c);let m=O(n),v=m||O(l),h=v||O(u),R=h;return i==="="&&R&&(i=""),c=e.includePrerelease?"-0":"",m?i===">"||i==="<"?s="<0.0.0-0":s="*":i&&R?(v&&(l=0),u=0,i===">"?(i=">=",v?(n=+n+1,l=0,u=0):(l=+l+1,u=0)):i==="<="&&(i="<",v?n=+n+1:l=+l+1),i==="<"&&(c="-0"),s=`${i+n}.${l}.${u}${c}`):v?s=`>=${n}.0.0${c} <${+n+1}.0.0-0`:h&&(s=`>=${n}.${l}.0${c} <${n}.${+l+1}.0-0`),$("xRange return",s),s})},hi=(t,e)=>($("replaceStars",t,e),t.trim().replace(L[N.STAR],"")),fi=(t,e)=>($("replaceGTE0",t,e),t.trim().replace(L[e.includePrerelease?N.GTE0PRE:N.GTE0],"")),pi=t=>(e,r,s,i,n,l,u,c,m,v,h,R,f)=>(O(s)?r="":O(i)?r=`>=${s}.0.0${t?"-0":""}`:O(n)?r=`>=${s}.${i}.0${t?"-0":""}`:l?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,O(m)?c="":O(v)?c=`<${+m+1}.0.0-0`:O(h)?c=`<${m}.${+v+1}.0-0`:R?c=`<=${m}.${v}.${h}-${R}`:t?c=`<${m}.${v}.${+h+1}-0`:c=`<=${c}`,`${r} ${c}`.trim()),Ei=(t,e,r)=>{for(let s=0;s<t.length;s++)if(!t[s].test(e))return!1;if(e.prerelease.length&&!r.includePrerelease){for(let s=0;s<t.length;s++)if($(t[s].semver),t[s].semver!==Ne.ANY&&t[s].semver.prerelease.length>0){let i=t[s].semver;if(i.major===e.major&&i.minor===e.minor&&i.patch===e.patch)return!0}return!1}return!0}});var W=p((yn,Jt)=>{var K=Symbol("SemVer ANY"),V=class{static get ANY(){return K}constructor(e,r){if(r=mi(r),e instanceof V){if(e.loose===!!r.loose)return e;e=e.value}Le("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===K?this.value="":this.value=this.operator+this.semver.version,Le("comp",this)}parse(e){let r=this.options.loose?Yt[Zt.COMPARATORLOOSE]:Yt[Zt.COMPARATOR],s=e.match(r);if(!s)throw new TypeError(`Invalid comparator: ${e}`);this.operator=s[1]!==void 0?s[1]:"",this.operator==="="&&(this.operator=""),s[2]?this.semver=new Wt(s[2],this.options.loose):this.semver=K}toString(){return this.value}test(e){if(Le("Comparator.test",e,this.options.loose),this.semver===K||e===K)return!0;if(typeof e=="string")try{e=new Wt(e,this.options)}catch{return!1}return Oe(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof V))throw new TypeError("a Comparator is required");if((!r||typeof r!="object")&&(r={loose:!!r,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Kt(e.value,r).test(this.value);if(e.operator==="")return e.value===""?!0:new Kt(this.value,r).test(e.semver);let s=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">"),i=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<"),n=this.semver.version===e.semver.version,l=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<="),u=Oe(this.semver,"<",e.semver,r)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),c=Oe(this.semver,">",e.semver,r)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return s||i||n&&l||u||c}};Jt.exports=V;var mi=M(),{re:Yt,t:Zt}=C(),Oe=de(),Le=B(),Wt=I(),Kt=T()});var J=p((Pn,Qt)=>{var vi=T(),di=(t,e,r)=>{try{e=new vi(e,r)}catch{return!1}return e.test(t)};Qt.exports=di});var er=p((Cn,kt)=>{var $i=T(),Ri=(t,e)=>new $i(t,e).set.map(r=>r.map(s=>s.value).join(" ").trim().split(" "));kt.exports=Ri});var rr=p((Gn,tr)=>{var gi=I(),Ii=T(),Ni=(t,e,r)=>{let s=null,i=null,n=null;try{n=new Ii(e,r)}catch{return null}return t.forEach(l=>{n.test(l)&&(!s||i.compare(l)===-1)&&(s=l,i=new gi(s,r))}),s};tr.exports=Ni});var ir=p((bn,sr)=>{var Oi=I(),Li=T(),xi=(t,e,r)=>{let s=null,i=null,n=null;try{n=new Li(e,r)}catch{return null}return t.forEach(l=>{n.test(l)&&(!s||i.compare(l)===1)&&(s=l,i=new Oi(s,r))}),s};sr.exports=xi});var ar=p((Dn,lr)=>{var xe=I(),Si=T(),nr=z(),Ti=(t,e)=>{t=new Si(t,e);let r=new xe("0.0.0");if(t.test(r)||(r=new xe("0.0.0-0"),t.test(r)))return r;r=null;for(let s=0;s<t.set.length;++s){let i=t.set[s],n=null;i.forEach(l=>{let u=new xe(l.semver.version);switch(l.operator){case">":u.prerelease.length===0?u.patch++:u.prerelease.push(0),u.raw=u.format();case"":case">=":(!n||nr(u,n))&&(n=u);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${l.operator}`)}}),n&&(!r||nr(r,n))&&(r=n)}return r&&t.test(r)?r:null};lr.exports=Ti});var ur=p((Xn,or)=>{var Ai=T(),wi=(t,e)=>{try{return new Ai(t,e).range||"*"}catch{return null}};or.exports=wi});var he=p((jn,pr)=>{var qi=I(),fr=W(),{ANY:yi}=fr,Pi=T(),Ci=J(),cr=z(),hr=ne(),Gi=ae(),bi=le(),Di=(t,e,r,s)=>{t=new qi(t,s),e=new Pi(e,s);let i,n,l,u,c;switch(r){case">":i=cr,n=Gi,l=hr,u=">",c=">=";break;case"<":i=hr,n=bi,l=cr,u="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Ci(t,e,s))return!1;for(let m=0;m<e.set.length;++m){let v=e.set[m],h=null,R=null;if(v.forEach(f=>{f.semver===yi&&(f=new fr(">=0.0.0")),h=h||f,R=R||f,i(f.semver,h.semver,s)?h=f:l(f.semver,R.semver,s)&&(R=f)}),h.operator===u||h.operator===c||(!R.operator||R.operator===u)&&n(t,R.semver))return!1;if(R.operator===c&&l(t,R.semver))return!1}return!0};pr.exports=Di});var mr=p((Fn,Er)=>{var Xi=he(),ji=(t,e,r)=>Xi(t,e,">",r);Er.exports=ji});var dr=p((Un,vr)=>{var Fi=he(),Ui=(t,e,r)=>Fi(t,e,"<",r);vr.exports=Ui});var gr=p((_n,Rr)=>{var $r=T(),_i=(t,e,r)=>(t=new $r(t,r),e=new $r(e,r),t.intersects(e));Rr.exports=_i});var Nr=p((Vn,Ir)=>{var Vi=J(),Hi=S();Ir.exports=(t,e,r)=>{let s=[],i=null,n=null,l=t.sort((v,h)=>Hi(v,h,r));for(let v of l)Vi(v,e,r)?(n=v,i||(i=v)):(n&&s.push([i,n]),n=null,i=null);i&&s.push([i,null]);let u=[];for(let[v,h]of s)v===h?u.push(v):!h&&v===l[0]?u.push("*"):h?v===l[0]?u.push(`<=${h}`):u.push(`${v} - ${h}`):u.push(`>=${v}`);let c=u.join(" || "),m=typeof e.raw=="string"?e.raw:String(e);return c.length<m.length?c:e}});var Tr=p((Hn,Sr)=>{var Or=T(),fe=W(),{ANY:Se}=fe,Q=J(),Te=S(),Bi=(t,e,r={})=>{if(t===e)return!0;t=new Or(t,r),e=new Or(e,r);let s=!1;e:for(let i of t.set){for(let n of e.set){let l=Mi(i,n,r);if(s=s||l!==null,l)continue e}if(s)return!1}return!0},Mi=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===Se){if(e.length===1&&e[0].semver===Se)return!0;r.includePrerelease?t=[new fe(">=0.0.0-0")]:t=[new fe(">=0.0.0")]}if(e.length===1&&e[0].semver===Se){if(r.includePrerelease)return!0;e=[new fe(">=0.0.0")]}let s=new Set,i,n;for(let f of t)f.operator===">"||f.operator===">="?i=Lr(i,f,r):f.operator==="<"||f.operator==="<="?n=xr(n,f,r):s.add(f.semver);if(s.size>1)return null;let l;if(i&&n){if(l=Te(i.semver,n.semver,r),l>0)return null;if(l===0&&(i.operator!==">="||n.operator!=="<="))return null}for(let f of s){if(i&&!Q(f,String(i),r)||n&&!Q(f,String(n),r))return null;for(let Pr of e)if(!Q(f,String(Pr),r))return!1;return!0}let u,c,m,v,h=n&&!r.includePrerelease&&n.semver.prerelease.length?n.semver:!1,R=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1;h&&h.prerelease.length===1&&n.operator==="<"&&h.prerelease[0]===0&&(h=!1);for(let f of e){if(v=v||f.operator===">"||f.operator===">=",m=m||f.operator==="<"||f.operator==="<=",i){if(R&&f.semver.prerelease&&f.semver.prerelease.length&&f.semver.major===R.major&&f.semver.minor===R.minor&&f.semver.patch===R.patch&&(R=!1),f.operator===">"||f.operator===">="){if(u=Lr(i,f,r),u===f&&u!==i)return!1}else if(i.operator===">="&&!Q(i.semver,String(f),r))return!1}if(n){if(h&&f.semver.prerelease&&f.semver.prerelease.length&&f.semver.major===h.major&&f.semver.minor===h.minor&&f.semver.patch===h.patch&&(h=!1),f.operator==="<"||f.operator==="<="){if(c=xr(n,f,r),c===f&&c!==n)return!1}else if(n.operator==="<="&&!Q(n.semver,String(f),r))return!1}if(!f.operator&&(n||i)&&l!==0)return!1}return!(i&&m&&!n&&l!==0||n&&v&&!i&&l!==0||R||h)},Lr=(t,e,r)=>{if(!t)return e;let s=Te(t.semver,e.semver,r);return s>0?t:s<0||e.operator===">"&&t.operator===">="?e:t},xr=(t,e,r)=>{if(!t)return e;let s=Te(t.semver,e.semver,r);return s<0?t:s>0||e.operator==="<"&&t.operator==="<="?e:t};Sr.exports=Bi});var wr=p((Bn,Ar)=>{var Ae=C();Ar.exports={re:Ae.re,src:Ae.src,tokens:Ae.t,SEMVER_SPEC_VERSION:H().SEMVER_SPEC_VERSION,SemVer:I(),compareIdentifiers:ee().compareIdentifiers,rcompareIdentifiers:ee().rcompareIdentifiers,parse:G(),valid:Ke(),clean:Qe(),inc:tt(),diff:at(),major:ut(),minor:ht(),patch:pt(),prerelease:mt(),compare:S(),rcompare:dt(),compareLoose:Rt(),compareBuild:ie(),sort:Ot(),rsort:xt(),gt:z(),lt:ne(),eq:se(),neq:ve(),gte:le(),lte:ae(),cmp:de(),coerce:Ct(),Comparator:W(),Range:T(),satisfies:J(),toComparators:er(),maxSatisfying:rr(),minSatisfying:ir(),minVersion:ar(),validRange:ur(),outside:he(),gtr:mr(),ltr:dr(),intersects:gr(),simplifyRange:Nr(),subset:Tr()}});var Wi={};jr(Wi,{Platform:()=>w,Platforms:()=>we,checkCache:()=>qe,detectCurrentPlatform:()=>ye});module.exports=Fr(Wi);var Ce={NIX_32:"linux32",NIX_64:"linux64",OSX_32:"osx32",OSX_64:"osx64",WIN_32:"win32",WIN_64:"win64"};Object.freeze(Ce);var w=Ce;var qr=Ee(wr(),1),zi={win32:{needsZip:!0,getRunnable:function(){return"nw.exe"},files:{"<=0.9.2":["nw.exe","ffmpegsumo.dll","icudt.dll","libEGL.dll","libGLESv2.dll","nw.pak"],">0.9.2 <0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales"],">=0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales","d3dcompiler_47.dll","pdf.dll"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-win-ia32.zip"},win64:{needsZip:!0,getRunnable:function(){return"nw.exe"},files:{"<=0.9.2":["nw.exe","ffmpegsumo.dll","icudt.dll","libEGL.dll","libGLESv2.dll","nw.pak","locales"],">0.9.2 <0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales"],">=0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales","d3dcompiler_47.dll","pdf.dll"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-win-x64.zip"},osx32:{needsZip:!1,getRunnable:function(t){return qr.default.satisfies(t,">=0.12.0 || ~0.12.0-alpha")?"nwjs.app/Contents/MacOS/nwjs":"node-webkit.app/Contents/MacOS/node-webkit"},files:{"<0.12.0-alpha":["node-webkit.app"],">=0.12.0 || ~0.12.0-alpha":["nwjs.app"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-osx-ia32.zip"},osx64:{needsZip:!1,getRunnable:function(t){return satisfies(t,">=0.12.0 || ~0.12.0-alpha")?"nwjs.app/Contents/MacOS/nwjs":"node-webkit.app/Contents/MacOS/node-webkit"},files:{"<0.12.0-alpha":["node-webkit.app"],">=0.12.0 || ~0.12.0-alpha":["nwjs.app"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-osx-x64.zip"},linux32:{needsZip:!0,chmod:"0755",getRunnable:function(){return"nw"},files:{"<=0.9.2":["nw","nw.pak","libffmpegsumo.so"],">0.9.2 <=0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat"],">0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat","locales"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-linux-ia32.tar.gz"},linux64:{needsZip:!0,chmod:"0755",getRunnable:function(){return"nw"},files:{"<=0.9.2":["nw","nw.pak","libffmpegsumo.so"],">0.9.2 <=0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat"],">0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat","locales"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-linux-x64.tar.gz"}},we=zi;var pe=Ee(require("fs"),1),yr=Ee(require("path"),1),Yi=(t,e)=>{let r=!1;if(e.length===1&&e[0]==="*")return pe.default.existsSync(t)&&pe.default.readdirSync(t).length>=2;for(let s of e){if(r)return!1;pe.default.existsSync(yr.default.join(t,s))||(r=!0)}return!r},qe=Yi;var Zi=t=>{switch(t.platform){case"darwin":return t.arch==="x64"?w.OSX_64:w.OSX_32;case"win32":return t.arch==="x64"||t.env.PROCESSOR_ARCHITEW6432?w.WIN_64:w.WIN_32;case"linux":return t.arch==="x64"?w.NIX_64:w.NIX_32;default:return}},ye=Zi;0&&(module.exports={Platform,Platforms,checkCache,detectCurrentPlatform});
1
+ var pa=Object.create;var He=Object.defineProperty;var va=Object.getOwnPropertyDescriptor;var da=Object.getOwnPropertyNames;var ga=Object.getPrototypeOf,ma=Object.prototype.hasOwnProperty;var v=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Ea=(e,t)=>{for(var r in t)He(e,r,{get:t[r],enumerable:!0})},$r=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of da(t))!ma.call(e,i)&&i!==r&&He(e,i,{get:()=>t[i],enumerable:!(n=va(t,i))||n.enumerable});return e};var Se=(e,t,r)=>(r=e!=null?pa(ga(e)):{},$r(t||!e||!e.__esModule?He(r,"default",{value:e,enumerable:!0}):r,e)),ya=e=>$r(He({},"__esModule",{value:!0}),e);var Ie=v((wf,Lr)=>{var wa="2.0.0",_a=Number.MAX_SAFE_INTEGER||9007199254740991,Oa=16;Lr.exports={SEMVER_SPEC_VERSION:wa,MAX_LENGTH:256,MAX_SAFE_INTEGER:_a,MAX_SAFE_COMPONENT_LENGTH:Oa}});var Ae=v((_f,Tr)=>{var Sa=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};Tr.exports=Sa});var J=v((V,qr)=>{var{MAX_SAFE_COMPONENT_LENGTH:It}=Ie(),Ia=Ae();V=qr.exports={};var Aa=V.re=[],d=V.src=[],g=V.t={},Ra=0,E=(e,t,r)=>{let n=Ra++;Ia(e,n,t),g[e]=n,d[n]=t,Aa[n]=new RegExp(t,r?"g":void 0)};E("NUMERICIDENTIFIER","0|[1-9]\\d*");E("NUMERICIDENTIFIERLOOSE","[0-9]+");E("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");E("MAINVERSION",`(${d[g.NUMERICIDENTIFIER]})\\.(${d[g.NUMERICIDENTIFIER]})\\.(${d[g.NUMERICIDENTIFIER]})`);E("MAINVERSIONLOOSE",`(${d[g.NUMERICIDENTIFIERLOOSE]})\\.(${d[g.NUMERICIDENTIFIERLOOSE]})\\.(${d[g.NUMERICIDENTIFIERLOOSE]})`);E("PRERELEASEIDENTIFIER",`(?:${d[g.NUMERICIDENTIFIER]}|${d[g.NONNUMERICIDENTIFIER]})`);E("PRERELEASEIDENTIFIERLOOSE",`(?:${d[g.NUMERICIDENTIFIERLOOSE]}|${d[g.NONNUMERICIDENTIFIER]})`);E("PRERELEASE",`(?:-(${d[g.PRERELEASEIDENTIFIER]}(?:\\.${d[g.PRERELEASEIDENTIFIER]})*))`);E("PRERELEASELOOSE",`(?:-?(${d[g.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${d[g.PRERELEASEIDENTIFIERLOOSE]})*))`);E("BUILDIDENTIFIER","[0-9A-Za-z-]+");E("BUILD",`(?:\\+(${d[g.BUILDIDENTIFIER]}(?:\\.${d[g.BUILDIDENTIFIER]})*))`);E("FULLPLAIN",`v?${d[g.MAINVERSION]}${d[g.PRERELEASE]}?${d[g.BUILD]}?`);E("FULL",`^${d[g.FULLPLAIN]}$`);E("LOOSEPLAIN",`[v=\\s]*${d[g.MAINVERSIONLOOSE]}${d[g.PRERELEASELOOSE]}?${d[g.BUILD]}?`);E("LOOSE",`^${d[g.LOOSEPLAIN]}$`);E("GTLT","((?:<|>)?=?)");E("XRANGEIDENTIFIERLOOSE",`${d[g.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);E("XRANGEIDENTIFIER",`${d[g.NUMERICIDENTIFIER]}|x|X|\\*`);E("XRANGEPLAIN",`[v=\\s]*(${d[g.XRANGEIDENTIFIER]})(?:\\.(${d[g.XRANGEIDENTIFIER]})(?:\\.(${d[g.XRANGEIDENTIFIER]})(?:${d[g.PRERELEASE]})?${d[g.BUILD]}?)?)?`);E("XRANGEPLAINLOOSE",`[v=\\s]*(${d[g.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[g.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[g.XRANGEIDENTIFIERLOOSE]})(?:${d[g.PRERELEASELOOSE]})?${d[g.BUILD]}?)?)?`);E("XRANGE",`^${d[g.GTLT]}\\s*${d[g.XRANGEPLAIN]}$`);E("XRANGELOOSE",`^${d[g.GTLT]}\\s*${d[g.XRANGEPLAINLOOSE]}$`);E("COERCE",`(^|[^\\d])(\\d{1,${It}})(?:\\.(\\d{1,${It}}))?(?:\\.(\\d{1,${It}}))?(?:$|[^\\d])`);E("COERCERTL",d[g.COERCE],!0);E("LONETILDE","(?:~>?)");E("TILDETRIM",`(\\s*)${d[g.LONETILDE]}\\s+`,!0);V.tildeTrimReplace="$1~";E("TILDE",`^${d[g.LONETILDE]}${d[g.XRANGEPLAIN]}$`);E("TILDELOOSE",`^${d[g.LONETILDE]}${d[g.XRANGEPLAINLOOSE]}$`);E("LONECARET","(?:\\^)");E("CARETTRIM",`(\\s*)${d[g.LONECARET]}\\s+`,!0);V.caretTrimReplace="$1^";E("CARET",`^${d[g.LONECARET]}${d[g.XRANGEPLAIN]}$`);E("CARETLOOSE",`^${d[g.LONECARET]}${d[g.XRANGEPLAINLOOSE]}$`);E("COMPARATORLOOSE",`^${d[g.GTLT]}\\s*(${d[g.LOOSEPLAIN]})$|^$`);E("COMPARATOR",`^${d[g.GTLT]}\\s*(${d[g.FULLPLAIN]})$|^$`);E("COMPARATORTRIM",`(\\s*)${d[g.GTLT]}\\s*(${d[g.LOOSEPLAIN]}|${d[g.XRANGEPLAIN]})`,!0);V.comparatorTrimReplace="$1$2$3";E("HYPHENRANGE",`^\\s*(${d[g.XRANGEPLAIN]})\\s+-\\s+(${d[g.XRANGEPLAIN]})\\s*$`);E("HYPHENRANGELOOSE",`^\\s*(${d[g.XRANGEPLAINLOOSE]})\\s+-\\s+(${d[g.XRANGEPLAINLOOSE]})\\s*$`);E("STAR","(<|>)?=?\\s*\\*");E("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");E("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var Re=v((Of,jr)=>{var $a=["includePrerelease","loose","rtl"],Na=e=>e?typeof e!="object"?{loose:!0}:$a.filter(t=>e[t]).reduce((t,r)=>(t[r]=!0,t),{}):{};jr.exports=Na});var Be=v((Sf,Dr)=>{var Cr=/^[0-9]+$/,Pr=(e,t)=>{let r=Cr.test(e),n=Cr.test(t);return r&&n&&(e=+e,t=+t),e===t?0:r&&!n?-1:n&&!r?1:e<t?-1:1},xa=(e,t)=>Pr(t,e);Dr.exports={compareIdentifiers:Pr,rcompareIdentifiers:xa}});var L=v((If,Mr)=>{var Ve=Ae(),{MAX_LENGTH:Gr,MAX_SAFE_INTEGER:ze}=Ie(),{re:kr,t:Fr}=J(),La=Re(),{compareIdentifiers:fe}=Be(),C=class{constructor(t,r){if(r=La(r),t instanceof C){if(t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease)return t;t=t.version}else if(typeof t!="string")throw new TypeError(`Invalid Version: ${t}`);if(t.length>Gr)throw new TypeError(`version is longer than ${Gr} characters`);Ve("SemVer",t,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let n=t.trim().match(r.loose?kr[Fr.LOOSE]:kr[Fr.FULL]);if(!n)throw new TypeError(`Invalid Version: ${t}`);if(this.raw=t,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>ze||this.major<0)throw new TypeError("Invalid major version");if(this.minor>ze||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>ze||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map(i=>{if(/^[0-9]+$/.test(i)){let s=+i;if(s>=0&&s<ze)return s}return i}):this.prerelease=[],this.build=n[5]?n[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(t){if(Ve("SemVer.compare",this.version,this.options,t),!(t instanceof C)){if(typeof t=="string"&&t===this.version)return 0;t=new C(t,this.options)}return t.version===this.version?0:this.compareMain(t)||this.comparePre(t)}compareMain(t){return t instanceof C||(t=new C(t,this.options)),fe(this.major,t.major)||fe(this.minor,t.minor)||fe(this.patch,t.patch)}comparePre(t){if(t instanceof C||(t=new C(t,this.options)),this.prerelease.length&&!t.prerelease.length)return-1;if(!this.prerelease.length&&t.prerelease.length)return 1;if(!this.prerelease.length&&!t.prerelease.length)return 0;let r=0;do{let n=this.prerelease[r],i=t.prerelease[r];if(Ve("prerelease compare",r,n,i),n===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(n===void 0)return-1;if(n===i)continue;return fe(n,i)}while(++r)}compareBuild(t){t instanceof C||(t=new C(t,this.options));let r=0;do{let n=this.build[r],i=t.build[r];if(Ve("prerelease compare",r,n,i),n===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(n===void 0)return-1;if(n===i)continue;return fe(n,i)}while(++r)}inc(t,r){switch(t){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r),this.inc("pre",r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r),this.inc("pre",r);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let n=this.prerelease.length;for(;--n>=0;)typeof this.prerelease[n]=="number"&&(this.prerelease[n]++,n=-2);n===-1&&this.prerelease.push(0)}r&&(fe(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error(`invalid increment argument: ${t}`)}return this.format(),this.raw=this.version,this}};Mr.exports=C});var ee=v((Af,Br)=>{var{MAX_LENGTH:Ta}=Ie(),{re:Xr,t:Ur}=J(),Hr=L(),qa=Re(),ja=(e,t)=>{if(t=qa(t),e instanceof Hr)return e;if(typeof e!="string"||e.length>Ta||!(t.loose?Xr[Ur.LOOSE]:Xr[Ur.FULL]).test(e))return null;try{return new Hr(e,t)}catch{return null}};Br.exports=ja});var zr=v((Rf,Vr)=>{var Ca=ee(),Pa=(e,t)=>{let r=Ca(e,t);return r?r.version:null};Vr.exports=Pa});var Wr=v(($f,Zr)=>{var Da=ee(),Ga=(e,t)=>{let r=Da(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null};Zr.exports=Ga});var Kr=v((Nf,Qr)=>{var Yr=L(),ka=(e,t,r,n)=>{typeof r=="string"&&(n=r,r=void 0);try{return new Yr(e instanceof Yr?e.version:e,r).inc(t,n).version}catch{return null}};Qr.exports=ka});var D=v((xf,en)=>{var Jr=L(),Fa=(e,t,r)=>new Jr(e,r).compare(new Jr(t,r));en.exports=Fa});var Ze=v((Lf,tn)=>{var Ma=D(),Xa=(e,t,r)=>Ma(e,t,r)===0;tn.exports=Xa});var sn=v((Tf,nn)=>{var rn=ee(),Ua=Ze(),Ha=(e,t)=>{if(Ua(e,t))return null;{let r=rn(e),n=rn(t),i=r.prerelease.length||n.prerelease.length,s=i?"pre":"",a=i?"prerelease":"";for(let u in r)if((u==="major"||u==="minor"||u==="patch")&&r[u]!==n[u])return s+u;return a}};nn.exports=Ha});var on=v((qf,an)=>{var Ba=L(),Va=(e,t)=>new Ba(e,t).major;an.exports=Va});var ln=v((jf,un)=>{var za=L(),Za=(e,t)=>new za(e,t).minor;un.exports=Za});var hn=v((Cf,cn)=>{var Wa=L(),Ya=(e,t)=>new Wa(e,t).patch;cn.exports=Ya});var pn=v((Pf,fn)=>{var Qa=ee(),Ka=(e,t)=>{let r=Qa(e,t);return r&&r.prerelease.length?r.prerelease:null};fn.exports=Ka});var dn=v((Df,vn)=>{var Ja=D(),eo=(e,t,r)=>Ja(t,e,r);vn.exports=eo});var mn=v((Gf,gn)=>{var to=D(),ro=(e,t)=>to(e,t,!0);gn.exports=ro});var We=v((kf,yn)=>{var En=L(),no=(e,t,r)=>{let n=new En(e,r),i=new En(t,r);return n.compare(i)||n.compareBuild(i)};yn.exports=no});var wn=v((Ff,bn)=>{var io=We(),so=(e,t)=>e.sort((r,n)=>io(r,n,t));bn.exports=so});var On=v((Mf,_n)=>{var ao=We(),oo=(e,t)=>e.sort((r,n)=>ao(n,r,t));_n.exports=oo});var $e=v((Xf,Sn)=>{var uo=D(),lo=(e,t,r)=>uo(e,t,r)>0;Sn.exports=lo});var Ye=v((Uf,In)=>{var co=D(),ho=(e,t,r)=>co(e,t,r)<0;In.exports=ho});var At=v((Hf,An)=>{var fo=D(),po=(e,t,r)=>fo(e,t,r)!==0;An.exports=po});var Qe=v((Bf,Rn)=>{var vo=D(),go=(e,t,r)=>vo(e,t,r)>=0;Rn.exports=go});var Ke=v((Vf,$n)=>{var mo=D(),Eo=(e,t,r)=>mo(e,t,r)<=0;$n.exports=Eo});var Rt=v((zf,Nn)=>{var yo=Ze(),bo=At(),wo=$e(),_o=Qe(),Oo=Ye(),So=Ke(),Io=(e,t,r,n)=>{switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e===r;case"!==":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e!==r;case"":case"=":case"==":return yo(e,r,n);case"!=":return bo(e,r,n);case">":return wo(e,r,n);case">=":return _o(e,r,n);case"<":return Oo(e,r,n);case"<=":return So(e,r,n);default:throw new TypeError(`Invalid operator: ${t}`)}};Nn.exports=Io});var Ln=v((Zf,xn)=>{var Ao=L(),Ro=ee(),{re:Je,t:et}=J(),$o=(e,t)=>{if(e instanceof Ao)return e;if(typeof e=="number"&&(e=String(e)),typeof e!="string")return null;t=t||{};let r=null;if(!t.rtl)r=e.match(Je[et.COERCE]);else{let n;for(;(n=Je[et.COERCERTL].exec(e))&&(!r||r.index+r[0].length!==e.length);)(!r||n.index+n[0].length!==r.index+r[0].length)&&(r=n),Je[et.COERCERTL].lastIndex=n.index+n[1].length+n[2].length;Je[et.COERCERTL].lastIndex=-1}return r===null?null:Ro(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,t)};xn.exports=$o});var qn=v((Wf,Tn)=>{"use strict";Tn.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let t=this.head;t;t=t.next)yield t.value}}});var Cn=v((Yf,jn)=>{"use strict";jn.exports=w;w.Node=te;w.create=w;function w(e){var t=this;if(t instanceof w||(t=new w),t.tail=null,t.head=null,t.length=0,e&&typeof e.forEach=="function")e.forEach(function(i){t.push(i)});else if(arguments.length>0)for(var r=0,n=arguments.length;r<n;r++)t.push(arguments[r]);return t}w.prototype.removeNode=function(e){if(e.list!==this)throw new Error("removing node which does not belong to this list");var t=e.next,r=e.prev;return t&&(t.prev=r),r&&(r.next=t),e===this.head&&(this.head=t),e===this.tail&&(this.tail=r),e.list.length--,e.next=null,e.prev=null,e.list=null,t};w.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var t=this.head;e.list=this,e.next=t,t&&(t.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}};w.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var t=this.tail;e.list=this,e.prev=t,t&&(t.next=e),this.tail=e,this.head||(this.head=e),this.length++}};w.prototype.push=function(){for(var e=0,t=arguments.length;e<t;e++)xo(this,arguments[e]);return this.length};w.prototype.unshift=function(){for(var e=0,t=arguments.length;e<t;e++)Lo(this,arguments[e]);return this.length};w.prototype.pop=function(){if(!!this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}};w.prototype.shift=function(){if(!!this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}};w.prototype.forEach=function(e,t){t=t||this;for(var r=this.head,n=0;r!==null;n++)e.call(t,r.value,n,this),r=r.next};w.prototype.forEachReverse=function(e,t){t=t||this;for(var r=this.tail,n=this.length-1;r!==null;n--)e.call(t,r.value,n,this),r=r.prev};w.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};w.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};w.prototype.map=function(e,t){t=t||this;for(var r=new w,n=this.head;n!==null;)r.push(e.call(t,n.value,this)),n=n.next;return r};w.prototype.mapReverse=function(e,t){t=t||this;for(var r=new w,n=this.tail;n!==null;)r.push(e.call(t,n.value,this)),n=n.prev;return r};w.prototype.reduce=function(e,t){var r,n=this.head;if(arguments.length>1)r=t;else if(this.head)n=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var i=0;n!==null;i++)r=e(r,n.value,i),n=n.next;return r};w.prototype.reduceReverse=function(e,t){var r,n=this.tail;if(arguments.length>1)r=t;else if(this.tail)n=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;n!==null;i--)r=e(r,n.value,i),n=n.prev;return r};w.prototype.toArray=function(){for(var e=new Array(this.length),t=0,r=this.head;r!==null;t++)e[t]=r.value,r=r.next;return e};w.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,r=this.tail;r!==null;t++)e[t]=r.value,r=r.prev;return e};w.prototype.slice=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var r=new w;if(t<e||t<0)return r;e<0&&(e=0),t>this.length&&(t=this.length);for(var n=0,i=this.head;i!==null&&n<e;n++)i=i.next;for(;i!==null&&n<t;n++,i=i.next)r.push(i.value);return r};w.prototype.sliceReverse=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var r=new w;if(t<e||t<0)return r;e<0&&(e=0),t>this.length&&(t=this.length);for(var n=this.length,i=this.tail;i!==null&&n>t;n--)i=i.prev;for(;i!==null&&n>e;n--,i=i.prev)r.push(i.value);return r};w.prototype.splice=function(e,t,...r){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var n=0,i=this.head;i!==null&&n<e;n++)i=i.next;for(var s=[],n=0;i&&n<t;n++)s.push(i.value),i=this.removeNode(i);i===null&&(i=this.tail),i!==this.head&&i!==this.tail&&(i=i.prev);for(var n=0;n<r.length;n++)i=No(this,i,r[n]);return s};w.prototype.reverse=function(){for(var e=this.head,t=this.tail,r=e;r!==null;r=r.prev){var n=r.prev;r.prev=r.next,r.next=n}return this.head=t,this.tail=e,this};function No(e,t,r){var n=t===e.head?new te(r,null,t,e):new te(r,t,t.next,e);return n.next===null&&(e.tail=n),n.prev===null&&(e.head=n),e.length++,n}function xo(e,t){e.tail=new te(t,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function Lo(e,t){e.head=new te(t,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function te(e,t,r,n){if(!(this instanceof te))return new te(e,t,r,n);this.list=n,this.value=e,t?(t.next=this,this.prev=t):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{qn()(w)}catch{}});var Fn=v((Qf,kn)=>{"use strict";var To=Cn(),re=Symbol("max"),H=Symbol("length"),pe=Symbol("lengthCalculator"),xe=Symbol("allowStale"),ne=Symbol("maxAge"),U=Symbol("dispose"),Pn=Symbol("noDisposeOnSet"),$=Symbol("lruList"),F=Symbol("cache"),Gn=Symbol("updateAgeOnGet"),$t=()=>1,xt=class{constructor(t){if(typeof t=="number"&&(t={max:t}),t||(t={}),t.max&&(typeof t.max!="number"||t.max<0))throw new TypeError("max must be a non-negative number");let r=this[re]=t.max||1/0,n=t.length||$t;if(this[pe]=typeof n!="function"?$t:n,this[xe]=t.stale||!1,t.maxAge&&typeof t.maxAge!="number")throw new TypeError("maxAge must be a number");this[ne]=t.maxAge||0,this[U]=t.dispose,this[Pn]=t.noDisposeOnSet||!1,this[Gn]=t.updateAgeOnGet||!1,this.reset()}set max(t){if(typeof t!="number"||t<0)throw new TypeError("max must be a non-negative number");this[re]=t||1/0,Ne(this)}get max(){return this[re]}set allowStale(t){this[xe]=!!t}get allowStale(){return this[xe]}set maxAge(t){if(typeof t!="number")throw new TypeError("maxAge must be a non-negative number");this[ne]=t,Ne(this)}get maxAge(){return this[ne]}set lengthCalculator(t){typeof t!="function"&&(t=$t),t!==this[pe]&&(this[pe]=t,this[H]=0,this[$].forEach(r=>{r.length=this[pe](r.value,r.key),this[H]+=r.length})),Ne(this)}get lengthCalculator(){return this[pe]}get length(){return this[H]}get itemCount(){return this[$].length}rforEach(t,r){r=r||this;for(let n=this[$].tail;n!==null;){let i=n.prev;Dn(this,t,n,r),n=i}}forEach(t,r){r=r||this;for(let n=this[$].head;n!==null;){let i=n.next;Dn(this,t,n,r),n=i}}keys(){return this[$].toArray().map(t=>t.key)}values(){return this[$].toArray().map(t=>t.value)}reset(){this[U]&&this[$]&&this[$].length&&this[$].forEach(t=>this[U](t.key,t.value)),this[F]=new Map,this[$]=new To,this[H]=0}dump(){return this[$].map(t=>tt(this,t)?!1:{k:t.key,v:t.value,e:t.now+(t.maxAge||0)}).toArray().filter(t=>t)}dumpLru(){return this[$]}set(t,r,n){if(n=n||this[ne],n&&typeof n!="number")throw new TypeError("maxAge must be a number");let i=n?Date.now():0,s=this[pe](r,t);if(this[F].has(t)){if(s>this[re])return ve(this,this[F].get(t)),!1;let o=this[F].get(t).value;return this[U]&&(this[Pn]||this[U](t,o.value)),o.now=i,o.maxAge=n,o.value=r,this[H]+=s-o.length,o.length=s,this.get(t),Ne(this),!0}let a=new Lt(t,r,s,i,n);return a.length>this[re]?(this[U]&&this[U](t,r),!1):(this[H]+=a.length,this[$].unshift(a),this[F].set(t,this[$].head),Ne(this),!0)}has(t){if(!this[F].has(t))return!1;let r=this[F].get(t).value;return!tt(this,r)}get(t){return Nt(this,t,!0)}peek(t){return Nt(this,t,!1)}pop(){let t=this[$].tail;return t?(ve(this,t),t.value):null}del(t){ve(this,this[F].get(t))}load(t){this.reset();let r=Date.now();for(let n=t.length-1;n>=0;n--){let i=t[n],s=i.e||0;if(s===0)this.set(i.k,i.v);else{let a=s-r;a>0&&this.set(i.k,i.v,a)}}}prune(){this[F].forEach((t,r)=>Nt(this,r,!1))}},Nt=(e,t,r)=>{let n=e[F].get(t);if(n){let i=n.value;if(tt(e,i)){if(ve(e,n),!e[xe])return}else r&&(e[Gn]&&(n.value.now=Date.now()),e[$].unshiftNode(n));return i.value}},tt=(e,t)=>{if(!t||!t.maxAge&&!e[ne])return!1;let r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[ne]&&r>e[ne]},Ne=e=>{if(e[H]>e[re])for(let t=e[$].tail;e[H]>e[re]&&t!==null;){let r=t.prev;ve(e,t),t=r}},ve=(e,t)=>{if(t){let r=t.value;e[U]&&e[U](r.key,r.value),e[H]-=r.length,e[F].delete(r.key),e[$].removeNode(t)}},Lt=class{constructor(t,r,n,i,s){this.key=t,this.value=r,this.length=n,this.now=i,this.maxAge=s||0}},Dn=(e,t,r,n)=>{let i=r.value;tt(e,i)&&(ve(e,r),e[xe]||(i=void 0)),i&&t.call(n,i.value,i.key,e)};kn.exports=xt});var G=v((Kf,Hn)=>{var ie=class{constructor(t,r){if(r=jo(r),t instanceof ie)return t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease?t:new ie(t.raw,r);if(t instanceof Tt)return this.raw=t.value,this.set=[[t]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=t,this.set=t.split("||").map(n=>this.parseRange(n.trim())).filter(n=>n.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${t}`);if(this.set.length>1){let n=this.set[0];if(this.set=this.set.filter(i=>!Xn(i[0])),this.set.length===0)this.set=[n];else if(this.set.length>1){for(let i of this.set)if(i.length===1&&ko(i[0])){this.set=[i];break}}}this.format()}format(){return this.range=this.set.map(t=>t.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(t){t=t.trim();let n=`parseRange:${Object.keys(this.options).join(",")}:${t}`,i=Mn.get(n);if(i)return i;let s=this.options.loose,a=s?j[T.HYPHENRANGELOOSE]:j[T.HYPHENRANGE];t=t.replace(a,Wo(this.options.includePrerelease)),I("hyphen replace",t),t=t.replace(j[T.COMPARATORTRIM],Po),I("comparator trim",t),t=t.replace(j[T.TILDETRIM],Do),t=t.replace(j[T.CARETTRIM],Go),t=t.split(/\s+/).join(" ");let u=t.split(" ").map(f=>Fo(f,this.options)).join(" ").split(/\s+/).map(f=>Zo(f,this.options));s&&(u=u.filter(f=>(I("loose invalid filter",f,this.options),!!f.match(j[T.COMPARATORLOOSE])))),I("range list",u);let o=new Map,l=u.map(f=>new Tt(f,this.options));for(let f of l){if(Xn(f))return[f];o.set(f.value,f)}o.size>1&&o.has("")&&o.delete("");let h=[...o.values()];return Mn.set(n,h),h}intersects(t,r){if(!(t instanceof ie))throw new TypeError("a Range is required");return this.set.some(n=>Un(n,r)&&t.set.some(i=>Un(i,r)&&n.every(s=>i.every(a=>s.intersects(a,r)))))}test(t){if(!t)return!1;if(typeof t=="string")try{t=new Co(t,this.options)}catch{return!1}for(let r=0;r<this.set.length;r++)if(Yo(this.set[r],t,this.options))return!0;return!1}};Hn.exports=ie;var qo=Fn(),Mn=new qo({max:1e3}),jo=Re(),Tt=Le(),I=Ae(),Co=L(),{re:j,t:T,comparatorTrimReplace:Po,tildeTrimReplace:Do,caretTrimReplace:Go}=J(),Xn=e=>e.value==="<0.0.0-0",ko=e=>e.value==="",Un=(e,t)=>{let r=!0,n=e.slice(),i=n.pop();for(;r&&n.length;)r=n.every(s=>i.intersects(s,t)),i=n.pop();return r},Fo=(e,t)=>(I("comp",e,t),e=Uo(e,t),I("caret",e),e=Mo(e,t),I("tildes",e),e=Bo(e,t),I("xrange",e),e=zo(e,t),I("stars",e),e),q=e=>!e||e.toLowerCase()==="x"||e==="*",Mo=(e,t)=>e.trim().split(/\s+/).map(r=>Xo(r,t)).join(" "),Xo=(e,t)=>{let r=t.loose?j[T.TILDELOOSE]:j[T.TILDE];return e.replace(r,(n,i,s,a,u)=>{I("tilde",e,n,i,s,a,u);let o;return q(i)?o="":q(s)?o=`>=${i}.0.0 <${+i+1}.0.0-0`:q(a)?o=`>=${i}.${s}.0 <${i}.${+s+1}.0-0`:u?(I("replaceTilde pr",u),o=`>=${i}.${s}.${a}-${u} <${i}.${+s+1}.0-0`):o=`>=${i}.${s}.${a} <${i}.${+s+1}.0-0`,I("tilde return",o),o})},Uo=(e,t)=>e.trim().split(/\s+/).map(r=>Ho(r,t)).join(" "),Ho=(e,t)=>{I("caret",e,t);let r=t.loose?j[T.CARETLOOSE]:j[T.CARET],n=t.includePrerelease?"-0":"";return e.replace(r,(i,s,a,u,o)=>{I("caret",e,i,s,a,u,o);let l;return q(s)?l="":q(a)?l=`>=${s}.0.0${n} <${+s+1}.0.0-0`:q(u)?s==="0"?l=`>=${s}.${a}.0${n} <${s}.${+a+1}.0-0`:l=`>=${s}.${a}.0${n} <${+s+1}.0.0-0`:o?(I("replaceCaret pr",o),s==="0"?a==="0"?l=`>=${s}.${a}.${u}-${o} <${s}.${a}.${+u+1}-0`:l=`>=${s}.${a}.${u}-${o} <${s}.${+a+1}.0-0`:l=`>=${s}.${a}.${u}-${o} <${+s+1}.0.0-0`):(I("no pr"),s==="0"?a==="0"?l=`>=${s}.${a}.${u}${n} <${s}.${a}.${+u+1}-0`:l=`>=${s}.${a}.${u}${n} <${s}.${+a+1}.0-0`:l=`>=${s}.${a}.${u} <${+s+1}.0.0-0`),I("caret return",l),l})},Bo=(e,t)=>(I("replaceXRanges",e,t),e.split(/\s+/).map(r=>Vo(r,t)).join(" ")),Vo=(e,t)=>{e=e.trim();let r=t.loose?j[T.XRANGELOOSE]:j[T.XRANGE];return e.replace(r,(n,i,s,a,u,o)=>{I("xRange",e,n,i,s,a,u,o);let l=q(s),h=l||q(a),f=h||q(u),p=f;return i==="="&&p&&(i=""),o=t.includePrerelease?"-0":"",l?i===">"||i==="<"?n="<0.0.0-0":n="*":i&&p?(h&&(a=0),u=0,i===">"?(i=">=",h?(s=+s+1,a=0,u=0):(a=+a+1,u=0)):i==="<="&&(i="<",h?s=+s+1:a=+a+1),i==="<"&&(o="-0"),n=`${i+s}.${a}.${u}${o}`):h?n=`>=${s}.0.0${o} <${+s+1}.0.0-0`:f&&(n=`>=${s}.${a}.0${o} <${s}.${+a+1}.0-0`),I("xRange return",n),n})},zo=(e,t)=>(I("replaceStars",e,t),e.trim().replace(j[T.STAR],"")),Zo=(e,t)=>(I("replaceGTE0",e,t),e.trim().replace(j[t.includePrerelease?T.GTE0PRE:T.GTE0],"")),Wo=e=>(t,r,n,i,s,a,u,o,l,h,f,p,c)=>(q(n)?r="":q(i)?r=`>=${n}.0.0${e?"-0":""}`:q(s)?r=`>=${n}.${i}.0${e?"-0":""}`:a?r=`>=${r}`:r=`>=${r}${e?"-0":""}`,q(l)?o="":q(h)?o=`<${+l+1}.0.0-0`:q(f)?o=`<${l}.${+h+1}.0-0`:p?o=`<=${l}.${h}.${f}-${p}`:e?o=`<${l}.${h}.${+f+1}-0`:o=`<=${o}`,`${r} ${o}`.trim()),Yo=(e,t,r)=>{for(let n=0;n<e.length;n++)if(!e[n].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(let n=0;n<e.length;n++)if(I(e[n].semver),e[n].semver!==Tt.ANY&&e[n].semver.prerelease.length>0){let i=e[n].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0}});var Le=v((Jf,Wn)=>{var Te=Symbol("SemVer ANY"),de=class{static get ANY(){return Te}constructor(t,r){if(r=Qo(r),t instanceof de){if(t.loose===!!r.loose)return t;t=t.value}jt("comparator",t,r),this.options=r,this.loose=!!r.loose,this.parse(t),this.semver===Te?this.value="":this.value=this.operator+this.semver.version,jt("comp",this)}parse(t){let r=this.options.loose?Bn[Vn.COMPARATORLOOSE]:Bn[Vn.COMPARATOR],n=t.match(r);if(!n)throw new TypeError(`Invalid comparator: ${t}`);this.operator=n[1]!==void 0?n[1]:"",this.operator==="="&&(this.operator=""),n[2]?this.semver=new zn(n[2],this.options.loose):this.semver=Te}toString(){return this.value}test(t){if(jt("Comparator.test",t,this.options.loose),this.semver===Te||t===Te)return!0;if(typeof t=="string")try{t=new zn(t,this.options)}catch{return!1}return qt(t,this.operator,this.semver,this.options)}intersects(t,r){if(!(t instanceof de))throw new TypeError("a Comparator is required");if((!r||typeof r!="object")&&(r={loose:!!r,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Zn(t.value,r).test(this.value);if(t.operator==="")return t.value===""?!0:new Zn(this.value,r).test(t.semver);let n=(this.operator===">="||this.operator===">")&&(t.operator===">="||t.operator===">"),i=(this.operator==="<="||this.operator==="<")&&(t.operator==="<="||t.operator==="<"),s=this.semver.version===t.semver.version,a=(this.operator===">="||this.operator==="<=")&&(t.operator===">="||t.operator==="<="),u=qt(this.semver,"<",t.semver,r)&&(this.operator===">="||this.operator===">")&&(t.operator==="<="||t.operator==="<"),o=qt(this.semver,">",t.semver,r)&&(this.operator==="<="||this.operator==="<")&&(t.operator===">="||t.operator===">");return n||i||s&&a||u||o}};Wn.exports=de;var Qo=Re(),{re:Bn,t:Vn}=J(),qt=Rt(),jt=Ae(),zn=L(),Zn=G()});var qe=v((ep,Yn)=>{var Ko=G(),Jo=(e,t,r)=>{try{t=new Ko(t,r)}catch{return!1}return t.test(e)};Yn.exports=Jo});var Kn=v((tp,Qn)=>{var eu=G(),tu=(e,t)=>new eu(e,t).set.map(r=>r.map(n=>n.value).join(" ").trim().split(" "));Qn.exports=tu});var ei=v((rp,Jn)=>{var ru=L(),nu=G(),iu=(e,t,r)=>{let n=null,i=null,s=null;try{s=new nu(t,r)}catch{return null}return e.forEach(a=>{s.test(a)&&(!n||i.compare(a)===-1)&&(n=a,i=new ru(n,r))}),n};Jn.exports=iu});var ri=v((np,ti)=>{var su=L(),au=G(),ou=(e,t,r)=>{let n=null,i=null,s=null;try{s=new au(t,r)}catch{return null}return e.forEach(a=>{s.test(a)&&(!n||i.compare(a)===1)&&(n=a,i=new su(n,r))}),n};ti.exports=ou});var si=v((ip,ii)=>{var Ct=L(),uu=G(),ni=$e(),lu=(e,t)=>{e=new uu(e,t);let r=new Ct("0.0.0");if(e.test(r)||(r=new Ct("0.0.0-0"),e.test(r)))return r;r=null;for(let n=0;n<e.set.length;++n){let i=e.set[n],s=null;i.forEach(a=>{let u=new Ct(a.semver.version);switch(a.operator){case">":u.prerelease.length===0?u.patch++:u.prerelease.push(0),u.raw=u.format();case"":case">=":(!s||ni(u,s))&&(s=u);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${a.operator}`)}}),s&&(!r||ni(r,s))&&(r=s)}return r&&e.test(r)?r:null};ii.exports=lu});var oi=v((sp,ai)=>{var cu=G(),hu=(e,t)=>{try{return new cu(e,t).range||"*"}catch{return null}};ai.exports=hu});var rt=v((ap,hi)=>{var fu=L(),ci=Le(),{ANY:pu}=ci,vu=G(),du=qe(),ui=$e(),li=Ye(),gu=Ke(),mu=Qe(),Eu=(e,t,r,n)=>{e=new fu(e,n),t=new vu(t,n);let i,s,a,u,o;switch(r){case">":i=ui,s=gu,a=li,u=">",o=">=";break;case"<":i=li,s=mu,a=ui,u="<",o="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(du(e,t,n))return!1;for(let l=0;l<t.set.length;++l){let h=t.set[l],f=null,p=null;if(h.forEach(c=>{c.semver===pu&&(c=new ci(">=0.0.0")),f=f||c,p=p||c,i(c.semver,f.semver,n)?f=c:a(c.semver,p.semver,n)&&(p=c)}),f.operator===u||f.operator===o||(!p.operator||p.operator===u)&&s(e,p.semver))return!1;if(p.operator===o&&a(e,p.semver))return!1}return!0};hi.exports=Eu});var pi=v((op,fi)=>{var yu=rt(),bu=(e,t,r)=>yu(e,t,">",r);fi.exports=bu});var di=v((up,vi)=>{var wu=rt(),_u=(e,t,r)=>wu(e,t,"<",r);vi.exports=_u});var Ei=v((lp,mi)=>{var gi=G(),Ou=(e,t,r)=>(e=new gi(e,r),t=new gi(t,r),e.intersects(t));mi.exports=Ou});var bi=v((cp,yi)=>{var Su=qe(),Iu=D();yi.exports=(e,t,r)=>{let n=[],i=null,s=null,a=e.sort((h,f)=>Iu(h,f,r));for(let h of a)Su(h,t,r)?(s=h,i||(i=h)):(s&&n.push([i,s]),s=null,i=null);i&&n.push([i,null]);let u=[];for(let[h,f]of n)h===f?u.push(h):!f&&h===a[0]?u.push("*"):f?h===a[0]?u.push(`<=${f}`):u.push(`${h} - ${f}`):u.push(`>=${h}`);let o=u.join(" || "),l=typeof t.raw=="string"?t.raw:String(t);return o.length<l.length?o:t}});var Ii=v((hp,Si)=>{var wi=G(),nt=Le(),{ANY:Pt}=nt,je=qe(),Dt=D(),Au=(e,t,r={})=>{if(e===t)return!0;e=new wi(e,r),t=new wi(t,r);let n=!1;e:for(let i of e.set){for(let s of t.set){let a=Ru(i,s,r);if(n=n||a!==null,a)continue e}if(n)return!1}return!0},Ru=(e,t,r)=>{if(e===t)return!0;if(e.length===1&&e[0].semver===Pt){if(t.length===1&&t[0].semver===Pt)return!0;r.includePrerelease?e=[new nt(">=0.0.0-0")]:e=[new nt(">=0.0.0")]}if(t.length===1&&t[0].semver===Pt){if(r.includePrerelease)return!0;t=[new nt(">=0.0.0")]}let n=new Set,i,s;for(let c of e)c.operator===">"||c.operator===">="?i=_i(i,c,r):c.operator==="<"||c.operator==="<="?s=Oi(s,c,r):n.add(c.semver);if(n.size>1)return null;let a;if(i&&s){if(a=Dt(i.semver,s.semver,r),a>0)return null;if(a===0&&(i.operator!==">="||s.operator!=="<="))return null}for(let c of n){if(i&&!je(c,String(i),r)||s&&!je(c,String(s),r))return null;for(let m of t)if(!je(c,String(m),r))return!1;return!0}let u,o,l,h,f=s&&!r.includePrerelease&&s.semver.prerelease.length?s.semver:!1,p=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1;f&&f.prerelease.length===1&&s.operator==="<"&&f.prerelease[0]===0&&(f=!1);for(let c of t){if(h=h||c.operator===">"||c.operator===">=",l=l||c.operator==="<"||c.operator==="<=",i){if(p&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===p.major&&c.semver.minor===p.minor&&c.semver.patch===p.patch&&(p=!1),c.operator===">"||c.operator===">="){if(u=_i(i,c,r),u===c&&u!==i)return!1}else if(i.operator===">="&&!je(i.semver,String(c),r))return!1}if(s){if(f&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===f.major&&c.semver.minor===f.minor&&c.semver.patch===f.patch&&(f=!1),c.operator==="<"||c.operator==="<="){if(o=Oi(s,c,r),o===c&&o!==s)return!1}else if(s.operator==="<="&&!je(s.semver,String(c),r))return!1}if(!c.operator&&(s||i)&&a!==0)return!1}return!(i&&l&&!s&&a!==0||s&&h&&!i&&a!==0||p||f)},_i=(e,t,r)=>{if(!e)return t;let n=Dt(e.semver,t.semver,r);return n>0?e:n<0||t.operator===">"&&e.operator===">="?t:e},Oi=(e,t,r)=>{if(!e)return t;let n=Dt(e.semver,t.semver,r);return n<0?e:n>0||t.operator==="<"&&e.operator==="<="?t:e};Si.exports=Au});var Ri=v((fp,Ai)=>{var Gt=J();Ai.exports={re:Gt.re,src:Gt.src,tokens:Gt.t,SEMVER_SPEC_VERSION:Ie().SEMVER_SPEC_VERSION,SemVer:L(),compareIdentifiers:Be().compareIdentifiers,rcompareIdentifiers:Be().rcompareIdentifiers,parse:ee(),valid:zr(),clean:Wr(),inc:Kr(),diff:sn(),major:on(),minor:ln(),patch:hn(),prerelease:pn(),compare:D(),rcompare:dn(),compareLoose:mn(),compareBuild:We(),sort:wn(),rsort:On(),gt:$e(),lt:Ye(),eq:Ze(),neq:At(),gte:Qe(),lte:Ke(),cmp:Rt(),coerce:Ln(),Comparator:Le(),Range:G(),satisfies:qe(),toComparators:Kn(),maxSatisfying:ei(),minSatisfying:ri(),minVersion:si(),validRange:oi(),outside:rt(),gtr:pi(),ltr:di(),intersects:Ei(),simplifyRange:bi(),subset:Ii()}});var qi=v((dp,Ti)=>{"use strict";var Li=Ti.exports={},Ft={};"Number String Boolean Function RegExp Array Date Error".split(" ").forEach(function(e){Ft["[object "+e+"]"]=e.toLowerCase()});Li.kindOf=function(e){return e==null?String(e):Ft[Ft.toString.call(e)]||"object"};Li.toArray=Function.call.bind(Array.prototype.slice)});var Bi=v((gp,Hi)=>{var xu=200,Ut="__lodash_hash_undefined__",Lu=9007199254740991,Tu="[object Arguments]",qu="[object Function]",ju="[object GeneratorFunction]",Cu=/[\\^$.*+?()[\]{}|]/g,Pu=/^\[object .+?Constructor\]$/,Du=typeof global=="object"&&global&&global.Object===Object&&global,Gu=typeof self=="object"&&self&&self.Object===Object&&self,Ht=Du||Gu||Function("return this")();function ku(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function Fu(e,t){var r=e?e.length:0;return!!r&&Bu(e,t,0)>-1}function Mu(e,t,r){for(var n=-1,i=e?e.length:0;++n<i;)if(r(t,e[n]))return!0;return!1}function Xu(e,t){for(var r=-1,n=e?e.length:0,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}function Uu(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}function Hu(e,t,r,n){for(var i=e.length,s=r+(n?1:-1);n?s--:++s<i;)if(t(e[s],s,e))return s;return-1}function Bu(e,t,r){if(t!==t)return Hu(e,Vu,r);for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}function Vu(e){return e!==e}function zu(e){return function(t){return e(t)}}function Zu(e,t){return e.has(t)}function Wu(e,t){return e?.[t]}function Yu(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch{}return t}var Qu=Array.prototype,Ku=Function.prototype,Bt=Object.prototype,Mt=Ht["__core-js_shared__"],ji=function(){var e=/[^.]+$/.exec(Mt&&Mt.keys&&Mt.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),Gi=Ku.toString,at=Bt.hasOwnProperty,ki=Bt.toString,Ju=RegExp("^"+Gi.call(at).replace(Cu,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ci=Ht.Symbol,el=Bt.propertyIsEnumerable,tl=Qu.splice,Pi=Ci?Ci.isConcatSpreadable:void 0,Di=Math.max,rl=Mi(Ht,"Map"),Ce=Mi(Object,"create");function se(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function nl(){this.__data__=Ce?Ce(null):{}}function il(e){return this.has(e)&&delete this.__data__[e]}function sl(e){var t=this.__data__;if(Ce){var r=t[e];return r===Ut?void 0:r}return at.call(t,e)?t[e]:void 0}function al(e){var t=this.__data__;return Ce?t[e]!==void 0:at.call(t,e)}function ol(e,t){var r=this.__data__;return r[e]=Ce&&t===void 0?Ut:t,this}se.prototype.clear=nl;se.prototype.delete=il;se.prototype.get=sl;se.prototype.has=al;se.prototype.set=ol;function ge(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function ul(){this.__data__=[]}function ll(e){var t=this.__data__,r=ot(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():tl.call(t,r,1),!0}function cl(e){var t=this.__data__,r=ot(t,e);return r<0?void 0:t[r][1]}function hl(e){return ot(this.__data__,e)>-1}function fl(e,t){var r=this.__data__,n=ot(r,e);return n<0?r.push([e,t]):r[n][1]=t,this}ge.prototype.clear=ul;ge.prototype.delete=ll;ge.prototype.get=cl;ge.prototype.has=hl;ge.prototype.set=fl;function me(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function pl(){this.__data__={hash:new se,map:new(rl||ge),string:new se}}function vl(e){return ut(this,e).delete(e)}function dl(e){return ut(this,e).get(e)}function gl(e){return ut(this,e).has(e)}function ml(e,t){return ut(this,e).set(e,t),this}me.prototype.clear=pl;me.prototype.delete=vl;me.prototype.get=dl;me.prototype.has=gl;me.prototype.set=ml;function st(e){var t=-1,r=e?e.length:0;for(this.__data__=new me;++t<r;)this.add(e[t])}function El(e){return this.__data__.set(e,Ut),this}function yl(e){return this.__data__.has(e)}st.prototype.add=st.prototype.push=El;st.prototype.has=yl;function ot(e,t){for(var r=e.length;r--;)if($l(e[r][0],t))return r;return-1}function bl(e,t,r,n){var i=-1,s=Fu,a=!0,u=e.length,o=[],l=t.length;if(!u)return o;r&&(t=Xu(t,zu(r))),n?(s=Mu,a=!1):t.length>=xu&&(s=Zu,a=!1,t=new st(t));e:for(;++i<u;){var h=e[i],f=r?r(h):h;if(h=n||h!==0?h:0,a&&f===f){for(var p=l;p--;)if(t[p]===f)continue e;o.push(h)}else s(t,f,n)||o.push(h)}return o}function Fi(e,t,r,n,i){var s=-1,a=e.length;for(r||(r=Ol),i||(i=[]);++s<a;){var u=e[s];t>0&&r(u)?t>1?Fi(u,t-1,r,n,i):Uu(i,u):n||(i[i.length]=u)}return i}function wl(e){if(!Ui(e)||Il(e))return!1;var t=Xi(e)||Yu(e)?Ju:Pu;return t.test(Al(e))}function _l(e,t){return t=Di(t===void 0?e.length-1:t,0),function(){for(var r=arguments,n=-1,i=Di(r.length-t,0),s=Array(i);++n<i;)s[n]=r[t+n];n=-1;for(var a=Array(t+1);++n<t;)a[n]=r[n];return a[t]=s,ku(e,this,a)}}function ut(e,t){var r=e.__data__;return Sl(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Mi(e,t){var r=Wu(e,t);return wl(r)?r:void 0}function Ol(e){return xl(e)||Nl(e)||!!(Pi&&e&&e[Pi])}function Sl(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Il(e){return!!ji&&ji in e}function Al(e){if(e!=null){try{return Gi.call(e)}catch{}try{return e+""}catch{}}return""}var Rl=_l(function(e,t){return Xt(e)?bl(e,Fi(t,1,Xt,!0)):[]});function $l(e,t){return e===t||e!==e&&t!==t}function Nl(e){return Xt(e)&&at.call(e,"callee")&&(!el.call(e,"callee")||ki.call(e)==Tu)}var xl=Array.isArray;function Ll(e){return e!=null&&Tl(e.length)&&!Xi(e)}function Xt(e){return ql(e)&&Ll(e)}function Xi(e){var t=Ui(e)?ki.call(e):"";return t==qu||t==ju}function Tl(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Lu}function Ui(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function ql(e){return!!e&&typeof e=="object"}Hi.exports=Rl});var Qi=v((mp,Yi)=>{var jl=9007199254740991,Cl="[object Arguments]",Pl="[object Function]",Dl="[object GeneratorFunction]",Gl=typeof global=="object"&&global&&global.Object===Object&&global,kl=typeof self=="object"&&self&&self.Object===Object&&self,Fl=Gl||kl||Function("return this")();function Ml(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}var Vt=Object.prototype,Xl=Vt.hasOwnProperty,Zi=Vt.toString,Vi=Fl.Symbol,Ul=Vt.propertyIsEnumerable,zi=Vi?Vi.isConcatSpreadable:void 0;function Wi(e,t,r,n,i){var s=-1,a=e.length;for(r||(r=Hl),i||(i=[]);++s<a;){var u=e[s];t>0&&r(u)?t>1?Wi(u,t-1,r,n,i):Ml(i,u):n||(i[i.length]=u)}return i}function Hl(e){return zl(e)||Vl(e)||!!(zi&&e&&e[zi])}function Bl(e){var t=e?e.length:0;return t?Wi(e,1):[]}function Vl(e){return Wl(e)&&Xl.call(e,"callee")&&(!Ul.call(e,"callee")||Zi.call(e)==Cl)}var zl=Array.isArray;function Zl(e){return e!=null&&Ql(e.length)&&!Yl(e)}function Wl(e){return Jl(e)&&Zl(e)}function Yl(e){var t=Kl(e)?Zi.call(e):"";return t==Pl||t==Dl}function Ql(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=jl}function Kl(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function Jl(e){return!!e&&typeof e=="object"}Yi.exports=Bl});var cs=v((Ep,ls)=>{var ec=200,Wt="__lodash_hash_undefined__",tc=1/0,rc=9007199254740991,nc="[object Arguments]",ic="[object Function]",sc="[object GeneratorFunction]",ac=/[\\^$.*+?()[\]{}|]/g,oc=/^\[object .+?Constructor\]$/,uc=typeof global=="object"&&global&&global.Object===Object&&global,lc=typeof self=="object"&&self&&self.Object===Object&&self,ct=uc||lc||Function("return this")();function cc(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function hc(e,t){var r=e?e.length:0;return!!r&&dc(e,t,0)>-1}function fc(e,t,r){for(var n=-1,i=e?e.length:0;++n<i;)if(r(t,e[n]))return!0;return!1}function pc(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}function vc(e,t,r,n){for(var i=e.length,s=r+(n?1:-1);n?s--:++s<i;)if(t(e[s],s,e))return s;return-1}function dc(e,t,r){if(t!==t)return vc(e,gc,r);for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}function gc(e){return e!==e}function mc(e,t){return e.has(t)}function Ec(e,t){return e?.[t]}function yc(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch{}return t}function rs(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var bc=Array.prototype,wc=Function.prototype,Yt=Object.prototype,zt=ct["__core-js_shared__"],Ki=function(){var e=/[^.]+$/.exec(zt&&zt.keys&&zt.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),ns=wc.toString,ht=Yt.hasOwnProperty,is=Yt.toString,_c=RegExp("^"+ns.call(ht).replace(ac,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ji=ct.Symbol,Oc=Yt.propertyIsEnumerable,Sc=bc.splice,es=Ji?Ji.isConcatSpreadable:void 0,ts=Math.max,Ic=Qt(ct,"Map"),Zt=Qt(ct,"Set"),Pe=Qt(Object,"create");function ae(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Ac(){this.__data__=Pe?Pe(null):{}}function Rc(e){return this.has(e)&&delete this.__data__[e]}function $c(e){var t=this.__data__;if(Pe){var r=t[e];return r===Wt?void 0:r}return ht.call(t,e)?t[e]:void 0}function Nc(e){var t=this.__data__;return Pe?t[e]!==void 0:ht.call(t,e)}function xc(e,t){var r=this.__data__;return r[e]=Pe&&t===void 0?Wt:t,this}ae.prototype.clear=Ac;ae.prototype.delete=Rc;ae.prototype.get=$c;ae.prototype.has=Nc;ae.prototype.set=xc;function Ee(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Lc(){this.__data__=[]}function Tc(e){var t=this.__data__,r=ft(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Sc.call(t,r,1),!0}function qc(e){var t=this.__data__,r=ft(t,e);return r<0?void 0:t[r][1]}function jc(e){return ft(this.__data__,e)>-1}function Cc(e,t){var r=this.__data__,n=ft(r,e);return n<0?r.push([e,t]):r[n][1]=t,this}Ee.prototype.clear=Lc;Ee.prototype.delete=Tc;Ee.prototype.get=qc;Ee.prototype.has=jc;Ee.prototype.set=Cc;function ye(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Pc(){this.__data__={hash:new ae,map:new(Ic||Ee),string:new ae}}function Dc(e){return pt(this,e).delete(e)}function Gc(e){return pt(this,e).get(e)}function kc(e){return pt(this,e).has(e)}function Fc(e,t){return pt(this,e).set(e,t),this}ye.prototype.clear=Pc;ye.prototype.delete=Dc;ye.prototype.get=Gc;ye.prototype.has=kc;ye.prototype.set=Fc;function lt(e){var t=-1,r=e?e.length:0;for(this.__data__=new ye;++t<r;)this.add(e[t])}function Mc(e){return this.__data__.set(e,Wt),this}function Xc(e){return this.__data__.has(e)}lt.prototype.add=lt.prototype.push=Mc;lt.prototype.has=Xc;function ft(e,t){for(var r=e.length;r--;)if(Kc(e[r][0],t))return r;return-1}function ss(e,t,r,n,i){var s=-1,a=e.length;for(r||(r=zc),i||(i=[]);++s<a;){var u=e[s];t>0&&r(u)?t>1?ss(u,t-1,r,n,i):pc(i,u):n||(i[i.length]=u)}return i}function Uc(e){if(!us(e)||Wc(e))return!1;var t=os(e)||yc(e)?_c:oc;return t.test(Yc(e))}function Hc(e,t){return t=ts(t===void 0?e.length-1:t,0),function(){for(var r=arguments,n=-1,i=ts(r.length-t,0),s=Array(i);++n<i;)s[n]=r[t+n];n=-1;for(var a=Array(t+1);++n<t;)a[n]=r[n];return a[t]=s,cc(e,this,a)}}function Bc(e,t,r){var n=-1,i=hc,s=e.length,a=!0,u=[],o=u;if(r)a=!1,i=fc;else if(s>=ec){var l=t?null:Vc(e);if(l)return rs(l);a=!1,i=mc,o=new lt}else o=t?[]:u;e:for(;++n<s;){var h=e[n],f=t?t(h):h;if(h=r||h!==0?h:0,a&&f===f){for(var p=o.length;p--;)if(o[p]===f)continue e;t&&o.push(f),u.push(h)}else i(o,f,r)||(o!==u&&o.push(f),u.push(h))}return u}var Vc=Zt&&1/rs(new Zt([,-0]))[1]==tc?function(e){return new Zt(e)}:ih;function pt(e,t){var r=e.__data__;return Zc(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Qt(e,t){var r=Ec(e,t);return Uc(r)?r:void 0}function zc(e){return eh(e)||Jc(e)||!!(es&&e&&e[es])}function Zc(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Wc(e){return!!Ki&&Ki in e}function Yc(e){if(e!=null){try{return ns.call(e)}catch{}try{return e+""}catch{}}return""}var Qc=Hc(function(e){return Bc(ss(e,1,as,!0))});function Kc(e,t){return e===t||e!==e&&t!==t}function Jc(e){return as(e)&&ht.call(e,"callee")&&(!Oc.call(e,"callee")||is.call(e)==nc)}var eh=Array.isArray;function th(e){return e!=null&&rh(e.length)&&!os(e)}function as(e){return nh(e)&&th(e)}function os(e){var t=us(e)?is.call(e):"";return t==ic||t==sc}function rh(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=rc}function us(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function nh(e){return!!e&&typeof e=="object"}function ih(){}ls.exports=Qc});var hs=v(Kt=>{var oe=require("path"),Z=process.platform==="win32",z=require("fs"),sh=process.env.NODE_DEBUG&&/fs/.test(process.env.NODE_DEBUG);function ah(){var e;if(sh){var t=new Error;e=r}else e=n;return e;function r(i){i&&(t.message=i.message,i=t,n(i))}function n(i){if(i){if(process.throwDeprecation)throw i;if(!process.noDeprecation){var s="fs: missing callback "+(i.stack||i.message);process.traceDeprecation?console.trace(s):console.error(s)}}}}function oh(e){return typeof e=="function"?e:ah()}var yp=oe.normalize;Z?B=/(.*?)(?:[\/\\]+|$)/g:B=/(.*?)(?:[\/]+|$)/g;var B;Z?De=/^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/:De=/^[\/]*/;var De;Kt.realpathSync=function(t,r){if(t=oe.resolve(t),r&&Object.prototype.hasOwnProperty.call(r,t))return r[t];var n=t,i={},s={},a,u,o,l;h();function h(){var b=De.exec(t);a=b[0].length,u=b[0],o=b[0],l="",Z&&!s[o]&&(z.lstatSync(o),s[o]=!0)}for(;a<t.length;){B.lastIndex=a;var f=B.exec(t);if(l=u,u+=f[0],o=l+f[1],a=B.lastIndex,!(s[o]||r&&r[o]===o)){var p;if(r&&Object.prototype.hasOwnProperty.call(r,o))p=r[o];else{var c=z.lstatSync(o);if(!c.isSymbolicLink()){s[o]=!0,r&&(r[o]=o);continue}var m=null;if(!Z){var y=c.dev.toString(32)+":"+c.ino.toString(32);i.hasOwnProperty(y)&&(m=i[y])}m===null&&(z.statSync(o),m=z.readlinkSync(o)),p=oe.resolve(l,m),r&&(r[o]=p),Z||(i[y]=m)}t=oe.resolve(p,t.slice(a)),h()}}return r&&(r[n]=t),t};Kt.realpath=function(t,r,n){if(typeof n!="function"&&(n=oh(r),r=null),t=oe.resolve(t),r&&Object.prototype.hasOwnProperty.call(r,t))return process.nextTick(n.bind(null,null,r[t]));var i=t,s={},a={},u,o,l,h;f();function f(){var b=De.exec(t);u=b[0].length,o=b[0],l=b[0],h="",Z&&!a[l]?z.lstat(l,function(O){if(O)return n(O);a[l]=!0,p()}):process.nextTick(p)}function p(){if(u>=t.length)return r&&(r[i]=t),n(null,t);B.lastIndex=u;var b=B.exec(t);return h=o,o+=b[0],l=h+b[1],u=B.lastIndex,a[l]||r&&r[l]===l?process.nextTick(p):r&&Object.prototype.hasOwnProperty.call(r,l)?y(r[l]):z.lstat(l,c)}function c(b,O){if(b)return n(b);if(!O.isSymbolicLink())return a[l]=!0,r&&(r[l]=l),process.nextTick(p);if(!Z){var S=O.dev.toString(32)+":"+O.ino.toString(32);if(s.hasOwnProperty(S))return m(null,s[S],l)}z.stat(l,function(x){if(x)return n(x);z.readlink(l,function(R,k){Z||(s[S]=k),m(R,k)})})}function m(b,O,S){if(b)return n(b);var x=oe.resolve(h,O);r&&(r[S]=x),y(x)}function y(b){t=oe.resolve(b,t.slice(u)),f()}}});var rr=v((wp,ds)=>{ds.exports=W;W.realpath=W;W.sync=tr;W.realpathSync=tr;W.monkeypatch=lh;W.unmonkeypatch=ch;var be=require("fs"),Jt=be.realpath,er=be.realpathSync,uh=process.version,fs=/^v[0-5]\./.test(uh),ps=hs();function vs(e){return e&&e.syscall==="realpath"&&(e.code==="ELOOP"||e.code==="ENOMEM"||e.code==="ENAMETOOLONG")}function W(e,t,r){if(fs)return Jt(e,t,r);typeof t=="function"&&(r=t,t=null),Jt(e,t,function(n,i){vs(n)?ps.realpath(e,t,r):r(n,i)})}function tr(e,t){if(fs)return er(e,t);try{return er(e,t)}catch(r){if(vs(r))return ps.realpathSync(e,t);throw r}}function lh(){be.realpath=W,be.realpathSync=tr}function ch(){be.realpath=Jt,be.realpathSync=er}});var ms=v((_p,gs)=>{gs.exports=function(e,t){for(var r=[],n=0;n<e.length;n++){var i=t(e[n],n);hh(i)?r.push.apply(r,i):r.push(i)}return r};var hh=Array.isArray||function(e){return Object.prototype.toString.call(e)==="[object Array]"}});var _s=v((Op,ws)=>{"use strict";ws.exports=ys;function ys(e,t,r){e instanceof RegExp&&(e=Es(e,r)),t instanceof RegExp&&(t=Es(t,r));var n=bs(e,t,r);return n&&{start:n[0],end:n[1],pre:r.slice(0,n[0]),body:r.slice(n[0]+e.length,n[1]),post:r.slice(n[1]+t.length)}}function Es(e,t){var r=t.match(e);return r?r[0]:null}ys.range=bs;function bs(e,t,r){var n,i,s,a,u,o=r.indexOf(e),l=r.indexOf(t,o+1),h=o;if(o>=0&&l>0){if(e===t)return[o,l];for(n=[],s=r.length;h>=0&&!u;)h==o?(n.push(h),o=r.indexOf(e,h+1)):n.length==1?u=[n.pop(),l]:(i=n.pop(),i<s&&(s=i,a=l),l=r.indexOf(t,h+1)),h=o<l&&o>=0?o:l;n.length&&(u=[s,a])}return u}});var xs=v((Sp,Ns)=>{var fh=ms(),Os=_s();Ns.exports=dh;var Ss="\0SLASH"+Math.random()+"\0",Is="\0OPEN"+Math.random()+"\0",ir="\0CLOSE"+Math.random()+"\0",As="\0COMMA"+Math.random()+"\0",Rs="\0PERIOD"+Math.random()+"\0";function nr(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function ph(e){return e.split("\\\\").join(Ss).split("\\{").join(Is).split("\\}").join(ir).split("\\,").join(As).split("\\.").join(Rs)}function vh(e){return e.split(Ss).join("\\").split(Is).join("{").split(ir).join("}").split(As).join(",").split(Rs).join(".")}function $s(e){if(!e)return[""];var t=[],r=Os("{","}",e);if(!r)return e.split(",");var n=r.pre,i=r.body,s=r.post,a=n.split(",");a[a.length-1]+="{"+i+"}";var u=$s(s);return s.length&&(a[a.length-1]+=u.shift(),a.push.apply(a,u)),t.push.apply(t,a),t}function dh(e){return e?(e.substr(0,2)==="{}"&&(e="\\{\\}"+e.substr(2)),we(ph(e),!0).map(vh)):[]}function gh(e){return"{"+e+"}"}function mh(e){return/^-?0\d/.test(e)}function Eh(e,t){return e<=t}function yh(e,t){return e>=t}function we(e,t){var r=[],n=Os("{","}",e);if(!n||/\$$/.test(n.pre))return[e];var i=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body),s=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body),a=i||s,u=n.body.indexOf(",")>=0;if(!a&&!u)return n.post.match(/,.*\}/)?(e=n.pre+"{"+n.body+ir+n.post,we(e)):[e];var o;if(a)o=n.body.split(/\.\./);else if(o=$s(n.body),o.length===1&&(o=we(o[0],!1).map(gh),o.length===1)){var h=n.post.length?we(n.post,!1):[""];return h.map(function(wt){return n.pre+o[0]+wt})}var l=n.pre,h=n.post.length?we(n.post,!1):[""],f;if(a){var p=nr(o[0]),c=nr(o[1]),m=Math.max(o[0].length,o[1].length),y=o.length==3?Math.abs(nr(o[2])):1,b=Eh,O=c<p;O&&(y*=-1,b=yh);var S=o.some(mh);f=[];for(var x=p;b(x,c);x+=y){var R;if(s)R=String.fromCharCode(x),R==="\\"&&(R="");else if(R=String(x),S){var k=m-R.length;if(k>0){var Xe=new Array(k+1).join("0");x<0?R="-"+Xe+R.slice(1):R=Xe+R}}f.push(R)}}else f=fh(o,function(Ue){return we(Ue,!1)});for(var he=0;he<f.length;he++)for(var K=0;K<h.length;K++){var M=l+f[he]+h[K];(!t||a||M)&&r.push(M)}return r}});var gt=v((Ip,Cs)=>{Cs.exports=P;P.Minimatch=N;var Ge=function(){try{return require("path")}catch{}}()||{sep:"/"};P.sep=Ge.sep;var or=P.GLOBSTAR=N.GLOBSTAR={},bh=xs(),Ls={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}},sr="[^/]",ar=sr+"*?",wh="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?",_h="(?:(?!(?:\\/|^)\\.).)*?",Ts=Oh("().*{}+?[]^$\\!");function Oh(e){return e.split("").reduce(function(t,r){return t[r]=!0,t},{})}var qs=/\/+/;P.filter=Sh;function Sh(e,t){return t=t||{},function(r,n,i){return P(r,e,t)}}function Y(e,t){t=t||{};var r={};return Object.keys(e).forEach(function(n){r[n]=e[n]}),Object.keys(t).forEach(function(n){r[n]=t[n]}),r}P.defaults=function(e){if(!e||typeof e!="object"||!Object.keys(e).length)return P;var t=P,r=function(i,s,a){return t(i,s,Y(e,a))};return r.Minimatch=function(i,s){return new t.Minimatch(i,Y(e,s))},r.Minimatch.defaults=function(i){return t.defaults(Y(e,i)).Minimatch},r.filter=function(i,s){return t.filter(i,Y(e,s))},r.defaults=function(i){return t.defaults(Y(e,i))},r.makeRe=function(i,s){return t.makeRe(i,Y(e,s))},r.braceExpand=function(i,s){return t.braceExpand(i,Y(e,s))},r.match=function(n,i,s){return t.match(n,i,Y(e,s))},r};N.defaults=function(e){return P.defaults(e).Minimatch};function P(e,t,r){return dt(t),r||(r={}),!r.nocomment&&t.charAt(0)==="#"?!1:new N(t,r).match(e)}function N(e,t){if(!(this instanceof N))return new N(e,t);dt(e),t||(t={}),e=e.trim(),!t.allowWindowsEscape&&Ge.sep!=="/"&&(e=e.split(Ge.sep).join("/")),this.options=t,this.set=[],this.pattern=e,this.regexp=null,this.negate=!1,this.comment=!1,this.empty=!1,this.partial=!!t.partial,this.make()}N.prototype.debug=function(){};N.prototype.make=Ih;function Ih(){var e=this.pattern,t=this.options;if(!t.nocomment&&e.charAt(0)==="#"){this.comment=!0;return}if(!e){this.empty=!0;return}this.parseNegate();var r=this.globSet=this.braceExpand();t.debug&&(this.debug=function(){console.error.apply(console,arguments)}),this.debug(this.pattern,r),r=this.globParts=r.map(function(n){return n.split(qs)}),this.debug(this.pattern,r),r=r.map(function(n,i,s){return n.map(this.parse,this)},this),this.debug(this.pattern,r),r=r.filter(function(n){return n.indexOf(!1)===-1}),this.debug(this.pattern,r),this.set=r}N.prototype.parseNegate=Ah;function Ah(){var e=this.pattern,t=!1,r=this.options,n=0;if(!r.nonegate){for(var i=0,s=e.length;i<s&&e.charAt(i)==="!";i++)t=!t,n++;n&&(this.pattern=e.substr(n)),this.negate=t}}P.braceExpand=function(e,t){return js(e,t)};N.prototype.braceExpand=js;function js(e,t){return t||(this instanceof N?t=this.options:t={}),e=typeof e>"u"?this.pattern:e,dt(e),t.nobrace||!/\{(?:(?!\{).)*\}/.test(e)?[e]:bh(e)}var Rh=1024*64,dt=function(e){if(typeof e!="string")throw new TypeError("invalid pattern");if(e.length>Rh)throw new TypeError("pattern is too long")};N.prototype.parse=$h;var vt={};function $h(e,t){dt(e);var r=this.options;if(e==="**")if(r.noglobstar)e="*";else return or;if(e==="")return"";var n="",i=!!r.nocase,s=!1,a=[],u=[],o,l=!1,h=-1,f=-1,p=e.charAt(0)==="."?"":r.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",c=this;function m(){if(o){switch(o){case"*":n+=ar,i=!0;break;case"?":n+=sr,i=!0;break;default:n+="\\"+o;break}c.debug("clearStateChar %j %j",o,n),o=!1}}for(var y=0,b=e.length,O;y<b&&(O=e.charAt(y));y++){if(this.debug("%s %s %s %j",e,y,n,O),s&&Ts[O]){n+="\\"+O,s=!1;continue}switch(O){case"/":return!1;case"\\":m(),s=!0;continue;case"?":case"*":case"+":case"@":case"!":if(this.debug("%s %s %s %j <-- stateChar",e,y,n,O),l){this.debug(" in class"),O==="!"&&y===f+1&&(O="^"),n+=O;continue}c.debug("call clearStateChar %j",o),m(),o=O,r.noext&&m();continue;case"(":if(l){n+="(";continue}if(!o){n+="\\(";continue}a.push({type:o,start:y-1,reStart:n.length,open:Ls[o].open,close:Ls[o].close}),n+=o==="!"?"(?:(?!(?:":"(?:",this.debug("plType %j %j",o,n),o=!1;continue;case")":if(l||!a.length){n+="\\)";continue}m(),i=!0;var S=a.pop();n+=S.close,S.type==="!"&&u.push(S),S.reEnd=n.length;continue;case"|":if(l||!a.length||s){n+="\\|",s=!1;continue}m(),n+="|";continue;case"[":if(m(),l){n+="\\"+O;continue}l=!0,f=y,h=n.length,n+=O;continue;case"]":if(y===f+1||!l){n+="\\"+O,s=!1;continue}var x=e.substring(f+1,y);try{RegExp("["+x+"]")}catch{var R=this.parse(x,vt);n=n.substr(0,h)+"\\["+R[0]+"\\]",i=i||R[1],l=!1;continue}i=!0,l=!1,n+=O;continue;default:m(),s?s=!1:Ts[O]&&!(O==="^"&&l)&&(n+="\\"),n+=O}}for(l&&(x=e.substr(f+1),R=this.parse(x,vt),n=n.substr(0,h)+"\\["+R[0],i=i||R[1]),S=a.pop();S;S=a.pop()){var k=n.slice(S.reStart+S.open.length);this.debug("setting tail",n,S),k=k.replace(/((?:\\{2}){0,64})(\\?)\|/g,function(Ar,Rr,St){return St||(St="\\"),Rr+Rr+St+"|"}),this.debug(`tail=%j
2
+ %s`,k,k,S,n);var Xe=S.type==="*"?ar:S.type==="?"?sr:"\\"+S.type;i=!0,n=n.slice(0,S.reStart)+Xe+"\\("+k}m(),s&&(n+="\\\\");var he=!1;switch(n.charAt(0)){case"[":case".":case"(":he=!0}for(var K=u.length-1;K>-1;K--){var M=u[K],Ue=n.slice(0,M.reStart),wt=n.slice(M.reStart,M.reEnd-8),Sr=n.slice(M.reEnd-8,M.reEnd),Oe=n.slice(M.reEnd);Sr+=Oe;var ca=Ue.split("(").length-1,_t=Oe;for(y=0;y<ca;y++)_t=_t.replace(/\)[+*?]?/,"");Oe=_t;var Ir="";Oe===""&&t!==vt&&(Ir="$");var ha=Ue+wt+Oe+Ir+Sr;n=ha}if(n!==""&&i&&(n="(?=.)"+n),he&&(n=p+n),t===vt)return[n,i];if(!i)return xh(e);var fa=r.nocase?"i":"";try{var Ot=new RegExp("^"+n+"$",fa)}catch{return new RegExp("$.")}return Ot._glob=e,Ot._src=n,Ot}P.makeRe=function(e,t){return new N(e,t||{}).makeRe()};N.prototype.makeRe=Nh;function Nh(){if(this.regexp||this.regexp===!1)return this.regexp;var e=this.set;if(!e.length)return this.regexp=!1,this.regexp;var t=this.options,r=t.noglobstar?ar:t.dot?wh:_h,n=t.nocase?"i":"",i=e.map(function(s){return s.map(function(a){return a===or?r:typeof a=="string"?Lh(a):a._src}).join("\\/")}).join("|");i="^(?:"+i+")$",this.negate&&(i="^(?!"+i+").*$");try{this.regexp=new RegExp(i,n)}catch{this.regexp=!1}return this.regexp}P.match=function(e,t,r){r=r||{};var n=new N(t,r);return e=e.filter(function(i){return n.match(i)}),n.options.nonull&&!e.length&&e.push(t),e};N.prototype.match=function(t,r){if(typeof r>"u"&&(r=this.partial),this.debug("match",t,this.pattern),this.comment)return!1;if(this.empty)return t==="";if(t==="/"&&r)return!0;var n=this.options;Ge.sep!=="/"&&(t=t.split(Ge.sep).join("/")),t=t.split(qs),this.debug(this.pattern,"split",t);var i=this.set;this.debug(this.pattern,"set",i);var s,a;for(a=t.length-1;a>=0&&(s=t[a],!s);a--);for(a=0;a<i.length;a++){var u=i[a],o=t;n.matchBase&&u.length===1&&(o=[s]);var l=this.matchOne(o,u,r);if(l)return n.flipNegate?!0:!this.negate}return n.flipNegate?!1:this.negate};N.prototype.matchOne=function(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 i=0,s=0,a=e.length,u=t.length;i<a&&s<u;i++,s++){this.debug("matchOne loop");var o=t[s],l=e[i];if(this.debug(t,o,l),o===!1)return!1;if(o===or){this.debug("GLOBSTAR",[t,o,l]);var h=i,f=s+1;if(f===u){for(this.debug("** at the end");i<a;i++)if(e[i]==="."||e[i]===".."||!n.dot&&e[i].charAt(0)===".")return!1;return!0}for(;h<a;){var p=e[h];if(this.debug(`
3
+ globstar while`,e,h,t,f,p),this.matchOne(e.slice(h),t.slice(f),r))return this.debug("globstar found match!",h,a,p),!0;if(p==="."||p===".."||!n.dot&&p.charAt(0)==="."){this.debug("dot detected!",e,h,t,f);break}this.debug("globstar swallow a segment, and continue"),h++}return!!(r&&(this.debug(`
4
+ >>> no match, partial?`,e,h,t,f),h===a))}var c;if(typeof o=="string"?(c=l===o,this.debug("string match",o,l,c)):(c=l.match(o),this.debug("pattern match",o,l,c)),!c)return!1}if(i===a&&s===u)return!0;if(i===a)return r;if(s===u)return i===a-1&&e[i]==="";throw new Error("wtf?")};function xh(e){return e.replace(/\\(.)/g,"$1")}function Lh(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}});var Ps=v((Ap,ur)=>{typeof Object.create=="function"?ur.exports=function(t,r){r&&(t.super_=r,t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:ur.exports=function(t,r){if(r){t.super_=r;var n=function(){};n.prototype=r.prototype,t.prototype=new n,t.prototype.constructor=t}}});var Ds=v((Rp,cr)=>{try{if(lr=require("util"),typeof lr.inherits!="function")throw"";cr.exports=lr.inherits}catch{cr.exports=Ps()}var lr});var Et=v(($p,mt)=>{"use strict";function Gs(e){return e.charAt(0)==="/"}function ks(e){var t=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/,r=t.exec(e),n=r[1]||"",i=Boolean(n&&n.charAt(1)!==":");return Boolean(r[2]||i)}mt.exports=process.platform==="win32"?ks:Gs;mt.exports.posix=Gs;mt.exports.win32=ks});var fr=v(Q=>{Q.setopts=Dh;Q.ownProp=Fs;Q.makeAbs=ke;Q.finish=Gh;Q.mark=kh;Q.isIgnored=Xs;Q.childrenIgnored=Fh;function Fs(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var Th=require("fs"),_e=require("path"),qh=gt(),Ms=Et(),hr=qh.Minimatch;function jh(e,t){return e.localeCompare(t,"en")}function Ch(e,t){e.ignore=t.ignore||[],Array.isArray(e.ignore)||(e.ignore=[e.ignore]),e.ignore.length&&(e.ignore=e.ignore.map(Ph))}function Ph(e){var t=null;if(e.slice(-3)==="/**"){var r=e.replace(/(\/\*\*)+$/,"");t=new hr(r,{dot:!0})}return{matcher:new hr(e,{dot:!0}),gmatcher:t}}function Dh(e,t,r){if(r||(r={}),r.matchBase&&t.indexOf("/")===-1){if(r.noglobstar)throw new Error("base matching requires globstar");t="**/"+t}e.silent=!!r.silent,e.pattern=t,e.strict=r.strict!==!1,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||Th,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),Ch(e,r),e.changedCwd=!1;var n=process.cwd();Fs(r,"cwd")?(e.cwd=_e.resolve(r.cwd),e.changedCwd=e.cwd!==n):e.cwd=n,e.root=r.root||_e.resolve(e.cwd,"/"),e.root=_e.resolve(e.root),process.platform==="win32"&&(e.root=e.root.replace(/\\/g,"/")),e.cwdAbs=Ms(e.cwd)?e.cwd:ke(e,e.cwd),process.platform==="win32"&&(e.cwdAbs=e.cwdAbs.replace(/\\/g,"/")),e.nomount=!!r.nomount,r.nonegate=!0,r.nocomment=!0,r.allowWindowsEscape=!1,e.minimatch=new hr(t,r),e.options=e.minimatch.options}function Gh(e){for(var t=e.nounique,r=t?[]:Object.create(null),n=0,i=e.matches.length;n<i;n++){var s=e.matches[n];if(!s||Object.keys(s).length===0){if(e.nonull){var a=e.minimatch.globSet[n];t?r.push(a):r[a]=!0}}else{var u=Object.keys(s);t?r.push.apply(r,u):u.forEach(function(o){r[o]=!0})}}if(t||(r=Object.keys(r)),e.nosort||(r=r.sort(jh)),e.mark){for(var n=0;n<r.length;n++)r[n]=e._mark(r[n]);e.nodir&&(r=r.filter(function(o){var l=!/\/$/.test(o),h=e.cache[o]||e.cache[ke(e,o)];return l&&h&&(l=h!=="DIR"&&!Array.isArray(h)),l}))}e.ignore.length&&(r=r.filter(function(o){return!Xs(e,o)})),e.found=r}function kh(e,t){var r=ke(e,t),n=e.cache[r],i=t;if(n){var s=n==="DIR"||Array.isArray(n),a=t.slice(-1)==="/";if(s&&!a?i+="/":!s&&a&&(i=i.slice(0,-1)),i!==t){var u=ke(e,i);e.statCache[u]=e.statCache[r],e.cache[u]=e.cache[r]}}return i}function ke(e,t){var r=t;return t.charAt(0)==="/"?r=_e.join(e.root,t):Ms(t)||t===""?r=t:e.changedCwd?r=_e.resolve(e.cwd,t):r=_e.resolve(t),process.platform==="win32"&&(r=r.replace(/\\/g,"/")),r}function Xs(e,t){return e.ignore.length?e.ignore.some(function(r){return r.matcher.match(t)||!!(r.gmatcher&&r.gmatcher.match(t))}):!1}function Fh(e,t){return e.ignore.length?e.ignore.some(function(r){return!!(r.gmatcher&&r.gmatcher.match(t))}):!1}});var zs=v((qp,Vs)=>{Vs.exports=Bs;Bs.GlobSync=A;var Mh=rr(),Us=gt(),xp=Us.Minimatch,Lp=dr().Glob,Tp=require("util"),pr=require("path"),Hs=require("assert"),yt=Et(),ue=fr(),Xh=ue.setopts,vr=ue.ownProp,Uh=ue.childrenIgnored,Hh=ue.isIgnored;function Bs(e,t){if(typeof t=="function"||arguments.length===3)throw new TypeError(`callback provided to sync glob
5
+ See: https://github.com/isaacs/node-glob/issues/167`);return new A(e,t).found}function A(e,t){if(!e)throw new Error("must provide pattern");if(typeof t=="function"||arguments.length===3)throw new TypeError(`callback provided to sync glob
6
+ See: https://github.com/isaacs/node-glob/issues/167`);if(!(this instanceof A))return new A(e,t);if(Xh(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()}A.prototype._finish=function(){if(Hs.ok(this instanceof A),this.realpath){var e=this;this.matches.forEach(function(t,r){var n=e.matches[r]=Object.create(null);for(var i in t)try{i=e._makeAbs(i);var s=Mh.realpathSync(i,e.realpathCache);n[s]=!0}catch(a){if(a.syscall==="stat")n[e._makeAbs(i)]=!0;else throw a}})}ue.finish(this)};A.prototype._process=function(e,t,r){Hs.ok(this instanceof A);for(var n=0;typeof e[n]=="string";)n++;var i;switch(n){case e.length:this._processSimple(e.join("/"),t);return;case 0:i=null;break;default:i=e.slice(0,n).join("/");break}var s=e.slice(n),a;i===null?a=".":((yt(i)||yt(e.map(function(l){return typeof l=="string"?l:"[*]"}).join("/")))&&(!i||!yt(i))&&(i="/"+i),a=i);var u=this._makeAbs(a);if(!Uh(this,a)){var o=s[0]===Us.GLOBSTAR;o?this._processGlobStar(i,a,u,s,t,r):this._processReaddir(i,a,u,s,t,r)}};A.prototype._processReaddir=function(e,t,r,n,i,s){var a=this._readdir(r,s);if(!!a){for(var u=n[0],o=!!this.minimatch.negate,l=u._glob,h=this.dot||l.charAt(0)===".",f=[],p=0;p<a.length;p++){var c=a[p];if(c.charAt(0)!=="."||h){var m;o&&!e?m=!c.match(u):m=c.match(u),m&&f.push(c)}}var y=f.length;if(y!==0){if(n.length===1&&!this.mark&&!this.stat){this.matches[i]||(this.matches[i]=Object.create(null));for(var p=0;p<y;p++){var c=f[p];e&&(e.slice(-1)!=="/"?c=e+"/"+c:c=e+c),c.charAt(0)==="/"&&!this.nomount&&(c=pr.join(this.root,c)),this._emitMatch(i,c)}return}n.shift();for(var p=0;p<y;p++){var c=f[p],b;e?b=[e,c]:b=[c],this._process(b.concat(n),i,s)}}}};A.prototype._emitMatch=function(e,t){if(!Hh(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(n==="DIR"||Array.isArray(n))return}this.matches[e][t]=!0,this.stat&&this._stat(t)}}};A.prototype._readdirInGlobStar=function(e){if(this.follow)return this._readdir(e,!1);var t,r,n;try{r=this.fs.lstatSync(e)}catch(s){if(s.code==="ENOENT")return null}var i=r&&r.isSymbolicLink();return this.symlinks[e]=i,!i&&r&&!r.isDirectory()?this.cache[e]="FILE":t=this._readdir(e,!1),t};A.prototype._readdir=function(e,t){var r;if(t&&!vr(this.symlinks,e))return this._readdirInGlobStar(e);if(vr(this.cache,e)){var n=this.cache[e];if(!n||n==="FILE")return null;if(Array.isArray(n))return n}try{return this._readdirEntries(e,this.fs.readdirSync(e))}catch(i){return this._readdirError(e,i),null}};A.prototype._readdirEntries=function(e,t){if(!this.mark&&!this.stat)for(var r=0;r<t.length;r++){var n=t[r];e==="/"?n=e+n:n=e+"/"+n,this.cache[n]=!0}return this.cache[e]=t,t};A.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);break}};A.prototype._processGlobStar=function(e,t,r,n,i,s){var a=this._readdir(r,s);if(!!a){var u=n.slice(1),o=e?[e]:[],l=o.concat(u);this._process(l,i,!1);var h=a.length,f=this.symlinks[r];if(!(f&&s))for(var p=0;p<h;p++){var c=a[p];if(!(c.charAt(0)==="."&&!this.dot)){var m=o.concat(a[p],u);this._process(m,i,!0);var y=o.concat(a[p],n);this._process(y,i,!0)}}}};A.prototype._processSimple=function(e,t){var r=this._stat(e);if(this.matches[t]||(this.matches[t]=Object.create(null)),!!r){if(e&&yt(e)&&!this.nomount){var n=/[\/\\]$/.test(e);e.charAt(0)==="/"?e=pr.join(this.root,e):(e=pr.resolve(this.root,e),n&&(e+="/"))}process.platform==="win32"&&(e=e.replace(/\\/g,"/")),this._emitMatch(t,e)}};A.prototype._stat=function(e){var t=this._makeAbs(e),r=e.slice(-1)==="/";if(e.length>this.maxLength)return!1;if(!this.stat&&vr(this.cache,t)){var a=this.cache[t];if(Array.isArray(a)&&(a="DIR"),!r||a==="DIR")return a;if(r&&a==="FILE")return!1}var n,i=this.statCache[t];if(!i){var s;try{s=this.fs.lstatSync(t)}catch(u){if(u&&(u.code==="ENOENT"||u.code==="ENOTDIR"))return this.statCache[t]=!1,!1}if(s&&s.isSymbolicLink())try{i=this.fs.statSync(t)}catch{i=s}else i=s}this.statCache[t]=i;var a=!0;return i&&(a=i.isDirectory()?"DIR":"FILE"),this.cache[t]=this.cache[t]||a,r&&a==="FILE"?!1:a};A.prototype._mark=function(e){return ue.mark(this,e)};A.prototype._makeAbs=function(e){return ue.makeAbs(this,e)}});var gr=v((jp,Ws)=>{Ws.exports=Zs;function Zs(e,t){if(e&&t)return Zs(e)(t);if(typeof e!="function")throw new TypeError("need wrapper function");return Object.keys(e).forEach(function(n){r[n]=e[n]}),r;function r(){for(var n=new Array(arguments.length),i=0;i<n.length;i++)n[i]=arguments[i];var s=e.apply(this,n),a=n[n.length-1];return typeof s=="function"&&s!==a&&Object.keys(a).forEach(function(u){s[u]=a[u]}),s}}});var Er=v((Cp,mr)=>{var Ys=gr();mr.exports=Ys(bt);mr.exports.strict=Ys(Qs);bt.proto=bt(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return bt(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return Qs(this)},configurable:!0})});function bt(e){var t=function(){return t.called?t.value:(t.called=!0,t.value=e.apply(this,arguments))};return t.called=!1,t}function Qs(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}});var Js=v((Pp,Ks)=>{var Bh=gr(),Fe=Object.create(null),Vh=Er();Ks.exports=Bh(zh);function zh(e,t){return Fe[e]?(Fe[e].push(t),null):(Fe[e]=[t],Zh(e))}function Zh(e){return Vh(function t(){var r=Fe[e],n=r.length,i=Wh(arguments);try{for(var s=0;s<n;s++)r[s].apply(null,i)}finally{r.length>n?(r.splice(0,n),process.nextTick(function(){t.apply(null,i)})):delete Fe[e]}})}function Wh(e){for(var t=e.length,r=[],n=0;n<t;n++)r[n]=e[n];return r}});var dr=v((kp,ta)=>{ta.exports=le;var Yh=rr(),ea=gt(),Dp=ea.Minimatch,Qh=Ds(),Kh=require("events").EventEmitter,yr=require("path"),br=require("assert"),Me=Et(),_r=zs(),ce=fr(),Jh=ce.setopts,wr=ce.ownProp,Or=Js(),Gp=require("util"),ef=ce.childrenIgnored,tf=ce.isIgnored,rf=Er();function le(e,t,r){if(typeof t=="function"&&(r=t,t={}),t||(t={}),t.sync){if(r)throw new TypeError("callback provided to sync glob");return _r(e,t)}return new _(e,t,r)}le.sync=_r;var nf=le.GlobSync=_r.GlobSync;le.glob=le;function sf(e,t){if(t===null||typeof t!="object")return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}le.hasMagic=function(e,t){var r=sf({},t);r.noprocess=!0;var n=new _(e,r),i=n.minimatch.set;if(!e)return!1;if(i.length>1)return!0;for(var s=0;s<i[0].length;s++)if(typeof i[0][s]!="string")return!0;return!1};le.Glob=_;Qh(_,Kh);function _(e,t,r){if(typeof t=="function"&&(r=t,t=null),t&&t.sync){if(r)throw new TypeError("callback provided to sync glob");return new nf(e,t)}if(!(this instanceof _))return new _(e,t,r);Jh(this,e,t),this._didRealPath=!1;var n=this.minimatch.set.length;this.matches=new Array(n),typeof r=="function"&&(r=rf(r),this.on("error",r),this.on("end",function(o){r(null,o)}));var i=this;if(this._processing=0,this._emitQueue=[],this._processQueue=[],this.paused=!1,this.noprocess)return this;if(n===0)return u();for(var s=!0,a=0;a<n;a++)this._process(this.minimatch.set[a],a,!1,u);s=!1;function u(){--i._processing,i._processing<=0&&(s?process.nextTick(function(){i._finish()}):i._finish())}}_.prototype._finish=function(){if(br(this instanceof _),!this.aborted){if(this.realpath&&!this._didRealpath)return this._realpath();ce.finish(this),this.emit("end",this.found)}};_.prototype._realpath=function(){if(this._didRealpath)return;this._didRealpath=!0;var e=this.matches.length;if(e===0)return this._finish();for(var t=this,r=0;r<this.matches.length;r++)this._realpathSet(r,n);function n(){--e===0&&t._finish()}};_.prototype._realpathSet=function(e,t){var r=this.matches[e];if(!r)return t();var n=Object.keys(r),i=this,s=n.length;if(s===0)return t();var a=this.matches[e]=Object.create(null);n.forEach(function(u,o){u=i._makeAbs(u),Yh.realpath(u,i.realpathCache,function(l,h){l?l.syscall==="stat"?a[u]=!0:i.emit("error",l):a[h]=!0,--s===0&&(i.matches[e]=a,t())})})};_.prototype._mark=function(e){return ce.mark(this,e)};_.prototype._makeAbs=function(e){return ce.makeAbs(this,e)};_.prototype.abort=function(){this.aborted=!0,this.emit("abort")};_.prototype.pause=function(){this.paused||(this.paused=!0,this.emit("pause"))};_.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);this._processQueue.length=0;for(var t=0;t<n.length;t++){var i=n[t];this._processing--,this._process(i[0],i[1],i[2],i[3])}}}};_.prototype._process=function(e,t,r,n){if(br(this instanceof _),br(typeof n=="function"),!this.aborted){if(this._processing++,this.paused){this._processQueue.push([e,t,r,n]);return}for(var i=0;typeof e[i]=="string";)i++;var s;switch(i){case e.length:this._processSimple(e.join("/"),t,n);return;case 0:s=null;break;default:s=e.slice(0,i).join("/");break}var a=e.slice(i),u;s===null?u=".":((Me(s)||Me(e.map(function(h){return typeof h=="string"?h:"[*]"}).join("/")))&&(!s||!Me(s))&&(s="/"+s),u=s);var o=this._makeAbs(u);if(ef(this,u))return n();var l=a[0]===ea.GLOBSTAR;l?this._processGlobStar(s,u,o,a,t,r,n):this._processReaddir(s,u,o,a,t,r,n)}};_.prototype._processReaddir=function(e,t,r,n,i,s,a){var u=this;this._readdir(r,s,function(o,l){return u._processReaddir2(e,t,r,n,i,s,l,a)})};_.prototype._processReaddir2=function(e,t,r,n,i,s,a,u){if(!a)return u();for(var o=n[0],l=!!this.minimatch.negate,h=o._glob,f=this.dot||h.charAt(0)===".",p=[],c=0;c<a.length;c++){var m=a[c];if(m.charAt(0)!=="."||f){var y;l&&!e?y=!m.match(o):y=m.match(o),y&&p.push(m)}}var b=p.length;if(b===0)return u();if(n.length===1&&!this.mark&&!this.stat){this.matches[i]||(this.matches[i]=Object.create(null));for(var c=0;c<b;c++){var m=p[c];e&&(e!=="/"?m=e+"/"+m:m=e+m),m.charAt(0)==="/"&&!this.nomount&&(m=yr.join(this.root,m)),this._emitMatch(i,m)}return u()}n.shift();for(var c=0;c<b;c++){var m=p[c],O;e&&(e!=="/"?m=e+"/"+m:m=e+m),this._process([m].concat(n),i,s,u)}u()};_.prototype._emitMatch=function(e,t){if(!this.aborted&&!tf(this,t)){if(this.paused){this._emitQueue.push([e,t]);return}var r=Me(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(n==="DIR"||Array.isArray(n))return}this.matches[e][t]=!0;var i=this.statCache[r];i&&this.emit("stat",t,i),this.emit("match",t)}}};_.prototype._readdirInGlobStar=function(e,t){if(this.aborted)return;if(this.follow)return this._readdir(e,!1,t);var r="lstat\0"+e,n=this,i=Or(r,s);i&&n.fs.lstat(e,i);function s(a,u){if(a&&a.code==="ENOENT")return t();var o=u&&u.isSymbolicLink();n.symlinks[e]=o,!o&&u&&!u.isDirectory()?(n.cache[e]="FILE",t()):n._readdir(e,!1,t)}};_.prototype._readdir=function(e,t,r){if(!this.aborted&&(r=Or("readdir\0"+e+"\0"+t,r),!!r)){if(t&&!wr(this.symlinks,e))return this._readdirInGlobStar(e,r);if(wr(this.cache,e)){var n=this.cache[e];if(!n||n==="FILE")return r();if(Array.isArray(n))return r(null,n)}var i=this;i.fs.readdir(e,af(this,e,r))}};function af(e,t,r){return function(n,i){n?e._readdirError(t,n,r):e._readdirEntries(t,i,r)}}_.prototype._readdirEntries=function(e,t,r){if(!this.aborted){if(!this.mark&&!this.stat)for(var n=0;n<t.length;n++){var i=t[n];e==="/"?i=e+i:i=e+"/"+i,this.cache[i]=!0}return this.cache[e]=t,r(null,t)}};_.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 i=new Error(t.code+" invalid cwd "+this.cwd);i.path=this.cwd,i.code=t.code,this.emit("error",i),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);break}return r()}};_.prototype._processGlobStar=function(e,t,r,n,i,s,a){var u=this;this._readdir(r,s,function(o,l){u._processGlobStar2(e,t,r,n,i,s,l,a)})};_.prototype._processGlobStar2=function(e,t,r,n,i,s,a,u){if(!a)return u();var o=n.slice(1),l=e?[e]:[],h=l.concat(o);this._process(h,i,!1,u);var f=this.symlinks[r],p=a.length;if(f&&s)return u();for(var c=0;c<p;c++){var m=a[c];if(!(m.charAt(0)==="."&&!this.dot)){var y=l.concat(a[c],o);this._process(y,i,!0,u);var b=l.concat(a[c],n);this._process(b,i,!0,u)}}u()};_.prototype._processSimple=function(e,t,r){var n=this;this._stat(e,function(i,s){n._processSimple2(e,t,i,s,r)})};_.prototype._processSimple2=function(e,t,r,n,i){if(this.matches[t]||(this.matches[t]=Object.create(null)),!n)return i();if(e&&Me(e)&&!this.nomount){var s=/[\/\\]$/.test(e);e.charAt(0)==="/"?e=yr.join(this.root,e):(e=yr.resolve(this.root,e),s&&(e+="/"))}process.platform==="win32"&&(e=e.replace(/\\/g,"/")),this._emitMatch(t,e),i()};_.prototype._stat=function(e,t){var r=this._makeAbs(e),n=e.slice(-1)==="/";if(e.length>this.maxLength)return t();if(!this.stat&&wr(this.cache,r)){var i=this.cache[r];if(Array.isArray(i)&&(i="DIR"),!n||i==="DIR")return t(null,i);if(n&&i==="FILE")return t()}var s,a=this.statCache[r];if(a!==void 0){if(a===!1)return t(null,a);var u=a.isDirectory()?"DIR":"FILE";return n&&u==="FILE"?t():t(null,u,a)}var o=this,l=Or("stat\0"+r,h);l&&o.fs.lstat(r,l);function h(f,p){if(p&&p.isSymbolicLink())return o.fs.stat(r,function(c,m){c?o._stat2(e,r,null,p,t):o._stat2(e,r,c,m,t)});o._stat2(e,r,f,p,t)}};_.prototype._stat2=function(e,t,r,n,i){if(r&&(r.code==="ENOENT"||r.code==="ENOTDIR"))return this.statCache[t]=!1,i();var s=e.slice(-1)==="/";if(this.statCache[t]=n,t.slice(-1)==="/"&&n&&!n.isDirectory())return i(null,!1,n);var a=!0;return n&&(a=n.isDirectory()?"DIR":"FILE"),this.cache[t]=this.cache[t]||a,s&&a==="FILE"?i():i(null,a,n)}});var ia=v((Fp,na)=>{"use strict";var ra=qi(),of=require("fs"),uf=require("path"),lf=Bi(),cf=Qi(),hf=cs(),ff=dr(),pf=function(e,t){var r=[];return cf(e).forEach(function(n){var i=n.indexOf("!")===0;i&&(n=n.slice(1));var s=t(n);i?r=lf(r,s):r=hf(r,s)}),r};na.exports=function(){var e=ra.toArray(arguments),t=ra.kindOf(e[0])==="object"?e.shift():{},r=Array.isArray(e[0])?e[0]:e;if(r.length===0)return[];var n=pf(r,function(i){return ff.sync(i,t)});return t.filter&&(n=n.filter(function(i){i=uf.join(t.cwd||"",i);try{return typeof t.filter=="function"?t.filter(i):of.statSync(i)[t.filter]()}catch{return!1}})),n}});var mf={};Ea(mf,{Options:()=>Nr,Platform:()=>X,Platforms:()=>$i,checkCache:()=>xi,checkPkgOptions:()=>oa,detectCurrentPlatform:()=>ua,parseOptions:()=>la});module.exports=ya(mf);var ba={mode:"run",quiet:"info",files:null,version:"latest",flavor:"sdk",cacheDir:"./cache",platforms:[],currentPlatform:null,downloadUrl:"https://dl.nwjs.io/",manifestUrl:"https://nwjs.io/versions.json",appName:!1,appVersion:!1,buildDir:"./build",buildType:"default",forceDownload:!1,macCredits:!1,macIcns:!1,macZip:null,macPlist:!1,winVersionString:{},winIco:null,useRcedit:!1,argv:[],zip:null,zipOptions:null,mergeZip:!0},Nr=ba;var xr={NIX_32:"linux32",NIX_64:"linux64",OSX_32:"osx32",OSX_64:"osx64",WIN_32:"win32",WIN_64:"win64"};Object.freeze(xr);var X=xr;var kt=Se(Ri(),1),$u={win32:{needsZip:!0,getRunnable:function(){return"nw.exe"},files:{"<=0.9.2":["nw.exe","ffmpegsumo.dll","icudt.dll","libEGL.dll","libGLESv2.dll","nw.pak"],">0.9.2 <0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales"],">=0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales","d3dcompiler_47.dll","pdf.dll"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-win-ia32.zip"},win64:{needsZip:!0,getRunnable:function(){return"nw.exe"},files:{"<=0.9.2":["nw.exe","ffmpegsumo.dll","icudt.dll","libEGL.dll","libGLESv2.dll","nw.pak","locales"],">0.9.2 <0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales"],">=0.12.0":["nw.exe","ffmpegsumo.dll","icudtl.dat","libEGL.dll","libGLESv2.dll","nw.pak","locales","d3dcompiler_47.dll","pdf.dll"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-win-x64.zip"},osx32:{needsZip:!1,getRunnable:function(e){return kt.default.satisfies(e,">=0.12.0 || ~0.12.0-alpha")?"nwjs.app/Contents/MacOS/nwjs":"node-webkit.app/Contents/MacOS/node-webkit"},files:{"<0.12.0-alpha":["node-webkit.app"],">=0.12.0 || ~0.12.0-alpha":["nwjs.app"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-osx-ia32.zip"},osx64:{needsZip:!1,getRunnable:function(e){return kt.default.satisfies(e,">=0.12.0 || ~0.12.0-alpha")?"nwjs.app/Contents/MacOS/nwjs":"node-webkit.app/Contents/MacOS/node-webkit"},files:{"<0.12.0-alpha":["node-webkit.app"],">=0.12.0 || ~0.12.0-alpha":["nwjs.app"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-osx-x64.zip"},linux32:{needsZip:!0,chmod:"0755",getRunnable:function(){return"nw"},files:{"<=0.9.2":["nw","nw.pak","libffmpegsumo.so"],">0.9.2 <=0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat"],">0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat","locales"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-linux-ia32.tar.gz"},linux64:{needsZip:!0,chmod:"0755",getRunnable:function(){return"nw"},files:{"<=0.9.2":["nw","nw.pak","libffmpegsumo.so"],">0.9.2 <=0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat"],">0.10.1":["nw","nw.pak","libffmpegsumo.so","icudtl.dat","locales"]},versionNameTemplate:"v${ version }/${ name }-v${ version }-linux-x64.tar.gz"}},$i=$u;var it=Se(require("fs"),1),Ni=Se(require("path"),1),Nu=(e,t)=>{let r=!1;if(t.length===1&&t[0]==="*")return it.default.existsSync(e)&&it.default.readdirSync(e).length>=2;for(let n of t){if(r)return!1;it.default.existsSync(Ni.default.join(e,n))||(r=!0)}return!r},xi=Nu;var sa=Se(require("fs"),1),aa=Se(ia(),1),vf=e=>{let t={};if(typeof e=="string"||Array.isArray(e)){let r=(0,aa.default)(e);r.length===0&&(console.error("[ ERROR ] package.json not found"),process.exit(1)),r.forEach(n=>{n.match(/package.json$/)&&(t=sa.default.readFileSync(`${n}`,"utf8"),t=JSON.parse(t))})}return t.nwbuild?t.nwbuild:{}},oa=vf;var df=e=>{switch(e.platform){case"darwin":return e.arch==="x64"?X.OSX_64:X.OSX_32;case"win32":return e.arch==="x64"||e.env.PROCESSOR_ARCHITEW6432?X.WIN_64:X.WIN_32;case"linux":return e.arch==="x64"?X.NIX_64:X.NIX_32;default:return}},ua=df;var gf=(e,t)=>{for(let r of Object.keys(e))t.hasOwnProperty(r)&&(t[r]=e[r]);return t},la=gf;0&&(module.exports={Options,Platform,Platforms,checkCache,checkPkgOptions,detectCurrentPlatform,parseOptions});
package/lib/index.cjs CHANGED
@@ -11,9 +11,15 @@ var spawn = require("child_process").spawn;
11
11
  var semver = require("semver");
12
12
  var platformOverrides = require("./platformOverrides.cjs");
13
13
  var deprecate = require("deprecate");
14
- var updateNotifier = require("update-notifier");
15
- const { checkCache, detectCurrentPlatform, Platforms } = require("../dist/index.cjs");
16
14
 
15
+ const {
16
+ checkCache,
17
+ detectCurrentPlatform,
18
+ Platforms,
19
+ checkPkgOptions,
20
+ Options,
21
+ parseOptions,
22
+ } = require("../dist/index.cjs");
17
23
  var NwVersions = require("./versions.cjs");
18
24
  var Version = require("./Version.cjs");
19
25
  var Utils = require("./utils.cjs");
@@ -22,89 +28,90 @@ var Downloader = require("./downloader.cjs");
22
28
 
23
29
  var pkg = require("../package.json");
24
30
 
25
- updateNotifier({ pkg }).notify();
31
+ (async () => {
32
+ let updateNotifier = undefined;
33
+ try {
34
+ updateNotifier = await import("update-notifier");
35
+ updateNotifier({ pkg }).notify();
36
+ } catch (e) {
37
+ console.error(e);
38
+ }
39
+ })();
26
40
 
27
41
  // We inherit from EventEmitter for logging
28
42
  inherits(NwBuilder, EventEmitter);
29
- module.exports = NwBuilder;
43
+
30
44
  function NwBuilder(options) {
31
- var defaults = {
32
- files: null,
33
- appName: false,
34
- appVersion: false,
35
- platforms: [detectCurrentPlatform(process)],
36
- currentPlatform: detectCurrentPlatform(process),
37
- version: "latest",
38
- buildDir: "./build",
39
- cacheDir: "./cache",
40
- downloadUrl: "https://dl.nwjs.io/",
41
- manifestUrl: "https://nwjs.io/versions.json",
42
- flavor: "sdk",
43
- buildType: "default",
44
- forceDownload: false,
45
- macCredits: false,
46
- macIcns: false,
47
- macZip: null,
48
- zip: null,
49
- zipOptions: null,
50
- macPlist: false,
51
- mergeZip: true,
52
- winVersionString: {},
53
- winIco: null,
54
- useRcedit: false,
55
- argv: [],
56
- };
45
+ const pkgOptions = checkPkgOptions(options.files);
46
+ // Options are defined in package.json take precedence
47
+ if (Object.entries(pkgOptions).length !== 0) {
48
+ this.options = parseOptions(pkgOptions, Options);
49
+ this.options.files = options.files;
50
+ } else {
51
+ this.options = parseOptions(options, Options);
52
+ }
53
+
54
+ if (this.options.currentPlatform === null) {
55
+ this.options.currentPlatform = detectCurrentPlatform(process);
56
+ }
57
+
58
+ if (this.options.platforms && this.options.platforms.length === 0) {
59
+ this.options.platforms = [detectCurrentPlatform(process)];
60
+ }
61
+
57
62
  // Intercept the platforms and check for the legacy platforms of 'osx' and 'win' and
58
63
  // replace with 'osx32', 'osx64', and 'win32', 'win64' respectively.
59
- if (typeof options.platforms != "undefined") {
60
- if (options.platforms.indexOf("osx") >= 0) {
61
- options.platforms.splice(
62
- options.platforms.indexOf("osx"),
64
+ if (typeof this.options.platforms != "undefined") {
65
+ if (this.options.platforms && this.options.platforms.indexOf("osx") >= 0) {
66
+ this.options.platforms.splice(
67
+ this.options.platforms.indexOf("osx"),
63
68
  1,
64
69
  "osx32",
65
70
  "osx64",
66
71
  );
67
72
  }
68
- if (options.platforms.indexOf("win") >= 0) {
69
- options.platforms.splice(
70
- options.platforms.indexOf("win"),
73
+ if (this.options.platforms && this.options.platforms.indexOf("win") >= 0) {
74
+ this.options.platforms.splice(
75
+ this.options.platforms.indexOf("win"),
71
76
  1,
72
77
  "win32",
73
78
  "win64",
74
79
  );
75
80
  }
76
- if (options.platforms.indexOf("linux") >= 0) {
77
- options.platforms.splice(
78
- options.platforms.indexOf("linux"),
81
+ if (
82
+ this.options.platforms &&
83
+ this.options.platforms.indexOf("linux") >= 0
84
+ ) {
85
+ this.options.platforms.splice(
86
+ this.options.platforms.indexOf("linux"),
79
87
  1,
80
88
  "linux32",
81
89
  "linux64",
82
90
  );
83
91
  }
84
92
  }
85
- // Assign options
86
- this.options = _.defaults(options, defaults);
87
93
 
88
94
  // Some Option checking
89
95
  if (!this.options.files) {
90
96
  throw new Error("Please specify some files");
91
97
  }
92
98
 
93
- if (this.options.platforms.length === 0)
99
+ if (this.options.platforms && this.options.platforms.length === 0)
94
100
  throw new Error("No platform to build!");
95
101
 
96
102
  // verify all the platforms specifed by the user are supported
97
103
  // this + previous check assures as we have only buildable platforms specified
98
- this.options.platforms.forEach(function (platform) {
99
- if (!(platform in Platforms))
100
- throw new Error("Unknown platform " + platform);
101
- });
104
+ this.options.platforms &&
105
+ this.options.platforms.forEach(function (platform) {
106
+ if (!(platform in Platforms))
107
+ throw new Error("Unknown platform " + platform);
108
+ });
102
109
 
103
110
  this._platforms = _.cloneDeep(Platforms);
104
111
 
105
112
  // clear all unused platforms
106
113
  for (var name in this._platforms) {
107
- if (this.options.platforms.indexOf(name) === -1)
114
+ if (this.options.platforms && this.options.platforms.indexOf(name) === -1)
108
115
  delete this._platforms[name];
109
116
  }
110
117
  }
@@ -1076,3 +1083,29 @@ NwBuilder.prototype.preparePlatformFiles = function (
1076
1083
  // will check properly where necessary
1077
1084
  return true;
1078
1085
  };
1086
+
1087
+ const nwbuild = (options, callback = [() => {}, () => {}, () => {}]) => {
1088
+ const nw = new NwBuilder(options);
1089
+
1090
+ nw.on("log", (msg) => {
1091
+ console.log(`[ INFO ] ${msg}`);
1092
+ });
1093
+
1094
+ if (nw.options.mode === "run") {
1095
+ nw.run()
1096
+ .then(callback[0])
1097
+ .catch(callback[1])
1098
+ .finally(callback[2]);
1099
+ } else if (nw.options.mode === "build") {
1100
+ nw.build()
1101
+ .then(callback[0])
1102
+ .catch(callback[1])
1103
+ .finally(callback[2]);
1104
+ } else {
1105
+ console.log("[ WARN ] Invalid mode option.");
1106
+ }
1107
+ };
1108
+
1109
+ module.exports = NwBuilder;
1110
+ exports = module.exports;
1111
+ exports.nwbuild = nwbuild;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nw-builder",
3
- "version": "3.7.4",
3
+ "version": "3.8.0",
4
4
  "description": "Build NW.js desktop applications for Mac, Windows and Linux.",
5
5
  "keywords": [
6
6
  "NW.js",
@@ -18,49 +18,49 @@
18
18
  },
19
19
  "scripts": {
20
20
  "format": "prettier --write ./bin ./lib ./src ./test",
21
- "lint": "eslint ./bin/**.cjs ./lib/**.cjs ./src/**.js ./test/**.cjs ",
22
- "test": "pnpm test:unit && tape './test/*.cjs'",
21
+ "lint": "eslint ./bin/**.cjs ./lib/**.cjs ./src/**.js",
22
+ "test": "npm run test:unit && tape './test/*.cjs'",
23
23
  "test:unit": "node --experimental-vm-modules node_modules/jest/bin/jest.js",
24
- "demo": "cd ./test/demo && pnpm start",
24
+ "demo": "cd ./test/demo && npm start",
25
25
  "build": "esbuild src/index.js --bundle --minify --platform=node --outfile=./dist/index.cjs"
26
26
  },
27
27
  "devDependencies": {
28
- "decompress-zip": "0.3.3",
29
- "eol": "0.9.1",
30
- "esbuild": "0.14.42",
31
- "eslint": "8.16.0",
32
- "eslint-plugin-jsdoc": "^39.3.2",
33
- "jest": "28.1.0",
34
- "jest-environment-jsdom": "28.1.0",
35
- "jsdom": "19.0.0",
36
- "nock": "13.2.4",
37
- "pnpm": "7.1.7",
38
- "prettier": "2.6.2",
39
- "redtape": "1.0.0",
40
- "tape": "5.5.3"
28
+ "decompress-zip": "^0.3.3",
29
+ "eol": "^0.9.1",
30
+ "esbuild": "^0.14.47",
31
+ "eslint": "^8.18.0",
32
+ "eslint-config-tjw-jsdoc": "^1.0.3",
33
+ "eslint-plugin-jsdoc": "^39.3.3",
34
+ "jest": "^28.1.1",
35
+ "jest-environment-jsdom": "^28.1.1",
36
+ "jsdom": "^20.0.0",
37
+ "nock": "^13.2.7",
38
+ "prettier": "^2.7.1",
39
+ "redtape": "^1.0.0",
40
+ "tape": "^5.5.3"
41
41
  },
42
42
  "dependencies": {
43
- "archiver": "5.3.1",
44
- "deprecate": "1.1.1",
45
- "extract-zip": "2.0.1",
46
- "graceful-fs-extra": "2.0.0",
47
- "graceful-ncp": "3.0.0",
48
- "inherits": "2.0.4",
49
- "lodash": "4.17.21",
50
- "plist": "3.0.5",
51
- "progress": "2.0.3",
52
- "rcedit": "3.0.1",
53
- "recursive-readdir-sync": "1.0.6",
54
- "request": "2.88.2",
55
- "rimraf": "3.0.2",
56
- "semver": "7.3.7",
57
- "simple-glob": "0.2.0",
58
- "tar-fs": "2.1.1",
59
- "temp": "github:adam-lynch/node-temp#remove_tmpdir_dep",
60
- "thenify": "3.3.1",
61
- "update-notifier": "5.1.0",
62
- "winresourcer": "0.9.0",
63
- "yargs": "17.5.1"
43
+ "archiver": "^5.3.1",
44
+ "deprecate": "^1.1.1",
45
+ "extract-zip": "^2.0.1",
46
+ "graceful-fs-extra": "^2.0.0",
47
+ "graceful-ncp": "^3.0.0",
48
+ "inherits": "^2.0.4",
49
+ "lodash": "^4.17.21",
50
+ "plist": "^3.0.5",
51
+ "progress": "^2.0.3",
52
+ "rcedit": "^3.0.1",
53
+ "recursive-readdir-sync": "^1.0.6",
54
+ "request": "^2.88.2",
55
+ "rimraf": "^3.0.2",
56
+ "semver": "^7.3.7",
57
+ "simple-glob": "^0.2.0",
58
+ "tar-fs": "^2.1.1",
59
+ "temp": "^0.9.4",
60
+ "thenify": "^3.3.1",
61
+ "update-notifier": "^6.0.2",
62
+ "winresourcer": "^0.9.0",
63
+ "yargs": "^17.5.1"
64
64
  },
65
65
  "bin": {
66
66
  "nwbuild": "./bin/nwbuild.cjs"
@@ -82,7 +82,6 @@
82
82
  "singleAttributePerLine": true
83
83
  },
84
84
  "eslintConfig": {
85
- "extends": "eslint:recommended",
86
85
  "parserOptions": {
87
86
  "ecmaVersion": 2021,
88
87
  "sourceType": "module"
@@ -91,6 +90,10 @@
91
90
  "es6": true,
92
91
  "node": true
93
92
  },
93
+ "extends": [
94
+ "eslint:recommended",
95
+ "tjw-jsdoc"
96
+ ],
94
97
  "overrides": [
95
98
  {
96
99
  "files": "./src/**/*.js"