@qlover/scripts-context 0.0.8 → 0.0.14
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 +1 -0
- package/dist/{cjs/index.d.ts → index.d.ts} +1 -1
- package/dist/index.js +1 -0
- package/package.json +20 -18
- package/dist/cjs/index.js +0 -1
- package/dist/es/index.d.ts +0 -545
- package/dist/es/index.js +0 -1
package/dist/index.cjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var r,t,n,e,o,u,i,c,a,f,s,l,p,v,h,g,d,y,_,b,j,m,w,O,x,P,R,$,A,S,C,z,F,E,k,T,N,U,q,B,I,M,L,D,G,V,W,J,H,K,Q,X,Y,Z,rr,tr,nr,er,or,ur,ir,cr,ar,fr,sr,lr,pr,vr,hr,gr,dr,yr,_r,br,jr,mr,wr,Or,xr,Pr,Rr,$r,Ar,Sr,Cr,zr,Fr,Er,kr,Tr,Nr,Ur,qr,Br,Ir,Mr,Lr,Dr,Gr,Vr,Wr,Jr,Hr,Kr,Qr,Xr,Yr,Zr,rt,tt,nt,et,ot,ut,it=require("cosmiconfig"),ct=require("@qlover/fe-corekit"),at=require("chalk"),ft=require("child_process"),st="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function lt(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function pt(){if(t)return r;return t=1,r=function(r,t,n){switch(n.length){case 0:return r.call(t);case 1:return r.call(t,n[0]);case 2:return r.call(t,n[0],n[1]);case 3:return r.call(t,n[0],n[1],n[2])}return r.apply(t,n)}}function vt(){if(e)return n;return e=1,n=function(r){return r}}function ht(){if(u)return o;u=1;var r=pt(),t=Math.max;return o=function(n,e,o){return e=t(void 0===e?n.length-1:e,0),function(){for(var u=arguments,i=-1,c=t(u.length-e,0),a=Array(c);++i<c;)a[i]=u[e+i];i=-1;for(var f=Array(e+1);++i<e;)f[i]=u[i];return f[e]=o(a),r(n,this,f)}},o}function gt(){if(c)return i;return c=1,i=function(r){return function(){return r}}}function dt(){if(f)return a;f=1;var r="object"==typeof st&&st&&st.Object===Object&&st;return a=r}function yt(){if(l)return s;l=1;var r=dt(),t="object"==typeof self&&self&&self.Object===Object&&self,n=r||t||Function("return this")();return s=n}function _t(){if(v)return p;v=1;var r=yt().Symbol;return p=r}function bt(){if(g)return h;g=1;var r=_t(),t=Object.prototype,n=t.hasOwnProperty,e=t.toString,o=r?r.toStringTag:void 0;return h=function(r){var t=n.call(r,o),u=r[o];try{r[o]=void 0;var i=!0}catch(r){}var c=e.call(r);return i&&(t?r[o]=u:delete r[o]),c}}function jt(){if(y)return d;y=1;var r=Object.prototype.toString;return d=function(t){return r.call(t)}}function mt(){if(b)return _;b=1;var r=_t(),t=bt(),n=jt(),e=r?r.toStringTag:void 0;return _=function(r){return null==r?void 0===r?"[object Undefined]":"[object Null]":e&&e in Object(r)?t(r):n(r)}}function wt(){if(m)return j;return m=1,j=function(r){var t=typeof r;return null!=r&&("object"==t||"function"==t)}}function Ot(){if(O)return w;O=1;var r=mt(),t=wt();return w=function(n){if(!t(n))return!1;var e=r(n);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}}function xt(){if(P)return x;P=1;var r=yt()["__core-js_shared__"];return x=r}function Pt(){if($)return R;$=1;var r,t=xt(),n=(r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";return R=function(r){return!!n&&n in r}}function Rt(){if(S)return A;S=1;var r=Function.prototype.toString;return A=function(t){if(null!=t){try{return r.call(t)}catch(r){}try{return t+""}catch(r){}}return""}}function $t(){if(z)return C;z=1;var r=Ot(),t=Pt(),n=wt(),e=Rt(),o=/^\[object .+?Constructor\]$/,u=Function.prototype,i=Object.prototype,c=u.toString,a=i.hasOwnProperty,f=RegExp("^"+c.call(a).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");return C=function(u){return!(!n(u)||t(u))&&(r(u)?f:o).test(e(u))}}function At(){if(E)return F;return E=1,F=function(r,t){return null==r?void 0:r[t]}}function St(){if(T)return k;T=1;var r=$t(),t=At();return k=function(n,e){var o=t(n,e);return r(o)?o:void 0}}function Ct(){if(U)return N;U=1;var r=St(),t=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(r){}}();return N=t}function zt(){if(B)return q;B=1;var r=gt(),t=Ct();return q=t?function(n,e){return t(n,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:vt()}function Ft(){if(M)return I;M=1;var r=Date.now;return I=function(t){var n=0,e=0;return function(){var o=r(),u=16-(o-e);if(e=o,u>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},I}function Et(){if(D)return L;D=1;var r=zt(),t=Ft()(r);return L=t}function kt(){if(V)return G;V=1;var r=vt(),t=ht(),n=Et();return G=function(e,o){return n(t(e,o,r),e+"")}}function Tt(){if(J)return W;return J=1,W=function(){this.__data__=[],this.size=0}}function Nt(){if(K)return H;return K=1,H=function(r,t){return r===t||r!=r&&t!=t}}function Ut(){if(X)return Q;X=1;var r=Nt();return Q=function(t,n){for(var e=t.length;e--;)if(r(t[e][0],n))return e;return-1}}function qt(){if(Z)return Y;Z=1;var r=Ut(),t=Array.prototype.splice;return Y=function(n){var e=this.__data__,o=r(e,n);return!(o<0)&&(o==e.length-1?e.pop():t.call(e,o,1),--this.size,!0)}}function Bt(){if(tr)return rr;tr=1;var r=Ut();return rr=function(t){var n=this.__data__,e=r(n,t);return e<0?void 0:n[e][1]}}function It(){if(er)return nr;er=1;var r=Ut();return nr=function(t){return r(this.__data__,t)>-1}}function Mt(){if(ur)return or;ur=1;var r=Ut();return or=function(t,n){var e=this.__data__,o=r(e,t);return o<0?(++this.size,e.push([t,n])):e[o][1]=n,this}}function Lt(){if(cr)return ir;cr=1;var r=Tt(),t=qt(),n=Bt(),e=It(),o=Mt();function u(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return u.prototype.clear=r,u.prototype.delete=t,u.prototype.get=n,u.prototype.has=e,u.prototype.set=o,ir=u}function Dt(){if(fr)return ar;fr=1;var r=Lt();return ar=function(){this.__data__=new r,this.size=0}}function Gt(){if(lr)return sr;return lr=1,sr=function(r){var t=this.__data__,n=t.delete(r);return this.size=t.size,n}}function Vt(){if(vr)return pr;return vr=1,pr=function(r){return this.__data__.get(r)}}function Wt(){if(gr)return hr;return gr=1,hr=function(r){return this.__data__.has(r)}}function Jt(){if(yr)return dr;yr=1;var r=St()(yt(),"Map");return dr=r}function Ht(){if(br)return _r;br=1;var r=St()(Object,"create");return _r=r}function Kt(){if(mr)return jr;mr=1;var r=Ht();return jr=function(){this.__data__=r?r(null):{},this.size=0}}function Qt(){if(Or)return wr;return Or=1,wr=function(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}}function Xt(){if(Pr)return xr;Pr=1;var r=Ht(),t=Object.prototype.hasOwnProperty;return xr=function(n){var e=this.__data__;if(r){var o=e[n];return"__lodash_hash_undefined__"===o?void 0:o}return t.call(e,n)?e[n]:void 0}}function Yt(){if($r)return Rr;$r=1;var r=Ht(),t=Object.prototype.hasOwnProperty;return Rr=function(n){var e=this.__data__;return r?void 0!==e[n]:t.call(e,n)}}function Zt(){if(Sr)return Ar;Sr=1;var r=Ht();return Ar=function(t,n){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=r&&void 0===n?"__lodash_hash_undefined__":n,this}}function rn(){if(zr)return Cr;zr=1;var r=Kt(),t=Qt(),n=Xt(),e=Yt(),o=Zt();function u(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return u.prototype.clear=r,u.prototype.delete=t,u.prototype.get=n,u.prototype.has=e,u.prototype.set=o,Cr=u}function tn(){if(Er)return Fr;Er=1;var r=rn(),t=Lt(),n=Jt();return Fr=function(){this.size=0,this.__data__={hash:new r,map:new(n||t),string:new r}}}function nn(){if(Tr)return kr;return Tr=1,kr=function(r){var t=typeof r;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==r:null===r}}function en(){if(Ur)return Nr;Ur=1;var r=nn();return Nr=function(t,n){var e=t.__data__;return r(n)?e["string"==typeof n?"string":"hash"]:e.map}}function on(){if(Br)return qr;Br=1;var r=en();return qr=function(t){var n=r(this,t).delete(t);return this.size-=n?1:0,n}}function un(){if(Mr)return Ir;Mr=1;var r=en();return Ir=function(t){return r(this,t).get(t)}}function cn(){if(Dr)return Lr;Dr=1;var r=en();return Lr=function(t){return r(this,t).has(t)}}function an(){if(Vr)return Gr;Vr=1;var r=en();return Gr=function(t,n){var e=r(this,t),o=e.size;return e.set(t,n),this.size+=e.size==o?0:1,this}}function fn(){if(Jr)return Wr;Jr=1;var r=tn(),t=on(),n=un(),e=cn(),o=an();function u(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return u.prototype.clear=r,u.prototype.delete=t,u.prototype.get=n,u.prototype.has=e,u.prototype.set=o,Wr=u}function sn(){if(Kr)return Hr;Kr=1;var r=Lt(),t=Jt(),n=fn();return Hr=function(e,o){var u=this.__data__;if(u instanceof r){var i=u.__data__;if(!t||i.length<199)return i.push([e,o]),this.size=++u.size,this;u=this.__data__=new n(i)}return u.set(e,o),this.size=u.size,this}}function ln(){if(Xr)return Qr;Xr=1;var r=Lt(),t=Dt(),n=Gt(),e=Vt(),o=Wt(),u=sn();function i(t){var n=this.__data__=new r(t);this.size=n.size}return i.prototype.clear=t,i.prototype.delete=n,i.prototype.get=e,i.prototype.has=o,i.prototype.set=u,Qr=i}function pn(){if(Zr)return Yr;Zr=1;var r=Ct();return Yr=function(t,n,e){"__proto__"==n&&r?r(t,n,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[n]=e}}function vn(){if(tt)return rt;tt=1;var r=pn(),t=Nt();return rt=function(n,e,o){(void 0!==o&&!t(n[e],o)||void 0===o&&!(e in n))&&r(n,e,o)}}function hn(){if(et)return nt;return et=1,nt=function(r){return function(t,n,e){for(var o=-1,u=Object(t),i=e(t),c=i.length;c--;){var a=i[r?c:++o];if(!1===n(u[a],a,u))break}return t}}}function gn(){if(ut)return ot;ut=1;var r=hn()();return ot=r}var dn,yn,_n,bn,jn,mn,wn,On,xn,Pn,Rn,$n,An,Sn,Cn,zn,Fn,En,kn,Tn,Nn,Un,qn,Bn,In,Mn,Ln,Dn,Gn,Vn,Wn,Jn,Hn,Kn={exports:{}};function Qn(){return dn||(dn=1,function(r,t){var n=yt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,u=o&&o.exports===e?n.Buffer:void 0,i=u?u.allocUnsafe:void 0;r.exports=function(r,t){if(t)return r.slice();var n=r.length,e=i?i(n):new r.constructor(n);return r.copy(e),e}}(Kn,Kn.exports)),Kn.exports}function Xn(){if(_n)return yn;_n=1;var r=yt().Uint8Array;return yn=r}function Yn(){if(jn)return bn;jn=1;var r=Xn();return bn=function(t){var n=new t.constructor(t.byteLength);return new r(n).set(new r(t)),n}}function Zn(){if(wn)return mn;wn=1;var r=Yn();return mn=function(t,n){var e=n?r(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.length)}}function re(){if(xn)return On;return xn=1,On=function(r,t){var n=-1,e=r.length;for(t||(t=Array(e));++n<e;)t[n]=r[n];return t}}function te(){if(Rn)return Pn;Rn=1;var r=wt(),t=Object.create,n=function(){function n(){}return function(e){if(!r(e))return{};if(t)return t(e);n.prototype=e;var o=new n;return n.prototype=void 0,o}}();return Pn=n}function ne(){if(An)return $n;return An=1,$n=function(r,t){return function(n){return r(t(n))}}}function ee(){if(Cn)return Sn;Cn=1;var r=ne()(Object.getPrototypeOf,Object);return Sn=r}function oe(){if(Fn)return zn;Fn=1;var r=Object.prototype;return zn=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||r)}}function ue(){if(kn)return En;kn=1;var r=te(),t=ee(),n=oe();return En=function(e){return"function"!=typeof e.constructor||n(e)?{}:r(t(e))}}function ie(){if(Nn)return Tn;return Nn=1,Tn=function(r){return null!=r&&"object"==typeof r}}function ce(){if(qn)return Un;qn=1;var r=mt(),t=ie();return Un=function(n){return t(n)&&"[object Arguments]"==r(n)}}function ae(){if(In)return Bn;In=1;var r=ce(),t=ie(),n=Object.prototype,e=n.hasOwnProperty,o=n.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(r){return t(r)&&e.call(r,"callee")&&!o.call(r,"callee")};return Bn=u}function fe(){if(Ln)return Mn;Ln=1;var r=Array.isArray;return Mn=r}function se(){if(Gn)return Dn;Gn=1;return Dn=function(r){return"number"==typeof r&&r>-1&&r%1==0&&r<=9007199254740991}}function le(){if(Wn)return Vn;Wn=1;var r=Ot(),t=se();return Vn=function(n){return null!=n&&t(n.length)&&!r(n)}}function pe(){if(Hn)return Jn;Hn=1;var r=le(),t=ie();return Jn=function(n){return t(n)&&r(n)}}var ve,he,ge,de,ye,_e,be,je,me,we={exports:{}};function Oe(){if(he)return ve;return he=1,ve=function(){return!1}}function xe(){return ge||(ge=1,function(r,t){var n=yt(),e=Oe(),o=t&&!t.nodeType&&t,u=o&&r&&!r.nodeType&&r,i=u&&u.exports===o?n.Buffer:void 0,c=(i?i.isBuffer:void 0)||e;r.exports=c}(we,we.exports)),we.exports}function Pe(){if(ye)return de;ye=1;var r=mt(),t=ee(),n=ie(),e=Function.prototype,o=Object.prototype,u=e.toString,i=o.hasOwnProperty,c=u.call(Object);return de=function(e){if(!n(e)||"[object Object]"!=r(e))return!1;var o=t(e);if(null===o)return!0;var a=i.call(o,"constructor")&&o.constructor;return"function"==typeof a&&a instanceof a&&u.call(a)==c}}function Re(){if(be)return _e;be=1;var r=mt(),t=se(),n=ie(),e={};return e["[object Float32Array]"]=e["[object Float64Array]"]=e["[object Int8Array]"]=e["[object Int16Array]"]=e["[object Int32Array]"]=e["[object Uint8Array]"]=e["[object Uint8ClampedArray]"]=e["[object Uint16Array]"]=e["[object Uint32Array]"]=!0,e["[object Arguments]"]=e["[object Array]"]=e["[object ArrayBuffer]"]=e["[object Boolean]"]=e["[object DataView]"]=e["[object Date]"]=e["[object Error]"]=e["[object Function]"]=e["[object Map]"]=e["[object Number]"]=e["[object Object]"]=e["[object RegExp]"]=e["[object Set]"]=e["[object String]"]=e["[object WeakMap]"]=!1,_e=function(o){return n(o)&&t(o.length)&&!!e[r(o)]}}function $e(){if(me)return je;return me=1,je=function(r){return function(t){return r(t)}}}var Ae,Se,Ce,ze,Fe,Ee,ke,Te,Ne,Ue,qe,Be,Ie,Me,Le,De,Ge,Ve,We,Je,He,Ke,Qe,Xe,Ye,Ze,ro,to,no,eo,oo,uo,io,co,ao,fo,so,lo={exports:{}};function po(){return Ae||(Ae=1,function(r,t){var n=dt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,u=o&&o.exports===e&&n.process,i=function(){try{var r=o&&o.require&&o.require("util").types;return r||u&&u.binding&&u.binding("util")}catch(r){}}();r.exports=i}(lo,lo.exports)),lo.exports}function vo(){if(Ce)return Se;Ce=1;var r=Re(),t=$e(),n=po(),e=n&&n.isTypedArray,o=e?t(e):r;return Se=o}function ho(){if(Fe)return ze;return Fe=1,ze=function(r,t){if(("constructor"!==t||"function"!=typeof r[t])&&"__proto__"!=t)return r[t]}}function go(){if(ke)return Ee;ke=1;var r=pn(),t=Nt(),n=Object.prototype.hasOwnProperty;return Ee=function(e,o,u){var i=e[o];n.call(e,o)&&t(i,u)&&(void 0!==u||o in e)||r(e,o,u)}}function yo(){if(Ne)return Te;Ne=1;var r=go(),t=pn();return Te=function(n,e,o,u){var i=!o;o||(o={});for(var c=-1,a=e.length;++c<a;){var f=e[c],s=u?u(o[f],n[f],f,o,n):void 0;void 0===s&&(s=n[f]),i?t(o,f,s):r(o,f,s)}return o}}function _o(){if(qe)return Ue;return qe=1,Ue=function(r,t){for(var n=-1,e=Array(r);++n<r;)e[n]=t(n);return e}}function bo(){if(Ie)return Be;Ie=1;var r=/^(?:0|[1-9]\d*)$/;return Be=function(t,n){var e=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==e||"symbol"!=e&&r.test(t))&&t>-1&&t%1==0&&t<n}}function jo(){if(Le)return Me;Le=1;var r=_o(),t=ae(),n=fe(),e=xe(),o=bo(),u=vo(),i=Object.prototype.hasOwnProperty;return Me=function(c,a){var f=n(c),s=!f&&t(c),l=!f&&!s&&e(c),p=!f&&!s&&!l&&u(c),v=f||s||l||p,h=v?r(c.length,String):[],g=h.length;for(var d in c)!a&&!i.call(c,d)||v&&("length"==d||l&&("offset"==d||"parent"==d)||p&&("buffer"==d||"byteLength"==d||"byteOffset"==d)||o(d,g))||h.push(d);return h}}function mo(){if(Ge)return De;return Ge=1,De=function(r){var t=[];if(null!=r)for(var n in Object(r))t.push(n);return t}}function wo(){if(We)return Ve;We=1;var r=wt(),t=oe(),n=mo(),e=Object.prototype.hasOwnProperty;return Ve=function(o){if(!r(o))return n(o);var u=t(o),i=[];for(var c in o)("constructor"!=c||!u&&e.call(o,c))&&i.push(c);return i}}function Oo(){if(He)return Je;He=1;var r=jo(),t=wo(),n=le();return Je=function(e){return n(e)?r(e,!0):t(e)}}function xo(){if(Qe)return Ke;Qe=1;var r=yo(),t=Oo();return Ke=function(n){return r(n,t(n))}}function Po(){if(Ye)return Xe;Ye=1;var r=vn(),t=Qn(),n=Zn(),e=re(),o=ue(),u=ae(),i=fe(),c=pe(),a=xe(),f=Ot(),s=wt(),l=Pe(),p=vo(),v=ho(),h=xo();return Xe=function(g,d,y,_,b,j,m){var w=v(g,y),O=v(d,y),x=m.get(O);if(x)r(g,y,x);else{var P=j?j(w,O,y+"",g,d,m):void 0,R=void 0===P;if(R){var $=i(O),A=!$&&a(O),S=!$&&!A&&p(O);P=O,$||A||S?i(w)?P=w:c(w)?P=e(w):A?(R=!1,P=t(O,!0)):S?(R=!1,P=n(O,!0)):P=[]:l(O)||u(O)?(P=w,u(w)?P=h(w):s(w)&&!f(w)||(P=o(O))):R=!1}R&&(m.set(O,P),b(P,O,_,j,m),m.delete(O)),r(g,y,P)}}}function Ro(){if(ro)return Ze;ro=1;var r=ln(),t=vn(),n=gn(),e=Po(),o=wt(),u=Oo(),i=ho();return Ze=function c(a,f,s,l,p){a!==f&&n(f,(function(n,u){if(p||(p=new r),o(n))e(a,f,u,s,c,l,p);else{var v=l?l(i(a,u),n,u+"",a,f,p):void 0;void 0===v&&(v=n),t(a,u,v)}}),u)},Ze}function $o(){if(no)return to;no=1;var r=Ro(),t=wt();return to=function n(e,o,u,i,c,a){return t(e)&&t(o)&&(a.set(o,e),r(e,o,void 0,n,a),a.delete(o)),e},to}function Ao(){if(oo)return eo;oo=1;var r=Nt(),t=le(),n=bo(),e=wt();return eo=function(o,u,i){if(!e(i))return!1;var c=typeof u;return!!("number"==c?t(i)&&n(u,i.length):"string"==c&&u in i)&&r(i[u],o)}}function So(){if(io)return uo;io=1;var r=kt(),t=Ao();return uo=function(n){return r((function(r,e){var o=-1,u=e.length,i=u>1?e[u-1]:void 0,c=u>2?e[2]:void 0;for(i=n.length>3&&"function"==typeof i?(u--,i):void 0,c&&t(e[0],e[1],c)&&(i=u<3?void 0:i,u=1),r=Object(r);++o<u;){var a=e[o];a&&n(r,a,o,i)}return r}))}}function Co(){if(ao)return co;ao=1;var r=Ro(),t=So()((function(t,n,e,o){r(t,n,e,o)}));return co=t}function zo(){if(so)return fo;so=1;var r=pt(),t=kt(),n=$o(),e=Co(),o=t((function(t){return t.push(void 0,n),r(e,void 0,t)}));return fo=o}var Fo=lt(zo()),Eo=lt(Pe());class ko{name;searchPlaces;_config;loaders;searchCache;constructor(r){const{name:t,searchPlaces:n,defaultConfig:e,loaders:o}=r;if(!t&&!n)throw new Error("searchPlaces or name is required");this.name=t,this.searchPlaces=n||function(r){const t=["json","js","ts","cjs","yaml","yml"];return["package.json",...t.map((t=>`${r}.${t}`)),...t.map((t=>`.${r}.${t}`))]}(t),this._config=e||{},this.loaders=o}get config(){return Fo({},this.search(),this._config)}getSearchPlaces(){return this.searchPlaces}get(r={}){const{file:t,dir:n=process.cwd()}=r,e={};if(!1===t)return e;const o=it.cosmiconfigSync(this.name,{searchPlaces:this.searchPlaces,loaders:this.loaders}),u=t?o.load(t):o.search(n);if(u&&"string"==typeof u.config)throw new Error(`Invalid configuration file at ${u.filepath}`);return u&&Eo(u.config)?u.config:e}search(){return this.searchCache?this.searchCache:this.searchCache=this.get({})}}const To={protectedBranches:["master","develop","main"],cleanFiles:["dist","node_modules","yarn.lock","package-lock.json",".eslintcache","*.log"],commitlint:{extends:["@commitlint/config-conventional"]},release:{publishPath:"",autoMergeReleasePR:!1,autoMergeType:"squash",branchName:"release-${pkgName}-${tagName}",PRTitle:"[${pkgName} Release] Branch:${branch}, Tag:${tagName}, Env:${env}",PRBody:"## Publish Details\n\n- 🏷️ Version: ${tagName}\n- 🌲 Branch: ${branch}\n- 🔧 Environment: ${env}\n\n## Changelog\n\n${changelog}\n\n## Notes\n\n- [ ] Please check if the version number is correct\n- [ ] Please confirm all tests have passed\n- [ ] Please confirm the documentation has been updated\n\n> This PR is auto created by release process, please contact the frontend team if there are any questions.",label:{color:"1A7F37",description:"Release PR",name:"CI-Release"},packagesDirectories:[],changePackagesLabel:"changes:${name}"},envOrder:[".env.local",".env.production",".env"]};var No,Uo,qo,Bo,Io,Mo,Lo,Do,Go,Vo,Wo,Jo,Ho,Ko,Qo,Xo,Yo,Zo,ru,tu,nu,eu,ou,uu,iu,cu,au,fu,su,lu,pu,vu,hu,gu,du,yu,_u,bu,ju,mu,wu,Ou;function xu(){if(Uo)return No;Uo=1;var r=yo(),t=So(),n=Oo(),e=t((function(t,e,o,u){r(e,n(e),t,u)}));return No=e}function Pu(){if(Bo)return qo;Bo=1;var r=mt(),t=ie(),n=Pe();return qo=function(e){if(!t(e))return!1;var o=r(e);return"[object Error]"==o||"[object DOMException]"==o||"string"==typeof e.message&&"string"==typeof e.name&&!n(e)}}function Ru(){if(Mo)return Io;Mo=1;var r=pt(),t=kt(),n=Pu(),e=t((function(t,e){try{return r(t,void 0,e)}catch(r){return n(r)?r:new Error(r)}}));return Io=e}function $u(){if(Do)return Lo;return Do=1,Lo=function(r,t){for(var n=-1,e=null==r?0:r.length,o=Array(e);++n<e;)o[n]=t(r[n],n,r);return o}}function Au(){if(Vo)return Go;Vo=1;var r=$u();return Go=function(t,n){return r(n,(function(r){return t[r]}))}}function Su(){if(Jo)return Wo;Jo=1;var r=Nt(),t=Object.prototype,n=t.hasOwnProperty;return Wo=function(e,o,u,i){return void 0===e||r(e,t[u])&&!n.call(i,u)?o:e}}function Cu(){if(Ko)return Ho;Ko=1;var r={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};return Ho=function(t){return"\\"+r[t]}}function zu(){if(Xo)return Qo;Xo=1;var r=ne()(Object.keys,Object);return Qo=r}function Fu(){if(Zo)return Yo;Zo=1;var r=oe(),t=zu(),n=Object.prototype.hasOwnProperty;return Yo=function(e){if(!r(e))return t(e);var o=[];for(var u in Object(e))n.call(e,u)&&"constructor"!=u&&o.push(u);return o}}function Eu(){if(tu)return ru;tu=1;var r=jo(),t=Fu(),n=le();return ru=function(e){return n(e)?r(e):t(e)}}function ku(){if(eu)return nu;eu=1;return nu=/<%=([\s\S]+?)%>/g}function Tu(){if(uu)return ou;return uu=1,ou=function(r){return function(t){return null==r?void 0:r[t]}}}function Nu(){if(cu)return iu;cu=1;var r=Tu()({"&":"&","<":"<",">":">",'"':""","'":"'"});return iu=r}function Uu(){if(fu)return au;fu=1;var r=mt(),t=ie();return au=function(n){return"symbol"==typeof n||t(n)&&"[object Symbol]"==r(n)}}function qu(){if(lu)return su;lu=1;var r=_t(),t=$u(),n=fe(),e=Uu(),o=r?r.prototype:void 0,u=o?o.toString:void 0;return su=function r(o){if("string"==typeof o)return o;if(n(o))return t(o,r)+"";if(e(o))return u?u.call(o):"";var i=o+"";return"0"==i&&1/o==-1/0?"-0":i},su}function Bu(){if(vu)return pu;vu=1;var r=qu();return pu=function(t){return null==t?"":r(t)}}function Iu(){if(gu)return hu;gu=1;var r=Nu(),t=Bu(),n=/[&<>"']/g,e=RegExp(n.source);return hu=function(o){return(o=t(o))&&e.test(o)?o.replace(n,r):o}}function Mu(){if(yu)return du;yu=1;return du=/<%-([\s\S]+?)%>/g}function Lu(){if(bu)return _u;bu=1;return _u=/<%([\s\S]+?)%>/g}function Du(){if(mu)return ju;mu=1;var r=Iu();return ju={escape:Mu(),evaluate:Lu(),interpolate:ku(),variable:"",imports:{_:{escape:r}}}}function Gu(){if(Ou)return wu;Ou=1;var r=xu(),t=Ru(),n=Au(),e=Su(),o=Cu(),u=Pu(),i=Ao(),c=Eu(),a=ku(),f=Du(),s=Bu(),l=/\b__p \+= '';/g,p=/\b(__p \+=) '' \+/g,v=/(__e\(.*?\)|\b__t\)) \+\n'';/g,h=/[()=,{}\[\]\/\s]/,g=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,d=/($^)/,y=/['\n\r\u2028\u2029\\]/g,_=Object.prototype.hasOwnProperty;return wu=function(b,j,m){var w=f.imports._.templateSettings||f;m&&i(b,j,m)&&(j=void 0),b=s(b),j=r({},j,w,e);var O,x,P=r({},j.imports,w.imports,e),R=c(P),$=n(P,R),A=0,S=j.interpolate||d,C="__p += '",z=RegExp((j.escape||d).source+"|"+S.source+"|"+(S===a?g:d).source+"|"+(j.evaluate||d).source+"|$","g"),F=_.call(j,"sourceURL")?"//# sourceURL="+(j.sourceURL+"").replace(/\s/g," ")+"\n":"";b.replace(z,(function(r,t,n,e,u,i){return n||(n=e),C+=b.slice(A,i).replace(y,o),t&&(O=!0,C+="' +\n__e("+t+") +\n'"),u&&(x=!0,C+="';\n"+u+";\n__p += '"),n&&(C+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),A=i+r.length,r})),C+="';\n";var E=_.call(j,"variable")&&j.variable;if(E){if(h.test(E))throw new Error("Invalid `variable` option passed into `_.template`")}else C="with (obj) {\n"+C+"\n}\n";C=(x?C.replace(l,""):C).replace(p,"$1").replace(v,"$1;"),C="function("+(E||"obj")+") {\n"+(E?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(O?", __e = _.escape":"")+(x?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+C+"return __p\n}";var k=t((function(){return Function(R,F+"return "+C).apply(void 0,$)}));if(k.source=C,u(k))throw k;return k}}var Vu,Wu,Ju=lt(Gu());class Hu{config;cache;constructor(r,t=new Map){this.config=r,this.cache=t}get logger(){return this.config.logger}static format(r="",t={}){return Ju(r)(t)}format(r="",t={}){try{return Hu.format(r,t)}catch(n){throw this.logger.error(`Unable to render template with context:\n${r}\n${JSON.stringify(t)}`),this.logger.error(n),n}}exec(r,t={}){const{context:n,...e}=t;return"string"==typeof r?this.execFormattedCommand(this.format(r,n||{}),e):this.execFormattedCommand(r,e)}run(r,t={}){return this.exec(r,{silent:!0,...t})}async execFormattedCommand(r,t={}){const n=this.config.execPromise;if(!n)throw new Error("execPromise is not defined");const{dryRunResult:e,silent:o,dryRun:u,isCache:i}=t,c=void 0!==u?u:this.config.dryRun,a=void 0!==i?!!i:!!this.config.isCache,f="string"==typeof r?r:r.join(" "),s=a&&this.cache.has(f);if(o||this.logger.exec(r,{isCached:s}),c)return Promise.resolve(e);if(s)return this.cache.get(f);const l=n(r,t);return this.cache.has(f)||this.cache.set(f,l),l}}function Ku(){if(Wu)return Vu;Wu=1;var r=Ro(),t=So()((function(t,n,e){r(t,n,e)}));return Vu=t}var Qu=lt(Ku());class Xu extends ct.Logger{prefix(r){switch(r){case"INFO":return at.blue(r);case"WARN":return at.yellow(r);case"ERROR":return at.red(r);case"DEBUG":return at.gray(r);default:return r}}obtrusive(r){const t=at.bold(r);super.obtrusive(t)}}const Yu=(r,t)=>{const n=Array.isArray(r)?r.join(" "):r;return new Promise(((r,e)=>{ft.exec(n,{encoding:"utf-8",...t},((t,n,o)=>{let u;u=t?void 0===t.code?1:t.code:0,0===u?r(n.trim()):e(new Error(o||n))}))}))};function Zu(r){return new ko({name:"fe-config",defaultConfig:Qu({},To,r)})}exports.ConfigSearch=ko,exports.FeScriptContext=class{logger;shell;feConfig;dryRun;verbose;options;constructor(r){const{logger:t,shell:n,feConfig:e,dryRun:o,verbose:u,options:i}=r||{},c=i||{};this.logger=t||new Xu({debug:u,dryRun:o}),this.shell=n||new Hu({logger:this.logger,dryRun:o,execPromise:c.execPromise||Yu}),this.feConfig=Zu(e).config,this.dryRun=!!o,this.verbose=!!u,this.options=c}},exports.ScriptsLogger=Xu,exports.Shell=Hu,exports.defaultFeConfig=To,exports.getFeConfigSearch=Zu;
|
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{cosmiconfigSync as r}from"cosmiconfig";import{Logger as t}from"@qlover/fe-corekit";import n from"chalk";import{exec as e}from"child_process";var o,u,i,c,a,f,s,l,p,v,h,d,y,g,_,b,m,j,w,O,P,x,R,$,A,S,z,C,E,F,k,T,N,U,B,I,M,q,D,L,G,V,W,J,H,K,Q,X,Y,Z,rr,tr,nr,er,or,ur,ir,cr,ar,fr,sr,lr,pr,vr,hr,dr,yr,gr,_r,br,mr,jr,wr,Or,Pr,xr,Rr,$r,Ar,Sr,zr,Cr,Er,Fr,kr,Tr,Nr,Ur,Br,Ir,Mr,qr,Dr,Lr,Gr,Vr,Wr,Jr,Hr,Kr,Qr,Xr,Yr,Zr,rt,tt,nt,et,ot,ut,it,ct,at,ft,st="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function lt(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function pt(){if(u)return o;return u=1,o=function(r,t,n){switch(n.length){case 0:return r.call(t);case 1:return r.call(t,n[0]);case 2:return r.call(t,n[0],n[1]);case 3:return r.call(t,n[0],n[1],n[2])}return r.apply(t,n)}}function vt(){if(c)return i;return c=1,i=function(r){return r}}function ht(){if(f)return a;f=1;var r=pt(),t=Math.max;return a=function(n,e,o){return e=t(void 0===e?n.length-1:e,0),function(){for(var u=arguments,i=-1,c=t(u.length-e,0),a=Array(c);++i<c;)a[i]=u[e+i];i=-1;for(var f=Array(e+1);++i<e;)f[i]=u[i];return f[e]=o(a),r(n,this,f)}},a}function dt(){if(l)return s;return l=1,s=function(r){return function(){return r}}}function yt(){if(v)return p;v=1;var r="object"==typeof st&&st&&st.Object===Object&&st;return p=r}function gt(){if(d)return h;d=1;var r=yt(),t="object"==typeof self&&self&&self.Object===Object&&self,n=r||t||Function("return this")();return h=n}function _t(){if(g)return y;g=1;var r=gt().Symbol;return y=r}function bt(){if(b)return _;b=1;var r=_t(),t=Object.prototype,n=t.hasOwnProperty,e=t.toString,o=r?r.toStringTag:void 0;return _=function(r){var t=n.call(r,o),u=r[o];try{r[o]=void 0;var i=!0}catch(r){}var c=e.call(r);return i&&(t?r[o]=u:delete r[o]),c}}function mt(){if(j)return m;j=1;var r=Object.prototype.toString;return m=function(t){return r.call(t)}}function jt(){if(O)return w;O=1;var r=_t(),t=bt(),n=mt(),e=r?r.toStringTag:void 0;return w=function(r){return null==r?void 0===r?"[object Undefined]":"[object Null]":e&&e in Object(r)?t(r):n(r)}}function wt(){if(x)return P;return x=1,P=function(r){var t=typeof r;return null!=r&&("object"==t||"function"==t)}}function Ot(){if($)return R;$=1;var r=jt(),t=wt();return R=function(n){if(!t(n))return!1;var e=r(n);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}}function Pt(){if(S)return A;S=1;var r=gt()["__core-js_shared__"];return A=r}function xt(){if(C)return z;C=1;var r,t=Pt(),n=(r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";return z=function(r){return!!n&&n in r}}function Rt(){if(F)return E;F=1;var r=Function.prototype.toString;return E=function(t){if(null!=t){try{return r.call(t)}catch(r){}try{return t+""}catch(r){}}return""}}function $t(){if(T)return k;T=1;var r=Ot(),t=xt(),n=wt(),e=Rt(),o=/^\[object .+?Constructor\]$/,u=Function.prototype,i=Object.prototype,c=u.toString,a=i.hasOwnProperty,f=RegExp("^"+c.call(a).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");return k=function(u){return!(!n(u)||t(u))&&(r(u)?f:o).test(e(u))}}function At(){if(U)return N;return U=1,N=function(r,t){return null==r?void 0:r[t]}}function St(){if(I)return B;I=1;var r=$t(),t=At();return B=function(n,e){var o=t(n,e);return r(o)?o:void 0}}function zt(){if(q)return M;q=1;var r=St(),t=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(r){}}();return M=t}function Ct(){if(L)return D;L=1;var r=dt(),t=zt();return D=t?function(n,e){return t(n,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:vt()}function Et(){if(V)return G;V=1;var r=Date.now;return G=function(t){var n=0,e=0;return function(){var o=r(),u=16-(o-e);if(e=o,u>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},G}function Ft(){if(J)return W;J=1;var r=Ct(),t=Et()(r);return W=t}function kt(){if(K)return H;K=1;var r=vt(),t=ht(),n=Ft();return H=function(e,o){return n(t(e,o,r),e+"")}}function Tt(){if(X)return Q;return X=1,Q=function(){this.__data__=[],this.size=0}}function Nt(){if(Z)return Y;return Z=1,Y=function(r,t){return r===t||r!=r&&t!=t}}function Ut(){if(tr)return rr;tr=1;var r=Nt();return rr=function(t,n){for(var e=t.length;e--;)if(r(t[e][0],n))return e;return-1}}function Bt(){if(er)return nr;er=1;var r=Ut(),t=Array.prototype.splice;return nr=function(n){var e=this.__data__,o=r(e,n);return!(o<0)&&(o==e.length-1?e.pop():t.call(e,o,1),--this.size,!0)}}function It(){if(ur)return or;ur=1;var r=Ut();return or=function(t){var n=this.__data__,e=r(n,t);return e<0?void 0:n[e][1]}}function Mt(){if(cr)return ir;cr=1;var r=Ut();return ir=function(t){return r(this.__data__,t)>-1}}function qt(){if(fr)return ar;fr=1;var r=Ut();return ar=function(t,n){var e=this.__data__,o=r(e,t);return o<0?(++this.size,e.push([t,n])):e[o][1]=n,this}}function Dt(){if(lr)return sr;lr=1;var r=Tt(),t=Bt(),n=It(),e=Mt(),o=qt();function u(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return u.prototype.clear=r,u.prototype.delete=t,u.prototype.get=n,u.prototype.has=e,u.prototype.set=o,sr=u}function Lt(){if(vr)return pr;vr=1;var r=Dt();return pr=function(){this.__data__=new r,this.size=0}}function Gt(){if(dr)return hr;return dr=1,hr=function(r){var t=this.__data__,n=t.delete(r);return this.size=t.size,n}}function Vt(){if(gr)return yr;return gr=1,yr=function(r){return this.__data__.get(r)}}function Wt(){if(br)return _r;return br=1,_r=function(r){return this.__data__.has(r)}}function Jt(){if(jr)return mr;jr=1;var r=St()(gt(),"Map");return mr=r}function Ht(){if(Or)return wr;Or=1;var r=St()(Object,"create");return wr=r}function Kt(){if(xr)return Pr;xr=1;var r=Ht();return Pr=function(){this.__data__=r?r(null):{},this.size=0}}function Qt(){if($r)return Rr;return $r=1,Rr=function(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}}function Xt(){if(Sr)return Ar;Sr=1;var r=Ht(),t=Object.prototype.hasOwnProperty;return Ar=function(n){var e=this.__data__;if(r){var o=e[n];return"__lodash_hash_undefined__"===o?void 0:o}return t.call(e,n)?e[n]:void 0}}function Yt(){if(Cr)return zr;Cr=1;var r=Ht(),t=Object.prototype.hasOwnProperty;return zr=function(n){var e=this.__data__;return r?void 0!==e[n]:t.call(e,n)}}function Zt(){if(Fr)return Er;Fr=1;var r=Ht();return Er=function(t,n){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=r&&void 0===n?"__lodash_hash_undefined__":n,this}}function rn(){if(Tr)return kr;Tr=1;var r=Kt(),t=Qt(),n=Xt(),e=Yt(),o=Zt();function u(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return u.prototype.clear=r,u.prototype.delete=t,u.prototype.get=n,u.prototype.has=e,u.prototype.set=o,kr=u}function tn(){if(Ur)return Nr;Ur=1;var r=rn(),t=Dt(),n=Jt();return Nr=function(){this.size=0,this.__data__={hash:new r,map:new(n||t),string:new r}}}function nn(){if(Ir)return Br;return Ir=1,Br=function(r){var t=typeof r;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==r:null===r}}function en(){if(qr)return Mr;qr=1;var r=nn();return Mr=function(t,n){var e=t.__data__;return r(n)?e["string"==typeof n?"string":"hash"]:e.map}}function on(){if(Lr)return Dr;Lr=1;var r=en();return Dr=function(t){var n=r(this,t).delete(t);return this.size-=n?1:0,n}}function un(){if(Vr)return Gr;Vr=1;var r=en();return Gr=function(t){return r(this,t).get(t)}}function cn(){if(Jr)return Wr;Jr=1;var r=en();return Wr=function(t){return r(this,t).has(t)}}function an(){if(Kr)return Hr;Kr=1;var r=en();return Hr=function(t,n){var e=r(this,t),o=e.size;return e.set(t,n),this.size+=e.size==o?0:1,this}}function fn(){if(Xr)return Qr;Xr=1;var r=tn(),t=on(),n=un(),e=cn(),o=an();function u(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return u.prototype.clear=r,u.prototype.delete=t,u.prototype.get=n,u.prototype.has=e,u.prototype.set=o,Qr=u}function sn(){if(Zr)return Yr;Zr=1;var r=Dt(),t=Jt(),n=fn();return Yr=function(e,o){var u=this.__data__;if(u instanceof r){var i=u.__data__;if(!t||i.length<199)return i.push([e,o]),this.size=++u.size,this;u=this.__data__=new n(i)}return u.set(e,o),this.size=u.size,this}}function ln(){if(tt)return rt;tt=1;var r=Dt(),t=Lt(),n=Gt(),e=Vt(),o=Wt(),u=sn();function i(t){var n=this.__data__=new r(t);this.size=n.size}return i.prototype.clear=t,i.prototype.delete=n,i.prototype.get=e,i.prototype.has=o,i.prototype.set=u,rt=i}function pn(){if(et)return nt;et=1;var r=zt();return nt=function(t,n,e){"__proto__"==n&&r?r(t,n,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[n]=e}}function vn(){if(ut)return ot;ut=1;var r=pn(),t=Nt();return ot=function(n,e,o){(void 0!==o&&!t(n[e],o)||void 0===o&&!(e in n))&&r(n,e,o)}}function hn(){if(ct)return it;return ct=1,it=function(r){return function(t,n,e){for(var o=-1,u=Object(t),i=e(t),c=i.length;c--;){var a=i[r?c:++o];if(!1===n(u[a],a,u))break}return t}}}function dn(){if(ft)return at;ft=1;var r=hn()();return at=r}var yn,gn,_n,bn,mn,jn,wn,On,Pn,xn,Rn,$n,An,Sn,zn,Cn,En,Fn,kn,Tn,Nn,Un,Bn,In,Mn,qn,Dn,Ln,Gn,Vn,Wn,Jn,Hn,Kn={exports:{}};function Qn(){return yn||(yn=1,r=Kn,t=Kn.exports,n=gt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,u=o&&o.exports===e?n.Buffer:void 0,i=u?u.allocUnsafe:void 0,r.exports=function(r,t){if(t)return r.slice();var n=r.length,e=i?i(n):new r.constructor(n);return r.copy(e),e}),Kn.exports;var r,t,n,e,o,u,i}function Xn(){if(_n)return gn;_n=1;var r=gt().Uint8Array;return gn=r}function Yn(){if(mn)return bn;mn=1;var r=Xn();return bn=function(t){var n=new t.constructor(t.byteLength);return new r(n).set(new r(t)),n}}function Zn(){if(wn)return jn;wn=1;var r=Yn();return jn=function(t,n){var e=n?r(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.length)}}function re(){if(Pn)return On;return Pn=1,On=function(r,t){var n=-1,e=r.length;for(t||(t=Array(e));++n<e;)t[n]=r[n];return t}}function te(){if(Rn)return xn;Rn=1;var r=wt(),t=Object.create,n=function(){function n(){}return function(e){if(!r(e))return{};if(t)return t(e);n.prototype=e;var o=new n;return n.prototype=void 0,o}}();return xn=n}function ne(){if(An)return $n;return An=1,$n=function(r,t){return function(n){return r(t(n))}}}function ee(){if(zn)return Sn;zn=1;var r=ne()(Object.getPrototypeOf,Object);return Sn=r}function oe(){if(En)return Cn;En=1;var r=Object.prototype;return Cn=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||r)}}function ue(){if(kn)return Fn;kn=1;var r=te(),t=ee(),n=oe();return Fn=function(e){return"function"!=typeof e.constructor||n(e)?{}:r(t(e))}}function ie(){if(Nn)return Tn;return Nn=1,Tn=function(r){return null!=r&&"object"==typeof r}}function ce(){if(Bn)return Un;Bn=1;var r=jt(),t=ie();return Un=function(n){return t(n)&&"[object Arguments]"==r(n)}}function ae(){if(Mn)return In;Mn=1;var r=ce(),t=ie(),n=Object.prototype,e=n.hasOwnProperty,o=n.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(r){return t(r)&&e.call(r,"callee")&&!o.call(r,"callee")};return In=u}function fe(){if(Dn)return qn;Dn=1;var r=Array.isArray;return qn=r}function se(){if(Gn)return Ln;Gn=1;return Ln=function(r){return"number"==typeof r&&r>-1&&r%1==0&&r<=9007199254740991}}function le(){if(Wn)return Vn;Wn=1;var r=Ot(),t=se();return Vn=function(n){return null!=n&&t(n.length)&&!r(n)}}function pe(){if(Hn)return Jn;Hn=1;var r=le(),t=ie();return Jn=function(n){return t(n)&&r(n)}}var ve,he,de,ye,ge,_e,be,me,je,we={exports:{}};function Oe(){if(he)return ve;return he=1,ve=function(){return!1}}function Pe(){return de||(de=1,function(r,t){var n=gt(),e=Oe(),o=t&&!t.nodeType&&t,u=o&&r&&!r.nodeType&&r,i=u&&u.exports===o?n.Buffer:void 0,c=(i?i.isBuffer:void 0)||e;r.exports=c}(we,we.exports)),we.exports}function xe(){if(ge)return ye;ge=1;var r=jt(),t=ee(),n=ie(),e=Function.prototype,o=Object.prototype,u=e.toString,i=o.hasOwnProperty,c=u.call(Object);return ye=function(e){if(!n(e)||"[object Object]"!=r(e))return!1;var o=t(e);if(null===o)return!0;var a=i.call(o,"constructor")&&o.constructor;return"function"==typeof a&&a instanceof a&&u.call(a)==c}}function Re(){if(be)return _e;be=1;var r=jt(),t=se(),n=ie(),e={};return e["[object Float32Array]"]=e["[object Float64Array]"]=e["[object Int8Array]"]=e["[object Int16Array]"]=e["[object Int32Array]"]=e["[object Uint8Array]"]=e["[object Uint8ClampedArray]"]=e["[object Uint16Array]"]=e["[object Uint32Array]"]=!0,e["[object Arguments]"]=e["[object Array]"]=e["[object ArrayBuffer]"]=e["[object Boolean]"]=e["[object DataView]"]=e["[object Date]"]=e["[object Error]"]=e["[object Function]"]=e["[object Map]"]=e["[object Number]"]=e["[object Object]"]=e["[object RegExp]"]=e["[object Set]"]=e["[object String]"]=e["[object WeakMap]"]=!1,_e=function(o){return n(o)&&t(o.length)&&!!e[r(o)]}}function $e(){if(je)return me;return je=1,me=function(r){return function(t){return r(t)}}}var Ae,Se,ze,Ce,Ee,Fe,ke,Te,Ne,Ue,Be,Ie,Me,qe,De,Le,Ge,Ve,We,Je,He,Ke,Qe,Xe,Ye,Ze,ro,to,no,eo,oo,uo,io,co,ao,fo,so,lo={exports:{}};function po(){return Ae||(Ae=1,r=lo,t=lo.exports,n=yt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,u=o&&o.exports===e&&n.process,i=function(){try{var r=o&&o.require&&o.require("util").types;return r||u&&u.binding&&u.binding("util")}catch(r){}}(),r.exports=i),lo.exports;var r,t,n,e,o,u,i}function vo(){if(ze)return Se;ze=1;var r=Re(),t=$e(),n=po(),e=n&&n.isTypedArray,o=e?t(e):r;return Se=o}function ho(){if(Ee)return Ce;return Ee=1,Ce=function(r,t){if(("constructor"!==t||"function"!=typeof r[t])&&"__proto__"!=t)return r[t]}}function yo(){if(ke)return Fe;ke=1;var r=pn(),t=Nt(),n=Object.prototype.hasOwnProperty;return Fe=function(e,o,u){var i=e[o];n.call(e,o)&&t(i,u)&&(void 0!==u||o in e)||r(e,o,u)}}function go(){if(Ne)return Te;Ne=1;var r=yo(),t=pn();return Te=function(n,e,o,u){var i=!o;o||(o={});for(var c=-1,a=e.length;++c<a;){var f=e[c],s=u?u(o[f],n[f],f,o,n):void 0;void 0===s&&(s=n[f]),i?t(o,f,s):r(o,f,s)}return o}}function _o(){if(Be)return Ue;return Be=1,Ue=function(r,t){for(var n=-1,e=Array(r);++n<r;)e[n]=t(n);return e}}function bo(){if(Me)return Ie;Me=1;var r=/^(?:0|[1-9]\d*)$/;return Ie=function(t,n){var e=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==e||"symbol"!=e&&r.test(t))&&t>-1&&t%1==0&&t<n}}function mo(){if(De)return qe;De=1;var r=_o(),t=ae(),n=fe(),e=Pe(),o=bo(),u=vo(),i=Object.prototype.hasOwnProperty;return qe=function(c,a){var f=n(c),s=!f&&t(c),l=!f&&!s&&e(c),p=!f&&!s&&!l&&u(c),v=f||s||l||p,h=v?r(c.length,String):[],d=h.length;for(var y in c)!a&&!i.call(c,y)||v&&("length"==y||l&&("offset"==y||"parent"==y)||p&&("buffer"==y||"byteLength"==y||"byteOffset"==y)||o(y,d))||h.push(y);return h}}function jo(){if(Ge)return Le;return Ge=1,Le=function(r){var t=[];if(null!=r)for(var n in Object(r))t.push(n);return t}}function wo(){if(We)return Ve;We=1;var r=wt(),t=oe(),n=jo(),e=Object.prototype.hasOwnProperty;return Ve=function(o){if(!r(o))return n(o);var u=t(o),i=[];for(var c in o)("constructor"!=c||!u&&e.call(o,c))&&i.push(c);return i}}function Oo(){if(He)return Je;He=1;var r=mo(),t=wo(),n=le();return Je=function(e){return n(e)?r(e,!0):t(e)}}function Po(){if(Qe)return Ke;Qe=1;var r=go(),t=Oo();return Ke=function(n){return r(n,t(n))}}function xo(){if(Ye)return Xe;Ye=1;var r=vn(),t=Qn(),n=Zn(),e=re(),o=ue(),u=ae(),i=fe(),c=pe(),a=Pe(),f=Ot(),s=wt(),l=xe(),p=vo(),v=ho(),h=Po();return Xe=function(d,y,g,_,b,m,j){var w=v(d,g),O=v(y,g),P=j.get(O);if(P)r(d,g,P);else{var x=m?m(w,O,g+"",d,y,j):void 0,R=void 0===x;if(R){var $=i(O),A=!$&&a(O),S=!$&&!A&&p(O);x=O,$||A||S?i(w)?x=w:c(w)?x=e(w):A?(R=!1,x=t(O,!0)):S?(R=!1,x=n(O,!0)):x=[]:l(O)||u(O)?(x=w,u(w)?x=h(w):s(w)&&!f(w)||(x=o(O))):R=!1}R&&(j.set(O,x),b(x,O,_,m,j),j.delete(O)),r(d,g,x)}}}function Ro(){if(ro)return Ze;ro=1;var r=ln(),t=vn(),n=dn(),e=xo(),o=wt(),u=Oo(),i=ho();return Ze=function c(a,f,s,l,p){a!==f&&n(f,(function(n,u){if(p||(p=new r),o(n))e(a,f,u,s,c,l,p);else{var v=l?l(i(a,u),n,u+"",a,f,p):void 0;void 0===v&&(v=n),t(a,u,v)}}),u)},Ze}function $o(){if(no)return to;no=1;var r=Ro(),t=wt();return to=function n(e,o,u,i,c,a){return t(e)&&t(o)&&(a.set(o,e),r(e,o,void 0,n,a),a.delete(o)),e},to}function Ao(){if(oo)return eo;oo=1;var r=Nt(),t=le(),n=bo(),e=wt();return eo=function(o,u,i){if(!e(i))return!1;var c=typeof u;return!!("number"==c?t(i)&&n(u,i.length):"string"==c&&u in i)&&r(i[u],o)}}function So(){if(io)return uo;io=1;var r=kt(),t=Ao();return uo=function(n){return r((function(r,e){var o=-1,u=e.length,i=u>1?e[u-1]:void 0,c=u>2?e[2]:void 0;for(i=n.length>3&&"function"==typeof i?(u--,i):void 0,c&&t(e[0],e[1],c)&&(i=u<3?void 0:i,u=1),r=Object(r);++o<u;){var a=e[o];a&&n(r,a,o,i)}return r}))}}function zo(){if(ao)return co;ao=1;var r=Ro(),t=So()((function(t,n,e,o){r(t,n,e,o)}));return co=t}function Co(){if(so)return fo;so=1;var r=pt(),t=kt(),n=$o(),e=zo(),o=t((function(t){return t.push(void 0,n),r(e,void 0,t)}));return fo=o}var Eo=lt(Co()),Fo=lt(xe());class ko{name;searchPlaces;_config;loaders;searchCache;constructor(r){const{name:t,searchPlaces:n,defaultConfig:e,loaders:o}=r;if(!t&&!n)throw new Error("searchPlaces or name is required");this.name=t,this.searchPlaces=n||function(r){const t=["json","js","ts","cjs","yaml","yml"];return["package.json",...t.map((t=>`${r}.${t}`)),...t.map((t=>`.${r}.${t}`))]}(t),this._config=e||{},this.loaders=o}get config(){return Eo({},this.search(),this._config)}getSearchPlaces(){return this.searchPlaces}get(t={}){const{file:n,dir:e=process.cwd()}=t,o={};if(!1===n)return o;const u=r(this.name,{searchPlaces:this.searchPlaces,loaders:this.loaders}),i=n?u.load(n):u.search(e);if(i&&"string"==typeof i.config)throw new Error(`Invalid configuration file at ${i.filepath}`);return i&&Fo(i.config)?i.config:o}search(){return this.searchCache?this.searchCache:this.searchCache=this.get({})}}const To={protectedBranches:["master","develop","main"],cleanFiles:["dist","node_modules","yarn.lock","package-lock.json",".eslintcache","*.log"],commitlint:{extends:["@commitlint/config-conventional"]},release:{publishPath:"",autoMergeReleasePR:!1,autoMergeType:"squash",branchName:"release-${pkgName}-${tagName}",PRTitle:"[${pkgName} Release] Branch:${branch}, Tag:${tagName}, Env:${env}",PRBody:"## Publish Details\n\n- 🏷️ Version: ${tagName}\n- 🌲 Branch: ${branch}\n- 🔧 Environment: ${env}\n\n## Changelog\n\n${changelog}\n\n## Notes\n\n- [ ] Please check if the version number is correct\n- [ ] Please confirm all tests have passed\n- [ ] Please confirm the documentation has been updated\n\n> This PR is auto created by release process, please contact the frontend team if there are any questions.",label:{color:"1A7F37",description:"Release PR",name:"CI-Release"},packagesDirectories:[],changePackagesLabel:"changes:${name}"},envOrder:[".env.local",".env.production",".env"]};var No,Uo,Bo,Io,Mo,qo,Do,Lo,Go,Vo,Wo,Jo,Ho,Ko,Qo,Xo,Yo,Zo,ru,tu,nu,eu,ou,uu,iu,cu,au,fu,su,lu,pu,vu,hu,du,yu,gu,_u,bu,mu,ju,wu,Ou;function Pu(){if(Uo)return No;Uo=1;var r=go(),t=So(),n=Oo(),e=t((function(t,e,o,u){r(e,n(e),t,u)}));return No=e}function xu(){if(Io)return Bo;Io=1;var r=jt(),t=ie(),n=xe();return Bo=function(e){if(!t(e))return!1;var o=r(e);return"[object Error]"==o||"[object DOMException]"==o||"string"==typeof e.message&&"string"==typeof e.name&&!n(e)}}function Ru(){if(qo)return Mo;qo=1;var r=pt(),t=kt(),n=xu(),e=t((function(t,e){try{return r(t,void 0,e)}catch(r){return n(r)?r:new Error(r)}}));return Mo=e}function $u(){if(Lo)return Do;return Lo=1,Do=function(r,t){for(var n=-1,e=null==r?0:r.length,o=Array(e);++n<e;)o[n]=t(r[n],n,r);return o}}function Au(){if(Vo)return Go;Vo=1;var r=$u();return Go=function(t,n){return r(n,(function(r){return t[r]}))}}function Su(){if(Jo)return Wo;Jo=1;var r=Nt(),t=Object.prototype,n=t.hasOwnProperty;return Wo=function(e,o,u,i){return void 0===e||r(e,t[u])&&!n.call(i,u)?o:e}}function zu(){if(Ko)return Ho;Ko=1;var r={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};return Ho=function(t){return"\\"+r[t]}}function Cu(){if(Xo)return Qo;Xo=1;var r=ne()(Object.keys,Object);return Qo=r}function Eu(){if(Zo)return Yo;Zo=1;var r=oe(),t=Cu(),n=Object.prototype.hasOwnProperty;return Yo=function(e){if(!r(e))return t(e);var o=[];for(var u in Object(e))n.call(e,u)&&"constructor"!=u&&o.push(u);return o}}function Fu(){if(tu)return ru;tu=1;var r=mo(),t=Eu(),n=le();return ru=function(e){return n(e)?r(e):t(e)}}function ku(){if(eu)return nu;eu=1;return nu=/<%=([\s\S]+?)%>/g}function Tu(){if(uu)return ou;return uu=1,ou=function(r){return function(t){return null==r?void 0:r[t]}}}function Nu(){if(cu)return iu;cu=1;var r=Tu()({"&":"&","<":"<",">":">",'"':""","'":"'"});return iu=r}function Uu(){if(fu)return au;fu=1;var r=jt(),t=ie();return au=function(n){return"symbol"==typeof n||t(n)&&"[object Symbol]"==r(n)}}function Bu(){if(lu)return su;lu=1;var r=_t(),t=$u(),n=fe(),e=Uu(),o=r?r.prototype:void 0,u=o?o.toString:void 0;return su=function r(o){if("string"==typeof o)return o;if(n(o))return t(o,r)+"";if(e(o))return u?u.call(o):"";var i=o+"";return"0"==i&&1/o==-1/0?"-0":i},su}function Iu(){if(vu)return pu;vu=1;var r=Bu();return pu=function(t){return null==t?"":r(t)}}function Mu(){if(du)return hu;du=1;var r=Nu(),t=Iu(),n=/[&<>"']/g,e=RegExp(n.source);return hu=function(o){return(o=t(o))&&e.test(o)?o.replace(n,r):o}}function qu(){if(gu)return yu;gu=1;return yu=/<%-([\s\S]+?)%>/g}function Du(){if(bu)return _u;bu=1;return _u=/<%([\s\S]+?)%>/g}function Lu(){if(ju)return mu;ju=1;var r=Mu();return mu={escape:qu(),evaluate:Du(),interpolate:ku(),variable:"",imports:{_:{escape:r}}}}function Gu(){if(Ou)return wu;Ou=1;var r=Pu(),t=Ru(),n=Au(),e=Su(),o=zu(),u=xu(),i=Ao(),c=Fu(),a=ku(),f=Lu(),s=Iu(),l=/\b__p \+= '';/g,p=/\b(__p \+=) '' \+/g,v=/(__e\(.*?\)|\b__t\)) \+\n'';/g,h=/[()=,{}\[\]\/\s]/,d=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,y=/($^)/,g=/['\n\r\u2028\u2029\\]/g,_=Object.prototype.hasOwnProperty;return wu=function(b,m,j){var w=f.imports._.templateSettings||f;j&&i(b,m,j)&&(m=void 0),b=s(b),m=r({},m,w,e);var O,P,x=r({},m.imports,w.imports,e),R=c(x),$=n(x,R),A=0,S=m.interpolate||y,z="__p += '",C=RegExp((m.escape||y).source+"|"+S.source+"|"+(S===a?d:y).source+"|"+(m.evaluate||y).source+"|$","g"),E=_.call(m,"sourceURL")?"//# sourceURL="+(m.sourceURL+"").replace(/\s/g," ")+"\n":"";b.replace(C,(function(r,t,n,e,u,i){return n||(n=e),z+=b.slice(A,i).replace(g,o),t&&(O=!0,z+="' +\n__e("+t+") +\n'"),u&&(P=!0,z+="';\n"+u+";\n__p += '"),n&&(z+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),A=i+r.length,r})),z+="';\n";var F=_.call(m,"variable")&&m.variable;if(F){if(h.test(F))throw new Error("Invalid `variable` option passed into `_.template`")}else z="with (obj) {\n"+z+"\n}\n";z=(P?z.replace(l,""):z).replace(p,"$1").replace(v,"$1;"),z="function("+(F||"obj")+") {\n"+(F?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(O?", __e = _.escape":"")+(P?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+z+"return __p\n}";var k=t((function(){return Function(R,E+"return "+z).apply(void 0,$)}));if(k.source=z,u(k))throw k;return k}}var Vu,Wu,Ju=lt(Gu());class Hu{config;cache;constructor(r,t=new Map){this.config=r,this.cache=t}get logger(){return this.config.logger}static format(r="",t={}){return Ju(r)(t)}format(r="",t={}){try{return Hu.format(r,t)}catch(n){throw this.logger.error(`Unable to render template with context:\n${r}\n${JSON.stringify(t)}`),this.logger.error(n),n}}exec(r,t={}){const{context:n,...e}=t;return"string"==typeof r?this.execFormattedCommand(this.format(r,n||{}),e):this.execFormattedCommand(r,e)}run(r,t={}){return this.exec(r,{silent:!0,...t})}async execFormattedCommand(r,t={}){const n=this.config.execPromise;if(!n)throw new Error("execPromise is not defined");const{dryRunResult:e,silent:o,dryRun:u,isCache:i}=t,c=void 0!==u?u:this.config.dryRun,a=void 0!==i?!!i:!!this.config.isCache,f="string"==typeof r?r:r.join(" "),s=a&&this.cache.has(f);if(o||this.logger.exec(r,{isCached:s}),c)return Promise.resolve(e);if(s)return this.cache.get(f);const l=n(r,t);return this.cache.has(f)||this.cache.set(f,l),l}}function Ku(){if(Wu)return Vu;Wu=1;var r=Ro(),t=So()((function(t,n,e){r(t,n,e)}));return Vu=t}var Qu=lt(Ku());class Xu extends t{prefix(r){switch(r){case"INFO":return n.blue(r);case"WARN":return n.yellow(r);case"ERROR":return n.red(r);case"DEBUG":return n.gray(r);default:return r}}obtrusive(r){const t=n.bold(r);super.obtrusive(t)}}const Yu=(r,t)=>{const n=Array.isArray(r)?r.join(" "):r;return new Promise(((r,o)=>{e(n,{encoding:"utf-8",...t},((t,n,e)=>{let u;u=t?void 0===t.code?1:t.code:0,0===u?r(n.trim()):o(new Error(e||n))}))}))};function Zu(r){return new ko({name:"fe-config",defaultConfig:Qu({},To,r)})}class ri{logger;shell;feConfig;dryRun;verbose;options;constructor(r){const{logger:t,shell:n,feConfig:e,dryRun:o,verbose:u,options:i}=r||{},c=i||{};this.logger=t||new Xu({debug:u,dryRun:o}),this.shell=n||new Hu({logger:this.logger,dryRun:o,execPromise:c.execPromise||Yu}),this.feConfig=Zu(e).config,this.dryRun=!!o,this.verbose=!!u,this.options=c}}export{ko as ConfigSearch,ri as FeScriptContext,Xu as ScriptsLogger,Hu as Shell,To as defaultFeConfig,Zu as getFeConfigSearch};
|
package/package.json
CHANGED
|
@@ -1,24 +1,26 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@qlover/scripts-context",
|
|
3
3
|
"description": "A scripts context for frontwork",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.14",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"private": false,
|
|
7
7
|
"homepage": "https://github.com/qlover/fe-base/tree/master/packages/scripts-context#readme",
|
|
8
8
|
"author": "qlover",
|
|
9
9
|
"license": "ISC",
|
|
10
|
-
"main": "./dist/
|
|
11
|
-
"module": "./dist/
|
|
12
|
-
"types": "./dist/
|
|
10
|
+
"main": "./dist/index.cjs",
|
|
11
|
+
"module": "./dist/index.js",
|
|
12
|
+
"types": "./dist/index.d.ts",
|
|
13
13
|
"exports": {
|
|
14
|
+
"./package.json": "./package.json",
|
|
14
15
|
".": {
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"
|
|
16
|
+
"types": "./dist/index.d.ts",
|
|
17
|
+
"import": "./dist/index.js",
|
|
18
|
+
"require": "./dist/index.cjs"
|
|
18
19
|
},
|
|
19
|
-
"./
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
"./cli": {
|
|
21
|
+
"import": "./dist/cli.js",
|
|
22
|
+
"require": "./dist/cli.cjs"
|
|
23
|
+
}
|
|
22
24
|
},
|
|
23
25
|
"repository": {
|
|
24
26
|
"type": "git",
|
|
@@ -37,19 +39,19 @@
|
|
|
37
39
|
"publishConfig": {
|
|
38
40
|
"access": "public"
|
|
39
41
|
},
|
|
40
|
-
"scripts": {
|
|
41
|
-
"build": "rollup -c",
|
|
42
|
-
"test": "jest"
|
|
43
|
-
},
|
|
44
42
|
"devDependencies": {
|
|
45
43
|
"@types/shelljs": "^0.8.15",
|
|
46
|
-
"@qlover/
|
|
47
|
-
"@
|
|
44
|
+
"@qlover/env-loader": "^0.0.4",
|
|
45
|
+
"@types/lodash": "^4.17.16",
|
|
46
|
+
"@commitlint/types": "^19.8.0"
|
|
48
47
|
},
|
|
49
48
|
"dependencies": {
|
|
50
|
-
"@qlover/fe-
|
|
49
|
+
"@qlover/fe-corekit": "^1.2.5",
|
|
51
50
|
"chalk": "^5.3.0",
|
|
52
51
|
"cosmiconfig": "^9.0.0",
|
|
53
52
|
"lodash": "^4.17.21"
|
|
53
|
+
},
|
|
54
|
+
"scripts": {
|
|
55
|
+
"build": "rollup -c"
|
|
54
56
|
}
|
|
55
|
-
}
|
|
57
|
+
}
|
package/dist/cjs/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";var r,t,n,e,o,i,u,c,a,f,s,l,p,h,v,g,y,d,b,_,m,O,j,w,R,x,k,P,S,A,E,N,T,C,$,z,B,F,I,M,U,V,D,H,G,L,W,q,Y,J,K,Q,X,Z,rr,tr,nr,er,or,ir,ur,cr,ar,fr,sr,lr,pr,hr,vr,gr,yr,dr,br,_r,mr,Or,jr,wr,Rr,xr,kr,Pr,Sr,Ar,Er,Nr,Tr,Cr,$r,zr,Br,Fr,Ir,Mr,Ur,Vr,Dr,Hr,Gr,Lr,Wr,qr,Yr,Jr,Kr,Qr,Xr,Zr,rt,tt,nt,et,ot,it,ut=require("cosmiconfig"),ct=require("child_process"),at="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function ft(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function st(){if(t)return r;return t=1,r=function(r,t,n){switch(n.length){case 0:return r.call(t);case 1:return r.call(t,n[0]);case 2:return r.call(t,n[0],n[1]);case 3:return r.call(t,n[0],n[1],n[2])}return r.apply(t,n)}}function lt(){if(e)return n;return e=1,n=function(r){return r}}function pt(){if(i)return o;i=1;var r=st(),t=Math.max;return o=function(n,e,o){return e=t(void 0===e?n.length-1:e,0),function(){for(var i=arguments,u=-1,c=t(i.length-e,0),a=Array(c);++u<c;)a[u]=i[e+u];u=-1;for(var f=Array(e+1);++u<e;)f[u]=i[u];return f[e]=o(a),r(n,this,f)}},o}function ht(){if(c)return u;return c=1,u=function(r){return function(){return r}}}function vt(){if(f)return a;f=1;var r="object"==typeof at&&at&&at.Object===Object&&at;return a=r}function gt(){if(l)return s;l=1;var r=vt(),t="object"==typeof self&&self&&self.Object===Object&&self,n=r||t||Function("return this")();return s=n}function yt(){if(h)return p;h=1;var r=gt().Symbol;return p=r}function dt(){if(g)return v;g=1;var r=yt(),t=Object.prototype,n=t.hasOwnProperty,e=t.toString,o=r?r.toStringTag:void 0;return v=function(r){var t=n.call(r,o),i=r[o];try{r[o]=void 0;var u=!0}catch(r){}var c=e.call(r);return u&&(t?r[o]=i:delete r[o]),c}}function bt(){if(d)return y;d=1;var r=Object.prototype.toString;return y=function(t){return r.call(t)}}function _t(){if(_)return b;_=1;var r=yt(),t=dt(),n=bt(),e=r?r.toStringTag:void 0;return b=function(r){return null==r?void 0===r?"[object Undefined]":"[object Null]":e&&e in Object(r)?t(r):n(r)}}function mt(){if(O)return m;return O=1,m=function(r){var t=typeof r;return null!=r&&("object"==t||"function"==t)}}function Ot(){if(w)return j;w=1;var r=_t(),t=mt();return j=function(n){if(!t(n))return!1;var e=r(n);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}}function jt(){if(x)return R;x=1;var r=gt()["__core-js_shared__"];return R=r}function wt(){if(P)return k;P=1;var r,t=jt(),n=(r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";return k=function(r){return!!n&&n in r}}function Rt(){if(A)return S;A=1;var r=Function.prototype.toString;return S=function(t){if(null!=t){try{return r.call(t)}catch(r){}try{return t+""}catch(r){}}return""}}function xt(){if(N)return E;N=1;var r=Ot(),t=wt(),n=mt(),e=Rt(),o=/^\[object .+?Constructor\]$/,i=Function.prototype,u=Object.prototype,c=i.toString,a=u.hasOwnProperty,f=RegExp("^"+c.call(a).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");return E=function(i){return!(!n(i)||t(i))&&(r(i)?f:o).test(e(i))}}function kt(){if(C)return T;return C=1,T=function(r,t){return null==r?void 0:r[t]}}function Pt(){if(z)return $;z=1;var r=xt(),t=kt();return $=function(n,e){var o=t(n,e);return r(o)?o:void 0}}function St(){if(F)return B;F=1;var r=Pt(),t=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(r){}}();return B=t}function At(){if(M)return I;M=1;var r=ht(),t=St();return I=t?function(n,e){return t(n,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:lt()}function Et(){if(V)return U;V=1;var r=Date.now;return U=function(t){var n=0,e=0;return function(){var o=r(),i=16-(o-e);if(e=o,i>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},U}function Nt(){if(H)return D;H=1;var r=At(),t=Et()(r);return D=t}function Tt(){if(L)return G;L=1;var r=lt(),t=pt(),n=Nt();return G=function(e,o){return n(t(e,o,r),e+"")}}function Ct(){if(q)return W;return q=1,W=function(){this.__data__=[],this.size=0}}function $t(){if(J)return Y;return J=1,Y=function(r,t){return r===t||r!=r&&t!=t}}function zt(){if(Q)return K;Q=1;var r=$t();return K=function(t,n){for(var e=t.length;e--;)if(r(t[e][0],n))return e;return-1}}function Bt(){if(Z)return X;Z=1;var r=zt(),t=Array.prototype.splice;return X=function(n){var e=this.__data__,o=r(e,n);return!(o<0)&&(o==e.length-1?e.pop():t.call(e,o,1),--this.size,!0)}}function Ft(){if(tr)return rr;tr=1;var r=zt();return rr=function(t){var n=this.__data__,e=r(n,t);return e<0?void 0:n[e][1]}}function It(){if(er)return nr;er=1;var r=zt();return nr=function(t){return r(this.__data__,t)>-1}}function Mt(){if(ir)return or;ir=1;var r=zt();return or=function(t,n){var e=this.__data__,o=r(e,t);return o<0?(++this.size,e.push([t,n])):e[o][1]=n,this}}function Ut(){if(cr)return ur;cr=1;var r=Ct(),t=Bt(),n=Ft(),e=It(),o=Mt();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,ur=i}function Vt(){if(fr)return ar;fr=1;var r=Ut();return ar=function(){this.__data__=new r,this.size=0}}function Dt(){if(lr)return sr;return lr=1,sr=function(r){var t=this.__data__,n=t.delete(r);return this.size=t.size,n}}function Ht(){if(hr)return pr;return hr=1,pr=function(r){return this.__data__.get(r)}}function Gt(){if(gr)return vr;return gr=1,vr=function(r){return this.__data__.has(r)}}function Lt(){if(dr)return yr;dr=1;var r=Pt()(gt(),"Map");return yr=r}function Wt(){if(_r)return br;_r=1;var r=Pt()(Object,"create");return br=r}function qt(){if(Or)return mr;Or=1;var r=Wt();return mr=function(){this.__data__=r?r(null):{},this.size=0}}function Yt(){if(wr)return jr;return wr=1,jr=function(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}}function Jt(){if(xr)return Rr;xr=1;var r=Wt(),t=Object.prototype.hasOwnProperty;return Rr=function(n){var e=this.__data__;if(r){var o=e[n];return"__lodash_hash_undefined__"===o?void 0:o}return t.call(e,n)?e[n]:void 0}}function Kt(){if(Pr)return kr;Pr=1;var r=Wt(),t=Object.prototype.hasOwnProperty;return kr=function(n){var e=this.__data__;return r?void 0!==e[n]:t.call(e,n)}}function Qt(){if(Ar)return Sr;Ar=1;var r=Wt();return Sr=function(t,n){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=r&&void 0===n?"__lodash_hash_undefined__":n,this}}function Xt(){if(Nr)return Er;Nr=1;var r=qt(),t=Yt(),n=Jt(),e=Kt(),o=Qt();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,Er=i}function Zt(){if(Cr)return Tr;Cr=1;var r=Xt(),t=Ut(),n=Lt();return Tr=function(){this.size=0,this.__data__={hash:new r,map:new(n||t),string:new r}}}function rn(){if(zr)return $r;return zr=1,$r=function(r){var t=typeof r;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==r:null===r}}function tn(){if(Fr)return Br;Fr=1;var r=rn();return Br=function(t,n){var e=t.__data__;return r(n)?e["string"==typeof n?"string":"hash"]:e.map}}function nn(){if(Mr)return Ir;Mr=1;var r=tn();return Ir=function(t){var n=r(this,t).delete(t);return this.size-=n?1:0,n}}function en(){if(Vr)return Ur;Vr=1;var r=tn();return Ur=function(t){return r(this,t).get(t)}}function on(){if(Hr)return Dr;Hr=1;var r=tn();return Dr=function(t){return r(this,t).has(t)}}function un(){if(Lr)return Gr;Lr=1;var r=tn();return Gr=function(t,n){var e=r(this,t),o=e.size;return e.set(t,n),this.size+=e.size==o?0:1,this}}function cn(){if(qr)return Wr;qr=1;var r=Zt(),t=nn(),n=en(),e=on(),o=un();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,Wr=i}function an(){if(Jr)return Yr;Jr=1;var r=Ut(),t=Lt(),n=cn();return Yr=function(e,o){var i=this.__data__;if(i instanceof r){var u=i.__data__;if(!t||u.length<199)return u.push([e,o]),this.size=++i.size,this;i=this.__data__=new n(u)}return i.set(e,o),this.size=i.size,this}}function fn(){if(Qr)return Kr;Qr=1;var r=Ut(),t=Vt(),n=Dt(),e=Ht(),o=Gt(),i=an();function u(t){var n=this.__data__=new r(t);this.size=n.size}return u.prototype.clear=t,u.prototype.delete=n,u.prototype.get=e,u.prototype.has=o,u.prototype.set=i,Kr=u}function sn(){if(Zr)return Xr;Zr=1;var r=St();return Xr=function(t,n,e){"__proto__"==n&&r?r(t,n,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[n]=e}}function ln(){if(tt)return rt;tt=1;var r=sn(),t=$t();return rt=function(n,e,o){(void 0!==o&&!t(n[e],o)||void 0===o&&!(e in n))&&r(n,e,o)}}function pn(){if(et)return nt;return et=1,nt=function(r){return function(t,n,e){for(var o=-1,i=Object(t),u=e(t),c=u.length;c--;){var a=u[r?c:++o];if(!1===n(i[a],a,i))break}return t}}}function hn(){if(it)return ot;it=1;var r=pn()();return ot=r}var vn,gn,yn,dn,bn,_n,mn,On,jn,wn,Rn,xn,kn,Pn,Sn,An,En,Nn,Tn,Cn,$n,zn,Bn,Fn,In,Mn,Un,Vn,Dn,Hn,Gn,Ln,Wn,qn={exports:{}};function Yn(){return vn||(vn=1,function(r,t){var n=gt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,i=o&&o.exports===e?n.Buffer:void 0,u=i?i.allocUnsafe:void 0;r.exports=function(r,t){if(t)return r.slice();var n=r.length,e=u?u(n):new r.constructor(n);return r.copy(e),e}}(qn,qn.exports)),qn.exports}function Jn(){if(yn)return gn;yn=1;var r=gt().Uint8Array;return gn=r}function Kn(){if(bn)return dn;bn=1;var r=Jn();return dn=function(t){var n=new t.constructor(t.byteLength);return new r(n).set(new r(t)),n}}function Qn(){if(mn)return _n;mn=1;var r=Kn();return _n=function(t,n){var e=n?r(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.length)}}function Xn(){if(jn)return On;return jn=1,On=function(r,t){var n=-1,e=r.length;for(t||(t=Array(e));++n<e;)t[n]=r[n];return t}}function Zn(){if(Rn)return wn;Rn=1;var r=mt(),t=Object.create,n=function(){function n(){}return function(e){if(!r(e))return{};if(t)return t(e);n.prototype=e;var o=new n;return n.prototype=void 0,o}}();return wn=n}function re(){if(kn)return xn;return kn=1,xn=function(r,t){return function(n){return r(t(n))}}}function te(){if(Sn)return Pn;Sn=1;var r=re()(Object.getPrototypeOf,Object);return Pn=r}function ne(){if(En)return An;En=1;var r=Object.prototype;return An=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||r)}}function ee(){if(Tn)return Nn;Tn=1;var r=Zn(),t=te(),n=ne();return Nn=function(e){return"function"!=typeof e.constructor||n(e)?{}:r(t(e))}}function oe(){if($n)return Cn;return $n=1,Cn=function(r){return null!=r&&"object"==typeof r}}function ie(){if(Bn)return zn;Bn=1;var r=_t(),t=oe();return zn=function(n){return t(n)&&"[object Arguments]"==r(n)}}function ue(){if(In)return Fn;In=1;var r=ie(),t=oe(),n=Object.prototype,e=n.hasOwnProperty,o=n.propertyIsEnumerable,i=r(function(){return arguments}())?r:function(r){return t(r)&&e.call(r,"callee")&&!o.call(r,"callee")};return Fn=i}function ce(){if(Un)return Mn;Un=1;var r=Array.isArray;return Mn=r}function ae(){if(Dn)return Vn;Dn=1;return Vn=function(r){return"number"==typeof r&&r>-1&&r%1==0&&r<=9007199254740991}}function fe(){if(Gn)return Hn;Gn=1;var r=Ot(),t=ae();return Hn=function(n){return null!=n&&t(n.length)&&!r(n)}}function se(){if(Wn)return Ln;Wn=1;var r=fe(),t=oe();return Ln=function(n){return t(n)&&r(n)}}var le,pe,he,ve,ge,ye,de,be,_e,me={exports:{}};function Oe(){if(pe)return le;return pe=1,le=function(){return!1}}function je(){return he||(he=1,function(r,t){var n=gt(),e=Oe(),o=t&&!t.nodeType&&t,i=o&&r&&!r.nodeType&&r,u=i&&i.exports===o?n.Buffer:void 0,c=(u?u.isBuffer:void 0)||e;r.exports=c}(me,me.exports)),me.exports}function we(){if(ge)return ve;ge=1;var r=_t(),t=te(),n=oe(),e=Function.prototype,o=Object.prototype,i=e.toString,u=o.hasOwnProperty,c=i.call(Object);return ve=function(e){if(!n(e)||"[object Object]"!=r(e))return!1;var o=t(e);if(null===o)return!0;var a=u.call(o,"constructor")&&o.constructor;return"function"==typeof a&&a instanceof a&&i.call(a)==c},ve}function Re(){if(de)return ye;de=1;var r=_t(),t=ae(),n=oe(),e={};return e["[object Float32Array]"]=e["[object Float64Array]"]=e["[object Int8Array]"]=e["[object Int16Array]"]=e["[object Int32Array]"]=e["[object Uint8Array]"]=e["[object Uint8ClampedArray]"]=e["[object Uint16Array]"]=e["[object Uint32Array]"]=!0,e["[object Arguments]"]=e["[object Array]"]=e["[object ArrayBuffer]"]=e["[object Boolean]"]=e["[object DataView]"]=e["[object Date]"]=e["[object Error]"]=e["[object Function]"]=e["[object Map]"]=e["[object Number]"]=e["[object Object]"]=e["[object RegExp]"]=e["[object Set]"]=e["[object String]"]=e["[object WeakMap]"]=!1,ye=function(o){return n(o)&&t(o.length)&&!!e[r(o)]}}function xe(){if(_e)return be;return _e=1,be=function(r){return function(t){return r(t)}}}var ke,Pe,Se,Ae,Ee,Ne,Te,Ce,$e,ze,Be,Fe,Ie,Me,Ue,Ve,De,He,Ge,Le,We,qe,Ye,Je,Ke,Qe,Xe,Ze,ro,to,no,eo,oo,io,uo,co,ao,fo={exports:{}};function so(){return ke||(ke=1,function(r,t){var n=vt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,i=o&&o.exports===e&&n.process,u=function(){try{var r=o&&o.require&&o.require("util").types;return r||i&&i.binding&&i.binding("util")}catch(r){}}();r.exports=u}(fo,fo.exports)),fo.exports}function lo(){if(Se)return Pe;Se=1;var r=Re(),t=xe(),n=so(),e=n&&n.isTypedArray,o=e?t(e):r;return Pe=o}function po(){if(Ee)return Ae;return Ee=1,Ae=function(r,t){if(("constructor"!==t||"function"!=typeof r[t])&&"__proto__"!=t)return r[t]}}function ho(){if(Te)return Ne;Te=1;var r=sn(),t=$t(),n=Object.prototype.hasOwnProperty;return Ne=function(e,o,i){var u=e[o];n.call(e,o)&&t(u,i)&&(void 0!==i||o in e)||r(e,o,i)}}function vo(){if($e)return Ce;$e=1;var r=ho(),t=sn();return Ce=function(n,e,o,i){var u=!o;o||(o={});for(var c=-1,a=e.length;++c<a;){var f=e[c],s=i?i(o[f],n[f],f,o,n):void 0;void 0===s&&(s=n[f]),u?t(o,f,s):r(o,f,s)}return o}}function go(){if(Be)return ze;return Be=1,ze=function(r,t){for(var n=-1,e=Array(r);++n<r;)e[n]=t(n);return e},ze}function yo(){if(Ie)return Fe;Ie=1;var r=/^(?:0|[1-9]\d*)$/;return Fe=function(t,n){var e=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==e||"symbol"!=e&&r.test(t))&&t>-1&&t%1==0&&t<n}}function bo(){if(Ue)return Me;Ue=1;var r=go(),t=ue(),n=ce(),e=je(),o=yo(),i=lo(),u=Object.prototype.hasOwnProperty;return Me=function(c,a){var f=n(c),s=!f&&t(c),l=!f&&!s&&e(c),p=!f&&!s&&!l&&i(c),h=f||s||l||p,v=h?r(c.length,String):[],g=v.length;for(var y in c)!a&&!u.call(c,y)||h&&("length"==y||l&&("offset"==y||"parent"==y)||p&&("buffer"==y||"byteLength"==y||"byteOffset"==y)||o(y,g))||v.push(y);return v}}function _o(){if(De)return Ve;return De=1,Ve=function(r){var t=[];if(null!=r)for(var n in Object(r))t.push(n);return t}}function mo(){if(Ge)return He;Ge=1;var r=mt(),t=ne(),n=_o(),e=Object.prototype.hasOwnProperty;return He=function(o){if(!r(o))return n(o);var i=t(o),u=[];for(var c in o)("constructor"!=c||!i&&e.call(o,c))&&u.push(c);return u}}function Oo(){if(We)return Le;We=1;var r=bo(),t=mo(),n=fe();return Le=function(e){return n(e)?r(e,!0):t(e)}}function jo(){if(Ye)return qe;Ye=1;var r=vo(),t=Oo();return qe=function(n){return r(n,t(n))}}function wo(){if(Ke)return Je;Ke=1;var r=ln(),t=Yn(),n=Qn(),e=Xn(),o=ee(),i=ue(),u=ce(),c=se(),a=je(),f=Ot(),s=mt(),l=we(),p=lo(),h=po(),v=jo();return Je=function(g,y,d,b,_,m,O){var j=h(g,d),w=h(y,d),R=O.get(w);if(R)r(g,d,R);else{var x=m?m(j,w,d+"",g,y,O):void 0,k=void 0===x;if(k){var P=u(w),S=!P&&a(w),A=!P&&!S&&p(w);x=w,P||S||A?u(j)?x=j:c(j)?x=e(j):S?(k=!1,x=t(w,!0)):A?(k=!1,x=n(w,!0)):x=[]:l(w)||i(w)?(x=j,i(j)?x=v(j):s(j)&&!f(j)||(x=o(w))):k=!1}k&&(O.set(w,x),_(x,w,b,m,O),O.delete(w)),r(g,d,x)}}}function Ro(){if(Xe)return Qe;Xe=1;var r=fn(),t=ln(),n=hn(),e=wo(),o=mt(),i=Oo(),u=po();return Qe=function c(a,f,s,l,p){a!==f&&n(f,(function(n,i){if(p||(p=new r),o(n))e(a,f,i,s,c,l,p);else{var h=l?l(u(a,i),n,i+"",a,f,p):void 0;void 0===h&&(h=n),t(a,i,h)}}),i)},Qe}function xo(){if(ro)return Ze;ro=1;var r=Ro(),t=mt();return Ze=function n(e,o,i,u,c,a){return t(e)&&t(o)&&(a.set(o,e),r(e,o,void 0,n,a),a.delete(o)),e},Ze}function ko(){if(no)return to;no=1;var r=$t(),t=fe(),n=yo(),e=mt();return to=function(o,i,u){if(!e(u))return!1;var c=typeof i;return!!("number"==c?t(u)&&n(i,u.length):"string"==c&&i in u)&&r(u[i],o)}}function Po(){if(oo)return eo;oo=1;var r=Tt(),t=ko();return eo=function(n){return r((function(r,e){var o=-1,i=e.length,u=i>1?e[i-1]:void 0,c=i>2?e[2]:void 0;for(u=n.length>3&&"function"==typeof u?(i--,u):void 0,c&&t(e[0],e[1],c)&&(u=i<3?void 0:u,i=1),r=Object(r);++o<i;){var a=e[o];a&&n(r,a,o,u)}return r}))}}function So(){if(uo)return io;uo=1;var r=Ro(),t=Po()((function(t,n,e,o){r(t,n,e,o)}));return io=t}function Ao(){if(ao)return co;ao=1;var r=st(),t=Tt(),n=xo(),e=So(),o=t((function(t){return t.push(void 0,n),r(e,void 0,t)}));return co=o}var Eo=ft(Ao()),No=ft(we());class To{name;searchPlaces;_config;loaders;searchCache;constructor(r){const{name:t,searchPlaces:n,defaultConfig:e,loaders:o}=r;if(!t&&!n)throw new Error("searchPlaces or name is required");this.name=t,this.searchPlaces=n||function(r){const t=["json","js","ts","cjs","yaml","yml"];return["package.json",...t.map((t=>`${r}.${t}`)),...t.map((t=>`.${r}.${t}`))]}(t),this._config=e||{},this.loaders=o}get config(){return Eo({},this.search(),this._config)}getSearchPlaces(){return this.searchPlaces}get(r={}){const{file:t,dir:n=process.cwd()}=r,e={};if(!1===t)return e;const o=ut.cosmiconfigSync(this.name,{searchPlaces:this.searchPlaces,loaders:this.loaders}),i=t?o.load(t):o.search(n);if(i&&"string"==typeof i.config)throw new Error(`Invalid configuration file at ${i.filepath}`);return i&&No(i.config)?i.config:e}search(){return this.searchCache?this.searchCache:this.searchCache=this.get({})}}const Co={protectedBranches:["master","develop","main"],cleanFiles:["dist","node_modules","yarn.lock","package-lock.json",".eslintcache","*.log"],commitlint:{extends:["@commitlint/config-conventional"]},release:{publishPath:"",autoMergeReleasePR:!1,autoMergeType:"squash",branchName:"release-${pkgName}-${tagName}",PRTitle:"[${pkgName} Release] Branch:${branch}, Tag:${tagName}, Env:${env}",PRBody:"## Publish Details\n\n- 🏷️ Version: ${tagName}\n- 🌲 Branch: ${branch}\n- 🔧 Environment: ${env}\n\n## Changelog\n\n${changelog}\n\n## Notes\n\n- [ ] Please check if the version number is correct\n- [ ] Please confirm all tests have passed\n- [ ] Please confirm the documentation has been updated\n\n> This PR is auto created by release process, please contact the frontend team if there are any questions.",label:{color:"1A7F37",description:"Release PR",name:"CI-Release"},packagesDirectories:[],changePackagesLabel:"changes:${name}"},envOrder:[".env.local",".env.production",".env"]};var $o,zo,Bo,Fo,Io,Mo,Uo,Vo,Do,Ho,Go,Lo,Wo,qo,Yo,Jo,Ko,Qo,Xo,Zo,ri,ti,ni,ei,oi,ii,ui,ci,ai,fi,si,li,pi,hi,vi,gi,yi,di,bi,_i,mi,Oi;function ji(){if(zo)return $o;zo=1;var r=vo(),t=Po(),n=Oo(),e=t((function(t,e,o,i){r(e,n(e),t,i)}));return $o=e}function wi(){if(Fo)return Bo;Fo=1;var r=_t(),t=oe(),n=we();return Bo=function(e){if(!t(e))return!1;var o=r(e);return"[object Error]"==o||"[object DOMException]"==o||"string"==typeof e.message&&"string"==typeof e.name&&!n(e)}}function Ri(){if(Mo)return Io;Mo=1;var r=st(),t=Tt(),n=wi(),e=t((function(t,e){try{return r(t,void 0,e)}catch(r){return n(r)?r:new Error(r)}}));return Io=e}function xi(){if(Vo)return Uo;return Vo=1,Uo=function(r,t){for(var n=-1,e=null==r?0:r.length,o=Array(e);++n<e;)o[n]=t(r[n],n,r);return o}}function ki(){if(Ho)return Do;Ho=1;var r=xi();return Do=function(t,n){return r(n,(function(r){return t[r]}))}}function Pi(){if(Lo)return Go;Lo=1;var r=$t(),t=Object.prototype,n=t.hasOwnProperty;return Go=function(e,o,i,u){return void 0===e||r(e,t[i])&&!n.call(u,i)?o:e}}function Si(){if(qo)return Wo;qo=1;var r={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};return Wo=function(t){return"\\"+r[t]}}function Ai(){if(Jo)return Yo;Jo=1;var r=re()(Object.keys,Object);return Yo=r}function Ei(){if(Qo)return Ko;Qo=1;var r=ne(),t=Ai(),n=Object.prototype.hasOwnProperty;return Ko=function(e){if(!r(e))return t(e);var o=[];for(var i in Object(e))n.call(e,i)&&"constructor"!=i&&o.push(i);return o}}function Ni(){if(Zo)return Xo;Zo=1;var r=bo(),t=Ei(),n=fe();return Xo=function(e){return n(e)?r(e):t(e)}}function Ti(){if(ti)return ri;ti=1;return ri=/<%=([\s\S]+?)%>/g}function Ci(){if(ei)return ni;return ei=1,ni=function(r){return function(t){return null==r?void 0:r[t]}}}function $i(){if(ii)return oi;ii=1;var r=Ci()({"&":"&","<":"<",">":">",'"':""","'":"'"});return oi=r}function zi(){if(ci)return ui;ci=1;var r=_t(),t=oe();return ui=function(n){return"symbol"==typeof n||t(n)&&"[object Symbol]"==r(n)}}function Bi(){if(fi)return ai;fi=1;var r=yt(),t=xi(),n=ce(),e=zi(),o=r?r.prototype:void 0,i=o?o.toString:void 0;return ai=function r(o){if("string"==typeof o)return o;if(n(o))return t(o,r)+"";if(e(o))return i?i.call(o):"";var u=o+"";return"0"==u&&1/o==-1/0?"-0":u},ai}function Fi(){if(li)return si;li=1;var r=Bi();return si=function(t){return null==t?"":r(t)}}function Ii(){if(hi)return pi;hi=1;var r=$i(),t=Fi(),n=/[&<>"']/g,e=RegExp(n.source);return pi=function(o){return(o=t(o))&&e.test(o)?o.replace(n,r):o}}function Mi(){if(gi)return vi;gi=1;return vi=/<%-([\s\S]+?)%>/g}function Ui(){if(di)return yi;di=1;return yi=/<%([\s\S]+?)%>/g}function Vi(){if(_i)return bi;_i=1;var r=Ii();return bi={escape:Mi(),evaluate:Ui(),interpolate:Ti(),variable:"",imports:{_:{escape:r}}}}function Di(){if(Oi)return mi;Oi=1;var r=ji(),t=Ri(),n=ki(),e=Pi(),o=Si(),i=wi(),u=ko(),c=Ni(),a=Ti(),f=Vi(),s=Fi(),l=/\b__p \+= '';/g,p=/\b(__p \+=) '' \+/g,h=/(__e\(.*?\)|\b__t\)) \+\n'';/g,v=/[()=,{}\[\]\/\s]/,g=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,y=/($^)/,d=/['\n\r\u2028\u2029\\]/g,b=Object.prototype.hasOwnProperty;return mi=function(_,m,O){var j=f.imports._.templateSettings||f;O&&u(_,m,O)&&(m=void 0),_=s(_),m=r({},m,j,e);var w,R,x=r({},m.imports,j.imports,e),k=c(x),P=n(x,k),S=0,A=m.interpolate||y,E="__p += '",N=RegExp((m.escape||y).source+"|"+A.source+"|"+(A===a?g:y).source+"|"+(m.evaluate||y).source+"|$","g"),T=b.call(m,"sourceURL")?"//# sourceURL="+(m.sourceURL+"").replace(/\s/g," ")+"\n":"";_.replace(N,(function(r,t,n,e,i,u){return n||(n=e),E+=_.slice(S,u).replace(d,o),t&&(w=!0,E+="' +\n__e("+t+") +\n'"),i&&(R=!0,E+="';\n"+i+";\n__p += '"),n&&(E+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),S=u+r.length,r})),E+="';\n";var C=b.call(m,"variable")&&m.variable;if(C){if(v.test(C))throw new Error("Invalid `variable` option passed into `_.template`")}else E="with (obj) {\n"+E+"\n}\n";E=(R?E.replace(l,""):E).replace(p,"$1").replace(h,"$1;"),E="function("+(C||"obj")+") {\n"+(C?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(w?", __e = _.escape":"")+(R?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+E+"return __p\n}";var $=t((function(){return Function(k,T+"return "+E).apply(void 0,P)}));if($.source=E,i($))throw $;return $}}var Hi,Gi,Li=ft(Di());class Wi{config;cache;constructor(r,t=new Map){this.config=r,this.cache=t}get logger(){return this.config.logger}static format(r="",t={}){return Li(r)(t)}format(r="",t={}){try{return Wi.format(r,t)}catch(n){throw this.logger.error(`Unable to render template with context:\n${r}\n${JSON.stringify(t)}`),this.logger.error(n),n}}exec(r,t={}){const{context:n,...e}=t;return"string"==typeof r?this.execFormattedCommand(this.format(r,n||{}),e):this.execFormattedCommand(r,e)}run(r,t={}){return this.exec(r,{silent:!0,...t})}async execFormattedCommand(r,t={}){const n=this.config.execPromise;if(!n)throw new Error("execPromise is not defined");const{dryRunResult:e,silent:o,dryRun:i,isCache:u}=t,c=void 0!==i?i:this.config.dryRun,a=void 0!==u?!!u:!!this.config.isCache,f="string"==typeof r?r:r.join(" "),s=a&&this.cache.has(f);if(o||this.logger.exec(r,{isCached:s}),c)return Promise.resolve(e);if(s)return this.cache.get(f);const l=n(r,t);return this.cache.has(f)||this.cache.set(f,l),l}}function qi(){if(Gi)return Hi;Gi=1;var r=Ro(),t=Po()((function(t,n,e){r(t,n,e)}));return Hi=t}var Yi=ft(qi()),Ji=function(){function r(r){this.config=r,this.plugins=[]}return r.prototype.use=function(r){this.plugins.find((function(t){return t===r||t.pluginName===r.pluginName||t.constructor===r.constructor}))&&r.onlyOne?console.warn("Plugin ".concat(r.pluginName," is already used, skip adding")):this.plugins.push(r)},r}(),Ki=function(r,t){return Ki=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,t){r.__proto__=t}||function(r,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])},Ki(r,t)};function Qi(r,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=r}Ki(r,t),r.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}function Xi(r,t,n,e){return new(n||(n=Promise))((function(t,o){function i(r){try{c(e.next(r))}catch(r){o(r)}}function u(r){try{c(e.throw(r))}catch(r){o(r)}}function c(r){var e;r.done?t(r.value):(e=r.value,e instanceof n?e:new n((function(r){r(e)}))).then(i,u)}c((e=e.apply(r,[])).next())}))}function Zi(r,t){var n,e,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},u=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return u.next=c(0),u.throw=c(1),u.return=c(2),"function"==typeof Symbol&&(u[Symbol.iterator]=function(){return this}),u;function c(c){return function(a){return function(c){if(n)throw new TypeError("Generator is already executing.");for(;u&&(u=0,c[0]&&(i=0)),i;)try{if(n=1,e&&(o=2&c[0]?e.return:c[0]?e.throw||((o=e.return)&&o.call(e),0):e.next)&&!(o=o.call(e,c[1])).done)return o;switch(e=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,e=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!((o=(o=i.trys).length>0&&o[o.length-1])||6!==c[0]&&2!==c[0])){i=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){i.label=c[1];break}if(6===c[0]&&i.label<o[1]){i.label=o[1],o=c;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(c);break}o[2]&&i.ops.pop(),i.trys.pop();continue}c=t.call(r,i)}catch(r){c=[6,r],e=0}finally{n=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([c,a])}}}function ru(r,t,n){if(2===arguments.length)for(var e,o=0,i=t.length;o<i;o++)!e&&o in t||(e||(e=Array.prototype.slice.call(t,0,o)),e[o]=t[o]);return r.concat(e||Array.prototype.slice.call(t))}"function"==typeof SuppressedError&&SuppressedError;var tu,nu,eu,ou,iu,uu=function(r){function t(t,n){var e=this.constructor,o=r.call(this,n instanceof Error?n.message:n||t)||this;return o.id=t,n instanceof Error&&"stack"in n&&(o.stack=n.stack),Object.setPrototypeOf(o,e.prototype),o}return Qi(t,r),t}(Error);!function(r){function t(){return null!==r&&r.apply(this,arguments)||this}Qi(t,r)}(uu),function(r){r.REQUEST_ERROR="REQUEST_ERROR",r.ENV_FETCH_NOT_SUPPORT="ENV_FETCH_NOT_SUPPORT",r.FETCHER_NONE="FETCHER_NONE",r.RESPONSE_NOT_OK="RESPONSE_NOT_OK",r.ABORT_ERROR="ABORT_ERROR",r.URL_NONE="URL_NONE"}(tu||(tu={})),function(r){function t(){return null!==r&&r.apply(this,arguments)||this}Qi(t,r),t.prototype.runHooks=function(r,t,n){for(var e=[],o=3;o<arguments.length;o++)e[o-3]=arguments[o];return Xi(this,0,void 0,(function(){var o,i,u,c,a,f,s,l;return Zi(this,(function(p){switch(p.label){case 0:o=-1,(u=n||{parameters:void 0,hooksRuntimes:{}}).hooksRuntimes.times=0,u.hooksRuntimes.index=void 0,c=0,a=r,p.label=1;case 1:return c<a.length?(f=a[c],o++,"function"!=typeof f[t]||"function"==typeof f.enabled&&!f.enabled(t,n)?[3,3]:(null===(l=u.hooksRuntimes)||void 0===l?void 0:l.breakChain)?[3,4]:(u.hooksRuntimes.pluginName=f.pluginName,u.hooksRuntimes.hookName=t,u.hooksRuntimes.times++,u.hooksRuntimes.index=o,[4,f[t].apply(f,ru([n],e,!1))])):[3,4];case 2:if(void 0!==(s=p.sent())&&(i=s,u.hooksRuntimes.returnValue=s,u.hooksRuntimes.returnBreakChain))return[2,i];p.label=3;case 3:return c++,[3,1];case 4:return[2,i]}}))}))},t.prototype.execNoError=function(r,t){return Xi(this,0,void 0,(function(){var n;return Zi(this,(function(e){switch(e.label){case 0:return e.trys.push([0,2,,3]),[4,this.exec(r,t)];case 1:return[2,e.sent()];case 2:return(n=e.sent())instanceof uu?[2,n]:[2,new uu("UNKNOWN_ASYNC_ERROR",n)];case 3:return[2]}}))}))},t.prototype.exec=function(r,t){var n=t||r,e=t?r:void 0;if("function"!=typeof n)throw new Error("Task must be a async function!");return this.run(e,n)},t.prototype.run=function(r,t){return Xi(this,0,void 0,(function(){var n,e,o,i=this;return Zi(this,(function(u){switch(u.label){case 0:n={parameters:r,returnValue:void 0,error:void 0,hooksRuntimes:{pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0}},e=function(r){return Xi(i,0,void 0,(function(){var n;return Zi(this,(function(e){switch(e.label){case 0:return[4,this.runHooks(this.plugins,"onExec",r,t)];case 1:return e.sent(),0!==r.hooksRuntimes.times?[3,3]:(n=r,[4,t(r)]);case 2:return n.returnValue=e.sent(),[2];case 3:return r.returnValue=r.hooksRuntimes.returnValue,[2]}}))}))},u.label=1;case 1:return u.trys.push([1,5,7,8]),[4,this.runHooks(this.plugins,"onBefore",n)];case 2:return u.sent(),[4,e(n)];case 3:return u.sent(),[4,this.runHooks(this.plugins,"onSuccess",n)];case 4:return u.sent(),[2,n.returnValue];case 5:return o=u.sent(),n.error=o,[4,this.runHooks(this.plugins,"onError",n)];case 6:if(u.sent(),n.hooksRuntimes.returnValue&&(n.error=n.hooksRuntimes.returnValue),n.error instanceof uu)throw n.error;throw new uu("UNKNOWN_ASYNC_ERROR",n.error);case 7:return n.hooksRuntimes={pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0},[7];case 8:return[2]}}))}))}}(Ji),function(r){function t(){return null!==r&&r.apply(this,arguments)||this}Qi(t,r),t.prototype.runHooks=function(r,t,n){for(var e,o=[],i=3;i<arguments.length;i++)o[i-3]=arguments[i];var u,c=-1,a=n||{parameters:void 0,hooksRuntimes:{}};a.hooksRuntimes.times=0,a.hooksRuntimes.index=void 0;for(var f=0,s=r;f<s.length;f++){var l=s[f];if(c++,"function"==typeof l[t]&&("function"!=typeof l.enabled||l.enabled(t,a))){if(null===(e=a.hooksRuntimes)||void 0===e?void 0:e.breakChain)break;a.hooksRuntimes.pluginName=l.pluginName,a.hooksRuntimes.hookName=t,a.hooksRuntimes.times++,a.hooksRuntimes.index=c;var p=l[t].apply(l,ru([n],o,!1));if(void 0!==p&&(u=p,a.hooksRuntimes.returnValue=p,a.hooksRuntimes.returnBreakChain))return u}}return u},t.prototype.execNoError=function(r,t){try{return this.exec(r,t)}catch(r){return r instanceof uu?r:new uu("UNKNOWN_SYNC_ERROR",r)}},t.prototype.exec=function(r,t){var n=t||r,e=t?r:void 0;if("function"!=typeof n)throw new Error("Task must be a function!");return this.run(e,n)},t.prototype.run=function(r,t){var n,e={parameters:r,returnValue:void 0,error:void 0,hooksRuntimes:{pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0}};try{return this.runHooks(this.plugins,"onBefore",e),n=e,this.runHooks(this.plugins,"onExec",n,t),n.returnValue=n.hooksRuntimes.times?n.hooksRuntimes.returnValue:t(n),this.runHooks(this.plugins,"onSuccess",e),e.returnValue}catch(r){if(e.error=r,this.runHooks(this.plugins,"onError",e),e.hooksRuntimes.returnValue&&(e.error=e.hooksRuntimes.returnValue),e.error instanceof uu)throw e.error;throw new uu("UNKNOWN_SYNC_ERROR",e.error)}finally{e.hooksRuntimes={pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0}}}}(Ji);var cu="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function au(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var fu,su,lu,pu,hu,vu,gu,yu,du,bu,_u,mu,Ou,ju,wu,Ru,xu,ku,Pu,Su,Au,Eu,Nu=au(iu?ou:(iu=1,ou=eu?nu:(eu=1,nu=function(r){return r&&r.length?r[0]:void 0}))),Tu=au(su?fu:(su=1,fu=function(r){var t=null==r?0:r.length;return t?r[t-1]:void 0}));function Cu(){if(vu)return hu;vu=1;var r=function(){if(pu)return lu;pu=1;var r="object"==typeof cu&&cu&&cu.Object===Object&&cu;return lu=r}(),t="object"==typeof self&&self&&self.Object===Object&&self,n=r||t||Function("return this")();return hu=n}function $u(){if(yu)return gu;yu=1;var r=Cu().Symbol;return gu=r}function zu(){if(ju)return Ou;ju=1;var r=$u(),t=function(){if(bu)return du;bu=1;var r=$u(),t=Object.prototype,n=t.hasOwnProperty,e=t.toString,o=r?r.toStringTag:void 0;return du=function(r){var t=n.call(r,o),i=r[o];try{r[o]=void 0;var u=!0}catch(r){}var c=e.call(r);return u&&(t?r[o]=i:delete r[o]),c}}(),n=function(){if(mu)return _u;mu=1;var r=Object.prototype.toString;return _u=function(t){return r.call(t)}}(),e=r?r.toStringTag:void 0;return Ou=function(r){return null==r?void 0===r?"[object Undefined]":"[object Null]":e&&e in Object(r)?t(r):n(r)}}function Bu(){return Su?Pu:(Su=1,Pu=function(r){return null!=r&&"object"==typeof r})}var Fu,Iu,Mu,Uu,Vu=au(function(){if(Eu)return Au;Eu=1;var r=zu(),t=function(){if(ku)return xu;ku=1;var r=(Ru?wu:(Ru=1,wu=function(r,t){return function(n){return r(t(n))}}))(Object.getPrototypeOf,Object);return xu=r}(),n=Bu(),e=Function.prototype,o=Object.prototype,i=e.toString,u=o.hasOwnProperty,c=i.call(Object);return Au=function(e){if(!n(e)||"[object Object]"!=r(e))return!1;var o=t(e);if(null===o)return!0;var a=u.call(o,"constructor")&&o.constructor;return"function"==typeof a&&a instanceof a&&i.call(a)==c}}());function Du(){if(Iu)return Fu;Iu=1;var r=Array.isArray;return Fu=r}var Hu,Gu,Lu=function(){if(Uu)return Mu;Uu=1;var r=zu(),t=Du(),n=Bu();return Mu=function(e){return"string"==typeof e||!t(e)&&n(e)&&"[object String]"==r(e)}}(),Wu=au(Lu),qu=au(Du());function Yu(){return Gu?Hu:(Gu=1,Hu=function(r){var t=typeof r;return null!=r&&("object"==t||"function"==t)})}var Ju,Ku,Qu,Xu,Zu,rc,tc,nc,ec,oc,ic,uc,cc,ac,fc,sc,lc,pc,hc,vc,gc,yc,dc,bc,_c,mc,Oc,jc,wc,Rc,xc,kc,Pc,Sc,Ac,Ec,Nc,Tc,Cc,$c,zc,Bc,Fc,Ic,Mc,Uc,Vc,Dc,Hc,Gc,Lc,Wc,qc,Yc,Jc,Kc,Qc,Xc,Zc,ra,ta,na,ea,oa,ia,ua,ca,aa,fa,sa,la,pa,ha,va,ga,ya,da,ba,_a,ma,Oa,ja,wa,Ra,xa,ka,Pa,Sa,Aa,Ea,Na,Ta,Ca,$a,za,Ba,Fa,Ia,Ma,Ua,Va,Da,Ha,Ga,La,Wa,qa,Ya,Ja,Ka,Qa,Xa,Za,rf,tf,nf,ef,of,uf,cf,af,ff,sf,lf,pf,hf,vf,gf,yf,df,bf,_f,mf,Of,jf,wf,Rf,xf=au(Yu()),kf="LOG",Pf="INFO",Sf="ERROR",Af="WARN",Ef="DEBUG",Nf=function(){function r(r){var t=void 0===r?{}:r,n=t.isCI,e=void 0!==n&&n,o=t.dryRun,i=void 0!==o&&o,u=t.debug,c=void 0!==u&&u,a=t.silent,f=void 0!==a&&a;this.isCI=e,this.isDryRun=i,this.isDebug=c,this.isSilent=f}return r.prototype.print=function(r){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.isSilent||console.log.apply(console,t)},r.prototype.prefix=function(r,t){return r},r.prototype.log=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([kf],r,!1))},r.prototype.info=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([Pf,this.prefix(Pf)],r,!1))},r.prototype.warn=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([Af,this.prefix(Af)],r,!1))},r.prototype.error=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([Sf,this.prefix(Sf)],r,!1))},r.prototype.debug=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];if(this.isDebug){var n=Nu(r),e=xf(n)?JSON.stringify(n):String(n);this.print.apply(this,ru([Ef,this.prefix(Ef),e],r.slice(1),!1))}},r.prototype.verbose=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.isDebug&&this.print.apply(this,ru([Ef],r,!1))},r.prototype.exec=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];var n=Vu(Tu(r))?Tu(r):void 0,e=n||{},o=e.isDryRun,i=e.isExternal;if(o||this.isDryRun){var u=[null==i?"$":"!",r.slice(0,null==n?void 0:-1).map((function(r){return Wu(r)?r:qu(r)?r.join(" "):String(r)})).join(" ")].join(" ").trim();this.log(u)}},r.prototype.obtrusive=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.isCI||this.log(),this.log.apply(this,r),this.isCI||this.log()},r}(),Tf={exports:{}},Cf=(Ju||(Ju=1,function(r,t){function n(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];return e.apply(void 0,r)}function e(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];return a(!0===r[0],!1,r)}function o(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];return a(!0===r[0],!0,r)}function i(r){if(Array.isArray(r)){for(var t=[],n=0;n<r.length;++n)t.push(i(r[n]));return t}if(u(r)){for(var n in t={},r)t[n]=i(r[n]);return t}return r}function u(r){return r&&"object"==typeof r&&!Array.isArray(r)}function c(r,t){if(!u(r))return t;for(var n in t)"__proto__"!==n&&"constructor"!==n&&"prototype"!==n&&(r[n]=u(r[n])&&u(t[n])?c(r[n],t[n]):t[n]);return r}function a(r,t,n){var e;!r&&u(e=n.shift())||(e={});for(var o=0;o<n.length;++o){var a=n[o];if(u(a))for(var f in a)if("__proto__"!==f&&"constructor"!==f&&"prototype"!==f){var s=r?i(a[f]):a[f];e[f]=t?c(e[f],s):s}}return e}Object.defineProperty(t,"__esModule",{value:!0}),t.isPlainObject=t.clone=t.recursive=t.merge=t.main=void 0,r.exports=t=n,t.default=n,t.main=n,n.clone=i,n.isPlainObject=u,n.recursive=o,t.merge=e,t.recursive=o,t.clone=i,t.isPlainObject=u}(Tf,Tf.exports)),Tf.exports);function $f(){if(Qu)return Ku;Qu=1;var r=zu(),t=Bu();return Ku=function(n){return"symbol"==typeof n||t(n)&&"[object Symbol]"==r(n)}}function zf(){if(fc)return ac;fc=1;var r=function(){if(tc)return rc;tc=1;var r=zu(),t=Yu();return rc=function(n){if(!t(n))return!1;var e=r(n);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}}(),t=function(){if(ic)return oc;ic=1;var r,t=function(){if(ec)return nc;ec=1;var r=Cu()["__core-js_shared__"];return nc=r}(),n=(r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";return oc=function(r){return!!n&&n in r}}(),n=Yu(),e=function(){if(cc)return uc;cc=1;var r=Function.prototype.toString;return uc=function(t){if(null!=t){try{return r.call(t)}catch(r){}try{return t+""}catch(r){}}return""}}(),o=/^\[object .+?Constructor\]$/,i=Function.prototype,u=Object.prototype,c=i.toString,a=u.hasOwnProperty,f=RegExp("^"+c.call(a).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");return ac=function(i){return!(!n(i)||t(i))&&(r(i)?f:o).test(e(i))}}function Bf(){if(hc)return pc;hc=1;var r=zf(),t=lc?sc:(lc=1,sc=function(r,t){return null==r?void 0:r[t]});return pc=function(n,e){var o=t(n,e);return r(o)?o:void 0}}function Ff(){if(gc)return vc;gc=1;var r=Bf()(Object,"create");return vc=r}function If(){return Nc?Ec:(Nc=1,Ec=function(r,t){return r===t||r!=r&&t!=t})}function Mf(){if(Cc)return Tc;Cc=1;var r=If();return Tc=function(t,n){for(var e=t.length;e--;)if(r(t[e][0],n))return e;return-1}}function Uf(){if(qc)return Wc;qc=1;var r=function(){if(Pc)return kc;Pc=1;var r=function(){if(dc)return yc;dc=1;var r=Ff();return yc=function(){this.__data__=r?r(null):{},this.size=0}}(),t=_c?bc:(_c=1,bc=function(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}),n=function(){if(Oc)return mc;Oc=1;var r=Ff(),t=Object.prototype.hasOwnProperty;return mc=function(n){var e=this.__data__;if(r){var o=e[n];return"__lodash_hash_undefined__"===o?void 0:o}return t.call(e,n)?e[n]:void 0}}(),e=function(){if(wc)return jc;wc=1;var r=Ff(),t=Object.prototype.hasOwnProperty;return jc=function(n){var e=this.__data__;return r?void 0!==e[n]:t.call(e,n)}}(),o=function(){if(xc)return Rc;xc=1;var r=Ff();return Rc=function(t,n){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=r&&void 0===n?"__lodash_hash_undefined__":n,this}}();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,kc=i}(),t=function(){if(Hc)return Dc;Hc=1;var r=Ac?Sc:(Ac=1,Sc=function(){this.__data__=[],this.size=0}),t=function(){if(zc)return $c;zc=1;var r=Mf(),t=Array.prototype.splice;return $c=function(n){var e=this.__data__,o=r(e,n);return!(o<0||(o==e.length-1?e.pop():t.call(e,o,1),--this.size,0))}}(),n=function(){if(Fc)return Bc;Fc=1;var r=Mf();return Bc=function(t){var n=this.__data__,e=r(n,t);return e<0?void 0:n[e][1]}}(),e=function(){if(Mc)return Ic;Mc=1;var r=Mf();return Ic=function(t){return r(this.__data__,t)>-1}}(),o=function(){if(Vc)return Uc;Vc=1;var r=Mf();return Uc=function(t,n){var e=this.__data__,o=r(e,t);return o<0?(++this.size,e.push([t,n])):e[o][1]=n,this}}();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,Dc=i}(),n=function(){if(Lc)return Gc;Lc=1;var r=Bf()(Cu(),"Map");return Gc=r}();return Wc=function(){this.size=0,this.__data__={hash:new r,map:new(n||t),string:new r}}}function Vf(){if(Qc)return Kc;Qc=1;var r=Jc?Yc:(Jc=1,Yc=function(r){var t=typeof r;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==r:null===r});return Kc=function(t,n){var e=t.__data__;return r(n)?e["string"==typeof n?"string":"hash"]:e.map}}function Df(){if(la)return sa;la=1;var r=function(){if(fa)return aa;fa=1;var r=function(){if(ca)return ua;ca=1;var r=Uf(),t=function(){if(Zc)return Xc;Zc=1;var r=Vf();return Xc=function(t){var n=r(this,t).delete(t);return this.size-=n?1:0,n}}(),n=function(){if(ta)return ra;ta=1;var r=Vf();return ra=function(t){return r(this,t).get(t)}}(),e=function(){if(ea)return na;ea=1;var r=Vf();return na=function(t){return r(this,t).has(t)}}(),o=function(){if(ia)return oa;ia=1;var r=Vf();return oa=function(t,n){var e=r(this,t),o=e.size;return e.set(t,n),this.size+=e.size==o?0:1,this}}();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,ua=i}();function t(n,e){if("function"!=typeof n||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var o=function(){var r=arguments,t=e?e.apply(this,r):r[0],i=o.cache;if(i.has(t))return i.get(t);var u=n.apply(this,r);return o.cache=i.set(t,u)||i,u};return o.cache=new(t.Cache||r),o}return t.Cache=r,aa=t}();return sa=function(t){var n=r(t,(function(r){return 500===e.size&&e.clear(),r})),e=n.cache;return n}}function Hf(){if(Oa)return ma;Oa=1;var r=Du(),t=function(){if(Zu)return Xu;Zu=1;var r=Du(),t=$f(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,e=/^\w*$/;return Xu=function(o,i){if(r(o))return!1;var u=typeof o;return!("number"!=u&&"symbol"!=u&&"boolean"!=u&&null!=o&&!t(o))||e.test(o)||!n.test(o)||null!=i&&o in Object(i)}}(),n=function(){if(ha)return pa;ha=1;var r=Df(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,e=r((function(r){var e=[];return 46===r.charCodeAt(0)&&e.push(""),r.replace(t,(function(r,t,o,i){e.push(o?i.replace(n,"$1"):t||r)})),e}));return pa=e}(),e=function(){if(_a)return ba;_a=1;var r=function(){if(da)return ya;da=1;var r=$u(),t=ga?va:(ga=1,va=function(r,t){for(var n=-1,e=null==r?0:r.length,o=Array(e);++n<e;)o[n]=t(r[n],n,r);return o}),n=Du(),e=$f(),o=r?r.prototype:void 0,i=o?o.toString:void 0;return ya=function r(o){if("string"==typeof o)return o;if(n(o))return t(o,r)+"";if(e(o))return i?i.call(o):"";var u=o+"";return"0"==u&&1/o==-1/0?"-0":u},ya}();return ba=function(t){return null==t?"":r(t)}}();return ma=function(o,i){return r(o)?o:t(o,i)?[o]:n(e(o))}}function Gf(){if(wa)return ja;wa=1;var r=$f();return ja=function(t){if("string"==typeof t||r(t))return t;var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}}function Lf(){if(Pa)return ka;Pa=1;var r=Bf(),t=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(r){}}();return ka=t}function Wf(){if(Ca)return Ta;Ca=1;var r=/^(?:0|[1-9]\d*)$/;return Ta=function(t,n){var e=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==e||"symbol"!=e&&r.test(t))&&t>-1&&t%1==0&&t<n}}function qf(){if(Fa)return Ba;Fa=1;var r=function(){if(xa)return Ra;xa=1;var r=Hf(),t=Gf();return Ra=function(n,e){for(var o=0,i=(e=r(e,n)).length;null!=n&&o<i;)n=n[t(e[o++])];return o&&o==i?n:void 0}}(),t=function(){if(za)return $a;za=1;var r=function(){if(Na)return Ea;Na=1;var r=function(){if(Aa)return Sa;Aa=1;var r=Lf();return Sa=function(t,n,e){"__proto__"==n&&r?r(t,n,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[n]=e}}(),t=If(),n=Object.prototype.hasOwnProperty;return Ea=function(e,o,i){var u=e[o];n.call(e,o)&&t(u,i)&&(void 0!==i||o in e)||r(e,o,i)}}(),t=Hf(),n=Wf(),e=Yu(),o=Gf();return $a=function(i,u,c,a){if(!e(i))return i;for(var f=-1,s=(u=t(u,i)).length,l=s-1,p=i;null!=p&&++f<s;){var h=o(u[f]),v=c;if("__proto__"===h||"constructor"===h||"prototype"===h)return i;if(f!=l){var g=p[h];void 0===(v=a?a(g,h,p):void 0)&&(v=e(g)?g:n(u[f+1])?[]:{})}r(p,h,v),p=p[h]}return i}}(),n=Hf();return Ba=function(e,o,i){for(var u=-1,c=o.length,a={};++u<c;){var f=o[u],s=r(e,f);i(s,f)&&t(a,n(f,e),s)}return a}}function Yf(){if(Ha)return Da;Ha=1;var r=function(){if(Va)return Ua;Va=1;var r=zu(),t=Bu();return Ua=function(n){return t(n)&&"[object Arguments]"==r(n)}}(),t=Bu(),n=Object.prototype,e=n.hasOwnProperty,o=n.propertyIsEnumerable,i=r(function(){return arguments}())?r:function(r){return t(r)&&e.call(r,"callee")&&!o.call(r,"callee")};return Da=i}function Jf(){if(Ja)return Ya;Ja=1;var r=Ma?Ia:(Ma=1,Ia=function(r,t){return null!=r&&t in Object(r)}),t=function(){if(qa)return Wa;qa=1;var r=Hf(),t=Yf(),n=Du(),e=Wf(),o=La?Ga:(La=1,Ga=function(r){return"number"==typeof r&&r>-1&&r%1==0&&r<=9007199254740991}),i=Gf();return Wa=function(u,c,a){for(var f=-1,s=(c=r(c,u)).length,l=!1;++f<s;){var p=i(c[f]);if(!(l=null!=u&&a(u,p)))break;u=u[p]}return l||++f!=s?l:!!(s=null==u?0:u.length)&&o(s)&&e(p,s)&&(n(u)||t(u))}}();return Ya=function(n,e){return null!=n&&t(n,e,r)}}function Kf(){if(mf)return _f;mf=1;var r=function(){if(yf)return gf;yf=1;var r=pf?lf:(pf=1,lf=function(r){return function(){return r}}),t=Lf(),n=vf?hf:(vf=1,hf=function(r){return r});return gf=t?function(n,e){return t(n,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:n}(),t=function(){if(bf)return df;bf=1;var r=Date.now;return df=function(t){var n=0,e=0;return function(){var o=r(),i=16-(o-e);if(e=o,i>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},df}(),n=t(r);return _f=n}function Qf(){if(jf)return Of;jf=1;var r=function(){if(uf)return of;uf=1;var r=function(){if(ef)return nf;ef=1;var r=Za?Xa:(Za=1,Xa=function(r,t){for(var n=-1,e=t.length,o=r.length;++n<e;)r[o+n]=t[n];return r}),t=function(){if(tf)return rf;tf=1;var r=$u(),t=Yf(),n=Du(),e=r?r.isConcatSpreadable:void 0;return rf=function(r){return n(r)||t(r)||!!(e&&r&&r[e])}}();return nf=function n(e,o,i,u,c){var a=-1,f=e.length;for(i||(i=t),c||(c=[]);++a<f;){var s=e[a];o>0&&i(s)?o>1?n(s,o-1,i,u,c):r(c,s):u||(c[c.length]=s)}return c},nf}();return of=function(t){return null!=t&&t.length?r(t,1):[]}}(),t=function(){if(sf)return ff;sf=1;var r=af?cf:(af=1,cf=function(r,t,n){switch(n.length){case 0:return r.call(t);case 1:return r.call(t,n[0]);case 2:return r.call(t,n[0],n[1]);case 3:return r.call(t,n[0],n[1],n[2])}return r.apply(t,n)}),t=Math.max;return ff=function(n,e,o){return e=t(void 0===e?n.length-1:e,0),function(){for(var i=arguments,u=-1,c=t(i.length-e,0),a=Array(c);++u<c;)a[u]=i[e+u];u=-1;for(var f=Array(e+1);++u<e;)f[u]=i[u];return f[e]=o(a),r(n,this,f)}},ff}(),n=Kf();return Of=function(e){return n(t(e,void 0,r),e+"")}}au(Cf);var Xf,Zf=function(){if(Rf)return wf;Rf=1;var r=function(){if(Qa)return Ka;Qa=1;var r=qf(),t=Jf();return Ka=function(n,e){return r(n,e,(function(r,e){return t(n,e)}))}}(),t=Qf()((function(t,n){return null==t?{}:r(t,n)}));return wf=t}();au(Zf);var rs=function(){function r(r){void 0===r&&(r={}),this.options=r,this[Xf]="JSONSerializer"}return r.prototype.createReplacer=function(r){return Array.isArray(r)?r:null===r?function(r,t){return"string"==typeof t?t.replace(/\r\n/g,"\n"):t}:"function"==typeof r?function(t,n){var e="string"==typeof n?n.replace(/\r\n/g,"\n"):n;return r.call(this,t,e)}:function(r,t){return"string"==typeof t?t.replace(/\r\n/g,"\n"):t}},r.prototype.stringify=function(r,t,n){try{var e=this.createReplacer(t);return Array.isArray(e)?JSON.stringify(r,e,n):JSON.stringify(r,e,null!=n?n:this.options.pretty?this.options.indent||2:void 0)}catch(r){if(r instanceof TypeError&&r.message.includes("circular"))throw new TypeError("Cannot stringify data with circular references");throw r}},r.prototype.parse=function(r,t){return JSON.parse(r,t)},r.prototype.serialize=function(r){return this.stringify(r,this.options.replacer||null,this.options.pretty?this.options.indent||2:void 0)},r.prototype.deserialize=function(r,t){try{return this.parse(r)}catch(r){return t}},r.prototype.serializeArray=function(r){return"["+r.map((function(r){return JSON.stringify(r)})).join(",")+"]"},r}();Xf=Symbol.toStringTag,function(){function r(r,t){void 0===t&&(t=new rs),this.storage=r,this.serializer=t,this.store={}}Object.defineProperty(r.prototype,"length",{get:function(){return this.storage?this.storage.length:Object.keys(this.store).length},enumerable:!1,configurable:!0}),r.prototype.setItem=function(r,t,n){var e={key:r,value:t,expire:n};"number"==typeof n&&n>0&&(e.expire=n);var o=this.serializer.serialize(e);this.storage?this.storage.setItem(r,o):this.store[r]=o},r.prototype.getItem=function(r,t){var n,e=this.storage?this.storage.getItem(r):this.store[r],o=null!=t?t:null;if(!e)return o;var i=this.serializer.deserialize(e,o);return"object"==typeof i?"number"==typeof i.expire&&i.expire<Date.now()?(this.removeItem(r),o):null!==(n=null==i?void 0:i.value)&&void 0!==n?n:o:o},r.prototype.removeItem=function(r){this.storage?this.storage.removeItem(r):delete this.store[r]},r.prototype.clear=function(){this.storage?this.storage.clear():this.store={}}}();const ts=(r=0)=>t=>`[${t+r}m`,ns=(r=0)=>t=>`[${38+r};5;${t}m`,es=(r=0)=>(t,n,e)=>`[${38+r};2;${t};${n};${e}m`,os={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};const is=function(){const r=new Map;for(const[t,n]of Object.entries(os)){for(const[t,e]of Object.entries(n))os[t]={open:`[${e[0]}m`,close:`[${e[1]}m`},n[t]=os[t],r.set(e[0],e[1]);Object.defineProperty(os,t,{value:n,enumerable:!1})}return Object.defineProperty(os,"codes",{value:r,enumerable:!1}),os.color.close="[39m",os.bgColor.close="[49m",os.color.ansi=ts(),os.color.ansi256=ns(),os.color.ansi16m=es(),os.bgColor.ansi=ts(10),os.bgColor.ansi256=ns(10),os.bgColor.ansi16m=es(10),Object.defineProperties(os,{rgbToAnsi256:{value:(r,t,n)=>r===t&&t===n?r<8?16:r>248?231:Math.round((r-8)/247*24)+232:16+36*Math.round(r/255*5)+6*Math.round(t/255*5)+Math.round(n/255*5),enumerable:!1},hexToRgb:{value(r){const t=/[a-f\d]{6}|[a-f\d]{3}/i.exec(r.toString(16));if(!t)return[0,0,0];let[n]=t;3===n.length&&(n=[...n].map((r=>r+r)).join(""));const e=Number.parseInt(n,16);return[e>>16&255,e>>8&255,255&e]},enumerable:!1},hexToAnsi256:{value:r=>os.rgbToAnsi256(...os.hexToRgb(r)),enumerable:!1},ansi256ToAnsi:{value(r){if(r<8)return 30+r;if(r<16)return r-8+90;let t,n,e;if(r>=232)t=(10*(r-232)+8)/255,n=t,e=t;else{const o=(r-=16)%36;t=Math.floor(r/36)/5,n=Math.floor(o/6)/5,e=o%6/5}const o=2*Math.max(t,n,e);if(0===o)return 30;let i=30+(Math.round(e)<<2|Math.round(n)<<1|Math.round(t));return 2===o&&(i+=60),i},enumerable:!1},rgbToAnsi:{value:(r,t,n)=>os.ansi256ToAnsi(os.rgbToAnsi256(r,t,n)),enumerable:!1},hexToAnsi:{value:r=>os.ansi256ToAnsi(os.hexToAnsi256(r)),enumerable:!1}}),os}(),us=(()=>{if(!("navigator"in globalThis))return 0;if(globalThis.navigator.userAgentData){const r=navigator.userAgentData.brands.find((({brand:r})=>"Chromium"===r));if(r&&r.version>93)return 3}return/\b(Chrome|Chromium)\//.test(globalThis.navigator.userAgent)?1:0})(),cs=0!==us&&{level:us},as={stdout:cs,stderr:cs};function fs(r,t,n){let e=r.indexOf(t);if(-1===e)return r;const o=t.length;let i=0,u="";do{u+=r.slice(i,e)+t+n,i=e+o,e=r.indexOf(t,i)}while(-1!==e);return u+=r.slice(i),u}const{stdout:ss,stderr:ls}=as,ps=Symbol("GENERATOR"),hs=Symbol("STYLER"),vs=Symbol("IS_EMPTY"),gs=["ansi","ansi","ansi256","ansi16m"],ys=Object.create(null),ds=r=>{const t=(...r)=>r.join(" ");return((r,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");const n=ss?ss.level:0;r.level=void 0===t.level?n:t.level})(t,r),Object.setPrototypeOf(t,bs.prototype),t};function bs(r){return ds(r)}Object.setPrototypeOf(bs.prototype,Function.prototype);for(const[r,t]of Object.entries(is))ys[r]={get(){const n=ws(this,js(t.open,t.close,this[hs]),this[vs]);return Object.defineProperty(this,r,{value:n}),n}};ys.visible={get(){const r=ws(this,this[hs],!0);return Object.defineProperty(this,"visible",{value:r}),r}};const _s=(r,t,n,...e)=>"rgb"===r?"ansi16m"===t?is[n].ansi16m(...e):"ansi256"===t?is[n].ansi256(is.rgbToAnsi256(...e)):is[n].ansi(is.rgbToAnsi(...e)):"hex"===r?_s("rgb",t,n,...is.hexToRgb(...e)):is[n][r](...e),ms=["rgb","hex","ansi256"];for(const r of ms){ys[r]={get(){const{level:t}=this;return function(...n){const e=js(_s(r,gs[t],"color",...n),is.color.close,this[hs]);return ws(this,e,this[vs])}}};ys["bg"+r[0].toUpperCase()+r.slice(1)]={get(){const{level:t}=this;return function(...n){const e=js(_s(r,gs[t],"bgColor",...n),is.bgColor.close,this[hs]);return ws(this,e,this[vs])}}}}const Os=Object.defineProperties((()=>{}),{...ys,level:{enumerable:!0,get(){return this[ps].level},set(r){this[ps].level=r}}}),js=(r,t,n)=>{let e,o;return void 0===n?(e=r,o=t):(e=n.openAll+r,o=t+n.closeAll),{open:r,close:t,openAll:e,closeAll:o,parent:n}},ws=(r,t,n)=>{const e=(...r)=>Rs(e,1===r.length?""+r[0]:r.join(" "));return Object.setPrototypeOf(e,Os),e[ps]=r,e[hs]=t,e[vs]=n,e},Rs=(r,t)=>{if(r.level<=0||!t)return r[vs]?"":t;let n=r[hs];if(void 0===n)return t;const{openAll:e,closeAll:o}=n;if(t.includes(""))for(;void 0!==n;)t=fs(t,n.close,n.open),n=n.parent;const i=t.indexOf("\n");return-1!==i&&(t=function(r,t,n,e){let o=0,i="";do{const u="\r"===r[e-1];i+=r.slice(o,u?e-1:e)+t+(u?"\r\n":"\n")+n,o=e+1,e=r.indexOf("\n",o)}while(-1!==e);return i+=r.slice(o),i}(t,o,e,i)),e+t+o};Object.defineProperties(bs.prototype,ys);const xs=bs();bs({level:ls?ls.level:0});class ks extends Nf{prefix(r){switch(r){case"INFO":return xs.blue(r);case"WARN":return xs.yellow(r);case"ERROR":return xs.red(r);case"DEBUG":return xs.gray(r);default:return r}}obtrusive(r){const t=xs.bold(r);super.obtrusive(t)}}const Ps=(r,t)=>{const n=Array.isArray(r)?r.join(" "):r;return new Promise(((r,e)=>{ct.exec(n,{encoding:"utf-8",...t},((t,n,o)=>{let i;i=t?void 0===t.code?1:t.code:0,0===i?r(n.trim()):e(new Error(o||n))}))}))};function Ss(r){return new To({name:"fe-config",defaultConfig:Yi({},Co,r)})}exports.ConfigSearch=To,exports.FeScriptContext=class{logger;shell;feConfig;dryRun;verbose;options;constructor(r){const{logger:t,shell:n,feConfig:e,dryRun:o,verbose:i,options:u}=r||{},c=u||{};this.logger=t||new ks({debug:i,dryRun:o}),this.shell=n||new Wi({logger:this.logger,dryRun:o,execPromise:c.execPromise||Ps}),this.feConfig=Ss(e).config,this.dryRun=!!o,this.verbose=!!i,this.options=c}},exports.ScriptsLogger=ks,exports.Shell=Wi,exports.defaultFeConfig=Co,exports.getFeConfigSearch=Ss;
|
package/dist/es/index.d.ts
DELETED
|
@@ -1,545 +0,0 @@
|
|
|
1
|
-
import * as _commitlint_types from '@commitlint/types';
|
|
2
|
-
import { Logger } from '@qlover/fe-utils';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Configuration search options interface
|
|
6
|
-
* @interface
|
|
7
|
-
* @description
|
|
8
|
-
* Significance: Defines the configuration structure for ConfigSearch initialization
|
|
9
|
-
* Core idea: Centralize configuration search parameters
|
|
10
|
-
* Main function: Type-safe configuration options
|
|
11
|
-
* Main purpose: Standardize configuration initialization
|
|
12
|
-
* Example:
|
|
13
|
-
* ```typescript
|
|
14
|
-
* const options: ConfigSearchOptions = {
|
|
15
|
-
* name: 'myapp',
|
|
16
|
-
* searchPlaces: ['myapp.config.js'],
|
|
17
|
-
* defaultConfig: { port: 3000 }
|
|
18
|
-
* };
|
|
19
|
-
* ```
|
|
20
|
-
*/
|
|
21
|
-
interface ConfigSearchOptions {
|
|
22
|
-
/** Base name for configuration files */
|
|
23
|
-
name: string;
|
|
24
|
-
/** Custom search locations for config files */
|
|
25
|
-
searchPlaces?: string[];
|
|
26
|
-
/** Default configuration object */
|
|
27
|
-
defaultConfig?: Record<string, unknown>;
|
|
28
|
-
/** Custom loaders for different file types */
|
|
29
|
-
loaders?: Record<string, (filepath: string) => unknown>;
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* Search options interface for configuration retrieval
|
|
33
|
-
* @interface
|
|
34
|
-
* @description
|
|
35
|
-
* Significance: Defines options for configuration search operation
|
|
36
|
-
* Core idea: Control configuration file search behavior
|
|
37
|
-
* Main function: Customize search parameters
|
|
38
|
-
* Main purpose: Flexible configuration loading
|
|
39
|
-
* Example:
|
|
40
|
-
* ```typescript
|
|
41
|
-
* const searchOptions: SearchOptions = {
|
|
42
|
-
* file: 'custom.config.js',
|
|
43
|
-
* dir: '/path/to/project'
|
|
44
|
-
* };
|
|
45
|
-
* ```
|
|
46
|
-
*/
|
|
47
|
-
interface SearchOptions {
|
|
48
|
-
/** Specific configuration file to load */
|
|
49
|
-
file?: string | false;
|
|
50
|
-
/** Directory to search in */
|
|
51
|
-
dir?: string;
|
|
52
|
-
}
|
|
53
|
-
/**
|
|
54
|
-
* Configuration search utility class
|
|
55
|
-
* @class
|
|
56
|
-
* @description
|
|
57
|
-
* Significance: Manages configuration file discovery and loading
|
|
58
|
-
* Core idea: Unified configuration management
|
|
59
|
-
* Main function: Search and load configuration from various sources
|
|
60
|
-
* Main purpose: Provide consistent configuration access
|
|
61
|
-
* Example:
|
|
62
|
-
* ```typescript
|
|
63
|
-
* const configSearch = new ConfigSearch({
|
|
64
|
-
* name: 'myapp',
|
|
65
|
-
* defaultConfig: { port: 3000 }
|
|
66
|
-
* });
|
|
67
|
-
* const config = configSearch.config;
|
|
68
|
-
* ```
|
|
69
|
-
*/
|
|
70
|
-
declare class ConfigSearch {
|
|
71
|
-
private name;
|
|
72
|
-
private searchPlaces;
|
|
73
|
-
private _config;
|
|
74
|
-
private loaders?;
|
|
75
|
-
private searchCache?;
|
|
76
|
-
/**
|
|
77
|
-
* Creates a ConfigSearch instance
|
|
78
|
-
* @param options - Configuration search options
|
|
79
|
-
* @throws Error if neither name nor searchPlaces is provided
|
|
80
|
-
* @description
|
|
81
|
-
* Significance: Initializes configuration search environment
|
|
82
|
-
* Core idea: Setup configuration search parameters
|
|
83
|
-
* Main function: Create search instance with options
|
|
84
|
-
* Main purpose: Prepare for configuration discovery
|
|
85
|
-
* Example:
|
|
86
|
-
* ```typescript
|
|
87
|
-
* const search = new ConfigSearch({
|
|
88
|
-
* name: 'myapp',
|
|
89
|
-
* defaultConfig: { debug: true }
|
|
90
|
-
* });
|
|
91
|
-
* ```
|
|
92
|
-
*/
|
|
93
|
-
constructor(options: ConfigSearchOptions);
|
|
94
|
-
/**
|
|
95
|
-
* Get effective configuration
|
|
96
|
-
* @returns Merged configuration object
|
|
97
|
-
* @description
|
|
98
|
-
* Significance: Provides access to final configuration
|
|
99
|
-
* Core idea: Merge default and discovered configurations
|
|
100
|
-
* Main function: Retrieve effective configuration
|
|
101
|
-
* Main purpose: Access complete configuration
|
|
102
|
-
* Example:
|
|
103
|
-
* ```typescript
|
|
104
|
-
* const config = configSearch.config;
|
|
105
|
-
* console.log(config.debug); // true
|
|
106
|
-
* ```
|
|
107
|
-
*/
|
|
108
|
-
get config(): Record<string, unknown>;
|
|
109
|
-
/**
|
|
110
|
-
* Get search locations
|
|
111
|
-
* @returns Array of search locations
|
|
112
|
-
* @description
|
|
113
|
-
* Significance: Exposes configuration search paths
|
|
114
|
-
* Core idea: Provide transparency in search process
|
|
115
|
-
* Main function: Return search locations
|
|
116
|
-
* Main purpose: Debug and verify search paths
|
|
117
|
-
* Example:
|
|
118
|
-
* ```typescript
|
|
119
|
-
* const places = configSearch.getSearchPlaces();
|
|
120
|
-
* // ['package.json', 'myapp.config.js', ...]
|
|
121
|
-
* ```
|
|
122
|
-
*/
|
|
123
|
-
getSearchPlaces(): string[];
|
|
124
|
-
/**
|
|
125
|
-
* Get configuration from specific location
|
|
126
|
-
* @param options - Search options
|
|
127
|
-
* @returns Configuration object
|
|
128
|
-
* @throws Error if configuration file is invalid
|
|
129
|
-
* @description
|
|
130
|
-
* Significance: Load configuration from specific location
|
|
131
|
-
* Core idea: Flexible configuration loading
|
|
132
|
-
* Main function: Load and validate configuration
|
|
133
|
-
* Main purpose: Custom configuration loading
|
|
134
|
-
* Example:
|
|
135
|
-
* ```typescript
|
|
136
|
-
* const config = configSearch.get({
|
|
137
|
-
* file: 'custom.config.js',
|
|
138
|
-
* dir: process.cwd()
|
|
139
|
-
* });
|
|
140
|
-
* ```
|
|
141
|
-
*/
|
|
142
|
-
get(options?: SearchOptions): Record<string, unknown>;
|
|
143
|
-
/**
|
|
144
|
-
* Search for configuration with caching
|
|
145
|
-
* @returns Cached configuration object
|
|
146
|
-
* @description
|
|
147
|
-
* Significance: Provides cached configuration access
|
|
148
|
-
* Core idea: Cache configuration for performance
|
|
149
|
-
* Main function: Search and cache configuration
|
|
150
|
-
* Main purpose: Optimize repeated access
|
|
151
|
-
* Example:
|
|
152
|
-
* ```typescript
|
|
153
|
-
* const config = configSearch.search();
|
|
154
|
-
* // Subsequent calls use cached result
|
|
155
|
-
* ```
|
|
156
|
-
*/
|
|
157
|
-
search(): Record<string, unknown>;
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
declare const defaultFeConfig: FeConfig;
|
|
161
|
-
type FeConfig = {
|
|
162
|
-
/**
|
|
163
|
-
* Run `fe-clean-branch` to exclude branches
|
|
164
|
-
*
|
|
165
|
-
* @default ["master", "develop", "main"]
|
|
166
|
-
*/
|
|
167
|
-
protectedBranches?: string[];
|
|
168
|
-
/**
|
|
169
|
-
* Run `fe-clean` to includes files
|
|
170
|
-
*
|
|
171
|
-
* @default ["dist","node_modules","yarn.lock","package-lock.json",".eslintcache","*.log"]
|
|
172
|
-
*/
|
|
173
|
-
cleanFiles?: string[];
|
|
174
|
-
/**
|
|
175
|
-
* Use author name when create merge PR
|
|
176
|
-
*
|
|
177
|
-
* @default `package.json -> autor`
|
|
178
|
-
*/
|
|
179
|
-
author?: string | {
|
|
180
|
-
name?: string;
|
|
181
|
-
email?: string;
|
|
182
|
-
};
|
|
183
|
-
/**
|
|
184
|
-
* Use repo info when create merge PR
|
|
185
|
-
*
|
|
186
|
-
* @default `package.json -> repository`
|
|
187
|
-
*/
|
|
188
|
-
repository?: string | {
|
|
189
|
-
url?: string;
|
|
190
|
-
[key: string]: unknown;
|
|
191
|
-
};
|
|
192
|
-
/**
|
|
193
|
-
* commitlint config
|
|
194
|
-
*
|
|
195
|
-
* @default { "extends": ["@commitlint/config-conventional"] }
|
|
196
|
-
*/
|
|
197
|
-
commitlint?: _commitlint_types.UserConfig;
|
|
198
|
-
/**
|
|
199
|
-
* config of CI release
|
|
200
|
-
*
|
|
201
|
-
* scripts release
|
|
202
|
-
*/
|
|
203
|
-
release?: FeReleaseConfig;
|
|
204
|
-
/**
|
|
205
|
-
* @default ['.env.local', '.env']
|
|
206
|
-
*/
|
|
207
|
-
envOrder?: string[];
|
|
208
|
-
};
|
|
209
|
-
type FeReleaseConfig = {
|
|
210
|
-
/**
|
|
211
|
-
* The path to publish the package
|
|
212
|
-
*
|
|
213
|
-
* @default ''
|
|
214
|
-
*/
|
|
215
|
-
publishPath?: string;
|
|
216
|
-
/**
|
|
217
|
-
* Whether to automatically merge PR when creating and publishing
|
|
218
|
-
*
|
|
219
|
-
* @default true
|
|
220
|
-
*/
|
|
221
|
-
autoMergeReleasePR?: boolean;
|
|
222
|
-
/**
|
|
223
|
-
* PR auto merged type
|
|
224
|
-
*
|
|
225
|
-
* @default squash
|
|
226
|
-
*/
|
|
227
|
-
autoMergeType?: 'merge' | 'squash' | 'rebase';
|
|
228
|
-
/**
|
|
229
|
-
* Create the branch name of PR when publishing
|
|
230
|
-
*
|
|
231
|
-
* support vars: pkgName, tagName, env, branch
|
|
232
|
-
*
|
|
233
|
-
* @default 'release-${pkgName}-${tagName}'
|
|
234
|
-
*/
|
|
235
|
-
branchName?: string;
|
|
236
|
-
/**
|
|
237
|
-
* Create a title for publishing PR
|
|
238
|
-
*
|
|
239
|
-
* @default [${pkgName} Release] Branch:${branch}, Tag:${tagName}, Env:${env}
|
|
240
|
-
*/
|
|
241
|
-
PRTitle?: string;
|
|
242
|
-
/**
|
|
243
|
-
* Create a body for publishing PR
|
|
244
|
-
*
|
|
245
|
-
* @default This PR includes version bump to ${tagName}
|
|
246
|
-
*/
|
|
247
|
-
PRBody?: string;
|
|
248
|
-
/**
|
|
249
|
-
* Create a label for publishing PR
|
|
250
|
-
*/
|
|
251
|
-
label?: {
|
|
252
|
-
/**
|
|
253
|
-
* hex color string
|
|
254
|
-
*
|
|
255
|
-
* @default `1A7F37`
|
|
256
|
-
*/
|
|
257
|
-
color?: string;
|
|
258
|
-
/**
|
|
259
|
-
* @default `Label for version update PRs`
|
|
260
|
-
*/
|
|
261
|
-
description?: string;
|
|
262
|
-
/**
|
|
263
|
-
* @default `CI-Release`
|
|
264
|
-
*/
|
|
265
|
-
name?: string;
|
|
266
|
-
};
|
|
267
|
-
/**
|
|
268
|
-
* @default `changes:${name}`
|
|
269
|
-
*/
|
|
270
|
-
changePackagesLabel?: string;
|
|
271
|
-
/**
|
|
272
|
-
* @default `[]`
|
|
273
|
-
*/
|
|
274
|
-
packagesDirectories?: string[];
|
|
275
|
-
};
|
|
276
|
-
|
|
277
|
-
/**
|
|
278
|
-
* Options for shell execution
|
|
279
|
-
*
|
|
280
|
-
* This interface defines the options available for executing shell commands.
|
|
281
|
-
* It provides flexibility in controlling the behavior of shell command execution.
|
|
282
|
-
*
|
|
283
|
-
* @interface
|
|
284
|
-
* @example
|
|
285
|
-
* const options: ShellExecOptions = {
|
|
286
|
-
* silent: true,
|
|
287
|
-
* env: { PATH: '/usr/bin' },
|
|
288
|
-
* dryRun: false
|
|
289
|
-
* };
|
|
290
|
-
*/
|
|
291
|
-
interface ShellExecOptions {
|
|
292
|
-
/**
|
|
293
|
-
* Whether to suppress output to the console.
|
|
294
|
-
*
|
|
295
|
-
* @type {boolean}
|
|
296
|
-
*/
|
|
297
|
-
silent?: boolean;
|
|
298
|
-
/**
|
|
299
|
-
* Environment variables to be passed to the command.
|
|
300
|
-
*
|
|
301
|
-
* @type {Record<string, string>}
|
|
302
|
-
*/
|
|
303
|
-
env?: Record<string, string>;
|
|
304
|
-
/**
|
|
305
|
-
* Result to return when in dry-run mode.
|
|
306
|
-
*
|
|
307
|
-
* @type {unknown}
|
|
308
|
-
*/
|
|
309
|
-
dryRunResult?: unknown;
|
|
310
|
-
/**
|
|
311
|
-
* Whether to perform a dry run.
|
|
312
|
-
* Overrides shell config.isDryRun if set.
|
|
313
|
-
*
|
|
314
|
-
* @type {boolean}
|
|
315
|
-
*/
|
|
316
|
-
dryRun?: boolean;
|
|
317
|
-
/**
|
|
318
|
-
* Template context for command string interpolation.
|
|
319
|
-
*
|
|
320
|
-
* @type {Record<string, unknown>}
|
|
321
|
-
*/
|
|
322
|
-
context?: Record<string, unknown>;
|
|
323
|
-
/**
|
|
324
|
-
* Encoding for command output.
|
|
325
|
-
*
|
|
326
|
-
* @type {string}
|
|
327
|
-
*/
|
|
328
|
-
encoding?: BufferEncoding;
|
|
329
|
-
/**
|
|
330
|
-
* Whether to cache the command
|
|
331
|
-
*
|
|
332
|
-
* @type {boolean}
|
|
333
|
-
* @default `false`
|
|
334
|
-
*/
|
|
335
|
-
isCache?: boolean;
|
|
336
|
-
[key: string]: unknown;
|
|
337
|
-
}
|
|
338
|
-
/**
|
|
339
|
-
* Interface for shell execution
|
|
340
|
-
*
|
|
341
|
-
* This interface defines a method for executing shell commands.
|
|
342
|
-
* It abstracts the details of shell command execution and provides a consistent interface.
|
|
343
|
-
*
|
|
344
|
-
* @interface
|
|
345
|
-
* @example
|
|
346
|
-
* const shell: ShellInterface = {
|
|
347
|
-
* exec: async (command, options) => {
|
|
348
|
-
* // Logic to execute the command
|
|
349
|
-
* return 'Command output';
|
|
350
|
-
* }
|
|
351
|
-
* };
|
|
352
|
-
*/
|
|
353
|
-
interface ShellInterface {
|
|
354
|
-
/**
|
|
355
|
-
* Execute a command.
|
|
356
|
-
*
|
|
357
|
-
* @param {string | string[]} command - The command to execute.
|
|
358
|
-
* @param {ShellExecOptions} [options] - Options for the command execution.
|
|
359
|
-
* @returns {Promise<string>} The output of the command.
|
|
360
|
-
*/
|
|
361
|
-
exec(command: string | string[], options?: ShellExecOptions): Promise<string>;
|
|
362
|
-
}
|
|
363
|
-
|
|
364
|
-
type ExecPromiseFunction = (command: string | string[], options: ShellExecOptions) => Promise<string>;
|
|
365
|
-
/**
|
|
366
|
-
* Configuration interface for Shell class
|
|
367
|
-
* @interface
|
|
368
|
-
*/
|
|
369
|
-
interface ShellConfig extends ShellExecOptions {
|
|
370
|
-
/** Logger instance */
|
|
371
|
-
logger: Logger;
|
|
372
|
-
/**
|
|
373
|
-
* Promise for the execer
|
|
374
|
-
*/
|
|
375
|
-
execPromise?: ExecPromiseFunction;
|
|
376
|
-
}
|
|
377
|
-
/**
|
|
378
|
-
* Shell class for command execution
|
|
379
|
-
* @class
|
|
380
|
-
* @description Provides methods for executing shell commands with caching and templating support
|
|
381
|
-
*/
|
|
382
|
-
declare class Shell implements ShellInterface {
|
|
383
|
-
config: ShellConfig;
|
|
384
|
-
private cache;
|
|
385
|
-
/**
|
|
386
|
-
* Creates a new Shell instance
|
|
387
|
-
* @param config - Shell configuration
|
|
388
|
-
* @param cache - Command cache map
|
|
389
|
-
*/
|
|
390
|
-
constructor(config: ShellConfig, cache?: Map<string, Promise<string>>);
|
|
391
|
-
/**
|
|
392
|
-
* Gets the logger instance
|
|
393
|
-
*/
|
|
394
|
-
get logger(): Logger;
|
|
395
|
-
/**
|
|
396
|
-
* Formats a template string with context
|
|
397
|
-
* @param template - Template string
|
|
398
|
-
* @param context - Context object for template interpolation
|
|
399
|
-
* @returns Formatted string
|
|
400
|
-
*/
|
|
401
|
-
static format(template?: string, context?: Record<string, unknown>): string;
|
|
402
|
-
/**
|
|
403
|
-
* Formats a template string with context and error handling
|
|
404
|
-
* @param template - Template string
|
|
405
|
-
* @param context - Context object for template interpolation
|
|
406
|
-
* @returns Formatted string
|
|
407
|
-
* @throws Error if template formatting fails
|
|
408
|
-
*/
|
|
409
|
-
format(template?: string, context?: Record<string, unknown>): string;
|
|
410
|
-
/**
|
|
411
|
-
* Executes a command with options
|
|
412
|
-
* @param command - Command string or array
|
|
413
|
-
* @param options - Execution options
|
|
414
|
-
* @returns Promise resolving to command output
|
|
415
|
-
*/
|
|
416
|
-
exec(command: string | string[], options?: ShellExecOptions): Promise<string>;
|
|
417
|
-
/**
|
|
418
|
-
* Executes a command silently
|
|
419
|
-
* @param command - Command string or array
|
|
420
|
-
* @param options - Execution options
|
|
421
|
-
* @returns Promise resolving to command output
|
|
422
|
-
* @deprecated Use `exec` instead
|
|
423
|
-
*/
|
|
424
|
-
run(command: string | string[], options?: ShellExecOptions): Promise<string>;
|
|
425
|
-
/**
|
|
426
|
-
* Executes a formatted command with caching
|
|
427
|
-
* @param command - Formatted command string or array
|
|
428
|
-
* @param options - Execution options
|
|
429
|
-
* @returns Promise resolving to command output
|
|
430
|
-
*/
|
|
431
|
-
execFormattedCommand(command: string | string[], options?: ShellExecOptions): Promise<string>;
|
|
432
|
-
}
|
|
433
|
-
|
|
434
|
-
/**
|
|
435
|
-
* Create a new ConfigSearch instance with fe configuration
|
|
436
|
-
* @param feConfig - Custom fe configuration
|
|
437
|
-
* @returns ConfigSearch instance
|
|
438
|
-
* @description
|
|
439
|
-
* Significance: Creates configuration search utility
|
|
440
|
-
* Core idea: Merge default and custom configurations
|
|
441
|
-
* Main function: Initialize configuration search
|
|
442
|
-
* Main purpose: Provide configuration discovery
|
|
443
|
-
*
|
|
444
|
-
* @example
|
|
445
|
-
* ```typescript
|
|
446
|
-
* const configSearch = getFeConfigSearch({ debug: true });
|
|
447
|
-
* ```
|
|
448
|
-
*/
|
|
449
|
-
declare function getFeConfigSearch(feConfig?: Record<string, unknown>): ConfigSearch;
|
|
450
|
-
type ScriptContextOptions<T> = T & {
|
|
451
|
-
execPromise?: ExecPromiseFunction;
|
|
452
|
-
};
|
|
453
|
-
/**
|
|
454
|
-
* Options interface for FeScriptContext
|
|
455
|
-
* @interface
|
|
456
|
-
* @description
|
|
457
|
-
* Significance: Defines script execution context options
|
|
458
|
-
* Core idea: Centralize script execution configuration
|
|
459
|
-
* Main function: Type-safe context options
|
|
460
|
-
* Main purpose: Configure script execution environment
|
|
461
|
-
*
|
|
462
|
-
* @example
|
|
463
|
-
* ```typescript
|
|
464
|
-
* const options: FeScriptContextOptions<T> = {
|
|
465
|
-
* logger: new ScriptsLogger(),
|
|
466
|
-
* dryRun: true
|
|
467
|
-
* };
|
|
468
|
-
* ```
|
|
469
|
-
*/
|
|
470
|
-
interface FeScriptContextOptions<T> {
|
|
471
|
-
/** Custom logger instance */
|
|
472
|
-
logger?: Logger;
|
|
473
|
-
/** Shell instance for command execution */
|
|
474
|
-
shell?: Shell;
|
|
475
|
-
/** Custom fe configuration */
|
|
476
|
-
feConfig?: Record<string, unknown>;
|
|
477
|
-
/** Whether to perform dry run */
|
|
478
|
-
dryRun?: boolean;
|
|
479
|
-
/** Enable verbose logging */
|
|
480
|
-
verbose?: boolean;
|
|
481
|
-
/** Additional script-specific options */
|
|
482
|
-
options?: ScriptContextOptions<T>;
|
|
483
|
-
}
|
|
484
|
-
/**
|
|
485
|
-
* Script execution context class
|
|
486
|
-
* @class
|
|
487
|
-
* @description
|
|
488
|
-
* Significance: Manages script execution environment
|
|
489
|
-
* Core idea: Provide unified context for script execution
|
|
490
|
-
* Main function: Initialize and maintain script context
|
|
491
|
-
* Main purpose: Standardize script execution environment
|
|
492
|
-
*
|
|
493
|
-
* @example
|
|
494
|
-
* ```typescript
|
|
495
|
-
* const context = new FeScriptContext<MyOptions>({
|
|
496
|
-
* dryRun: true,
|
|
497
|
-
* verbose: true
|
|
498
|
-
* });
|
|
499
|
-
* ```
|
|
500
|
-
*/
|
|
501
|
-
declare class FeScriptContext<T = unknown> {
|
|
502
|
-
/** Logger instance */
|
|
503
|
-
readonly logger: Logger;
|
|
504
|
-
/** Shell instance */
|
|
505
|
-
readonly shell: Shell;
|
|
506
|
-
/** Fe configuration */
|
|
507
|
-
readonly feConfig: FeConfig;
|
|
508
|
-
/** Dry run flag */
|
|
509
|
-
readonly dryRun: boolean;
|
|
510
|
-
/** Verbose logging flag */
|
|
511
|
-
readonly verbose: boolean;
|
|
512
|
-
/** Script-specific options */
|
|
513
|
-
options: ScriptContextOptions<T>;
|
|
514
|
-
/**
|
|
515
|
-
* Creates a FeScriptContext instance
|
|
516
|
-
*
|
|
517
|
-
* @description
|
|
518
|
-
* Significance: Initializes script execution context
|
|
519
|
-
* Core idea: Setup execution environment
|
|
520
|
-
* Main function: Create context with options
|
|
521
|
-
* Main purpose: Prepare script execution environment
|
|
522
|
-
*
|
|
523
|
-
* @example
|
|
524
|
-
* ```typescript
|
|
525
|
-
* const context = new FeScriptContext({
|
|
526
|
-
* dryRun: true,
|
|
527
|
-
* options: { branch: 'main' }
|
|
528
|
-
* });
|
|
529
|
-
* ```
|
|
530
|
-
*/
|
|
531
|
-
constructor(scriptsOptions?: FeScriptContextOptions<T>);
|
|
532
|
-
}
|
|
533
|
-
|
|
534
|
-
declare class ScriptsLogger extends Logger {
|
|
535
|
-
/**
|
|
536
|
-
* @override
|
|
537
|
-
* @param {string} value
|
|
538
|
-
* @returns {string}
|
|
539
|
-
*/
|
|
540
|
-
prefix(value: string): string;
|
|
541
|
-
obtrusive(title: string): void;
|
|
542
|
-
}
|
|
543
|
-
|
|
544
|
-
export { ConfigSearch, FeScriptContext, ScriptsLogger, Shell, defaultFeConfig, getFeConfigSearch };
|
|
545
|
-
export type { ConfigSearchOptions, ExecPromiseFunction, FeConfig, FeReleaseConfig, FeScriptContextOptions, ScriptContextOptions, ShellConfig, ShellExecOptions, ShellInterface };
|
package/dist/es/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{cosmiconfigSync as r}from"cosmiconfig";import{exec as t}from"child_process";var n,e,o,i,u,a,c,f,s,l,p,h,v,y,g,d,b,_,m,O,j,w,R,k,x,P,A,E,N,S,T,C,$,z,B,F,I,M,U,V,D,H,G,L,W,Y,J,q,K,Q,X,Z,rr,tr,nr,er,or,ir,ur,ar,cr,fr,sr,lr,pr,hr,vr,yr,gr,dr,br,_r,mr,Or,jr,wr,Rr,kr,xr,Pr,Ar,Er,Nr,Sr,Tr,Cr,$r,zr,Br,Fr,Ir,Mr,Ur,Vr,Dr,Hr,Gr,Lr,Wr,Yr,Jr,qr,Kr,Qr,Xr,Zr,rt,tt,nt,et,ot,it,ut,at,ct="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function ft(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function st(){if(e)return n;return e=1,n=function(r,t,n){switch(n.length){case 0:return r.call(t);case 1:return r.call(t,n[0]);case 2:return r.call(t,n[0],n[1]);case 3:return r.call(t,n[0],n[1],n[2])}return r.apply(t,n)}}function lt(){if(i)return o;return i=1,o=function(r){return r}}function pt(){if(a)return u;a=1;var r=st(),t=Math.max;return u=function(n,e,o){return e=t(void 0===e?n.length-1:e,0),function(){for(var i=arguments,u=-1,a=t(i.length-e,0),c=Array(a);++u<a;)c[u]=i[e+u];u=-1;for(var f=Array(e+1);++u<e;)f[u]=i[u];return f[e]=o(c),r(n,this,f)}},u}function ht(){if(f)return c;return f=1,c=function(r){return function(){return r}}}function vt(){if(l)return s;l=1;var r="object"==typeof ct&&ct&&ct.Object===Object&&ct;return s=r}function yt(){if(h)return p;h=1;var r=vt(),t="object"==typeof self&&self&&self.Object===Object&&self,n=r||t||Function("return this")();return p=n}function gt(){if(y)return v;y=1;var r=yt().Symbol;return v=r}function dt(){if(d)return g;d=1;var r=gt(),t=Object.prototype,n=t.hasOwnProperty,e=t.toString,o=r?r.toStringTag:void 0;return g=function(r){var t=n.call(r,o),i=r[o];try{r[o]=void 0;var u=!0}catch(r){}var a=e.call(r);return u&&(t?r[o]=i:delete r[o]),a}}function bt(){if(_)return b;_=1;var r=Object.prototype.toString;return b=function(t){return r.call(t)}}function _t(){if(O)return m;O=1;var r=gt(),t=dt(),n=bt(),e=r?r.toStringTag:void 0;return m=function(r){return null==r?void 0===r?"[object Undefined]":"[object Null]":e&&e in Object(r)?t(r):n(r)}}function mt(){if(w)return j;return w=1,j=function(r){var t=typeof r;return null!=r&&("object"==t||"function"==t)}}function Ot(){if(k)return R;k=1;var r=_t(),t=mt();return R=function(n){if(!t(n))return!1;var e=r(n);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}}function jt(){if(P)return x;P=1;var r=yt()["__core-js_shared__"];return x=r}function wt(){if(E)return A;E=1;var r,t=jt(),n=(r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";return A=function(r){return!!n&&n in r}}function Rt(){if(S)return N;S=1;var r=Function.prototype.toString;return N=function(t){if(null!=t){try{return r.call(t)}catch(r){}try{return t+""}catch(r){}}return""}}function kt(){if(C)return T;C=1;var r=Ot(),t=wt(),n=mt(),e=Rt(),o=/^\[object .+?Constructor\]$/,i=Function.prototype,u=Object.prototype,a=i.toString,c=u.hasOwnProperty,f=RegExp("^"+a.call(c).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");return T=function(i){return!(!n(i)||t(i))&&(r(i)?f:o).test(e(i))}}function xt(){if(z)return $;return z=1,$=function(r,t){return null==r?void 0:r[t]}}function Pt(){if(F)return B;F=1;var r=kt(),t=xt();return B=function(n,e){var o=t(n,e);return r(o)?o:void 0}}function At(){if(M)return I;M=1;var r=Pt(),t=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(r){}}();return I=t}function Et(){if(V)return U;V=1;var r=ht(),t=At();return U=t?function(n,e){return t(n,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:lt()}function Nt(){if(H)return D;H=1;var r=Date.now;return D=function(t){var n=0,e=0;return function(){var o=r(),i=16-(o-e);if(e=o,i>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},D}function St(){if(L)return G;L=1;var r=Et(),t=Nt()(r);return G=t}function Tt(){if(Y)return W;Y=1;var r=lt(),t=pt(),n=St();return W=function(e,o){return n(t(e,o,r),e+"")}}function Ct(){if(q)return J;return q=1,J=function(){this.__data__=[],this.size=0}}function $t(){if(Q)return K;return Q=1,K=function(r,t){return r===t||r!=r&&t!=t}}function zt(){if(Z)return X;Z=1;var r=$t();return X=function(t,n){for(var e=t.length;e--;)if(r(t[e][0],n))return e;return-1}}function Bt(){if(tr)return rr;tr=1;var r=zt(),t=Array.prototype.splice;return rr=function(n){var e=this.__data__,o=r(e,n);return!(o<0)&&(o==e.length-1?e.pop():t.call(e,o,1),--this.size,!0)}}function Ft(){if(er)return nr;er=1;var r=zt();return nr=function(t){var n=this.__data__,e=r(n,t);return e<0?void 0:n[e][1]}}function It(){if(ir)return or;ir=1;var r=zt();return or=function(t){return r(this.__data__,t)>-1}}function Mt(){if(ar)return ur;ar=1;var r=zt();return ur=function(t,n){var e=this.__data__,o=r(e,t);return o<0?(++this.size,e.push([t,n])):e[o][1]=n,this}}function Ut(){if(fr)return cr;fr=1;var r=Ct(),t=Bt(),n=Ft(),e=It(),o=Mt();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,cr=i}function Vt(){if(lr)return sr;lr=1;var r=Ut();return sr=function(){this.__data__=new r,this.size=0}}function Dt(){if(hr)return pr;return hr=1,pr=function(r){var t=this.__data__,n=t.delete(r);return this.size=t.size,n}}function Ht(){if(yr)return vr;return yr=1,vr=function(r){return this.__data__.get(r)}}function Gt(){if(dr)return gr;return dr=1,gr=function(r){return this.__data__.has(r)}}function Lt(){if(_r)return br;_r=1;var r=Pt()(yt(),"Map");return br=r}function Wt(){if(Or)return mr;Or=1;var r=Pt()(Object,"create");return mr=r}function Yt(){if(wr)return jr;wr=1;var r=Wt();return jr=function(){this.__data__=r?r(null):{},this.size=0}}function Jt(){if(kr)return Rr;return kr=1,Rr=function(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}}function qt(){if(Pr)return xr;Pr=1;var r=Wt(),t=Object.prototype.hasOwnProperty;return xr=function(n){var e=this.__data__;if(r){var o=e[n];return"__lodash_hash_undefined__"===o?void 0:o}return t.call(e,n)?e[n]:void 0}}function Kt(){if(Er)return Ar;Er=1;var r=Wt(),t=Object.prototype.hasOwnProperty;return Ar=function(n){var e=this.__data__;return r?void 0!==e[n]:t.call(e,n)}}function Qt(){if(Sr)return Nr;Sr=1;var r=Wt();return Nr=function(t,n){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=r&&void 0===n?"__lodash_hash_undefined__":n,this}}function Xt(){if(Cr)return Tr;Cr=1;var r=Yt(),t=Jt(),n=qt(),e=Kt(),o=Qt();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,Tr=i}function Zt(){if(zr)return $r;zr=1;var r=Xt(),t=Ut(),n=Lt();return $r=function(){this.size=0,this.__data__={hash:new r,map:new(n||t),string:new r}}}function rn(){if(Fr)return Br;return Fr=1,Br=function(r){var t=typeof r;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==r:null===r}}function tn(){if(Mr)return Ir;Mr=1;var r=rn();return Ir=function(t,n){var e=t.__data__;return r(n)?e["string"==typeof n?"string":"hash"]:e.map}}function nn(){if(Vr)return Ur;Vr=1;var r=tn();return Ur=function(t){var n=r(this,t).delete(t);return this.size-=n?1:0,n}}function en(){if(Hr)return Dr;Hr=1;var r=tn();return Dr=function(t){return r(this,t).get(t)}}function on(){if(Lr)return Gr;Lr=1;var r=tn();return Gr=function(t){return r(this,t).has(t)}}function un(){if(Yr)return Wr;Yr=1;var r=tn();return Wr=function(t,n){var e=r(this,t),o=e.size;return e.set(t,n),this.size+=e.size==o?0:1,this}}function an(){if(qr)return Jr;qr=1;var r=Zt(),t=nn(),n=en(),e=on(),o=un();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,Jr=i}function cn(){if(Qr)return Kr;Qr=1;var r=Ut(),t=Lt(),n=an();return Kr=function(e,o){var i=this.__data__;if(i instanceof r){var u=i.__data__;if(!t||u.length<199)return u.push([e,o]),this.size=++i.size,this;i=this.__data__=new n(u)}return i.set(e,o),this.size=i.size,this}}function fn(){if(Zr)return Xr;Zr=1;var r=Ut(),t=Vt(),n=Dt(),e=Ht(),o=Gt(),i=cn();function u(t){var n=this.__data__=new r(t);this.size=n.size}return u.prototype.clear=t,u.prototype.delete=n,u.prototype.get=e,u.prototype.has=o,u.prototype.set=i,Xr=u}function sn(){if(tt)return rt;tt=1;var r=At();return rt=function(t,n,e){"__proto__"==n&&r?r(t,n,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[n]=e}}function ln(){if(et)return nt;et=1;var r=sn(),t=$t();return nt=function(n,e,o){(void 0!==o&&!t(n[e],o)||void 0===o&&!(e in n))&&r(n,e,o)}}function pn(){if(it)return ot;return it=1,ot=function(r){return function(t,n,e){for(var o=-1,i=Object(t),u=e(t),a=u.length;a--;){var c=u[r?a:++o];if(!1===n(i[c],c,i))break}return t}}}function hn(){if(at)return ut;at=1;var r=pn()();return ut=r}var vn,yn,gn,dn,bn,_n,mn,On,jn,wn,Rn,kn,xn,Pn,An,En,Nn,Sn,Tn,Cn,$n,zn,Bn,Fn,In,Mn,Un,Vn,Dn,Hn,Gn,Ln,Wn,Yn={exports:{}};function Jn(){return vn||(vn=1,r=Yn,t=Yn.exports,n=yt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,i=o&&o.exports===e?n.Buffer:void 0,u=i?i.allocUnsafe:void 0,r.exports=function(r,t){if(t)return r.slice();var n=r.length,e=u?u(n):new r.constructor(n);return r.copy(e),e}),Yn.exports;var r,t,n,e,o,i,u}function qn(){if(gn)return yn;gn=1;var r=yt().Uint8Array;return yn=r}function Kn(){if(bn)return dn;bn=1;var r=qn();return dn=function(t){var n=new t.constructor(t.byteLength);return new r(n).set(new r(t)),n}}function Qn(){if(mn)return _n;mn=1;var r=Kn();return _n=function(t,n){var e=n?r(t.buffer):t.buffer;return new t.constructor(e,t.byteOffset,t.length)}}function Xn(){if(jn)return On;return jn=1,On=function(r,t){var n=-1,e=r.length;for(t||(t=Array(e));++n<e;)t[n]=r[n];return t}}function Zn(){if(Rn)return wn;Rn=1;var r=mt(),t=Object.create,n=function(){function n(){}return function(e){if(!r(e))return{};if(t)return t(e);n.prototype=e;var o=new n;return n.prototype=void 0,o}}();return wn=n}function re(){if(xn)return kn;return xn=1,kn=function(r,t){return function(n){return r(t(n))}}}function te(){if(An)return Pn;An=1;var r=re()(Object.getPrototypeOf,Object);return Pn=r}function ne(){if(Nn)return En;Nn=1;var r=Object.prototype;return En=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||r)}}function ee(){if(Tn)return Sn;Tn=1;var r=Zn(),t=te(),n=ne();return Sn=function(e){return"function"!=typeof e.constructor||n(e)?{}:r(t(e))}}function oe(){if($n)return Cn;return $n=1,Cn=function(r){return null!=r&&"object"==typeof r}}function ie(){if(Bn)return zn;Bn=1;var r=_t(),t=oe();return zn=function(n){return t(n)&&"[object Arguments]"==r(n)}}function ue(){if(In)return Fn;In=1;var r=ie(),t=oe(),n=Object.prototype,e=n.hasOwnProperty,o=n.propertyIsEnumerable,i=r(function(){return arguments}())?r:function(r){return t(r)&&e.call(r,"callee")&&!o.call(r,"callee")};return Fn=i}function ae(){if(Un)return Mn;Un=1;var r=Array.isArray;return Mn=r}function ce(){if(Dn)return Vn;Dn=1;return Vn=function(r){return"number"==typeof r&&r>-1&&r%1==0&&r<=9007199254740991}}function fe(){if(Gn)return Hn;Gn=1;var r=Ot(),t=ce();return Hn=function(n){return null!=n&&t(n.length)&&!r(n)}}function se(){if(Wn)return Ln;Wn=1;var r=fe(),t=oe();return Ln=function(n){return t(n)&&r(n)}}var le,pe,he,ve,ye,ge,de,be,_e,me={exports:{}};function Oe(){if(pe)return le;return pe=1,le=function(){return!1}}function je(){return he||(he=1,function(r,t){var n=yt(),e=Oe(),o=t&&!t.nodeType&&t,i=o&&r&&!r.nodeType&&r,u=i&&i.exports===o?n.Buffer:void 0,a=(u?u.isBuffer:void 0)||e;r.exports=a}(me,me.exports)),me.exports}function we(){if(ye)return ve;ye=1;var r=_t(),t=te(),n=oe(),e=Function.prototype,o=Object.prototype,i=e.toString,u=o.hasOwnProperty,a=i.call(Object);return ve=function(e){if(!n(e)||"[object Object]"!=r(e))return!1;var o=t(e);if(null===o)return!0;var c=u.call(o,"constructor")&&o.constructor;return"function"==typeof c&&c instanceof c&&i.call(c)==a},ve}function Re(){if(de)return ge;de=1;var r=_t(),t=ce(),n=oe(),e={};return e["[object Float32Array]"]=e["[object Float64Array]"]=e["[object Int8Array]"]=e["[object Int16Array]"]=e["[object Int32Array]"]=e["[object Uint8Array]"]=e["[object Uint8ClampedArray]"]=e["[object Uint16Array]"]=e["[object Uint32Array]"]=!0,e["[object Arguments]"]=e["[object Array]"]=e["[object ArrayBuffer]"]=e["[object Boolean]"]=e["[object DataView]"]=e["[object Date]"]=e["[object Error]"]=e["[object Function]"]=e["[object Map]"]=e["[object Number]"]=e["[object Object]"]=e["[object RegExp]"]=e["[object Set]"]=e["[object String]"]=e["[object WeakMap]"]=!1,ge=function(o){return n(o)&&t(o.length)&&!!e[r(o)]}}function ke(){if(_e)return be;return _e=1,be=function(r){return function(t){return r(t)}}}var xe,Pe,Ae,Ee,Ne,Se,Te,Ce,$e,ze,Be,Fe,Ie,Me,Ue,Ve,De,He,Ge,Le,We,Ye,Je,qe,Ke,Qe,Xe,Ze,ro,to,no,eo,oo,io,uo,ao,co,fo={exports:{}};function so(){return xe||(xe=1,r=fo,t=fo.exports,n=vt(),e=t&&!t.nodeType&&t,o=e&&r&&!r.nodeType&&r,i=o&&o.exports===e&&n.process,u=function(){try{var r=o&&o.require&&o.require("util").types;return r||i&&i.binding&&i.binding("util")}catch(r){}}(),r.exports=u),fo.exports;var r,t,n,e,o,i,u}function lo(){if(Ae)return Pe;Ae=1;var r=Re(),t=ke(),n=so(),e=n&&n.isTypedArray,o=e?t(e):r;return Pe=o}function po(){if(Ne)return Ee;return Ne=1,Ee=function(r,t){if(("constructor"!==t||"function"!=typeof r[t])&&"__proto__"!=t)return r[t]}}function ho(){if(Te)return Se;Te=1;var r=sn(),t=$t(),n=Object.prototype.hasOwnProperty;return Se=function(e,o,i){var u=e[o];n.call(e,o)&&t(u,i)&&(void 0!==i||o in e)||r(e,o,i)}}function vo(){if($e)return Ce;$e=1;var r=ho(),t=sn();return Ce=function(n,e,o,i){var u=!o;o||(o={});for(var a=-1,c=e.length;++a<c;){var f=e[a],s=i?i(o[f],n[f],f,o,n):void 0;void 0===s&&(s=n[f]),u?t(o,f,s):r(o,f,s)}return o}}function yo(){if(Be)return ze;return Be=1,ze=function(r,t){for(var n=-1,e=Array(r);++n<r;)e[n]=t(n);return e},ze}function go(){if(Ie)return Fe;Ie=1;var r=/^(?:0|[1-9]\d*)$/;return Fe=function(t,n){var e=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==e||"symbol"!=e&&r.test(t))&&t>-1&&t%1==0&&t<n}}function bo(){if(Ue)return Me;Ue=1;var r=yo(),t=ue(),n=ae(),e=je(),o=go(),i=lo(),u=Object.prototype.hasOwnProperty;return Me=function(a,c){var f=n(a),s=!f&&t(a),l=!f&&!s&&e(a),p=!f&&!s&&!l&&i(a),h=f||s||l||p,v=h?r(a.length,String):[],y=v.length;for(var g in a)!c&&!u.call(a,g)||h&&("length"==g||l&&("offset"==g||"parent"==g)||p&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||o(g,y))||v.push(g);return v}}function _o(){if(De)return Ve;return De=1,Ve=function(r){var t=[];if(null!=r)for(var n in Object(r))t.push(n);return t}}function mo(){if(Ge)return He;Ge=1;var r=mt(),t=ne(),n=_o(),e=Object.prototype.hasOwnProperty;return He=function(o){if(!r(o))return n(o);var i=t(o),u=[];for(var a in o)("constructor"!=a||!i&&e.call(o,a))&&u.push(a);return u}}function Oo(){if(We)return Le;We=1;var r=bo(),t=mo(),n=fe();return Le=function(e){return n(e)?r(e,!0):t(e)}}function jo(){if(Je)return Ye;Je=1;var r=vo(),t=Oo();return Ye=function(n){return r(n,t(n))}}function wo(){if(Ke)return qe;Ke=1;var r=ln(),t=Jn(),n=Qn(),e=Xn(),o=ee(),i=ue(),u=ae(),a=se(),c=je(),f=Ot(),s=mt(),l=we(),p=lo(),h=po(),v=jo();return qe=function(y,g,d,b,_,m,O){var j=h(y,d),w=h(g,d),R=O.get(w);if(R)r(y,d,R);else{var k=m?m(j,w,d+"",y,g,O):void 0,x=void 0===k;if(x){var P=u(w),A=!P&&c(w),E=!P&&!A&&p(w);k=w,P||A||E?u(j)?k=j:a(j)?k=e(j):A?(x=!1,k=t(w,!0)):E?(x=!1,k=n(w,!0)):k=[]:l(w)||i(w)?(k=j,i(j)?k=v(j):s(j)&&!f(j)||(k=o(w))):x=!1}x&&(O.set(w,k),_(k,w,b,m,O),O.delete(w)),r(y,d,k)}}}function Ro(){if(Xe)return Qe;Xe=1;var r=fn(),t=ln(),n=hn(),e=wo(),o=mt(),i=Oo(),u=po();return Qe=function a(c,f,s,l,p){c!==f&&n(f,(function(n,i){if(p||(p=new r),o(n))e(c,f,i,s,a,l,p);else{var h=l?l(u(c,i),n,i+"",c,f,p):void 0;void 0===h&&(h=n),t(c,i,h)}}),i)},Qe}function ko(){if(ro)return Ze;ro=1;var r=Ro(),t=mt();return Ze=function n(e,o,i,u,a,c){return t(e)&&t(o)&&(c.set(o,e),r(e,o,void 0,n,c),c.delete(o)),e},Ze}function xo(){if(no)return to;no=1;var r=$t(),t=fe(),n=go(),e=mt();return to=function(o,i,u){if(!e(u))return!1;var a=typeof i;return!!("number"==a?t(u)&&n(i,u.length):"string"==a&&i in u)&&r(u[i],o)}}function Po(){if(oo)return eo;oo=1;var r=Tt(),t=xo();return eo=function(n){return r((function(r,e){var o=-1,i=e.length,u=i>1?e[i-1]:void 0,a=i>2?e[2]:void 0;for(u=n.length>3&&"function"==typeof u?(i--,u):void 0,a&&t(e[0],e[1],a)&&(u=i<3?void 0:u,i=1),r=Object(r);++o<i;){var c=e[o];c&&n(r,c,o,u)}return r}))}}function Ao(){if(uo)return io;uo=1;var r=Ro(),t=Po()((function(t,n,e,o){r(t,n,e,o)}));return io=t}function Eo(){if(co)return ao;co=1;var r=st(),t=Tt(),n=ko(),e=Ao(),o=t((function(t){return t.push(void 0,n),r(e,void 0,t)}));return ao=o}var No=ft(Eo()),So=ft(we());class To{name;searchPlaces;_config;loaders;searchCache;constructor(r){const{name:t,searchPlaces:n,defaultConfig:e,loaders:o}=r;if(!t&&!n)throw new Error("searchPlaces or name is required");this.name=t,this.searchPlaces=n||function(r){const t=["json","js","ts","cjs","yaml","yml"];return["package.json",...t.map((t=>`${r}.${t}`)),...t.map((t=>`.${r}.${t}`))]}(t),this._config=e||{},this.loaders=o}get config(){return No({},this.search(),this._config)}getSearchPlaces(){return this.searchPlaces}get(t={}){const{file:n,dir:e=process.cwd()}=t,o={};if(!1===n)return o;const i=r(this.name,{searchPlaces:this.searchPlaces,loaders:this.loaders}),u=n?i.load(n):i.search(e);if(u&&"string"==typeof u.config)throw new Error(`Invalid configuration file at ${u.filepath}`);return u&&So(u.config)?u.config:o}search(){return this.searchCache?this.searchCache:this.searchCache=this.get({})}}const Co={protectedBranches:["master","develop","main"],cleanFiles:["dist","node_modules","yarn.lock","package-lock.json",".eslintcache","*.log"],commitlint:{extends:["@commitlint/config-conventional"]},release:{publishPath:"",autoMergeReleasePR:!1,autoMergeType:"squash",branchName:"release-${pkgName}-${tagName}",PRTitle:"[${pkgName} Release] Branch:${branch}, Tag:${tagName}, Env:${env}",PRBody:"## Publish Details\n\n- 🏷️ Version: ${tagName}\n- 🌲 Branch: ${branch}\n- 🔧 Environment: ${env}\n\n## Changelog\n\n${changelog}\n\n## Notes\n\n- [ ] Please check if the version number is correct\n- [ ] Please confirm all tests have passed\n- [ ] Please confirm the documentation has been updated\n\n> This PR is auto created by release process, please contact the frontend team if there are any questions.",label:{color:"1A7F37",description:"Release PR",name:"CI-Release"},packagesDirectories:[],changePackagesLabel:"changes:${name}"},envOrder:[".env.local",".env.production",".env"]};var $o,zo,Bo,Fo,Io,Mo,Uo,Vo,Do,Ho,Go,Lo,Wo,Yo,Jo,qo,Ko,Qo,Xo,Zo,ri,ti,ni,ei,oi,ii,ui,ai,ci,fi,si,li,pi,hi,vi,yi,gi,di,bi,_i,mi,Oi;function ji(){if(zo)return $o;zo=1;var r=vo(),t=Po(),n=Oo(),e=t((function(t,e,o,i){r(e,n(e),t,i)}));return $o=e}function wi(){if(Fo)return Bo;Fo=1;var r=_t(),t=oe(),n=we();return Bo=function(e){if(!t(e))return!1;var o=r(e);return"[object Error]"==o||"[object DOMException]"==o||"string"==typeof e.message&&"string"==typeof e.name&&!n(e)}}function Ri(){if(Mo)return Io;Mo=1;var r=st(),t=Tt(),n=wi(),e=t((function(t,e){try{return r(t,void 0,e)}catch(r){return n(r)?r:new Error(r)}}));return Io=e}function ki(){if(Vo)return Uo;return Vo=1,Uo=function(r,t){for(var n=-1,e=null==r?0:r.length,o=Array(e);++n<e;)o[n]=t(r[n],n,r);return o}}function xi(){if(Ho)return Do;Ho=1;var r=ki();return Do=function(t,n){return r(n,(function(r){return t[r]}))}}function Pi(){if(Lo)return Go;Lo=1;var r=$t(),t=Object.prototype,n=t.hasOwnProperty;return Go=function(e,o,i,u){return void 0===e||r(e,t[i])&&!n.call(u,i)?o:e}}function Ai(){if(Yo)return Wo;Yo=1;var r={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};return Wo=function(t){return"\\"+r[t]}}function Ei(){if(qo)return Jo;qo=1;var r=re()(Object.keys,Object);return Jo=r}function Ni(){if(Qo)return Ko;Qo=1;var r=ne(),t=Ei(),n=Object.prototype.hasOwnProperty;return Ko=function(e){if(!r(e))return t(e);var o=[];for(var i in Object(e))n.call(e,i)&&"constructor"!=i&&o.push(i);return o}}function Si(){if(Zo)return Xo;Zo=1;var r=bo(),t=Ni(),n=fe();return Xo=function(e){return n(e)?r(e):t(e)}}function Ti(){if(ti)return ri;ti=1;return ri=/<%=([\s\S]+?)%>/g}function Ci(){if(ei)return ni;return ei=1,ni=function(r){return function(t){return null==r?void 0:r[t]}}}function $i(){if(ii)return oi;ii=1;var r=Ci()({"&":"&","<":"<",">":">",'"':""","'":"'"});return oi=r}function zi(){if(ai)return ui;ai=1;var r=_t(),t=oe();return ui=function(n){return"symbol"==typeof n||t(n)&&"[object Symbol]"==r(n)}}function Bi(){if(fi)return ci;fi=1;var r=gt(),t=ki(),n=ae(),e=zi(),o=r?r.prototype:void 0,i=o?o.toString:void 0;return ci=function r(o){if("string"==typeof o)return o;if(n(o))return t(o,r)+"";if(e(o))return i?i.call(o):"";var u=o+"";return"0"==u&&1/o==-1/0?"-0":u},ci}function Fi(){if(li)return si;li=1;var r=Bi();return si=function(t){return null==t?"":r(t)}}function Ii(){if(hi)return pi;hi=1;var r=$i(),t=Fi(),n=/[&<>"']/g,e=RegExp(n.source);return pi=function(o){return(o=t(o))&&e.test(o)?o.replace(n,r):o}}function Mi(){if(yi)return vi;yi=1;return vi=/<%-([\s\S]+?)%>/g}function Ui(){if(di)return gi;di=1;return gi=/<%([\s\S]+?)%>/g}function Vi(){if(_i)return bi;_i=1;var r=Ii();return bi={escape:Mi(),evaluate:Ui(),interpolate:Ti(),variable:"",imports:{_:{escape:r}}}}function Di(){if(Oi)return mi;Oi=1;var r=ji(),t=Ri(),n=xi(),e=Pi(),o=Ai(),i=wi(),u=xo(),a=Si(),c=Ti(),f=Vi(),s=Fi(),l=/\b__p \+= '';/g,p=/\b(__p \+=) '' \+/g,h=/(__e\(.*?\)|\b__t\)) \+\n'';/g,v=/[()=,{}\[\]\/\s]/,y=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,g=/($^)/,d=/['\n\r\u2028\u2029\\]/g,b=Object.prototype.hasOwnProperty;return mi=function(_,m,O){var j=f.imports._.templateSettings||f;O&&u(_,m,O)&&(m=void 0),_=s(_),m=r({},m,j,e);var w,R,k=r({},m.imports,j.imports,e),x=a(k),P=n(k,x),A=0,E=m.interpolate||g,N="__p += '",S=RegExp((m.escape||g).source+"|"+E.source+"|"+(E===c?y:g).source+"|"+(m.evaluate||g).source+"|$","g"),T=b.call(m,"sourceURL")?"//# sourceURL="+(m.sourceURL+"").replace(/\s/g," ")+"\n":"";_.replace(S,(function(r,t,n,e,i,u){return n||(n=e),N+=_.slice(A,u).replace(d,o),t&&(w=!0,N+="' +\n__e("+t+") +\n'"),i&&(R=!0,N+="';\n"+i+";\n__p += '"),n&&(N+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),A=u+r.length,r})),N+="';\n";var C=b.call(m,"variable")&&m.variable;if(C){if(v.test(C))throw new Error("Invalid `variable` option passed into `_.template`")}else N="with (obj) {\n"+N+"\n}\n";N=(R?N.replace(l,""):N).replace(p,"$1").replace(h,"$1;"),N="function("+(C||"obj")+") {\n"+(C?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(w?", __e = _.escape":"")+(R?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+N+"return __p\n}";var $=t((function(){return Function(x,T+"return "+N).apply(void 0,P)}));if($.source=N,i($))throw $;return $}}var Hi,Gi,Li=ft(Di());class Wi{config;cache;constructor(r,t=new Map){this.config=r,this.cache=t}get logger(){return this.config.logger}static format(r="",t={}){return Li(r)(t)}format(r="",t={}){try{return Wi.format(r,t)}catch(n){throw this.logger.error(`Unable to render template with context:\n${r}\n${JSON.stringify(t)}`),this.logger.error(n),n}}exec(r,t={}){const{context:n,...e}=t;return"string"==typeof r?this.execFormattedCommand(this.format(r,n||{}),e):this.execFormattedCommand(r,e)}run(r,t={}){return this.exec(r,{silent:!0,...t})}async execFormattedCommand(r,t={}){const n=this.config.execPromise;if(!n)throw new Error("execPromise is not defined");const{dryRunResult:e,silent:o,dryRun:i,isCache:u}=t,a=void 0!==i?i:this.config.dryRun,c=void 0!==u?!!u:!!this.config.isCache,f="string"==typeof r?r:r.join(" "),s=c&&this.cache.has(f);if(o||this.logger.exec(r,{isCached:s}),a)return Promise.resolve(e);if(s)return this.cache.get(f);const l=n(r,t);return this.cache.has(f)||this.cache.set(f,l),l}}function Yi(){if(Gi)return Hi;Gi=1;var r=Ro(),t=Po()((function(t,n,e){r(t,n,e)}));return Hi=t}var Ji=ft(Yi()),qi=function(){function r(r){this.config=r,this.plugins=[]}return r.prototype.use=function(r){this.plugins.find((function(t){return t===r||t.pluginName===r.pluginName||t.constructor===r.constructor}))&&r.onlyOne?console.warn("Plugin ".concat(r.pluginName," is already used, skip adding")):this.plugins.push(r)},r}(),Ki=function(r,t){return Ki=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,t){r.__proto__=t}||function(r,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])},Ki(r,t)};function Qi(r,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=r}Ki(r,t),r.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}function Xi(r,t,n,e){return new(n||(n=Promise))((function(t,o){function i(r){try{a(e.next(r))}catch(r){o(r)}}function u(r){try{a(e.throw(r))}catch(r){o(r)}}function a(r){var e;r.done?t(r.value):(e=r.value,e instanceof n?e:new n((function(r){r(e)}))).then(i,u)}a((e=e.apply(r,[])).next())}))}function Zi(r,t){var n,e,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},u=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return u.next=a(0),u.throw=a(1),u.return=a(2),"function"==typeof Symbol&&(u[Symbol.iterator]=function(){return this}),u;function a(a){return function(c){return function(a){if(n)throw new TypeError("Generator is already executing.");for(;u&&(u=0,a[0]&&(i=0)),i;)try{if(n=1,e&&(o=2&a[0]?e.return:a[0]?e.throw||((o=e.return)&&o.call(e),0):e.next)&&!(o=o.call(e,a[1])).done)return o;switch(e=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return i.label++,{value:a[1],done:!1};case 5:i.label++,e=a[1],a=[0];continue;case 7:a=i.ops.pop(),i.trys.pop();continue;default:if(!((o=(o=i.trys).length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){i=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){i.label=a[1];break}if(6===a[0]&&i.label<o[1]){i.label=o[1],o=a;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(a);break}o[2]&&i.ops.pop(),i.trys.pop();continue}a=t.call(r,i)}catch(r){a=[6,r],e=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,c])}}}function ru(r,t,n){if(2===arguments.length)for(var e,o=0,i=t.length;o<i;o++)!e&&o in t||(e||(e=Array.prototype.slice.call(t,0,o)),e[o]=t[o]);return r.concat(e||Array.prototype.slice.call(t))}"function"==typeof SuppressedError&&SuppressedError;var tu,nu,eu,ou,iu,uu=function(r){function t(t,n){var e=this.constructor,o=r.call(this,n instanceof Error?n.message:n||t)||this;return o.id=t,n instanceof Error&&"stack"in n&&(o.stack=n.stack),Object.setPrototypeOf(o,e.prototype),o}return Qi(t,r),t}(Error);!function(r){function t(){return null!==r&&r.apply(this,arguments)||this}Qi(t,r)}(uu),function(r){r.REQUEST_ERROR="REQUEST_ERROR",r.ENV_FETCH_NOT_SUPPORT="ENV_FETCH_NOT_SUPPORT",r.FETCHER_NONE="FETCHER_NONE",r.RESPONSE_NOT_OK="RESPONSE_NOT_OK",r.ABORT_ERROR="ABORT_ERROR",r.URL_NONE="URL_NONE"}(tu||(tu={})),function(r){function t(){return null!==r&&r.apply(this,arguments)||this}Qi(t,r),t.prototype.runHooks=function(r,t,n){for(var e=[],o=3;o<arguments.length;o++)e[o-3]=arguments[o];return Xi(this,0,void 0,(function(){var o,i,u,a,c,f,s,l;return Zi(this,(function(p){switch(p.label){case 0:o=-1,(u=n||{parameters:void 0,hooksRuntimes:{}}).hooksRuntimes.times=0,u.hooksRuntimes.index=void 0,a=0,c=r,p.label=1;case 1:return a<c.length?(f=c[a],o++,"function"!=typeof f[t]||"function"==typeof f.enabled&&!f.enabled(t,n)?[3,3]:(null===(l=u.hooksRuntimes)||void 0===l?void 0:l.breakChain)?[3,4]:(u.hooksRuntimes.pluginName=f.pluginName,u.hooksRuntimes.hookName=t,u.hooksRuntimes.times++,u.hooksRuntimes.index=o,[4,f[t].apply(f,ru([n],e,!1))])):[3,4];case 2:if(void 0!==(s=p.sent())&&(i=s,u.hooksRuntimes.returnValue=s,u.hooksRuntimes.returnBreakChain))return[2,i];p.label=3;case 3:return a++,[3,1];case 4:return[2,i]}}))}))},t.prototype.execNoError=function(r,t){return Xi(this,0,void 0,(function(){var n;return Zi(this,(function(e){switch(e.label){case 0:return e.trys.push([0,2,,3]),[4,this.exec(r,t)];case 1:return[2,e.sent()];case 2:return(n=e.sent())instanceof uu?[2,n]:[2,new uu("UNKNOWN_ASYNC_ERROR",n)];case 3:return[2]}}))}))},t.prototype.exec=function(r,t){var n=t||r,e=t?r:void 0;if("function"!=typeof n)throw new Error("Task must be a async function!");return this.run(e,n)},t.prototype.run=function(r,t){return Xi(this,0,void 0,(function(){var n,e,o,i=this;return Zi(this,(function(u){switch(u.label){case 0:n={parameters:r,returnValue:void 0,error:void 0,hooksRuntimes:{pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0}},e=function(r){return Xi(i,0,void 0,(function(){var n;return Zi(this,(function(e){switch(e.label){case 0:return[4,this.runHooks(this.plugins,"onExec",r,t)];case 1:return e.sent(),0!==r.hooksRuntimes.times?[3,3]:(n=r,[4,t(r)]);case 2:return n.returnValue=e.sent(),[2];case 3:return r.returnValue=r.hooksRuntimes.returnValue,[2]}}))}))},u.label=1;case 1:return u.trys.push([1,5,7,8]),[4,this.runHooks(this.plugins,"onBefore",n)];case 2:return u.sent(),[4,e(n)];case 3:return u.sent(),[4,this.runHooks(this.plugins,"onSuccess",n)];case 4:return u.sent(),[2,n.returnValue];case 5:return o=u.sent(),n.error=o,[4,this.runHooks(this.plugins,"onError",n)];case 6:if(u.sent(),n.hooksRuntimes.returnValue&&(n.error=n.hooksRuntimes.returnValue),n.error instanceof uu)throw n.error;throw new uu("UNKNOWN_ASYNC_ERROR",n.error);case 7:return n.hooksRuntimes={pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0},[7];case 8:return[2]}}))}))}}(qi),function(r){function t(){return null!==r&&r.apply(this,arguments)||this}Qi(t,r),t.prototype.runHooks=function(r,t,n){for(var e,o=[],i=3;i<arguments.length;i++)o[i-3]=arguments[i];var u,a=-1,c=n||{parameters:void 0,hooksRuntimes:{}};c.hooksRuntimes.times=0,c.hooksRuntimes.index=void 0;for(var f=0,s=r;f<s.length;f++){var l=s[f];if(a++,"function"==typeof l[t]&&("function"!=typeof l.enabled||l.enabled(t,c))){if(null===(e=c.hooksRuntimes)||void 0===e?void 0:e.breakChain)break;c.hooksRuntimes.pluginName=l.pluginName,c.hooksRuntimes.hookName=t,c.hooksRuntimes.times++,c.hooksRuntimes.index=a;var p=l[t].apply(l,ru([n],o,!1));if(void 0!==p&&(u=p,c.hooksRuntimes.returnValue=p,c.hooksRuntimes.returnBreakChain))return u}}return u},t.prototype.execNoError=function(r,t){try{return this.exec(r,t)}catch(r){return r instanceof uu?r:new uu("UNKNOWN_SYNC_ERROR",r)}},t.prototype.exec=function(r,t){var n=t||r,e=t?r:void 0;if("function"!=typeof n)throw new Error("Task must be a function!");return this.run(e,n)},t.prototype.run=function(r,t){var n,e={parameters:r,returnValue:void 0,error:void 0,hooksRuntimes:{pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0}};try{return this.runHooks(this.plugins,"onBefore",e),n=e,this.runHooks(this.plugins,"onExec",n,t),n.returnValue=n.hooksRuntimes.times?n.hooksRuntimes.returnValue:t(n),this.runHooks(this.plugins,"onSuccess",e),e.returnValue}catch(r){if(e.error=r,this.runHooks(this.plugins,"onError",e),e.hooksRuntimes.returnValue&&(e.error=e.hooksRuntimes.returnValue),e.error instanceof uu)throw e.error;throw new uu("UNKNOWN_SYNC_ERROR",e.error)}finally{e.hooksRuntimes={pluginName:"",hookName:"",returnValue:void 0,returnBreakChain:!1,times:0}}}}(qi);var au="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function cu(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var fu,su,lu,pu,hu,vu,yu,gu,du,bu,_u,mu,Ou,ju,wu,Ru,ku,xu,Pu,Au,Eu,Nu,Su=cu(iu?ou:(iu=1,ou=eu?nu:(eu=1,nu=function(r){return r&&r.length?r[0]:void 0}))),Tu=cu(su?fu:(su=1,fu=function(r){var t=null==r?0:r.length;return t?r[t-1]:void 0}));function Cu(){if(vu)return hu;vu=1;var r=function(){if(pu)return lu;pu=1;var r="object"==typeof au&&au&&au.Object===Object&&au;return lu=r}(),t="object"==typeof self&&self&&self.Object===Object&&self,n=r||t||Function("return this")();return hu=n}function $u(){if(gu)return yu;gu=1;var r=Cu().Symbol;return yu=r}function zu(){if(ju)return Ou;ju=1;var r=$u(),t=function(){if(bu)return du;bu=1;var r=$u(),t=Object.prototype,n=t.hasOwnProperty,e=t.toString,o=r?r.toStringTag:void 0;return du=function(r){var t=n.call(r,o),i=r[o];try{r[o]=void 0;var u=!0}catch(r){}var a=e.call(r);return u&&(t?r[o]=i:delete r[o]),a}}(),n=function(){if(mu)return _u;mu=1;var r=Object.prototype.toString;return _u=function(t){return r.call(t)}}(),e=r?r.toStringTag:void 0;return Ou=function(r){return null==r?void 0===r?"[object Undefined]":"[object Null]":e&&e in Object(r)?t(r):n(r)}}function Bu(){return Au?Pu:(Au=1,Pu=function(r){return null!=r&&"object"==typeof r})}var Fu,Iu,Mu,Uu,Vu=cu(function(){if(Nu)return Eu;Nu=1;var r=zu(),t=function(){if(xu)return ku;xu=1;var r=(Ru?wu:(Ru=1,wu=function(r,t){return function(n){return r(t(n))}}))(Object.getPrototypeOf,Object);return ku=r}(),n=Bu(),e=Function.prototype,o=Object.prototype,i=e.toString,u=o.hasOwnProperty,a=i.call(Object);return Eu=function(e){if(!n(e)||"[object Object]"!=r(e))return!1;var o=t(e);if(null===o)return!0;var c=u.call(o,"constructor")&&o.constructor;return"function"==typeof c&&c instanceof c&&i.call(c)==a}}());function Du(){if(Iu)return Fu;Iu=1;var r=Array.isArray;return Fu=r}var Hu,Gu,Lu=function(){if(Uu)return Mu;Uu=1;var r=zu(),t=Du(),n=Bu();return Mu=function(e){return"string"==typeof e||!t(e)&&n(e)&&"[object String]"==r(e)}}(),Wu=cu(Lu),Yu=cu(Du());function Ju(){return Gu?Hu:(Gu=1,Hu=function(r){var t=typeof r;return null!=r&&("object"==t||"function"==t)})}var qu,Ku,Qu,Xu,Zu,ra,ta,na,ea,oa,ia,ua,aa,ca,fa,sa,la,pa,ha,va,ya,ga,da,ba,_a,ma,Oa,ja,wa,Ra,ka,xa,Pa,Aa,Ea,Na,Sa,Ta,Ca,$a,za,Ba,Fa,Ia,Ma,Ua,Va,Da,Ha,Ga,La,Wa,Ya,Ja,qa,Ka,Qa,Xa,Za,rc,tc,nc,ec,oc,ic,uc,ac,cc,fc,sc,lc,pc,hc,vc,yc,gc,dc,bc,_c,mc,Oc,jc,wc,Rc,kc,xc,Pc,Ac,Ec,Nc,Sc,Tc,Cc,$c,zc,Bc,Fc,Ic,Mc,Uc,Vc,Dc,Hc,Gc,Lc,Wc,Yc,Jc,qc,Kc,Qc,Xc,Zc,rf,tf,nf,ef,of,uf,af,cf,ff,sf,lf,pf,hf,vf,yf,gf,df,bf,_f,mf,Of,jf,wf,Rf,kf=cu(Ju()),xf="LOG",Pf="INFO",Af="ERROR",Ef="WARN",Nf="DEBUG",Sf=function(){function r(r){var t=void 0===r?{}:r,n=t.isCI,e=void 0!==n&&n,o=t.dryRun,i=void 0!==o&&o,u=t.debug,a=void 0!==u&&u,c=t.silent,f=void 0!==c&&c;this.isCI=e,this.isDryRun=i,this.isDebug=a,this.isSilent=f}return r.prototype.print=function(r){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.isSilent||console.log.apply(console,t)},r.prototype.prefix=function(r,t){return r},r.prototype.log=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([xf],r,!1))},r.prototype.info=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([Pf,this.prefix(Pf)],r,!1))},r.prototype.warn=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([Ef,this.prefix(Ef)],r,!1))},r.prototype.error=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.print.apply(this,ru([Af,this.prefix(Af)],r,!1))},r.prototype.debug=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];if(this.isDebug){var n=Su(r),e=kf(n)?JSON.stringify(n):String(n);this.print.apply(this,ru([Nf,this.prefix(Nf),e],r.slice(1),!1))}},r.prototype.verbose=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.isDebug&&this.print.apply(this,ru([Nf],r,!1))},r.prototype.exec=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];var n=Vu(Tu(r))?Tu(r):void 0,e=n||{},o=e.isDryRun,i=e.isExternal;if(o||this.isDryRun){var u=[null==i?"$":"!",r.slice(0,null==n?void 0:-1).map((function(r){return Wu(r)?r:Yu(r)?r.join(" "):String(r)})).join(" ")].join(" ").trim();this.log(u)}},r.prototype.obtrusive=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];this.isCI||this.log(),this.log.apply(this,r),this.isCI||this.log()},r}(),Tf={exports:{}},Cf=(qu||(qu=1,function(r,t){function n(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];return e.apply(void 0,r)}function e(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];return c(!0===r[0],!1,r)}function o(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];return c(!0===r[0],!0,r)}function i(r){if(Array.isArray(r)){for(var t=[],n=0;n<r.length;++n)t.push(i(r[n]));return t}if(u(r)){for(var n in t={},r)t[n]=i(r[n]);return t}return r}function u(r){return r&&"object"==typeof r&&!Array.isArray(r)}function a(r,t){if(!u(r))return t;for(var n in t)"__proto__"!==n&&"constructor"!==n&&"prototype"!==n&&(r[n]=u(r[n])&&u(t[n])?a(r[n],t[n]):t[n]);return r}function c(r,t,n){var e;!r&&u(e=n.shift())||(e={});for(var o=0;o<n.length;++o){var c=n[o];if(u(c))for(var f in c)if("__proto__"!==f&&"constructor"!==f&&"prototype"!==f){var s=r?i(c[f]):c[f];e[f]=t?a(e[f],s):s}}return e}Object.defineProperty(t,"__esModule",{value:!0}),t.isPlainObject=t.clone=t.recursive=t.merge=t.main=void 0,r.exports=t=n,t.default=n,t.main=n,n.clone=i,n.isPlainObject=u,n.recursive=o,t.merge=e,t.recursive=o,t.clone=i,t.isPlainObject=u}(Tf,Tf.exports)),Tf.exports);function $f(){if(Qu)return Ku;Qu=1;var r=zu(),t=Bu();return Ku=function(n){return"symbol"==typeof n||t(n)&&"[object Symbol]"==r(n)}}function zf(){if(fa)return ca;fa=1;var r=function(){if(ta)return ra;ta=1;var r=zu(),t=Ju();return ra=function(n){if(!t(n))return!1;var e=r(n);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}}(),t=function(){if(ia)return oa;ia=1;var r,t=function(){if(ea)return na;ea=1;var r=Cu()["__core-js_shared__"];return na=r}(),n=(r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";return oa=function(r){return!!n&&n in r}}(),n=Ju(),e=function(){if(aa)return ua;aa=1;var r=Function.prototype.toString;return ua=function(t){if(null!=t){try{return r.call(t)}catch(r){}try{return t+""}catch(r){}}return""}}(),o=/^\[object .+?Constructor\]$/,i=Function.prototype,u=Object.prototype,a=i.toString,c=u.hasOwnProperty,f=RegExp("^"+a.call(c).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");return ca=function(i){return!(!n(i)||t(i))&&(r(i)?f:o).test(e(i))}}function Bf(){if(ha)return pa;ha=1;var r=zf(),t=la?sa:(la=1,sa=function(r,t){return null==r?void 0:r[t]});return pa=function(n,e){var o=t(n,e);return r(o)?o:void 0}}function Ff(){if(ya)return va;ya=1;var r=Bf()(Object,"create");return va=r}function If(){return Sa?Na:(Sa=1,Na=function(r,t){return r===t||r!=r&&t!=t})}function Mf(){if(Ca)return Ta;Ca=1;var r=If();return Ta=function(t,n){for(var e=t.length;e--;)if(r(t[e][0],n))return e;return-1}}function Uf(){if(Ya)return Wa;Ya=1;var r=function(){if(Pa)return xa;Pa=1;var r=function(){if(da)return ga;da=1;var r=Ff();return ga=function(){this.__data__=r?r(null):{},this.size=0}}(),t=_a?ba:(_a=1,ba=function(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}),n=function(){if(Oa)return ma;Oa=1;var r=Ff(),t=Object.prototype.hasOwnProperty;return ma=function(n){var e=this.__data__;if(r){var o=e[n];return"__lodash_hash_undefined__"===o?void 0:o}return t.call(e,n)?e[n]:void 0}}(),e=function(){if(wa)return ja;wa=1;var r=Ff(),t=Object.prototype.hasOwnProperty;return ja=function(n){var e=this.__data__;return r?void 0!==e[n]:t.call(e,n)}}(),o=function(){if(ka)return Ra;ka=1;var r=Ff();return Ra=function(t,n){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=r&&void 0===n?"__lodash_hash_undefined__":n,this}}();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,xa=i}(),t=function(){if(Ha)return Da;Ha=1;var r=Ea?Aa:(Ea=1,Aa=function(){this.__data__=[],this.size=0}),t=function(){if(za)return $a;za=1;var r=Mf(),t=Array.prototype.splice;return $a=function(n){var e=this.__data__,o=r(e,n);return!(o<0||(o==e.length-1?e.pop():t.call(e,o,1),--this.size,0))}}(),n=function(){if(Fa)return Ba;Fa=1;var r=Mf();return Ba=function(t){var n=this.__data__,e=r(n,t);return e<0?void 0:n[e][1]}}(),e=function(){if(Ma)return Ia;Ma=1;var r=Mf();return Ia=function(t){return r(this.__data__,t)>-1}}(),o=function(){if(Va)return Ua;Va=1;var r=Mf();return Ua=function(t,n){var e=this.__data__,o=r(e,t);return o<0?(++this.size,e.push([t,n])):e[o][1]=n,this}}();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,Da=i}(),n=function(){if(La)return Ga;La=1;var r=Bf()(Cu(),"Map");return Ga=r}();return Wa=function(){this.size=0,this.__data__={hash:new r,map:new(n||t),string:new r}}}function Vf(){if(Qa)return Ka;Qa=1;var r=qa?Ja:(qa=1,Ja=function(r){var t=typeof r;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==r:null===r});return Ka=function(t,n){var e=t.__data__;return r(n)?e["string"==typeof n?"string":"hash"]:e.map}}function Df(){if(lc)return sc;lc=1;var r=function(){if(fc)return cc;fc=1;var r=function(){if(ac)return uc;ac=1;var r=Uf(),t=function(){if(Za)return Xa;Za=1;var r=Vf();return Xa=function(t){var n=r(this,t).delete(t);return this.size-=n?1:0,n}}(),n=function(){if(tc)return rc;tc=1;var r=Vf();return rc=function(t){return r(this,t).get(t)}}(),e=function(){if(ec)return nc;ec=1;var r=Vf();return nc=function(t){return r(this,t).has(t)}}(),o=function(){if(ic)return oc;ic=1;var r=Vf();return oc=function(t,n){var e=r(this,t),o=e.size;return e.set(t,n),this.size+=e.size==o?0:1,this}}();function i(r){var t=-1,n=null==r?0:r.length;for(this.clear();++t<n;){var e=r[t];this.set(e[0],e[1])}}return i.prototype.clear=r,i.prototype.delete=t,i.prototype.get=n,i.prototype.has=e,i.prototype.set=o,uc=i}();function t(n,e){if("function"!=typeof n||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var o=function(){var r=arguments,t=e?e.apply(this,r):r[0],i=o.cache;if(i.has(t))return i.get(t);var u=n.apply(this,r);return o.cache=i.set(t,u)||i,u};return o.cache=new(t.Cache||r),o}return t.Cache=r,cc=t}();return sc=function(t){var n=r(t,(function(r){return 500===e.size&&e.clear(),r})),e=n.cache;return n}}function Hf(){if(Oc)return mc;Oc=1;var r=Du(),t=function(){if(Zu)return Xu;Zu=1;var r=Du(),t=$f(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,e=/^\w*$/;return Xu=function(o,i){if(r(o))return!1;var u=typeof o;return!("number"!=u&&"symbol"!=u&&"boolean"!=u&&null!=o&&!t(o))||e.test(o)||!n.test(o)||null!=i&&o in Object(i)}}(),n=function(){if(hc)return pc;hc=1;var r=Df(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,e=r((function(r){var e=[];return 46===r.charCodeAt(0)&&e.push(""),r.replace(t,(function(r,t,o,i){e.push(o?i.replace(n,"$1"):t||r)})),e}));return pc=e}(),e=function(){if(_c)return bc;_c=1;var r=function(){if(dc)return gc;dc=1;var r=$u(),t=yc?vc:(yc=1,vc=function(r,t){for(var n=-1,e=null==r?0:r.length,o=Array(e);++n<e;)o[n]=t(r[n],n,r);return o}),n=Du(),e=$f(),o=r?r.prototype:void 0,i=o?o.toString:void 0;return gc=function r(o){if("string"==typeof o)return o;if(n(o))return t(o,r)+"";if(e(o))return i?i.call(o):"";var u=o+"";return"0"==u&&1/o==-1/0?"-0":u},gc}();return bc=function(t){return null==t?"":r(t)}}();return mc=function(o,i){return r(o)?o:t(o,i)?[o]:n(e(o))}}function Gf(){if(wc)return jc;wc=1;var r=$f();return jc=function(t){if("string"==typeof t||r(t))return t;var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}}function Lf(){if(Pc)return xc;Pc=1;var r=Bf(),t=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(r){}}();return xc=t}function Wf(){if(Cc)return Tc;Cc=1;var r=/^(?:0|[1-9]\d*)$/;return Tc=function(t,n){var e=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==e||"symbol"!=e&&r.test(t))&&t>-1&&t%1==0&&t<n}}function Yf(){if(Fc)return Bc;Fc=1;var r=function(){if(kc)return Rc;kc=1;var r=Hf(),t=Gf();return Rc=function(n,e){for(var o=0,i=(e=r(e,n)).length;null!=n&&o<i;)n=n[t(e[o++])];return o&&o==i?n:void 0}}(),t=function(){if(zc)return $c;zc=1;var r=function(){if(Sc)return Nc;Sc=1;var r=function(){if(Ec)return Ac;Ec=1;var r=Lf();return Ac=function(t,n,e){"__proto__"==n&&r?r(t,n,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[n]=e}}(),t=If(),n=Object.prototype.hasOwnProperty;return Nc=function(e,o,i){var u=e[o];n.call(e,o)&&t(u,i)&&(void 0!==i||o in e)||r(e,o,i)}}(),t=Hf(),n=Wf(),e=Ju(),o=Gf();return $c=function(i,u,a,c){if(!e(i))return i;for(var f=-1,s=(u=t(u,i)).length,l=s-1,p=i;null!=p&&++f<s;){var h=o(u[f]),v=a;if("__proto__"===h||"constructor"===h||"prototype"===h)return i;if(f!=l){var y=p[h];void 0===(v=c?c(y,h,p):void 0)&&(v=e(y)?y:n(u[f+1])?[]:{})}r(p,h,v),p=p[h]}return i}}(),n=Hf();return Bc=function(e,o,i){for(var u=-1,a=o.length,c={};++u<a;){var f=o[u],s=r(e,f);i(s,f)&&t(c,n(f,e),s)}return c}}function Jf(){if(Hc)return Dc;Hc=1;var r=function(){if(Vc)return Uc;Vc=1;var r=zu(),t=Bu();return Uc=function(n){return t(n)&&"[object Arguments]"==r(n)}}(),t=Bu(),n=Object.prototype,e=n.hasOwnProperty,o=n.propertyIsEnumerable,i=r(function(){return arguments}())?r:function(r){return t(r)&&e.call(r,"callee")&&!o.call(r,"callee")};return Dc=i}function qf(){if(qc)return Jc;qc=1;var r=Mc?Ic:(Mc=1,Ic=function(r,t){return null!=r&&t in Object(r)}),t=function(){if(Yc)return Wc;Yc=1;var r=Hf(),t=Jf(),n=Du(),e=Wf(),o=Lc?Gc:(Lc=1,Gc=function(r){return"number"==typeof r&&r>-1&&r%1==0&&r<=9007199254740991}),i=Gf();return Wc=function(u,a,c){for(var f=-1,s=(a=r(a,u)).length,l=!1;++f<s;){var p=i(a[f]);if(!(l=null!=u&&c(u,p)))break;u=u[p]}return l||++f!=s?l:!!(s=null==u?0:u.length)&&o(s)&&e(p,s)&&(n(u)||t(u))}}();return Jc=function(n,e){return null!=n&&t(n,e,r)}}function Kf(){if(mf)return _f;mf=1;var r=function(){if(gf)return yf;gf=1;var r=pf?lf:(pf=1,lf=function(r){return function(){return r}}),t=Lf(),n=vf?hf:(vf=1,hf=function(r){return r});return yf=t?function(n,e){return t(n,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:n}(),t=function(){if(bf)return df;bf=1;var r=Date.now;return df=function(t){var n=0,e=0;return function(){var o=r(),i=16-(o-e);if(e=o,i>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},df}(),n=t(r);return _f=n}function Qf(){if(jf)return Of;jf=1;var r=function(){if(uf)return of;uf=1;var r=function(){if(ef)return nf;ef=1;var r=Zc?Xc:(Zc=1,Xc=function(r,t){for(var n=-1,e=t.length,o=r.length;++n<e;)r[o+n]=t[n];return r}),t=function(){if(tf)return rf;tf=1;var r=$u(),t=Jf(),n=Du(),e=r?r.isConcatSpreadable:void 0;return rf=function(r){return n(r)||t(r)||!!(e&&r&&r[e])}}();return nf=function n(e,o,i,u,a){var c=-1,f=e.length;for(i||(i=t),a||(a=[]);++c<f;){var s=e[c];o>0&&i(s)?o>1?n(s,o-1,i,u,a):r(a,s):u||(a[a.length]=s)}return a},nf}();return of=function(t){return null!=t&&t.length?r(t,1):[]}}(),t=function(){if(sf)return ff;sf=1;var r=cf?af:(cf=1,af=function(r,t,n){switch(n.length){case 0:return r.call(t);case 1:return r.call(t,n[0]);case 2:return r.call(t,n[0],n[1]);case 3:return r.call(t,n[0],n[1],n[2])}return r.apply(t,n)}),t=Math.max;return ff=function(n,e,o){return e=t(void 0===e?n.length-1:e,0),function(){for(var i=arguments,u=-1,a=t(i.length-e,0),c=Array(a);++u<a;)c[u]=i[e+u];u=-1;for(var f=Array(e+1);++u<e;)f[u]=i[u];return f[e]=o(c),r(n,this,f)}},ff}(),n=Kf();return Of=function(e){return n(t(e,void 0,r),e+"")}}cu(Cf);var Xf,Zf=function(){if(Rf)return wf;Rf=1;var r=function(){if(Qc)return Kc;Qc=1;var r=Yf(),t=qf();return Kc=function(n,e){return r(n,e,(function(r,e){return t(n,e)}))}}(),t=Qf()((function(t,n){return null==t?{}:r(t,n)}));return wf=t}();cu(Zf);var rs=function(){function r(r){void 0===r&&(r={}),this.options=r,this[Xf]="JSONSerializer"}return r.prototype.createReplacer=function(r){return Array.isArray(r)?r:null===r?function(r,t){return"string"==typeof t?t.replace(/\r\n/g,"\n"):t}:"function"==typeof r?function(t,n){var e="string"==typeof n?n.replace(/\r\n/g,"\n"):n;return r.call(this,t,e)}:function(r,t){return"string"==typeof t?t.replace(/\r\n/g,"\n"):t}},r.prototype.stringify=function(r,t,n){try{var e=this.createReplacer(t);return Array.isArray(e)?JSON.stringify(r,e,n):JSON.stringify(r,e,null!=n?n:this.options.pretty?this.options.indent||2:void 0)}catch(r){if(r instanceof TypeError&&r.message.includes("circular"))throw new TypeError("Cannot stringify data with circular references");throw r}},r.prototype.parse=function(r,t){return JSON.parse(r,t)},r.prototype.serialize=function(r){return this.stringify(r,this.options.replacer||null,this.options.pretty?this.options.indent||2:void 0)},r.prototype.deserialize=function(r,t){try{return this.parse(r)}catch(r){return t}},r.prototype.serializeArray=function(r){return"["+r.map((function(r){return JSON.stringify(r)})).join(",")+"]"},r}();Xf=Symbol.toStringTag,function(){function r(r,t){void 0===t&&(t=new rs),this.storage=r,this.serializer=t,this.store={}}Object.defineProperty(r.prototype,"length",{get:function(){return this.storage?this.storage.length:Object.keys(this.store).length},enumerable:!1,configurable:!0}),r.prototype.setItem=function(r,t,n){var e={key:r,value:t,expire:n};"number"==typeof n&&n>0&&(e.expire=n);var o=this.serializer.serialize(e);this.storage?this.storage.setItem(r,o):this.store[r]=o},r.prototype.getItem=function(r,t){var n,e=this.storage?this.storage.getItem(r):this.store[r],o=null!=t?t:null;if(!e)return o;var i=this.serializer.deserialize(e,o);return"object"==typeof i?"number"==typeof i.expire&&i.expire<Date.now()?(this.removeItem(r),o):null!==(n=null==i?void 0:i.value)&&void 0!==n?n:o:o},r.prototype.removeItem=function(r){this.storage?this.storage.removeItem(r):delete this.store[r]},r.prototype.clear=function(){this.storage?this.storage.clear():this.store={}}}();const ts=(r=0)=>t=>`[${t+r}m`,ns=(r=0)=>t=>`[${38+r};5;${t}m`,es=(r=0)=>(t,n,e)=>`[${38+r};2;${t};${n};${e}m`,os={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};const is=function(){const r=new Map;for(const[t,n]of Object.entries(os)){for(const[t,e]of Object.entries(n))os[t]={open:`[${e[0]}m`,close:`[${e[1]}m`},n[t]=os[t],r.set(e[0],e[1]);Object.defineProperty(os,t,{value:n,enumerable:!1})}return Object.defineProperty(os,"codes",{value:r,enumerable:!1}),os.color.close="[39m",os.bgColor.close="[49m",os.color.ansi=ts(),os.color.ansi256=ns(),os.color.ansi16m=es(),os.bgColor.ansi=ts(10),os.bgColor.ansi256=ns(10),os.bgColor.ansi16m=es(10),Object.defineProperties(os,{rgbToAnsi256:{value:(r,t,n)=>r===t&&t===n?r<8?16:r>248?231:Math.round((r-8)/247*24)+232:16+36*Math.round(r/255*5)+6*Math.round(t/255*5)+Math.round(n/255*5),enumerable:!1},hexToRgb:{value(r){const t=/[a-f\d]{6}|[a-f\d]{3}/i.exec(r.toString(16));if(!t)return[0,0,0];let[n]=t;3===n.length&&(n=[...n].map((r=>r+r)).join(""));const e=Number.parseInt(n,16);return[e>>16&255,e>>8&255,255&e]},enumerable:!1},hexToAnsi256:{value:r=>os.rgbToAnsi256(...os.hexToRgb(r)),enumerable:!1},ansi256ToAnsi:{value(r){if(r<8)return 30+r;if(r<16)return r-8+90;let t,n,e;if(r>=232)t=(10*(r-232)+8)/255,n=t,e=t;else{const o=(r-=16)%36;t=Math.floor(r/36)/5,n=Math.floor(o/6)/5,e=o%6/5}const o=2*Math.max(t,n,e);if(0===o)return 30;let i=30+(Math.round(e)<<2|Math.round(n)<<1|Math.round(t));return 2===o&&(i+=60),i},enumerable:!1},rgbToAnsi:{value:(r,t,n)=>os.ansi256ToAnsi(os.rgbToAnsi256(r,t,n)),enumerable:!1},hexToAnsi:{value:r=>os.ansi256ToAnsi(os.hexToAnsi256(r)),enumerable:!1}}),os}(),us=(()=>{if(!("navigator"in globalThis))return 0;if(globalThis.navigator.userAgentData){const r=navigator.userAgentData.brands.find((({brand:r})=>"Chromium"===r));if(r&&r.version>93)return 3}return/\b(Chrome|Chromium)\//.test(globalThis.navigator.userAgent)?1:0})(),as=0!==us&&{level:us},cs={stdout:as,stderr:as};function fs(r,t,n){let e=r.indexOf(t);if(-1===e)return r;const o=t.length;let i=0,u="";do{u+=r.slice(i,e)+t+n,i=e+o,e=r.indexOf(t,i)}while(-1!==e);return u+=r.slice(i),u}const{stdout:ss,stderr:ls}=cs,ps=Symbol("GENERATOR"),hs=Symbol("STYLER"),vs=Symbol("IS_EMPTY"),ys=["ansi","ansi","ansi256","ansi16m"],gs=Object.create(null),ds=r=>{const t=(...r)=>r.join(" ");return((r,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");const n=ss?ss.level:0;r.level=void 0===t.level?n:t.level})(t,r),Object.setPrototypeOf(t,bs.prototype),t};function bs(r){return ds(r)}Object.setPrototypeOf(bs.prototype,Function.prototype);for(const[r,t]of Object.entries(is))gs[r]={get(){const n=ws(this,js(t.open,t.close,this[hs]),this[vs]);return Object.defineProperty(this,r,{value:n}),n}};gs.visible={get(){const r=ws(this,this[hs],!0);return Object.defineProperty(this,"visible",{value:r}),r}};const _s=(r,t,n,...e)=>"rgb"===r?"ansi16m"===t?is[n].ansi16m(...e):"ansi256"===t?is[n].ansi256(is.rgbToAnsi256(...e)):is[n].ansi(is.rgbToAnsi(...e)):"hex"===r?_s("rgb",t,n,...is.hexToRgb(...e)):is[n][r](...e),ms=["rgb","hex","ansi256"];for(const r of ms){gs[r]={get(){const{level:t}=this;return function(...n){const e=js(_s(r,ys[t],"color",...n),is.color.close,this[hs]);return ws(this,e,this[vs])}}};gs["bg"+r[0].toUpperCase()+r.slice(1)]={get(){const{level:t}=this;return function(...n){const e=js(_s(r,ys[t],"bgColor",...n),is.bgColor.close,this[hs]);return ws(this,e,this[vs])}}}}const Os=Object.defineProperties((()=>{}),{...gs,level:{enumerable:!0,get(){return this[ps].level},set(r){this[ps].level=r}}}),js=(r,t,n)=>{let e,o;return void 0===n?(e=r,o=t):(e=n.openAll+r,o=t+n.closeAll),{open:r,close:t,openAll:e,closeAll:o,parent:n}},ws=(r,t,n)=>{const e=(...r)=>Rs(e,1===r.length?""+r[0]:r.join(" "));return Object.setPrototypeOf(e,Os),e[ps]=r,e[hs]=t,e[vs]=n,e},Rs=(r,t)=>{if(r.level<=0||!t)return r[vs]?"":t;let n=r[hs];if(void 0===n)return t;const{openAll:e,closeAll:o}=n;if(t.includes(""))for(;void 0!==n;)t=fs(t,n.close,n.open),n=n.parent;const i=t.indexOf("\n");return-1!==i&&(t=function(r,t,n,e){let o=0,i="";do{const u="\r"===r[e-1];i+=r.slice(o,u?e-1:e)+t+(u?"\r\n":"\n")+n,o=e+1,e=r.indexOf("\n",o)}while(-1!==e);return i+=r.slice(o),i}(t,o,e,i)),e+t+o};Object.defineProperties(bs.prototype,gs);const ks=bs();bs({level:ls?ls.level:0});class xs extends Sf{prefix(r){switch(r){case"INFO":return ks.blue(r);case"WARN":return ks.yellow(r);case"ERROR":return ks.red(r);case"DEBUG":return ks.gray(r);default:return r}}obtrusive(r){const t=ks.bold(r);super.obtrusive(t)}}const Ps=(r,n)=>{const e=Array.isArray(r)?r.join(" "):r;return new Promise(((r,o)=>{t(e,{encoding:"utf-8",...n},((t,n,e)=>{let i;i=t?void 0===t.code?1:t.code:0,0===i?r(n.trim()):o(new Error(e||n))}))}))};function As(r){return new To({name:"fe-config",defaultConfig:Ji({},Co,r)})}class Es{logger;shell;feConfig;dryRun;verbose;options;constructor(r){const{logger:t,shell:n,feConfig:e,dryRun:o,verbose:i,options:u}=r||{},a=u||{};this.logger=t||new xs({debug:i,dryRun:o}),this.shell=n||new Wi({logger:this.logger,dryRun:o,execPromise:a.execPromise||Ps}),this.feConfig=As(e).config,this.dryRun=!!o,this.verbose=!!i,this.options=a}}export{To as ConfigSearch,Es as FeScriptContext,xs as ScriptsLogger,Wi as Shell,Co as defaultFeConfig,As as getFeConfigSearch};
|