@serverless-devs/s 2.0.100-beta.4 → 2.0.100-beta.5

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.
@@ -31,7 +31,7 @@ __p += '`),Y&&(O+=`' +
31
31
  function print() { __p += __j.call(arguments, '') }
32
32
  `:`;
33
33
  `)+O+`return __p
34
- }`;var G=il(function(){return Z(c,N+"return "+O).apply(i,p)});if(G.source=O,Ws(G))throw G;return G}function M0(e){return J(e).toLowerCase()}function H0(e){return J(e).toUpperCase()}function U0(e,t,n){if(e=J(e),e&&(n||t===i))return ho(e);if(!e||!(t=$e(t)))return e;var u=Qe(e),a=Qe(t),c=po(u,a),p=go(u,a)+1;return Nt(u,c,p).join("")}function W0(e,t,n){if(e=J(e),e&&(n||t===i))return e.slice(0,mo(e)+1);if(!e||!(t=$e(t)))return e;var u=Qe(e),a=go(u,Qe(t))+1;return Nt(u,0,a).join("")}function B0(e,t,n){if(e=J(e),e&&(n||t===i))return e.replace(Wi,"");if(!e||!(t=$e(t)))return e;var u=Qe(e),a=po(u,Qe(t));return Nt(u,a).join("")}function G0(e,t){var n=Fc,u=Pc;if(re(t)){var a="separator"in t?t.separator:a;n="length"in t?B(t.length):n,u="omission"in t?$e(t.omission):u}e=J(e);var c=e.length;if(an(e)){var p=Qe(e);c=p.length}if(n>=c)return e;var d=n-ln(u);if(d<1)return u;var _=p?Nt(p,0,d).join(""):e.slice(0,d);if(a===i)return _+u;if(p&&(d+=_.length-d),Bs(a)){if(e.slice(d).search(a)){var A,R=_;for(a.global||(a=is(a.source,J(Du.exec(a))+"g")),a.lastIndex=0;A=a.exec(R);)var O=A.index;_=_.slice(0,O===i?d:O)}}else if(e.indexOf($e(a),d)!=d){var I=_.lastIndexOf(a);I>-1&&(_=_.slice(0,I))}return _+u}function X0(e){return e=J(e),e&&th.test(e)?e.replace(Tu,Ep):e}var z0=gn(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),zs=sa("toUpperCase");function rl(e,t,n){return e=J(e),t=n?i:t,t===i?dp(e)?xp(e):sp(e):e.match(t)||[]}var il=z(function(e,t){try{return Le(e,i,t)}catch(n){return Ws(n)?n:new U(n)}}),V0=mt(function(e,t){return Me(t,function(n){n=at(n),gt(e,n,Hs(e[n],e))}),e});function j0(e){var t=e==null?0:e.length,n=P();return e=t?ne(e,function(u){if(typeof u[1]!="function")throw new He(f);return[n(u[0]),u[1]]}):[],z(function(u){for(var a=-1;++a<t;){var c=e[a];if(Le(c[0],this,u))return Le(c[1],this,u)}})}function Y0(e){return Ed(We(e,v))}function Vs(e){return function(){return e}}function K0(e,t){return e==null||e!==e?t:e}var Z0=oa(),J0=oa(!0);function Ie(e){return e}function js(e){return Po(typeof e=="function"?e:We(e,v))}function Q0(e){return Ho(We(e,v))}function k0(e,t){return Uo(e,We(t,v))}var ev=z(function(e,t){return function(n){return Gn(n,e,t)}}),tv=z(function(e,t){return function(n){return Gn(e,n,t)}});function Ys(e,t,n){var u=ce(t),a=zr(t,u);n==null&&!(re(t)&&(a.length||!u.length))&&(n=t,t=e,e=this,a=zr(t,ce(t)));var c=!(re(n)&&"chain"in n)||!!n.chain,p=Et(e);return Me(a,function(d){var _=t[d];e[d]=_,p&&(e.prototype[d]=function(){var A=this.__chain__;if(c||A){var R=e(this.__wrapped__),O=R.__actions__=Re(this.__actions__);return O.push({func:_,args:arguments,thisArg:e}),R.__chain__=A,R}return _.apply(e,St([this.value()],arguments))})}),e}function nv(){return fe._===this&&(fe._=Cp),this}function Ks(){}function rv(e){return e=B(e),z(function(t){return Wo(t,e)})}var iv=Ss(ne),sv=Ss(oo),uv=Ss(Ji);function sl(e){return Ns(e)?Qi(at(e)):Fd(e)}function ov(e){return function(t){return e==null?i:Gt(e,t)}}var av=la(),lv=la(!0);function Zs(){return[]}function Js(){return!1}function fv(){return{}}function cv(){return""}function hv(){return!0}function pv(e,t){if(e=B(e),e<1||e>Rt)return[];var n=st,u=ge(e,st);t=P(t),e-=st;for(var a=ts(u,t);++n<e;)t(n);return a}function dv(e){return W(e)?ne(e,at):Ne(e)?[e]:Re(Oa(J(e)))}function gv(e){var t=++Sp;return J(e)+t}var _v=Jr(function(e,t){return e+t},0),mv=Is("ceil"),vv=Jr(function(e,t){return e/t},1),Ev=Is("floor");function yv(e){return e&&e.length?Xr(e,Ie,hs):i}function wv(e,t){return e&&e.length?Xr(e,P(t,2),hs):i}function xv(e){return fo(e,Ie)}function Av(e,t){return fo(e,P(t,2))}function Rv(e){return e&&e.length?Xr(e,Ie,_s):i}function Ov(e,t){return e&&e.length?Xr(e,P(t,2),_s):i}var Sv=Jr(function(e,t){return e*t},1),Iv=Is("round"),Cv=Jr(function(e,t){return e-t},0);function bv(e){return e&&e.length?es(e,Ie):0}function Lv(e,t){return e&&e.length?es(e,P(t,2)):0}return l.after=Q_,l.ary=Fa,l.assign=Hm,l.assignIn=Za,l.assignInWith=fi,l.assignWith=Um,l.at=Wm,l.before=Pa,l.bind=Hs,l.bindAll=V0,l.bindKey=Ma,l.castArray=fm,l.chain=Na,l.chunk=Eg,l.compact=yg,l.concat=wg,l.cond=j0,l.conforms=Y0,l.constant=Vs,l.countBy=b_,l.create=Bm,l.curry=Ha,l.curryRight=Ua,l.debounce=Wa,l.defaults=Gm,l.defaultsDeep=Xm,l.defer=k_,l.delay=em,l.difference=xg,l.differenceBy=Ag,l.differenceWith=Rg,l.drop=Og,l.dropRight=Sg,l.dropRightWhile=Ig,l.dropWhile=Cg,l.fill=bg,l.filter=T_,l.flatMap=D_,l.flatMapDeep=q_,l.flatMapDepth=F_,l.flatten=ba,l.flattenDeep=Lg,l.flattenDepth=Tg,l.flip=tm,l.flow=Z0,l.flowRight=J0,l.fromPairs=$g,l.functions=Jm,l.functionsIn=Qm,l.groupBy=P_,l.initial=Dg,l.intersection=qg,l.intersectionBy=Fg,l.intersectionWith=Pg,l.invert=e0,l.invertBy=t0,l.invokeMap=H_,l.iteratee=js,l.keyBy=U_,l.keys=ce,l.keysIn=Se,l.map=ii,l.mapKeys=r0,l.mapValues=i0,l.matches=Q0,l.matchesProperty=k0,l.memoize=ui,l.merge=s0,l.mergeWith=Ja,l.method=ev,l.methodOf=tv,l.mixin=Ys,l.negate=oi,l.nthArg=rv,l.omit=u0,l.omitBy=o0,l.once=nm,l.orderBy=W_,l.over=iv,l.overArgs=rm,l.overEvery=sv,l.overSome=uv,l.partial=Us,l.partialRight=Ba,l.partition=B_,l.pick=a0,l.pickBy=Qa,l.property=sl,l.propertyOf=ov,l.pull=Wg,l.pullAll=Ta,l.pullAllBy=Bg,l.pullAllWith=Gg,l.pullAt=Xg,l.range=av,l.rangeRight=lv,l.rearg=im,l.reject=z_,l.remove=zg,l.rest=sm,l.reverse=Ps,l.sampleSize=j_,l.set=f0,l.setWith=c0,l.shuffle=Y_,l.slice=Vg,l.sortBy=J_,l.sortedUniq=kg,l.sortedUniqBy=e_,l.split=D0,l.spread=um,l.tail=t_,l.take=n_,l.takeRight=r_,l.takeRightWhile=i_,l.takeWhile=s_,l.tap=y_,l.throttle=om,l.thru=ri,l.toArray=ja,l.toPairs=ka,l.toPairsIn=el,l.toPath=dv,l.toPlainObject=Ka,l.transform=h0,l.unary=am,l.union=u_,l.unionBy=o_,l.unionWith=a_,l.uniq=l_,l.uniqBy=f_,l.uniqWith=c_,l.unset=p0,l.unzip=Ms,l.unzipWith=$a,l.update=d0,l.updateWith=g0,l.values=vn,l.valuesIn=_0,l.without=h_,l.words=rl,l.wrap=lm,l.xor=p_,l.xorBy=d_,l.xorWith=g_,l.zip=__,l.zipObject=m_,l.zipObjectDeep=v_,l.zipWith=E_,l.entries=ka,l.entriesIn=el,l.extend=Za,l.extendWith=fi,Ys(l,l),l.add=_v,l.attempt=il,l.camelCase=y0,l.capitalize=tl,l.ceil=mv,l.clamp=m0,l.clone=cm,l.cloneDeep=pm,l.cloneDeepWith=dm,l.cloneWith=hm,l.conformsTo=gm,l.deburr=nl,l.defaultTo=K0,l.divide=vv,l.endsWith=w0,l.eq=et,l.escape=x0,l.escapeRegExp=A0,l.every=L_,l.find=$_,l.findIndex=Ia,l.findKey=zm,l.findLast=N_,l.findLastIndex=Ca,l.findLastKey=Vm,l.floor=Ev,l.forEach=Da,l.forEachRight=qa,l.forIn=jm,l.forInRight=Ym,l.forOwn=Km,l.forOwnRight=Zm,l.get=Gs,l.gt=_m,l.gte=mm,l.has=km,l.hasIn=Xs,l.head=La,l.identity=Ie,l.includes=M_,l.indexOf=Ng,l.inRange=v0,l.invoke=n0,l.isArguments=Vt,l.isArray=W,l.isArrayBuffer=vm,l.isArrayLike=Oe,l.isArrayLikeObject=se,l.isBoolean=Em,l.isBuffer=Dt,l.isDate=ym,l.isElement=wm,l.isEmpty=xm,l.isEqual=Am,l.isEqualWith=Rm,l.isError=Ws,l.isFinite=Om,l.isFunction=Et,l.isInteger=Ga,l.isLength=ai,l.isMap=Xa,l.isMatch=Sm,l.isMatchWith=Im,l.isNaN=Cm,l.isNative=bm,l.isNil=Tm,l.isNull=Lm,l.isNumber=za,l.isObject=re,l.isObjectLike=ie,l.isPlainObject=Kn,l.isRegExp=Bs,l.isSafeInteger=$m,l.isSet=Va,l.isString=li,l.isSymbol=Ne,l.isTypedArray=mn,l.isUndefined=Nm,l.isWeakMap=Dm,l.isWeakSet=qm,l.join=Mg,l.kebabCase=R0,l.last=Ge,l.lastIndexOf=Hg,l.lowerCase=O0,l.lowerFirst=S0,l.lt=Fm,l.lte=Pm,l.max=yv,l.maxBy=wv,l.mean=xv,l.meanBy=Av,l.min=Rv,l.minBy=Ov,l.stubArray=Zs,l.stubFalse=Js,l.stubObject=fv,l.stubString=cv,l.stubTrue=hv,l.multiply=Sv,l.nth=Ug,l.noConflict=nv,l.noop=Ks,l.now=si,l.pad=I0,l.padEnd=C0,l.padStart=b0,l.parseInt=L0,l.random=E0,l.reduce=G_,l.reduceRight=X_,l.repeat=T0,l.replace=$0,l.result=l0,l.round=Iv,l.runInContext=g,l.sample=V_,l.size=K_,l.snakeCase=N0,l.some=Z_,l.sortedIndex=jg,l.sortedIndexBy=Yg,l.sortedIndexOf=Kg,l.sortedLastIndex=Zg,l.sortedLastIndexBy=Jg,l.sortedLastIndexOf=Qg,l.startCase=q0,l.startsWith=F0,l.subtract=Cv,l.sum=bv,l.sumBy=Lv,l.template=P0,l.times=pv,l.toFinite=yt,l.toInteger=B,l.toLength=Ya,l.toLower=M0,l.toNumber=Xe,l.toSafeInteger=Mm,l.toString=J,l.toUpper=H0,l.trim=U0,l.trimEnd=W0,l.trimStart=B0,l.truncate=G0,l.unescape=X0,l.uniqueId=gv,l.upperCase=z0,l.upperFirst=zs,l.each=Da,l.eachRight=qa,l.first=La,Ys(l,function(){var e={};return ut(l,function(t,n){Q.call(l.prototype,n)||(e[n]=t)}),e}(),{chain:!1}),l.VERSION=r,Me(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){l[e].placeholder=l}),Me(["drop","take"],function(e,t){j.prototype[e]=function(n){n=n===i?1:le(B(n),0);var u=this.__filtered__&&!t?new j(this):this.clone();return u.__filtered__?u.__takeCount__=ge(n,u.__takeCount__):u.__views__.push({size:ge(n,st),type:e+(u.__dir__<0?"Right":"")}),u},j.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Me(["filter","map","takeWhile"],function(e,t){var n=t+1,u=n==Cu||n==Wc;j.prototype[e]=function(a){var c=this.clone();return c.__iteratees__.push({iteratee:P(a,3),type:n}),c.__filtered__=c.__filtered__||u,c}}),Me(["head","last"],function(e,t){var n="take"+(t?"Right":"");j.prototype[e]=function(){return this[n](1).value()[0]}}),Me(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");j.prototype[e]=function(){return this.__filtered__?new j(this):this[n](1)}}),j.prototype.compact=function(){return this.filter(Ie)},j.prototype.find=function(e){return this.filter(e).head()},j.prototype.findLast=function(e){return this.reverse().find(e)},j.prototype.invokeMap=z(function(e,t){return typeof e=="function"?new j(this):this.map(function(n){return Gn(n,e,t)})}),j.prototype.reject=function(e){return this.filter(oi(P(e)))},j.prototype.slice=function(e,t){e=B(e);var n=this;return n.__filtered__&&(e>0||t<0)?new j(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=B(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},j.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},j.prototype.toArray=function(){return this.take(st)},ut(j.prototype,function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),u=/^(?:head|last)$/.test(t),a=l[u?"take"+(t=="last"?"Right":""):t],c=u||/^find/.test(t);!a||(l.prototype[t]=function(){var p=this.__wrapped__,d=u?[1]:arguments,_=p instanceof j,A=d[0],R=_||W(p),O=function(V){var Y=a.apply(l,St([V],d));return u&&I?Y[0]:Y};R&&n&&typeof A=="function"&&A.length!=1&&(_=R=!1);var I=this.__chain__,N=!!this.__actions__.length,M=c&&!I,G=_&&!N;if(!c&&R){p=G?p:new j(this);var H=e.apply(p,d);return H.__actions__.push({func:ri,args:[O],thisArg:i}),new Ue(H,I)}return M&&G?e.apply(this,d):(H=this.thru(O),M?u?H.value()[0]:H.value():H)})}),Me(["pop","push","shift","sort","splice","unshift"],function(e){var t=br[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",u=/^(?:pop|shift)$/.test(e);l.prototype[e]=function(){var a=arguments;if(u&&!this.__chain__){var c=this.value();return t.apply(W(c)?c:[],a)}return this[n](function(p){return t.apply(W(p)?p:[],a)})}}),ut(j.prototype,function(e,t){var n=l[t];if(n){var u=n.name+"";Q.call(hn,u)||(hn[u]=[]),hn[u].push({name:t,func:n})}}),hn[Zr(i,Ft).name]=[{name:"wrapper",func:i}],j.prototype.clone=Xp,j.prototype.reverse=zp,j.prototype.value=Vp,l.prototype.at=w_,l.prototype.chain=x_,l.prototype.commit=A_,l.prototype.next=R_,l.prototype.plant=S_,l.prototype.reverse=I_,l.prototype.toJSON=l.prototype.valueOf=l.prototype.value=C_,l.prototype.first=l.prototype.head,Fn&&(l.prototype[Fn]=O_),l},Ct=Ap();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(fe._=Ct,define(function(){return Ct})):Mt?((Mt.exports=Ct)._=Ct,ji._=Ct):fe._=Ct}).call(xn)});var mu=q(Ce=>{"use strict";var VE=Ce&&Ce.__awaiter||function(i,r,s,o){function f(h){return h instanceof s?h:new s(function(m){m(h)})}return new(s||(s=Promise))(function(h,m){function w(S){try{v(o.next(S))}catch($){m($)}}function y(S){try{v(o.throw(S))}catch($){m($)}}function v(S){S.done?h(S.value):f(S.value).then(w,y)}v((o=o.apply(i,r||[])).next())})},jE=Ce&&Ce.__generator||function(i,r){var s={label:0,sent:function(){if(h[0]&1)throw h[1];return h[1]},trys:[],ops:[]},o,f,h,m;return m={next:w(0),throw:w(1),return:w(2)},typeof Symbol=="function"&&(m[Symbol.iterator]=function(){return this}),m;function w(v){return function(S){return y([v,S])}}function y(v){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(h=v[0]&2?f.return:v[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,v[1])).done)return h;switch(f=0,h&&(v=[v[0]&2,h.value]),v[0]){case 0:case 1:h=v;break;case 4:return s.label++,{value:v[1],done:!1};case 5:s.label++,f=v[1],v=[0];continue;case 7:v=s.ops.pop(),s.trys.pop();continue;default:if(h=s.trys,!(h=h.length>0&&h[h.length-1])&&(v[0]===6||v[0]===2)){s=0;continue}if(v[0]===3&&(!h||v[1]>h[0]&&v[1]<h[3])){s.label=v[1];break}if(v[0]===6&&s.label<h[1]){s.label=h[1],h=v;break}if(h&&s.label<h[2]){s.label=h[2],s.ops.push(v);break}h[2]&&s.ops.pop(),s.trys.pop();continue}v=r.call(i,s)}catch(S){v=[6,S],f=0}finally{o=h=0}if(v[0]&5)throw v[1];return{value:v[0]?v[1]:void 0,done:!0}}},Ec=Ce&&Ce.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Ce,"__esModule",{value:!0});Ce.handlerProfileFile=Ce.getConfig=Ce.setConfig=void 0;var yc=Ec(require("path")),gu=Ec(fr()),lt=gu.default.fse,Oi=gu.default.jsyaml,_u=gu.default.getRootHome;function YE(i){var r=xc();lt.writeFileSync(r,Oi.dump(i))}function wc(){var i=xc();if(!lt.existsSync(i))return{};try{var r=Oi.load(lt.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function xc(){var i=yc.default.join(_u(),"set-config.yml");return lt.existsSync(i)||lt.createFileSync(i),i}function KE(i,r){var s=wc();s[i]=r,YE(s)}Ce.setConfig=KE;function ZE(i,r){var s=wc();return s[i]||r}Ce.getConfig=ZE;function JE(i){return VE(this,void 0,void 0,function(){var r,s,o,f,h,m,w;return jE(this,function(y){switch(y.label){case 0:if(r=i.filePath||"set-config.yml",s=yc.default.join(_u(),r),o=lt.existsSync(s),f={},o)return[3,5];h=_u(),y.label=1;case 1:return y.trys.push([1,2,,4]),lt.statSync(h),[3,4];case 2:return m=y.sent(),[4,lt.mkdirSync(h)];case 3:return y.sent(),[3,4];case 4:return[3,6];case 5:try{f=Oi.load(lt.readFileSync(s,"utf8"))||{}}catch(v){throw v}y.label=6;case 6:return i.read?[2,f]:(w=i.configKey||"",f[w]=i.data,[4,lt.writeFileSync(s,Oi.dump(f))]);case 7:return y.sent(),[2,f]}})})}Ce.handlerProfileFile=JE});var Ac=q((Fw,QE)=>{QE.exports={name:"@serverless-devs/s",version:"2.0.100-beta.4",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"MIT",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./shell/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.0.0","@types/jest":"^27.4.0","@types/lodash":"^4.14.168","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2",husky:"^4.2.3",inquirer:"^8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",lodash:"^4.17.20","os-locale":"5.0.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"beta"}}});var Eu=q(F=>{"use strict";var kE=F&&F.__createBinding||(Object.create?function(i,r,s,o){o===void 0&&(o=s),Object.defineProperty(i,o,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,o){o===void 0&&(o=s),i[o]=r[s]}),ey=F&&F.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),ty=F&&F.__importStar||function(i){if(i&&i.__esModule)return i;var r={};if(i!=null)for(var s in i)s!=="default"&&Object.prototype.hasOwnProperty.call(i,s)&&kE(r,i,s);return ey(r,i),r},An=F&&F.__awaiter||function(i,r,s,o){function f(h){return h instanceof s?h:new s(function(m){m(h)})}return new(s||(s=Promise))(function(h,m){function w(S){try{v(o.next(S))}catch($){m($)}}function y(S){try{v(o.throw(S))}catch($){m($)}}function v(S){S.done?h(S.value):f(S.value).then(w,y)}v((o=o.apply(i,r||[])).next())})},Rn=F&&F.__generator||function(i,r){var s={label:0,sent:function(){if(h[0]&1)throw h[1];return h[1]},trys:[],ops:[]},o,f,h,m;return m={next:w(0),throw:w(1),return:w(2)},typeof Symbol=="function"&&(m[Symbol.iterator]=function(){return this}),m;function w(v){return function(S){return y([v,S])}}function y(v){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(h=v[0]&2?f.return:v[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,v[1])).done)return h;switch(f=0,h&&(v=[v[0]&2,h.value]),v[0]){case 0:case 1:h=v;break;case 4:return s.label++,{value:v[1],done:!1};case 5:s.label++,f=v[1],v=[0];continue;case 7:v=s.ops.pop(),s.trys.pop();continue;default:if(h=s.trys,!(h=h.length>0&&h[h.length-1])&&(v[0]===6||v[0]===2)){s=0;continue}if(v[0]===3&&(!h||v[1]>h[0]&&v[1]<h[3])){s.label=v[1];break}if(v[0]===6&&s.label<h[1]){s.label=h[1],h=v;break}if(h&&s.label<h[2]){s.label=h[2],s.ops.push(v);break}h[2]&&s.ops.pop(),s.trys.pop();continue}v=r.call(i,s)}catch(S){v=[6,S],f=0}finally{o=h=0}if(v[0]&5)throw v[1];return{value:v[0]?v[1]:void 0,done:!0}}},vu=F&&F.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(F,"__esModule",{value:!0});F.emoji=F.mark=F.replaceTemplate=F.getTemplatekey=F.replaceFun=F.getLang=F.printn=F.getFolderSize=F.getVersion=F.getPid=F.aiRequest=F.getCredentialWithAll=F.getCredentialWithExisted=F.getCredentialAliasList=F.getProcessArgv=F.bgRed=F.yellow=F.red=void 0;var Rc=vu(require("path")),hr=vu(require("fs")),Ye=vc(),ny=vu(require("os")),Ke=ty(fr()),ry=mu(),Oc=Ac(),Si=Ke.default.colors,iy=Ke.default.got,sy=Ke.default.getMAC,uy=Ke.default.isDocker,oy=Ke.default.isCiCdEnv,ay=Ke.default.getGlobalArgs,ly=Ke.default.getYamlContent,fy=Ke.default.getRootHome,Sc=Ke.default.getCredential,cy=Ke.default.getCredentialFromEnv;F.red=Si.hex("#fd5750");F.yellow=Si.hex("#F3F99D");F.bgRed=Si.hex("#000").bgHex("#fd5750");var hy=function(){var i=process.env.serverless_devs_temp_argv;try{var r=JSON.parse(i),s=ay(r);return process.argv=process.argv.slice(0,2).concat(s._argsObj),(0,Ye.assign)({},s,{noHelpArgv:process.argv.slice(0,2).concat((0,Ye.filter)(s._argsObj,function(o){return!(0,Ye.includes)(["-h","--help"],o)}))})}catch{return{}}};F.getProcessArgv=hy;var py=function(){return An(void 0,void 0,void 0,function(){var i,r,s;return Rn(this,function(o){switch(o.label){case 0:return i=[],[4,ly(Rc.default.join(fy(),"access.yaml"))];case 1:return r=o.sent(),r&&(i=(0,Ye.keys)(r)),[4,cy()];case 2:return s=o.sent(),s&&(i=(0,Ye.filter)(i,function(f){return f!==s.Alias}),i.push(s.Alias)),[2,i]}})})};F.getCredentialAliasList=py;var dy=function(i){return An(void 0,void 0,void 0,function(){var r,s;return Rn(this,function(o){switch(o.label){case 0:return[4,(0,F.getCredentialAliasList)()];case 1:return r=o.sent(),(0,Ye.includes)(r,i)?[4,Sc(i)]:[3,3];case 2:return s=o.sent(),[2,(0,Ye.omit)(s,"Alias")];case 3:return[2]}})})};F.getCredentialWithExisted=dy;var gy=function(){return An(void 0,void 0,void 0,function(){var i,r,s,o,f,h;return Rn(this,function(m){switch(m.label){case 0:return[4,(0,F.getCredentialAliasList)()];case 1:if(i=m.sent(),!(i.length>0))return[3,6];r={},s=0,o=i,m.label=2;case 2:return s<o.length?(f=o[s],[4,Sc(f)]):[3,5];case 3:h=m.sent(),r[h.Alias]=(0,Ye.omit)(h,"Alias"),m.label=4;case 4:return s++,[3,2];case 5:return[2,r];case 6:return[2]}})})};F.getCredentialWithAll=gy;var _y=function(i,r){return r===void 0&&(r="unknow"),An(void 0,void 0,void 0,function(){var s,o,f,h;return Rn(this,function(m){switch(m.label){case 0:return m.trys.push([0,2,,3]),s=(0,ry.getConfig)("analysis"),s!=="enable"?[2]:uy()||oy()?[2]:[4,iy("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(r,"&code=TypeError&s=").concat(i),{timeout:2e3,json:!0})];case 1:return o=m.sent(),f=(0,Ye.get)(o.body,"shorturl"),f&&console.log(`AI Tips:
34
+ }`;var G=il(function(){return Z(c,N+"return "+O).apply(i,p)});if(G.source=O,Ws(G))throw G;return G}function M0(e){return J(e).toLowerCase()}function H0(e){return J(e).toUpperCase()}function U0(e,t,n){if(e=J(e),e&&(n||t===i))return ho(e);if(!e||!(t=$e(t)))return e;var u=Qe(e),a=Qe(t),c=po(u,a),p=go(u,a)+1;return Nt(u,c,p).join("")}function W0(e,t,n){if(e=J(e),e&&(n||t===i))return e.slice(0,mo(e)+1);if(!e||!(t=$e(t)))return e;var u=Qe(e),a=go(u,Qe(t))+1;return Nt(u,0,a).join("")}function B0(e,t,n){if(e=J(e),e&&(n||t===i))return e.replace(Wi,"");if(!e||!(t=$e(t)))return e;var u=Qe(e),a=po(u,Qe(t));return Nt(u,a).join("")}function G0(e,t){var n=Fc,u=Pc;if(re(t)){var a="separator"in t?t.separator:a;n="length"in t?B(t.length):n,u="omission"in t?$e(t.omission):u}e=J(e);var c=e.length;if(an(e)){var p=Qe(e);c=p.length}if(n>=c)return e;var d=n-ln(u);if(d<1)return u;var _=p?Nt(p,0,d).join(""):e.slice(0,d);if(a===i)return _+u;if(p&&(d+=_.length-d),Bs(a)){if(e.slice(d).search(a)){var A,R=_;for(a.global||(a=is(a.source,J(Du.exec(a))+"g")),a.lastIndex=0;A=a.exec(R);)var O=A.index;_=_.slice(0,O===i?d:O)}}else if(e.indexOf($e(a),d)!=d){var I=_.lastIndexOf(a);I>-1&&(_=_.slice(0,I))}return _+u}function X0(e){return e=J(e),e&&th.test(e)?e.replace(Tu,Ep):e}var z0=gn(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),zs=sa("toUpperCase");function rl(e,t,n){return e=J(e),t=n?i:t,t===i?dp(e)?xp(e):sp(e):e.match(t)||[]}var il=z(function(e,t){try{return Le(e,i,t)}catch(n){return Ws(n)?n:new U(n)}}),V0=mt(function(e,t){return Me(t,function(n){n=at(n),gt(e,n,Hs(e[n],e))}),e});function j0(e){var t=e==null?0:e.length,n=P();return e=t?ne(e,function(u){if(typeof u[1]!="function")throw new He(f);return[n(u[0]),u[1]]}):[],z(function(u){for(var a=-1;++a<t;){var c=e[a];if(Le(c[0],this,u))return Le(c[1],this,u)}})}function Y0(e){return Ed(We(e,v))}function Vs(e){return function(){return e}}function K0(e,t){return e==null||e!==e?t:e}var Z0=oa(),J0=oa(!0);function Ie(e){return e}function js(e){return Po(typeof e=="function"?e:We(e,v))}function Q0(e){return Ho(We(e,v))}function k0(e,t){return Uo(e,We(t,v))}var ev=z(function(e,t){return function(n){return Gn(n,e,t)}}),tv=z(function(e,t){return function(n){return Gn(e,n,t)}});function Ys(e,t,n){var u=ce(t),a=zr(t,u);n==null&&!(re(t)&&(a.length||!u.length))&&(n=t,t=e,e=this,a=zr(t,ce(t)));var c=!(re(n)&&"chain"in n)||!!n.chain,p=Et(e);return Me(a,function(d){var _=t[d];e[d]=_,p&&(e.prototype[d]=function(){var A=this.__chain__;if(c||A){var R=e(this.__wrapped__),O=R.__actions__=Re(this.__actions__);return O.push({func:_,args:arguments,thisArg:e}),R.__chain__=A,R}return _.apply(e,St([this.value()],arguments))})}),e}function nv(){return fe._===this&&(fe._=Cp),this}function Ks(){}function rv(e){return e=B(e),z(function(t){return Wo(t,e)})}var iv=Ss(ne),sv=Ss(oo),uv=Ss(Ji);function sl(e){return Ns(e)?Qi(at(e)):Fd(e)}function ov(e){return function(t){return e==null?i:Gt(e,t)}}var av=la(),lv=la(!0);function Zs(){return[]}function Js(){return!1}function fv(){return{}}function cv(){return""}function hv(){return!0}function pv(e,t){if(e=B(e),e<1||e>Rt)return[];var n=st,u=ge(e,st);t=P(t),e-=st;for(var a=ts(u,t);++n<e;)t(n);return a}function dv(e){return W(e)?ne(e,at):Ne(e)?[e]:Re(Oa(J(e)))}function gv(e){var t=++Sp;return J(e)+t}var _v=Jr(function(e,t){return e+t},0),mv=Is("ceil"),vv=Jr(function(e,t){return e/t},1),Ev=Is("floor");function yv(e){return e&&e.length?Xr(e,Ie,hs):i}function wv(e,t){return e&&e.length?Xr(e,P(t,2),hs):i}function xv(e){return fo(e,Ie)}function Av(e,t){return fo(e,P(t,2))}function Rv(e){return e&&e.length?Xr(e,Ie,_s):i}function Ov(e,t){return e&&e.length?Xr(e,P(t,2),_s):i}var Sv=Jr(function(e,t){return e*t},1),Iv=Is("round"),Cv=Jr(function(e,t){return e-t},0);function bv(e){return e&&e.length?es(e,Ie):0}function Lv(e,t){return e&&e.length?es(e,P(t,2)):0}return l.after=Q_,l.ary=Fa,l.assign=Hm,l.assignIn=Za,l.assignInWith=fi,l.assignWith=Um,l.at=Wm,l.before=Pa,l.bind=Hs,l.bindAll=V0,l.bindKey=Ma,l.castArray=fm,l.chain=Na,l.chunk=Eg,l.compact=yg,l.concat=wg,l.cond=j0,l.conforms=Y0,l.constant=Vs,l.countBy=b_,l.create=Bm,l.curry=Ha,l.curryRight=Ua,l.debounce=Wa,l.defaults=Gm,l.defaultsDeep=Xm,l.defer=k_,l.delay=em,l.difference=xg,l.differenceBy=Ag,l.differenceWith=Rg,l.drop=Og,l.dropRight=Sg,l.dropRightWhile=Ig,l.dropWhile=Cg,l.fill=bg,l.filter=T_,l.flatMap=D_,l.flatMapDeep=q_,l.flatMapDepth=F_,l.flatten=ba,l.flattenDeep=Lg,l.flattenDepth=Tg,l.flip=tm,l.flow=Z0,l.flowRight=J0,l.fromPairs=$g,l.functions=Jm,l.functionsIn=Qm,l.groupBy=P_,l.initial=Dg,l.intersection=qg,l.intersectionBy=Fg,l.intersectionWith=Pg,l.invert=e0,l.invertBy=t0,l.invokeMap=H_,l.iteratee=js,l.keyBy=U_,l.keys=ce,l.keysIn=Se,l.map=ii,l.mapKeys=r0,l.mapValues=i0,l.matches=Q0,l.matchesProperty=k0,l.memoize=ui,l.merge=s0,l.mergeWith=Ja,l.method=ev,l.methodOf=tv,l.mixin=Ys,l.negate=oi,l.nthArg=rv,l.omit=u0,l.omitBy=o0,l.once=nm,l.orderBy=W_,l.over=iv,l.overArgs=rm,l.overEvery=sv,l.overSome=uv,l.partial=Us,l.partialRight=Ba,l.partition=B_,l.pick=a0,l.pickBy=Qa,l.property=sl,l.propertyOf=ov,l.pull=Wg,l.pullAll=Ta,l.pullAllBy=Bg,l.pullAllWith=Gg,l.pullAt=Xg,l.range=av,l.rangeRight=lv,l.rearg=im,l.reject=z_,l.remove=zg,l.rest=sm,l.reverse=Ps,l.sampleSize=j_,l.set=f0,l.setWith=c0,l.shuffle=Y_,l.slice=Vg,l.sortBy=J_,l.sortedUniq=kg,l.sortedUniqBy=e_,l.split=D0,l.spread=um,l.tail=t_,l.take=n_,l.takeRight=r_,l.takeRightWhile=i_,l.takeWhile=s_,l.tap=y_,l.throttle=om,l.thru=ri,l.toArray=ja,l.toPairs=ka,l.toPairsIn=el,l.toPath=dv,l.toPlainObject=Ka,l.transform=h0,l.unary=am,l.union=u_,l.unionBy=o_,l.unionWith=a_,l.uniq=l_,l.uniqBy=f_,l.uniqWith=c_,l.unset=p0,l.unzip=Ms,l.unzipWith=$a,l.update=d0,l.updateWith=g0,l.values=vn,l.valuesIn=_0,l.without=h_,l.words=rl,l.wrap=lm,l.xor=p_,l.xorBy=d_,l.xorWith=g_,l.zip=__,l.zipObject=m_,l.zipObjectDeep=v_,l.zipWith=E_,l.entries=ka,l.entriesIn=el,l.extend=Za,l.extendWith=fi,Ys(l,l),l.add=_v,l.attempt=il,l.camelCase=y0,l.capitalize=tl,l.ceil=mv,l.clamp=m0,l.clone=cm,l.cloneDeep=pm,l.cloneDeepWith=dm,l.cloneWith=hm,l.conformsTo=gm,l.deburr=nl,l.defaultTo=K0,l.divide=vv,l.endsWith=w0,l.eq=et,l.escape=x0,l.escapeRegExp=A0,l.every=L_,l.find=$_,l.findIndex=Ia,l.findKey=zm,l.findLast=N_,l.findLastIndex=Ca,l.findLastKey=Vm,l.floor=Ev,l.forEach=Da,l.forEachRight=qa,l.forIn=jm,l.forInRight=Ym,l.forOwn=Km,l.forOwnRight=Zm,l.get=Gs,l.gt=_m,l.gte=mm,l.has=km,l.hasIn=Xs,l.head=La,l.identity=Ie,l.includes=M_,l.indexOf=Ng,l.inRange=v0,l.invoke=n0,l.isArguments=Vt,l.isArray=W,l.isArrayBuffer=vm,l.isArrayLike=Oe,l.isArrayLikeObject=se,l.isBoolean=Em,l.isBuffer=Dt,l.isDate=ym,l.isElement=wm,l.isEmpty=xm,l.isEqual=Am,l.isEqualWith=Rm,l.isError=Ws,l.isFinite=Om,l.isFunction=Et,l.isInteger=Ga,l.isLength=ai,l.isMap=Xa,l.isMatch=Sm,l.isMatchWith=Im,l.isNaN=Cm,l.isNative=bm,l.isNil=Tm,l.isNull=Lm,l.isNumber=za,l.isObject=re,l.isObjectLike=ie,l.isPlainObject=Kn,l.isRegExp=Bs,l.isSafeInteger=$m,l.isSet=Va,l.isString=li,l.isSymbol=Ne,l.isTypedArray=mn,l.isUndefined=Nm,l.isWeakMap=Dm,l.isWeakSet=qm,l.join=Mg,l.kebabCase=R0,l.last=Ge,l.lastIndexOf=Hg,l.lowerCase=O0,l.lowerFirst=S0,l.lt=Fm,l.lte=Pm,l.max=yv,l.maxBy=wv,l.mean=xv,l.meanBy=Av,l.min=Rv,l.minBy=Ov,l.stubArray=Zs,l.stubFalse=Js,l.stubObject=fv,l.stubString=cv,l.stubTrue=hv,l.multiply=Sv,l.nth=Ug,l.noConflict=nv,l.noop=Ks,l.now=si,l.pad=I0,l.padEnd=C0,l.padStart=b0,l.parseInt=L0,l.random=E0,l.reduce=G_,l.reduceRight=X_,l.repeat=T0,l.replace=$0,l.result=l0,l.round=Iv,l.runInContext=g,l.sample=V_,l.size=K_,l.snakeCase=N0,l.some=Z_,l.sortedIndex=jg,l.sortedIndexBy=Yg,l.sortedIndexOf=Kg,l.sortedLastIndex=Zg,l.sortedLastIndexBy=Jg,l.sortedLastIndexOf=Qg,l.startCase=q0,l.startsWith=F0,l.subtract=Cv,l.sum=bv,l.sumBy=Lv,l.template=P0,l.times=pv,l.toFinite=yt,l.toInteger=B,l.toLength=Ya,l.toLower=M0,l.toNumber=Xe,l.toSafeInteger=Mm,l.toString=J,l.toUpper=H0,l.trim=U0,l.trimEnd=W0,l.trimStart=B0,l.truncate=G0,l.unescape=X0,l.uniqueId=gv,l.upperCase=z0,l.upperFirst=zs,l.each=Da,l.eachRight=qa,l.first=La,Ys(l,function(){var e={};return ut(l,function(t,n){Q.call(l.prototype,n)||(e[n]=t)}),e}(),{chain:!1}),l.VERSION=r,Me(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){l[e].placeholder=l}),Me(["drop","take"],function(e,t){j.prototype[e]=function(n){n=n===i?1:le(B(n),0);var u=this.__filtered__&&!t?new j(this):this.clone();return u.__filtered__?u.__takeCount__=ge(n,u.__takeCount__):u.__views__.push({size:ge(n,st),type:e+(u.__dir__<0?"Right":"")}),u},j.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Me(["filter","map","takeWhile"],function(e,t){var n=t+1,u=n==Cu||n==Wc;j.prototype[e]=function(a){var c=this.clone();return c.__iteratees__.push({iteratee:P(a,3),type:n}),c.__filtered__=c.__filtered__||u,c}}),Me(["head","last"],function(e,t){var n="take"+(t?"Right":"");j.prototype[e]=function(){return this[n](1).value()[0]}}),Me(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");j.prototype[e]=function(){return this.__filtered__?new j(this):this[n](1)}}),j.prototype.compact=function(){return this.filter(Ie)},j.prototype.find=function(e){return this.filter(e).head()},j.prototype.findLast=function(e){return this.reverse().find(e)},j.prototype.invokeMap=z(function(e,t){return typeof e=="function"?new j(this):this.map(function(n){return Gn(n,e,t)})}),j.prototype.reject=function(e){return this.filter(oi(P(e)))},j.prototype.slice=function(e,t){e=B(e);var n=this;return n.__filtered__&&(e>0||t<0)?new j(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=B(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},j.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},j.prototype.toArray=function(){return this.take(st)},ut(j.prototype,function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),u=/^(?:head|last)$/.test(t),a=l[u?"take"+(t=="last"?"Right":""):t],c=u||/^find/.test(t);!a||(l.prototype[t]=function(){var p=this.__wrapped__,d=u?[1]:arguments,_=p instanceof j,A=d[0],R=_||W(p),O=function(V){var Y=a.apply(l,St([V],d));return u&&I?Y[0]:Y};R&&n&&typeof A=="function"&&A.length!=1&&(_=R=!1);var I=this.__chain__,N=!!this.__actions__.length,M=c&&!I,G=_&&!N;if(!c&&R){p=G?p:new j(this);var H=e.apply(p,d);return H.__actions__.push({func:ri,args:[O],thisArg:i}),new Ue(H,I)}return M&&G?e.apply(this,d):(H=this.thru(O),M?u?H.value()[0]:H.value():H)})}),Me(["pop","push","shift","sort","splice","unshift"],function(e){var t=br[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",u=/^(?:pop|shift)$/.test(e);l.prototype[e]=function(){var a=arguments;if(u&&!this.__chain__){var c=this.value();return t.apply(W(c)?c:[],a)}return this[n](function(p){return t.apply(W(p)?p:[],a)})}}),ut(j.prototype,function(e,t){var n=l[t];if(n){var u=n.name+"";Q.call(hn,u)||(hn[u]=[]),hn[u].push({name:t,func:n})}}),hn[Zr(i,Ft).name]=[{name:"wrapper",func:i}],j.prototype.clone=Xp,j.prototype.reverse=zp,j.prototype.value=Vp,l.prototype.at=w_,l.prototype.chain=x_,l.prototype.commit=A_,l.prototype.next=R_,l.prototype.plant=S_,l.prototype.reverse=I_,l.prototype.toJSON=l.prototype.valueOf=l.prototype.value=C_,l.prototype.first=l.prototype.head,Fn&&(l.prototype[Fn]=O_),l},Ct=Ap();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(fe._=Ct,define(function(){return Ct})):Mt?((Mt.exports=Ct)._=Ct,ji._=Ct):fe._=Ct}).call(xn)});var mu=q(Ce=>{"use strict";var VE=Ce&&Ce.__awaiter||function(i,r,s,o){function f(h){return h instanceof s?h:new s(function(m){m(h)})}return new(s||(s=Promise))(function(h,m){function w(S){try{v(o.next(S))}catch($){m($)}}function y(S){try{v(o.throw(S))}catch($){m($)}}function v(S){S.done?h(S.value):f(S.value).then(w,y)}v((o=o.apply(i,r||[])).next())})},jE=Ce&&Ce.__generator||function(i,r){var s={label:0,sent:function(){if(h[0]&1)throw h[1];return h[1]},trys:[],ops:[]},o,f,h,m;return m={next:w(0),throw:w(1),return:w(2)},typeof Symbol=="function"&&(m[Symbol.iterator]=function(){return this}),m;function w(v){return function(S){return y([v,S])}}function y(v){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(h=v[0]&2?f.return:v[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,v[1])).done)return h;switch(f=0,h&&(v=[v[0]&2,h.value]),v[0]){case 0:case 1:h=v;break;case 4:return s.label++,{value:v[1],done:!1};case 5:s.label++,f=v[1],v=[0];continue;case 7:v=s.ops.pop(),s.trys.pop();continue;default:if(h=s.trys,!(h=h.length>0&&h[h.length-1])&&(v[0]===6||v[0]===2)){s=0;continue}if(v[0]===3&&(!h||v[1]>h[0]&&v[1]<h[3])){s.label=v[1];break}if(v[0]===6&&s.label<h[1]){s.label=h[1],h=v;break}if(h&&s.label<h[2]){s.label=h[2],s.ops.push(v);break}h[2]&&s.ops.pop(),s.trys.pop();continue}v=r.call(i,s)}catch(S){v=[6,S],f=0}finally{o=h=0}if(v[0]&5)throw v[1];return{value:v[0]?v[1]:void 0,done:!0}}},Ec=Ce&&Ce.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Ce,"__esModule",{value:!0});Ce.handlerProfileFile=Ce.getConfig=Ce.setConfig=void 0;var yc=Ec(require("path")),gu=Ec(fr()),lt=gu.default.fse,Oi=gu.default.jsyaml,_u=gu.default.getRootHome;function YE(i){var r=xc();lt.writeFileSync(r,Oi.dump(i))}function wc(){var i=xc();if(!lt.existsSync(i))return{};try{var r=Oi.load(lt.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function xc(){var i=yc.default.join(_u(),"set-config.yml");return lt.existsSync(i)||lt.createFileSync(i),i}function KE(i,r){var s=wc();s[i]=r,YE(s)}Ce.setConfig=KE;function ZE(i,r){var s=wc();return s[i]||r}Ce.getConfig=ZE;function JE(i){return VE(this,void 0,void 0,function(){var r,s,o,f,h,m,w;return jE(this,function(y){switch(y.label){case 0:if(r=i.filePath||"set-config.yml",s=yc.default.join(_u(),r),o=lt.existsSync(s),f={},o)return[3,5];h=_u(),y.label=1;case 1:return y.trys.push([1,2,,4]),lt.statSync(h),[3,4];case 2:return m=y.sent(),[4,lt.mkdirSync(h)];case 3:return y.sent(),[3,4];case 4:return[3,6];case 5:try{f=Oi.load(lt.readFileSync(s,"utf8"))||{}}catch(v){throw v}y.label=6;case 6:return i.read?[2,f]:(w=i.configKey||"",f[w]=i.data,[4,lt.writeFileSync(s,Oi.dump(f))]);case 7:return y.sent(),[2,f]}})})}Ce.handlerProfileFile=JE});var Ac=q((Fw,QE)=>{QE.exports={name:"@serverless-devs/s",version:"2.0.100-beta.5",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"MIT",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./shell/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.0.0","@types/jest":"^27.4.0","@types/lodash":"^4.14.168","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2",husky:"^4.2.3",inquirer:"^8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",lodash:"^4.17.20","os-locale":"5.0.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"beta"}}});var Eu=q(F=>{"use strict";var kE=F&&F.__createBinding||(Object.create?function(i,r,s,o){o===void 0&&(o=s),Object.defineProperty(i,o,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,o){o===void 0&&(o=s),i[o]=r[s]}),ey=F&&F.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),ty=F&&F.__importStar||function(i){if(i&&i.__esModule)return i;var r={};if(i!=null)for(var s in i)s!=="default"&&Object.prototype.hasOwnProperty.call(i,s)&&kE(r,i,s);return ey(r,i),r},An=F&&F.__awaiter||function(i,r,s,o){function f(h){return h instanceof s?h:new s(function(m){m(h)})}return new(s||(s=Promise))(function(h,m){function w(S){try{v(o.next(S))}catch($){m($)}}function y(S){try{v(o.throw(S))}catch($){m($)}}function v(S){S.done?h(S.value):f(S.value).then(w,y)}v((o=o.apply(i,r||[])).next())})},Rn=F&&F.__generator||function(i,r){var s={label:0,sent:function(){if(h[0]&1)throw h[1];return h[1]},trys:[],ops:[]},o,f,h,m;return m={next:w(0),throw:w(1),return:w(2)},typeof Symbol=="function"&&(m[Symbol.iterator]=function(){return this}),m;function w(v){return function(S){return y([v,S])}}function y(v){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(h=v[0]&2?f.return:v[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,v[1])).done)return h;switch(f=0,h&&(v=[v[0]&2,h.value]),v[0]){case 0:case 1:h=v;break;case 4:return s.label++,{value:v[1],done:!1};case 5:s.label++,f=v[1],v=[0];continue;case 7:v=s.ops.pop(),s.trys.pop();continue;default:if(h=s.trys,!(h=h.length>0&&h[h.length-1])&&(v[0]===6||v[0]===2)){s=0;continue}if(v[0]===3&&(!h||v[1]>h[0]&&v[1]<h[3])){s.label=v[1];break}if(v[0]===6&&s.label<h[1]){s.label=h[1],h=v;break}if(h&&s.label<h[2]){s.label=h[2],s.ops.push(v);break}h[2]&&s.ops.pop(),s.trys.pop();continue}v=r.call(i,s)}catch(S){v=[6,S],f=0}finally{o=h=0}if(v[0]&5)throw v[1];return{value:v[0]?v[1]:void 0,done:!0}}},vu=F&&F.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(F,"__esModule",{value:!0});F.emoji=F.mark=F.replaceTemplate=F.getTemplatekey=F.replaceFun=F.getLang=F.printn=F.getFolderSize=F.getVersion=F.getPid=F.aiRequest=F.getCredentialWithAll=F.getCredentialWithExisted=F.getCredentialAliasList=F.getProcessArgv=F.bgRed=F.yellow=F.red=void 0;var Rc=vu(require("path")),hr=vu(require("fs")),Ye=vc(),ny=vu(require("os")),Ke=ty(fr()),ry=mu(),Oc=Ac(),Si=Ke.default.colors,iy=Ke.default.got,sy=Ke.default.getMAC,uy=Ke.default.isDocker,oy=Ke.default.isCiCdEnv,ay=Ke.default.getGlobalArgs,ly=Ke.default.getYamlContent,fy=Ke.default.getRootHome,Sc=Ke.default.getCredential,cy=Ke.default.getCredentialFromEnv;F.red=Si.hex("#fd5750");F.yellow=Si.hex("#F3F99D");F.bgRed=Si.hex("#000").bgHex("#fd5750");var hy=function(){var i=process.env.serverless_devs_temp_argv;try{var r=JSON.parse(i),s=ay(r);return process.argv=process.argv.slice(0,2).concat(s._argsObj),(0,Ye.assign)({},s,{noHelpArgv:process.argv.slice(0,2).concat((0,Ye.filter)(s._argsObj,function(o){return!(0,Ye.includes)(["-h","--help"],o)}))})}catch{return{}}};F.getProcessArgv=hy;var py=function(){return An(void 0,void 0,void 0,function(){var i,r,s;return Rn(this,function(o){switch(o.label){case 0:return i=[],[4,ly(Rc.default.join(fy(),"access.yaml"))];case 1:return r=o.sent(),r&&(i=(0,Ye.keys)(r)),[4,cy()];case 2:return s=o.sent(),s&&(i=(0,Ye.filter)(i,function(f){return f!==s.Alias}),i.push(s.Alias)),[2,i]}})})};F.getCredentialAliasList=py;var dy=function(i){return An(void 0,void 0,void 0,function(){var r,s;return Rn(this,function(o){switch(o.label){case 0:return[4,(0,F.getCredentialAliasList)()];case 1:return r=o.sent(),(0,Ye.includes)(r,i)?[4,Sc(i)]:[3,3];case 2:return s=o.sent(),[2,(0,Ye.omit)(s,"Alias")];case 3:return[2]}})})};F.getCredentialWithExisted=dy;var gy=function(){return An(void 0,void 0,void 0,function(){var i,r,s,o,f,h;return Rn(this,function(m){switch(m.label){case 0:return[4,(0,F.getCredentialAliasList)()];case 1:if(i=m.sent(),!(i.length>0))return[3,6];r={},s=0,o=i,m.label=2;case 2:return s<o.length?(f=o[s],[4,Sc(f)]):[3,5];case 3:h=m.sent(),r[h.Alias]=(0,Ye.omit)(h,"Alias"),m.label=4;case 4:return s++,[3,2];case 5:return[2,r];case 6:return[2]}})})};F.getCredentialWithAll=gy;var _y=function(i,r){return r===void 0&&(r="unknow"),An(void 0,void 0,void 0,function(){var s,o,f,h;return Rn(this,function(m){switch(m.label){case 0:return m.trys.push([0,2,,3]),s=(0,ry.getConfig)("analysis"),s!=="enable"?[2]:uy()||oy()?[2]:[4,iy("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(r,"&code=TypeError&s=").concat(i),{timeout:2e3,json:!0})];case 1:return o=m.sent(),f=(0,Ye.get)(o.body,"shorturl"),f&&console.log(`AI Tips:
35
35
  You can try to solve the problem through: `.concat(Si.underline(f),`
36
36
  `)),[3,3];case 2:return h=m.sent(),[3,3];case 3:return[2]}})})};F.aiRequest=_y;var my=function(){try{return sy().replace(/:/g,"")}catch{return"unknown"}};F.getPid=my;function vy(){var i=(0,Ke.getCoreVersion)(),r="".concat(process.platform,"-").concat(process.arch),s="node-".concat(process.version),o="core: ".concat(i),f="s-home: ".concat(Ke.default.getRootHome()),h="".concat(Oc.name,": ").concat(Oc.version);return i?"".concat(h,", ").concat(o,", ").concat(f,", ").concat(r,", ").concat(s):"".concat(h,", ").concat(f,", ").concat(r,", ").concat(s)}F.getVersion=vy;function Ey(i){return An(this,void 0,void 0,function(){function r(f){return An(this,void 0,void 0,function(){var h,m;return Rn(this,function(w){switch(w.label){case 0:return h=hr.default.lstatSync(f),typeof h!="object"?[2]:(s.set(h.ino,h.size),h.isDirectory()?(m=hr.default.readdirSync(f),typeof m!="object"?[2]:[4,Promise.all(m.map(function(y){return r(Rc.default.join(f,y))}))]):[3,2]);case 1:w.sent(),w.label=2;case 2:return[2]}})})}var s,o;return Rn(this,function(f){switch(f.label){case 0:return s=new Map,[4,r(i)];case 1:return f.sent(),o=Array.from(s.values()).reduce(function(h,m){return h+m},0),[2,o]}})})}F.getFolderSize=Ey;function yy(i,r){r===void 0&&(r=" ");for(var s="",o=0;o<i;o++)s=s+r;return s}F.printn=yy;function wy(){return"en"}F.getLang=wy;function Ic(i,r){var s=/\{\{(.*?)\}\}/g,o=i.match(s);if(o)for(var f=0;f<o.length;f++){var h=o[f].replace(/{{|}}/g,""),m=(0,Ye.trim)(h.split("|")[0]);r[m]&&(i=i.replace(o[f],r[m]))}return i}F.replaceFun=Ic;function xy(i){var r=/\{\{(.*?)\}\}/g,s=i.match(r);return s?s.filter(function(o){return o}).map(function(o){var f=o.replace(/{{|}}/g,""),h=f.split("|");return{name:(0,Ye.trim)(h[0]),desc:(0,Ye.trim)(h[1])}}):[]}F.getTemplatekey=xy;function Ay(i,r){i.forEach(function(s){if(hr.default.existsSync(s)){var o=hr.default.readFileSync(s,"utf-8"),f=Ic(o,r);hr.default.writeFileSync(s,f,"utf-8")}})}F.replaceTemplate=Ay;function Ry(i){if(!i)return i;var r=i.slice(-4);return"***********".concat(r)}F.mark=Ry;function Oy(i,r){return ny.default.platform()==="win32"?r||"\u25C6":"".concat(i," ")}F.emoji=Oy});var Cc=q(yu=>{"use strict";Object.defineProperty(yu,"__esModule",{value:!0});yu.default={clean_up_the_environment:"\u6E05\u7406\u73AF\u5883",display_help_for_command:"\u663E\u793A\u547D\u4EE4\u5E2E\u52A9",remove_components:"\u5220\u9664\u7EC4\u4EF6",delete_the_file_under_the_cache:"\u5220\u9664\u7F13\u5B58\u91CC\u7684\u7684<dirname>\u6587\u4EF6",record_your_log_information:"\u662F\u5426\u8BB0\u5F55\u60A8\u7684\u65E5\u5FD7\u4FE1\u606F\uFF1F",init_pproject_deploy_tip:"\u662F\u5426\u7ACB\u5373\u90E8\u7F72\u8BE5\u9879\u76EE\uFF1F",tip_for_a_serverless_project:"\u68C0\u6D4B\u5230\u5F53\u524D\u76EE\u5F55\u4E0B\u5DF2\u5B58\u5728\u4E00\u4E2AServerless-Devs\u9879\u76EE\uFF0C\u8BF7\u901A\u8FC7 's deploy' \u8FDB\u884C\u90E8\u7F72\u6216\u901A\u8FC7 's -h' \u83B7\u53D6\u66F4\u591A\u4FE1\u606F",create_a_new_project:"\u672A\u68C0\u6D4B\u5230 Serverless-Devs \u9879\u76EE\uFF0C\u662F\u5426\u65B0\u5EFA\u4E00\u4E2A\u9879\u76EE\uFF1F",en:"English (en)",zh:"\u4E2D\u6587 (zh)",select_current_language:"\u8BF7\u9009\u62E9\u5F53\u524D\u8BED\u8A00","app-tip":"\u8BF7\u9009\u62E9\u60A8\u5E0C\u671B\u521B\u5EFA\u7684 Serverless-Devs \u5E94\u7528","template-tip":"\u8BF7\u9009\u62E9\u60A8\u559C\u6B22\u7684\u6A21\u7248","fc-runtime-starter":"fc-runtime-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A FC \u51FD\u6570","fc-custom-container-stater":"fc-custom-container-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A custom-container \u5E94\u7528",web:"web-framework-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Web \u6846\u67B6","static-site":"static-website-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","best-practice":"serverless-best-practice - \u5FEB\u901F\u4F53\u9A8C Serverless \u6700\u4F73\u5B9E\u8DF5","devs-template":"Serverless Devs \u5F00\u53D1\u6A21\u677F","fc-http-nodejs":"fc-http-nodejs - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nodejs12 \u51FD\u6570","fc-http-python":"fc-http-python - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A python3 \u51FD\u6570","fc-http-java":"fc-http-java - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A java8 \u51FD\u6570","fc-custom-container-event-python3":"fc-custom-container-event-python3 - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 python3 \u5E94\u7528","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 cpp \u5E94\u7528","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 springboot \u5E94\u7528","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 aspdotnetcore \u5E94\u7528","express-starter":"express-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A express \u57FA\u7840\u5E94\u7528","koa-starter":"koa-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A koa \u57FA\u7840\u5E94\u7528","nuxtjs-starter":"nuxtjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nuxtjs \u57FA\u7840\u5E94\u7528","eggjs-starter":"eggjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A eggjs \u57FA\u7840\u5E94\u7528","flask-starter":"flask-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A flask \u57FA\u7840\u5E94\u7528","SpringBoot-starter":"SpringBoot-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A SpringBoot \u57FA\u7840\u5E94\u7528","Zblog-starter":"Zblog-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Zblog \u57FA\u7840\u5E94\u7528","website-starter":"website-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","react-starter":"react-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A React.js \u5E94\u7528","vue-starter":"vue-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Vue.js \u5E94\u7528",puppeteer:"puppeteer - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E puppeteer \u622A\u56FE\u7684 Web \u5E94\u7528",ffmpeg:"ffmpeg - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E ffmpeg \u5B9E\u73B0\u97F3\u89C6\u9891\u5904\u7406\u5E94\u7528",pdf2Img:"pdf2Img - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A pdf \u8F6C\u56FE\u7247\u5E94\u7528",tensorflow:"tensorflow - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A tensorflow \u5E94\u7528",todoList:"todoList - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E nodejs \u7684\u7F51\u9875 TodoList \u5E94\u7528"}});var bc=q(wu=>{"use strict";Object.defineProperty(wu,"__esModule",{value:!0});wu.default={clean_up_the_environment:"Clean up the environment",display_help_for_command:"Display help for command",remove_components:"Remove component (like: fc, fc@0.0.1)",delete_the_file_under_the_cache:"Delete the <dirname> file in the cache",record_your_log_information:"Do you record your log information?",init_pproject_deploy_tip:"Do you want to deploy the project immediately?",tip_for_a_serverless_project:"A Serverless-Devs project is detected in the current directory, please deploy via 's deploy' or get more information via 's -h'",create_a_new_project:"No Serverless-Devs project is currently detected. Do you want to create a new project?",en:"English (en)",zh:"Chinese (zh)",select_current_language:"Please select current language","app-tip":"Hello, serverlesser. Which template do you like?","template-tip":"Which template do you like?","fc-runtime-starter":"fc-runtime-starter - Deploy FC function in 5 minutes","fc-custom-container-stater":"fc-custom-container-stater - Deploy FC function with custom-container",web:"web-framework-stater-Quickly deploy a web framework","static-site":"static-website-stater-Quickly deploy a static website","best-practice":"serverless-best-practice-Quickly experience serverless best practices","devs-template":"Serverless Develop scaffold","fc-http-nodejs":"fc-http-nodejs - Deploy FC nodejs12 runtime function","fc-http-python":"fc-http-python - Deploy FC python3 runtime function","fc-http-java":"fc-http-java - Deploy FC java8 runtime function","fc-custom-container-event-python3":"fc-custom-container-event-python3 - Deploy python3 event-triggered application","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - Deploy cpp event-triggered application","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - Deploy springboot HTTP Request-triggered application","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - Deploy dotnetcore HTTP Request-triggered application","express-starter":"express-starter - Deploy express application","koa-starter":"koa-starter - Deploy koa application","nuxtjs-starter":"nuxtjs-starter - Deploy nuxtjs application","eggjs-starter":"eggjs-starter - Deploy eggjs application","flask-starter":"flask-starter - Deploy flask application","SpringBoot-starter":"SpringBoot-starter - Deploy SpringBoot application","Zblog-starter":"Zblog-starter - Deploy Zblog application","website-starter":"website-starter - Deploy static website","react-starter":"react-starter - Deploy React.js application","vue-starter":"vue-starter - Deploy Vue.js application",puppeteer:"puppeteer - Deploy screenshot application base on puppeteer + fc",ffmpeg:"ffmpeg - Deploy audio and video processing application base on ffmpeg + fc",pdf2Img:"pdf2Img - Deploy pdf to images application",tensorflow:"tensorflow - Deploy tensorflow application",todoList:"todoList - Deploy todoList application"}});var Tc=q(pr=>{"use strict";var Lc=pr&&pr.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(pr,"__esModule",{value:!0});var Sy=Eu(),Iy=Lc(Cc()),Cy=Lc(bc()),xu={en:Cy.default,zh:Iy.default},by=function(i){var r=(0,Sy.getLang)(),s=xu[r]?xu[r][i]:xu.en[i];return s||i};pr.default=by});var $c=q(dr=>{"use strict";var Ly=dr&&dr.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(dr,"__esModule",{value:!0});var Ty=Ly(fr()),$y=Ty.default.Logger,Au=new $y("S-CLI");Au.success=function(i){return Au.log(i,"green")};dr.default=Au});var gr=exports&&exports.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(exports,"__esModule",{value:!0});var Ny=gr(dl()),_r=gr(fr()),Ii=gr(Tc()),ft=gr(require("path")),On=gr($c()),Dy=mu(),qy=Eu(),Sn=_r.default.rimraf,Fy=_r.default.minimist,Ru=_r.default.fse,Py=_r.default.colors,My=_r.default.getRootHome,Hy=`Clean up the cache related functions of serverless devs. You can clean up the environment, unused dependent packages and related cache contents through this command.
37
37
 
package/lib/cli/index.js CHANGED
@@ -31,7 +31,7 @@ __p += '`),Y&&(S+=`' +
31
31
  function print() { __p += __j.call(arguments, '') }
32
32
  `:`;
33
33
  `)+S+`return __p
34
- }`;var B=pl(function(){return Z(h,N+"return "+S).apply(i,g)});if(B.source=S,Ks(B))throw B;return B}function rv(e){return k(e).toLowerCase()}function iv(e){return k(e).toUpperCase()}function sv(e,t,n){if(e=k(e),e&&(n||t===i))return xo(e);if(!e||!(t=Ne(t)))return e;var u=rt(e),l=rt(t),h=Ao(u,l),g=Oo(u,l)+1;return Mt(u,h,g).join("")}function uv(e,t,n){if(e=k(e),e&&(n||t===i))return e.slice(0,So(e)+1);if(!e||!(t=Ne(t)))return e;var u=rt(e),l=Oo(u,rt(t))+1;return Mt(u,0,l).join("")}function ov(e,t,n){if(e=k(e),e&&(n||t===i))return e.replace(Ki,"");if(!e||!(t=Ne(t)))return e;var u=rt(e),l=Ao(u,rt(t));return Mt(u,l).join("")}function av(e,t){var n=th,u=nh;if(ie(t)){var l="separator"in t?t.separator:l;n="length"in t?G(t.length):n,u="omission"in t?Ne(t.omission):u}e=k(e);var h=e.length;if(gn(e)){var g=rt(e);h=g.length}if(n>=h)return e;var _=n-dn(u);if(_<1)return u;var v=g?Mt(g,0,_).join(""):e.slice(0,_);if(l===i)return v+u;if(g&&(_+=v.length-_),Zs(l)){if(e.slice(_).search(l)){var O,b=v;for(l.global||(l=hs(l.source,k(Bu.exec(l))+"g")),l.lastIndex=0;O=l.exec(b);)var S=O.index;v=v.slice(0,S===i?_:S)}}else if(e.indexOf(Ne(l),_)!=_){var C=v.lastIndexOf(l);C>-1&&(v=v.slice(0,C))}return v+u}function lv(e){return e=k(e),e&&yh.test(e)?e.replace(Wu,Mp):e}var fv=wn(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),Qs=ga("toUpperCase");function hl(e,t,n){return e=k(e),t=n?i:t,t===i?Dp(e)?Up(e):Op(e):e.match(t)||[]}var pl=X(function(e,t){try{return De(e,i,t)}catch(n){return Ks(n)?n:new W(n)}}),cv=xt(function(e,t){return Ge(t,function(n){n=ct(n),yt(e,n,Vs(e[n],e))}),e});function hv(e){var t=e==null?0:e.length,n=F();return e=t?re(e,function(u){if(typeof u[1]!="function")throw new Be(f);return[n(u[0]),u[1]]}):[],X(function(u){for(var l=-1;++l<t;){var h=e[l];if(De(h[0],this,u))return De(h[1],this,u)}})}function pv(e){return Mg(Xe(e,p))}function eu(e){return function(){return e}}function gv(e,t){return e==null||e!==e?t:e}var dv=_a(),_v=_a(!0);function Le(e){return e}function tu(e){return zo(typeof e=="function"?e:Xe(e,p))}function mv(e){return Yo(Xe(e,p))}function vv(e,t){return Ko(e,Xe(t,p))}var Ev=X(function(e,t){return function(n){return er(n,e,t)}}),yv=X(function(e,t){return function(n){return er(e,n,t)}});function nu(e,t,n){var u=pe(t),l=Qr(t,u);n==null&&!(ie(t)&&(l.length||!u.length))&&(n=t,t=e,e=this,l=Qr(t,pe(t)));var h=!(ie(n)&&"chain"in n)||!!n.chain,g=Ot(e);return Ge(l,function(_){var v=t[_];e[_]=v,g&&(e.prototype[_]=function(){var O=this.__chain__;if(h||O){var b=e(this.__wrapped__),S=b.__actions__=Re(this.__actions__);return S.push({func:v,args:arguments,thisArg:e}),b.__chain__=O,b}return v.apply(e,Tt([this.value()],arguments))})}),e}function wv(){return he._===this&&(he._=Vp),this}function ru(){}function xv(e){return e=G(e),X(function(t){return Zo(t,e)})}var Av=Ps(re),Ov=Ps(mo),bv=Ps(ss);function gl(e){return Us(e)?us(ct(e)):td(e)}function Sv(e){return function(t){return e==null?i:Kt(e,t)}}var Rv=va(),Cv=va(!0);function iu(){return[]}function su(){return!1}function Iv(){return{}}function Lv(){return""}function Tv(){return!0}function $v(e,t){if(e=G(e),e<1||e>It)return[];var n=at,u=Ee(e,at);t=F(t),e-=at;for(var l=ls(u,t);++n<e;)t(n);return l}function Dv(e){return U(e)?re(e,ct):qe(e)?[e]:Re(Pa(k(e)))}function Pv(e){var t=++Xp;return k(e)+t}var Nv=si(function(e,t){return e+t},0),qv=Ns("ceil"),Fv=si(function(e,t){return e/t},1),Mv=Ns("floor");function Hv(e){return e&&e.length?Jr(e,Le,ys):i}function Wv(e,t){return e&&e.length?Jr(e,F(t,2),ys):i}function Uv(e){return yo(e,Le)}function Gv(e,t){return yo(e,F(t,2))}function Bv(e){return e&&e.length?Jr(e,Le,Os):i}function jv(e,t){return e&&e.length?Jr(e,F(t,2),Os):i}var Xv=si(function(e,t){return e*t},1),zv=Ns("round"),Vv=si(function(e,t){return e-t},0);function Yv(e){return e&&e.length?as(e,Le):0}function Kv(e,t){return e&&e.length?as(e,F(t,2)):0}return c.after=mm,c.ary=Xa,c.assign=i0,c.assignIn=sl,c.assignInWith=vi,c.assignWith=s0,c.at=u0,c.before=za,c.bind=Vs,c.bindAll=cv,c.bindKey=Va,c.castArray=Im,c.chain=Ga,c.chunk=Md,c.compact=Hd,c.concat=Wd,c.cond=hv,c.conforms=pv,c.constant=eu,c.countBy=Y_,c.create=o0,c.curry=Ya,c.curryRight=Ka,c.debounce=Za,c.defaults=a0,c.defaultsDeep=l0,c.defer=vm,c.delay=Em,c.difference=Ud,c.differenceBy=Gd,c.differenceWith=Bd,c.drop=jd,c.dropRight=Xd,c.dropRightWhile=zd,c.dropWhile=Vd,c.fill=Yd,c.filter=Z_,c.flatMap=Q_,c.flatMapDeep=em,c.flatMapDepth=tm,c.flatten=Ma,c.flattenDeep=Kd,c.flattenDepth=Zd,c.flip=ym,c.flow=dv,c.flowRight=_v,c.fromPairs=kd,c.functions=_0,c.functionsIn=m0,c.groupBy=nm,c.initial=Qd,c.intersection=e_,c.intersectionBy=t_,c.intersectionWith=n_,c.invert=E0,c.invertBy=y0,c.invokeMap=im,c.iteratee=tu,c.keyBy=sm,c.keys=pe,c.keysIn=Ie,c.map=hi,c.mapKeys=x0,c.mapValues=A0,c.matches=mv,c.matchesProperty=vv,c.memoize=gi,c.merge=O0,c.mergeWith=ul,c.method=Ev,c.methodOf=yv,c.mixin=nu,c.negate=di,c.nthArg=xv,c.omit=b0,c.omitBy=S0,c.once=wm,c.orderBy=um,c.over=Av,c.overArgs=xm,c.overEvery=Ov,c.overSome=bv,c.partial=Ys,c.partialRight=ka,c.partition=om,c.pick=R0,c.pickBy=ol,c.property=gl,c.propertyOf=Sv,c.pull=u_,c.pullAll=Wa,c.pullAllBy=o_,c.pullAllWith=a_,c.pullAt=l_,c.range=Rv,c.rangeRight=Cv,c.rearg=Am,c.reject=fm,c.remove=f_,c.rest=Om,c.reverse=Xs,c.sampleSize=hm,c.set=I0,c.setWith=L0,c.shuffle=pm,c.slice=c_,c.sortBy=_m,c.sortedUniq=v_,c.sortedUniqBy=E_,c.split=Q0,c.spread=bm,c.tail=y_,c.take=w_,c.takeRight=x_,c.takeRightWhile=A_,c.takeWhile=O_,c.tap=H_,c.throttle=Sm,c.thru=ci,c.toArray=nl,c.toPairs=al,c.toPairsIn=ll,c.toPath=Dv,c.toPlainObject=il,c.transform=T0,c.unary=Rm,c.union=b_,c.unionBy=S_,c.unionWith=R_,c.uniq=C_,c.uniqBy=I_,c.uniqWith=L_,c.unset=$0,c.unzip=zs,c.unzipWith=Ua,c.update=D0,c.updateWith=P0,c.values=On,c.valuesIn=N0,c.without=T_,c.words=hl,c.wrap=Cm,c.xor=$_,c.xorBy=D_,c.xorWith=P_,c.zip=N_,c.zipObject=q_,c.zipObjectDeep=F_,c.zipWith=M_,c.entries=al,c.entriesIn=ll,c.extend=sl,c.extendWith=vi,nu(c,c),c.add=Nv,c.attempt=pl,c.camelCase=H0,c.capitalize=fl,c.ceil=qv,c.clamp=q0,c.clone=Lm,c.cloneDeep=$m,c.cloneDeepWith=Dm,c.cloneWith=Tm,c.conformsTo=Pm,c.deburr=cl,c.defaultTo=gv,c.divide=Fv,c.endsWith=W0,c.eq=st,c.escape=U0,c.escapeRegExp=G0,c.every=K_,c.find=k_,c.findIndex=qa,c.findKey=f0,c.findLast=J_,c.findLastIndex=Fa,c.findLastKey=c0,c.floor=Mv,c.forEach=Ba,c.forEachRight=ja,c.forIn=h0,c.forInRight=p0,c.forOwn=g0,c.forOwnRight=d0,c.get=ks,c.gt=Nm,c.gte=qm,c.has=v0,c.hasIn=Js,c.head=Ha,c.identity=Le,c.includes=rm,c.indexOf=Jd,c.inRange=F0,c.invoke=w0,c.isArguments=Jt,c.isArray=U,c.isArrayBuffer=Fm,c.isArrayLike=Ce,c.isArrayLikeObject=ue,c.isBoolean=Mm,c.isBuffer=Ht,c.isDate=Hm,c.isElement=Wm,c.isEmpty=Um,c.isEqual=Gm,c.isEqualWith=Bm,c.isError=Ks,c.isFinite=jm,c.isFunction=Ot,c.isInteger=Ja,c.isLength=_i,c.isMap=Qa,c.isMatch=Xm,c.isMatchWith=zm,c.isNaN=Vm,c.isNative=Ym,c.isNil=Zm,c.isNull=Km,c.isNumber=el,c.isObject=ie,c.isObjectLike=se,c.isPlainObject=ur,c.isRegExp=Zs,c.isSafeInteger=km,c.isSet=tl,c.isString=mi,c.isSymbol=qe,c.isTypedArray=An,c.isUndefined=Jm,c.isWeakMap=Qm,c.isWeakSet=e0,c.join=r_,c.kebabCase=B0,c.last=Ve,c.lastIndexOf=i_,c.lowerCase=j0,c.lowerFirst=X0,c.lt=t0,c.lte=n0,c.max=Hv,c.maxBy=Wv,c.mean=Uv,c.meanBy=Gv,c.min=Bv,c.minBy=jv,c.stubArray=iu,c.stubFalse=su,c.stubObject=Iv,c.stubString=Lv,c.stubTrue=Tv,c.multiply=Xv,c.nth=s_,c.noConflict=wv,c.noop=ru,c.now=pi,c.pad=z0,c.padEnd=V0,c.padStart=Y0,c.parseInt=K0,c.random=M0,c.reduce=am,c.reduceRight=lm,c.repeat=Z0,c.replace=k0,c.result=C0,c.round=zv,c.runInContext=m,c.sample=cm,c.size=gm,c.snakeCase=J0,c.some=dm,c.sortedIndex=h_,c.sortedIndexBy=p_,c.sortedIndexOf=g_,c.sortedLastIndex=d_,c.sortedLastIndexBy=__,c.sortedLastIndexOf=m_,c.startCase=ev,c.startsWith=tv,c.subtract=Vv,c.sum=Yv,c.sumBy=Kv,c.template=nv,c.times=$v,c.toFinite=bt,c.toInteger=G,c.toLength=rl,c.toLower=rv,c.toNumber=Ye,c.toSafeInteger=r0,c.toString=k,c.toUpper=iv,c.trim=sv,c.trimEnd=uv,c.trimStart=ov,c.truncate=av,c.unescape=lv,c.uniqueId=Pv,c.upperCase=fv,c.upperFirst=Qs,c.each=Ba,c.eachRight=ja,c.first=Ha,nu(c,function(){var e={};return lt(c,function(t,n){J.call(c.prototype,n)||(e[n]=t)}),e}(),{chain:!1}),c.VERSION=r,Ge(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){c[e].placeholder=c}),Ge(["drop","take"],function(e,t){V.prototype[e]=function(n){n=n===i?1:fe(G(n),0);var u=this.__filtered__&&!t?new V(this):this.clone();return u.__filtered__?u.__takeCount__=Ee(n,u.__takeCount__):u.__views__.push({size:Ee(n,at),type:e+(u.__dir__<0?"Right":"")}),u},V.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Ge(["filter","map","takeWhile"],function(e,t){var n=t+1,u=n==Fu||n==uh;V.prototype[e]=function(l){var h=this.clone();return h.__iteratees__.push({iteratee:F(l,3),type:n}),h.__filtered__=h.__filtered__||u,h}}),Ge(["head","last"],function(e,t){var n="take"+(t?"Right":"");V.prototype[e]=function(){return this[n](1).value()[0]}}),Ge(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");V.prototype[e]=function(){return this.__filtered__?new V(this):this[n](1)}}),V.prototype.compact=function(){return this.filter(Le)},V.prototype.find=function(e){return this.filter(e).head()},V.prototype.findLast=function(e){return this.reverse().find(e)},V.prototype.invokeMap=X(function(e,t){return typeof e=="function"?new V(this):this.map(function(n){return er(n,e,t)})}),V.prototype.reject=function(e){return this.filter(di(F(e)))},V.prototype.slice=function(e,t){e=G(e);var n=this;return n.__filtered__&&(e>0||t<0)?new V(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=G(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},V.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},V.prototype.toArray=function(){return this.take(at)},lt(V.prototype,function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),u=/^(?:head|last)$/.test(t),l=c[u?"take"+(t=="last"?"Right":""):t],h=u||/^find/.test(t);!l||(c.prototype[t]=function(){var g=this.__wrapped__,_=u?[1]:arguments,v=g instanceof V,O=_[0],b=v||U(g),S=function(z){var Y=l.apply(c,Tt([z],_));return u&&C?Y[0]:Y};b&&n&&typeof O=="function"&&O.length!=1&&(v=b=!1);var C=this.__chain__,N=!!this.__actions__.length,M=h&&!C,B=v&&!N;if(!h&&b){g=B?g:new V(this);var H=e.apply(g,_);return H.__actions__.push({func:ci,args:[S],thisArg:i}),new je(H,C)}return M&&B?e.apply(this,_):(H=this.thru(S),M?u?H.value()[0]:H.value():H)})}),Ge(["pop","push","shift","sort","splice","unshift"],function(e){var t=Fr[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",u=/^(?:pop|shift)$/.test(e);c.prototype[e]=function(){var l=arguments;if(u&&!this.__chain__){var h=this.value();return t.apply(U(h)?h:[],l)}return this[n](function(g){return t.apply(U(g)?g:[],l)})}}),lt(V.prototype,function(e,t){var n=c[t];if(n){var u=n.name+"";J.call(vn,u)||(vn[u]=[]),vn[u].push({name:t,func:n})}}),vn[ii(i,et).name]=[{name:"wrapper",func:i}],V.prototype.clone=lg,V.prototype.reverse=fg,V.prototype.value=cg,c.prototype.at=W_,c.prototype.chain=U_,c.prototype.commit=G_,c.prototype.next=B_,c.prototype.plant=X_,c.prototype.reverse=z_,c.prototype.toJSON=c.prototype.valueOf=c.prototype.value=V_,c.prototype.first=c.prototype.head,Vn&&(c.prototype[Vn]=j_),c},Dt=Gp();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(he._=Dt,define(function(){return Dt})):jt?((jt.exports=Dt)._=Dt,ts._=Dt):he._=Dt}).call(Cn)});var Cu=L(Te=>{"use strict";var gy=Te&&Te.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function E(x){try{p(o.next(x))}catch(R){d(R)}}function y(x){try{p(o.throw(x))}catch(R){d(R)}}function p(x){x.done?a(x.value):f(x.value).then(E,y)}p((o=o.apply(i,r||[])).next())})},dy=Te&&Te.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,f,a,d;return d={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function E(p){return function(x){return y([p,x])}}function y(p){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(a=p[0]&2?f.return:p[0]?f.throw||((a=f.return)&&a.call(f),0):f.next)&&!(a=a.call(f,p[1])).done)return a;switch(f=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,f=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Rc=Te&&Te.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Te,"__esModule",{value:!0});Te.handlerProfileFile=Te.getConfig=Te.setConfig=void 0;var Cc=Rc(require("path")),Su=Rc(ht()),pt=Su.default.fse,Di=Su.default.jsyaml,Ru=Su.default.getRootHome;function _y(i){var r=Lc();pt.writeFileSync(r,Di.dump(i))}function Ic(){var i=Lc();if(!pt.existsSync(i))return{};try{var r=Di.load(pt.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function Lc(){var i=Cc.default.join(Ru(),"set-config.yml");return pt.existsSync(i)||pt.createFileSync(i),i}function my(i,r){var s=Ic();s[i]=r,_y(s)}Te.setConfig=my;function vy(i,r){var s=Ic();return s[i]||r}Te.getConfig=vy;function Ey(i){return gy(this,void 0,void 0,function(){var r,s,o,f,a,d,E;return dy(this,function(y){switch(y.label){case 0:if(r=i.filePath||"set-config.yml",s=Cc.default.join(Ru(),r),o=pt.existsSync(s),f={},o)return[3,5];a=Ru(),y.label=1;case 1:return y.trys.push([1,2,,4]),pt.statSync(a),[3,4];case 2:return d=y.sent(),[4,pt.mkdirSync(a)];case 3:return y.sent(),[3,4];case 4:return[3,6];case 5:try{f=Di.load(pt.readFileSync(s,"utf8"))||{}}catch(p){throw p}y.label=6;case 6:return i.read?[2,f]:(E=i.configKey||"",f[E]=i.data,[4,pt.writeFileSync(s,Di.dump(f))]);case 7:return y.sent(),[2,f]}})})}Te.handlerProfileFile=Ey});var Tc=L((eA,yy)=>{yy.exports={name:"@serverless-devs/s",version:"2.0.100-beta.4",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"MIT",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./shell/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.0.0","@types/jest":"^27.4.0","@types/lodash":"^4.14.168","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2",husky:"^4.2.3",inquirer:"^8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",lodash:"^4.17.20","os-locale":"5.0.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"beta"}}});var Ni=L(q=>{"use strict";var wy=q&&q.__createBinding||(Object.create?function(i,r,s,o){o===void 0&&(o=s),Object.defineProperty(i,o,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,o){o===void 0&&(o=s),i[o]=r[s]}),xy=q&&q.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),Ay=q&&q.__importStar||function(i){if(i&&i.__esModule)return i;var r={};if(i!=null)for(var s in i)s!=="default"&&Object.prototype.hasOwnProperty.call(i,s)&&wy(r,i,s);return xy(r,i),r},In=q&&q.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function E(x){try{p(o.next(x))}catch(R){d(R)}}function y(x){try{p(o.throw(x))}catch(R){d(R)}}function p(x){x.done?a(x.value):f(x.value).then(E,y)}p((o=o.apply(i,r||[])).next())})},Ln=q&&q.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,f,a,d;return d={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function E(p){return function(x){return y([p,x])}}function y(p){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(a=p[0]&2?f.return:p[0]?f.throw||((a=f.return)&&a.call(f),0):f.next)&&!(a=a.call(f,p[1])).done)return a;switch(f=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,f=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Iu=q&&q.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(q,"__esModule",{value:!0});q.emoji=q.mark=q.replaceTemplate=q.getTemplatekey=q.replaceFun=q.getLang=q.printn=q.getFolderSize=q.getVersion=q.getPid=q.aiRequest=q.getCredentialWithAll=q.getCredentialWithExisted=q.getCredentialAliasList=q.getProcessArgv=q.bgRed=q.yellow=q.red=void 0;var $c=Iu(require("path")),Ar=Iu(require("fs")),Je=bu(),Oy=Iu(require("os")),Qe=Ay(ht()),by=Cu(),Dc=Tc(),Pi=Qe.default.colors,Sy=Qe.default.got,Ry=Qe.default.getMAC,Cy=Qe.default.isDocker,Iy=Qe.default.isCiCdEnv,Ly=Qe.default.getGlobalArgs,Ty=Qe.default.getYamlContent,$y=Qe.default.getRootHome,Pc=Qe.default.getCredential,Dy=Qe.default.getCredentialFromEnv;q.red=Pi.hex("#fd5750");q.yellow=Pi.hex("#F3F99D");q.bgRed=Pi.hex("#000").bgHex("#fd5750");var Py=function(){var i=process.env.serverless_devs_temp_argv;try{var r=JSON.parse(i),s=Ly(r);return process.argv=process.argv.slice(0,2).concat(s._argsObj),(0,Je.assign)({},s,{noHelpArgv:process.argv.slice(0,2).concat((0,Je.filter)(s._argsObj,function(o){return!(0,Je.includes)(["-h","--help"],o)}))})}catch{return{}}};q.getProcessArgv=Py;var Ny=function(){return In(void 0,void 0,void 0,function(){var i,r,s;return Ln(this,function(o){switch(o.label){case 0:return i=[],[4,Ty($c.default.join($y(),"access.yaml"))];case 1:return r=o.sent(),r&&(i=(0,Je.keys)(r)),[4,Dy()];case 2:return s=o.sent(),s&&(i=(0,Je.filter)(i,function(f){return f!==s.Alias}),i.push(s.Alias)),[2,i]}})})};q.getCredentialAliasList=Ny;var qy=function(i){return In(void 0,void 0,void 0,function(){var r,s;return Ln(this,function(o){switch(o.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:return r=o.sent(),(0,Je.includes)(r,i)?[4,Pc(i)]:[3,3];case 2:return s=o.sent(),[2,(0,Je.omit)(s,"Alias")];case 3:return[2]}})})};q.getCredentialWithExisted=qy;var Fy=function(){return In(void 0,void 0,void 0,function(){var i,r,s,o,f,a;return Ln(this,function(d){switch(d.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:if(i=d.sent(),!(i.length>0))return[3,6];r={},s=0,o=i,d.label=2;case 2:return s<o.length?(f=o[s],[4,Pc(f)]):[3,5];case 3:a=d.sent(),r[a.Alias]=(0,Je.omit)(a,"Alias"),d.label=4;case 4:return s++,[3,2];case 5:return[2,r];case 6:return[2]}})})};q.getCredentialWithAll=Fy;var My=function(i,r){return r===void 0&&(r="unknow"),In(void 0,void 0,void 0,function(){var s,o,f,a;return Ln(this,function(d){switch(d.label){case 0:return d.trys.push([0,2,,3]),s=(0,by.getConfig)("analysis"),s!=="enable"?[2]:Cy()||Iy()?[2]:[4,Sy("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(r,"&code=TypeError&s=").concat(i),{timeout:2e3,json:!0})];case 1:return o=d.sent(),f=(0,Je.get)(o.body,"shorturl"),f&&console.log(`AI Tips:
34
+ }`;var B=pl(function(){return Z(h,N+"return "+S).apply(i,g)});if(B.source=S,Ks(B))throw B;return B}function rv(e){return k(e).toLowerCase()}function iv(e){return k(e).toUpperCase()}function sv(e,t,n){if(e=k(e),e&&(n||t===i))return xo(e);if(!e||!(t=Ne(t)))return e;var u=rt(e),l=rt(t),h=Ao(u,l),g=Oo(u,l)+1;return Mt(u,h,g).join("")}function uv(e,t,n){if(e=k(e),e&&(n||t===i))return e.slice(0,So(e)+1);if(!e||!(t=Ne(t)))return e;var u=rt(e),l=Oo(u,rt(t))+1;return Mt(u,0,l).join("")}function ov(e,t,n){if(e=k(e),e&&(n||t===i))return e.replace(Ki,"");if(!e||!(t=Ne(t)))return e;var u=rt(e),l=Ao(u,rt(t));return Mt(u,l).join("")}function av(e,t){var n=th,u=nh;if(ie(t)){var l="separator"in t?t.separator:l;n="length"in t?G(t.length):n,u="omission"in t?Ne(t.omission):u}e=k(e);var h=e.length;if(gn(e)){var g=rt(e);h=g.length}if(n>=h)return e;var _=n-dn(u);if(_<1)return u;var v=g?Mt(g,0,_).join(""):e.slice(0,_);if(l===i)return v+u;if(g&&(_+=v.length-_),Zs(l)){if(e.slice(_).search(l)){var O,b=v;for(l.global||(l=hs(l.source,k(Bu.exec(l))+"g")),l.lastIndex=0;O=l.exec(b);)var S=O.index;v=v.slice(0,S===i?_:S)}}else if(e.indexOf(Ne(l),_)!=_){var C=v.lastIndexOf(l);C>-1&&(v=v.slice(0,C))}return v+u}function lv(e){return e=k(e),e&&yh.test(e)?e.replace(Wu,Mp):e}var fv=wn(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),Qs=ga("toUpperCase");function hl(e,t,n){return e=k(e),t=n?i:t,t===i?Dp(e)?Up(e):Op(e):e.match(t)||[]}var pl=X(function(e,t){try{return De(e,i,t)}catch(n){return Ks(n)?n:new W(n)}}),cv=xt(function(e,t){return Ge(t,function(n){n=ct(n),yt(e,n,Vs(e[n],e))}),e});function hv(e){var t=e==null?0:e.length,n=F();return e=t?re(e,function(u){if(typeof u[1]!="function")throw new Be(f);return[n(u[0]),u[1]]}):[],X(function(u){for(var l=-1;++l<t;){var h=e[l];if(De(h[0],this,u))return De(h[1],this,u)}})}function pv(e){return Mg(Xe(e,p))}function eu(e){return function(){return e}}function gv(e,t){return e==null||e!==e?t:e}var dv=_a(),_v=_a(!0);function Le(e){return e}function tu(e){return zo(typeof e=="function"?e:Xe(e,p))}function mv(e){return Yo(Xe(e,p))}function vv(e,t){return Ko(e,Xe(t,p))}var Ev=X(function(e,t){return function(n){return er(n,e,t)}}),yv=X(function(e,t){return function(n){return er(e,n,t)}});function nu(e,t,n){var u=pe(t),l=Qr(t,u);n==null&&!(ie(t)&&(l.length||!u.length))&&(n=t,t=e,e=this,l=Qr(t,pe(t)));var h=!(ie(n)&&"chain"in n)||!!n.chain,g=Ot(e);return Ge(l,function(_){var v=t[_];e[_]=v,g&&(e.prototype[_]=function(){var O=this.__chain__;if(h||O){var b=e(this.__wrapped__),S=b.__actions__=Re(this.__actions__);return S.push({func:v,args:arguments,thisArg:e}),b.__chain__=O,b}return v.apply(e,Tt([this.value()],arguments))})}),e}function wv(){return he._===this&&(he._=Vp),this}function ru(){}function xv(e){return e=G(e),X(function(t){return Zo(t,e)})}var Av=Ps(re),Ov=Ps(mo),bv=Ps(ss);function gl(e){return Us(e)?us(ct(e)):td(e)}function Sv(e){return function(t){return e==null?i:Kt(e,t)}}var Rv=va(),Cv=va(!0);function iu(){return[]}function su(){return!1}function Iv(){return{}}function Lv(){return""}function Tv(){return!0}function $v(e,t){if(e=G(e),e<1||e>It)return[];var n=at,u=Ee(e,at);t=F(t),e-=at;for(var l=ls(u,t);++n<e;)t(n);return l}function Dv(e){return U(e)?re(e,ct):qe(e)?[e]:Re(Pa(k(e)))}function Pv(e){var t=++Xp;return k(e)+t}var Nv=si(function(e,t){return e+t},0),qv=Ns("ceil"),Fv=si(function(e,t){return e/t},1),Mv=Ns("floor");function Hv(e){return e&&e.length?Jr(e,Le,ys):i}function Wv(e,t){return e&&e.length?Jr(e,F(t,2),ys):i}function Uv(e){return yo(e,Le)}function Gv(e,t){return yo(e,F(t,2))}function Bv(e){return e&&e.length?Jr(e,Le,Os):i}function jv(e,t){return e&&e.length?Jr(e,F(t,2),Os):i}var Xv=si(function(e,t){return e*t},1),zv=Ns("round"),Vv=si(function(e,t){return e-t},0);function Yv(e){return e&&e.length?as(e,Le):0}function Kv(e,t){return e&&e.length?as(e,F(t,2)):0}return c.after=mm,c.ary=Xa,c.assign=i0,c.assignIn=sl,c.assignInWith=vi,c.assignWith=s0,c.at=u0,c.before=za,c.bind=Vs,c.bindAll=cv,c.bindKey=Va,c.castArray=Im,c.chain=Ga,c.chunk=Md,c.compact=Hd,c.concat=Wd,c.cond=hv,c.conforms=pv,c.constant=eu,c.countBy=Y_,c.create=o0,c.curry=Ya,c.curryRight=Ka,c.debounce=Za,c.defaults=a0,c.defaultsDeep=l0,c.defer=vm,c.delay=Em,c.difference=Ud,c.differenceBy=Gd,c.differenceWith=Bd,c.drop=jd,c.dropRight=Xd,c.dropRightWhile=zd,c.dropWhile=Vd,c.fill=Yd,c.filter=Z_,c.flatMap=Q_,c.flatMapDeep=em,c.flatMapDepth=tm,c.flatten=Ma,c.flattenDeep=Kd,c.flattenDepth=Zd,c.flip=ym,c.flow=dv,c.flowRight=_v,c.fromPairs=kd,c.functions=_0,c.functionsIn=m0,c.groupBy=nm,c.initial=Qd,c.intersection=e_,c.intersectionBy=t_,c.intersectionWith=n_,c.invert=E0,c.invertBy=y0,c.invokeMap=im,c.iteratee=tu,c.keyBy=sm,c.keys=pe,c.keysIn=Ie,c.map=hi,c.mapKeys=x0,c.mapValues=A0,c.matches=mv,c.matchesProperty=vv,c.memoize=gi,c.merge=O0,c.mergeWith=ul,c.method=Ev,c.methodOf=yv,c.mixin=nu,c.negate=di,c.nthArg=xv,c.omit=b0,c.omitBy=S0,c.once=wm,c.orderBy=um,c.over=Av,c.overArgs=xm,c.overEvery=Ov,c.overSome=bv,c.partial=Ys,c.partialRight=ka,c.partition=om,c.pick=R0,c.pickBy=ol,c.property=gl,c.propertyOf=Sv,c.pull=u_,c.pullAll=Wa,c.pullAllBy=o_,c.pullAllWith=a_,c.pullAt=l_,c.range=Rv,c.rangeRight=Cv,c.rearg=Am,c.reject=fm,c.remove=f_,c.rest=Om,c.reverse=Xs,c.sampleSize=hm,c.set=I0,c.setWith=L0,c.shuffle=pm,c.slice=c_,c.sortBy=_m,c.sortedUniq=v_,c.sortedUniqBy=E_,c.split=Q0,c.spread=bm,c.tail=y_,c.take=w_,c.takeRight=x_,c.takeRightWhile=A_,c.takeWhile=O_,c.tap=H_,c.throttle=Sm,c.thru=ci,c.toArray=nl,c.toPairs=al,c.toPairsIn=ll,c.toPath=Dv,c.toPlainObject=il,c.transform=T0,c.unary=Rm,c.union=b_,c.unionBy=S_,c.unionWith=R_,c.uniq=C_,c.uniqBy=I_,c.uniqWith=L_,c.unset=$0,c.unzip=zs,c.unzipWith=Ua,c.update=D0,c.updateWith=P0,c.values=On,c.valuesIn=N0,c.without=T_,c.words=hl,c.wrap=Cm,c.xor=$_,c.xorBy=D_,c.xorWith=P_,c.zip=N_,c.zipObject=q_,c.zipObjectDeep=F_,c.zipWith=M_,c.entries=al,c.entriesIn=ll,c.extend=sl,c.extendWith=vi,nu(c,c),c.add=Nv,c.attempt=pl,c.camelCase=H0,c.capitalize=fl,c.ceil=qv,c.clamp=q0,c.clone=Lm,c.cloneDeep=$m,c.cloneDeepWith=Dm,c.cloneWith=Tm,c.conformsTo=Pm,c.deburr=cl,c.defaultTo=gv,c.divide=Fv,c.endsWith=W0,c.eq=st,c.escape=U0,c.escapeRegExp=G0,c.every=K_,c.find=k_,c.findIndex=qa,c.findKey=f0,c.findLast=J_,c.findLastIndex=Fa,c.findLastKey=c0,c.floor=Mv,c.forEach=Ba,c.forEachRight=ja,c.forIn=h0,c.forInRight=p0,c.forOwn=g0,c.forOwnRight=d0,c.get=ks,c.gt=Nm,c.gte=qm,c.has=v0,c.hasIn=Js,c.head=Ha,c.identity=Le,c.includes=rm,c.indexOf=Jd,c.inRange=F0,c.invoke=w0,c.isArguments=Jt,c.isArray=U,c.isArrayBuffer=Fm,c.isArrayLike=Ce,c.isArrayLikeObject=ue,c.isBoolean=Mm,c.isBuffer=Ht,c.isDate=Hm,c.isElement=Wm,c.isEmpty=Um,c.isEqual=Gm,c.isEqualWith=Bm,c.isError=Ks,c.isFinite=jm,c.isFunction=Ot,c.isInteger=Ja,c.isLength=_i,c.isMap=Qa,c.isMatch=Xm,c.isMatchWith=zm,c.isNaN=Vm,c.isNative=Ym,c.isNil=Zm,c.isNull=Km,c.isNumber=el,c.isObject=ie,c.isObjectLike=se,c.isPlainObject=ur,c.isRegExp=Zs,c.isSafeInteger=km,c.isSet=tl,c.isString=mi,c.isSymbol=qe,c.isTypedArray=An,c.isUndefined=Jm,c.isWeakMap=Qm,c.isWeakSet=e0,c.join=r_,c.kebabCase=B0,c.last=Ve,c.lastIndexOf=i_,c.lowerCase=j0,c.lowerFirst=X0,c.lt=t0,c.lte=n0,c.max=Hv,c.maxBy=Wv,c.mean=Uv,c.meanBy=Gv,c.min=Bv,c.minBy=jv,c.stubArray=iu,c.stubFalse=su,c.stubObject=Iv,c.stubString=Lv,c.stubTrue=Tv,c.multiply=Xv,c.nth=s_,c.noConflict=wv,c.noop=ru,c.now=pi,c.pad=z0,c.padEnd=V0,c.padStart=Y0,c.parseInt=K0,c.random=M0,c.reduce=am,c.reduceRight=lm,c.repeat=Z0,c.replace=k0,c.result=C0,c.round=zv,c.runInContext=m,c.sample=cm,c.size=gm,c.snakeCase=J0,c.some=dm,c.sortedIndex=h_,c.sortedIndexBy=p_,c.sortedIndexOf=g_,c.sortedLastIndex=d_,c.sortedLastIndexBy=__,c.sortedLastIndexOf=m_,c.startCase=ev,c.startsWith=tv,c.subtract=Vv,c.sum=Yv,c.sumBy=Kv,c.template=nv,c.times=$v,c.toFinite=bt,c.toInteger=G,c.toLength=rl,c.toLower=rv,c.toNumber=Ye,c.toSafeInteger=r0,c.toString=k,c.toUpper=iv,c.trim=sv,c.trimEnd=uv,c.trimStart=ov,c.truncate=av,c.unescape=lv,c.uniqueId=Pv,c.upperCase=fv,c.upperFirst=Qs,c.each=Ba,c.eachRight=ja,c.first=Ha,nu(c,function(){var e={};return lt(c,function(t,n){J.call(c.prototype,n)||(e[n]=t)}),e}(),{chain:!1}),c.VERSION=r,Ge(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){c[e].placeholder=c}),Ge(["drop","take"],function(e,t){V.prototype[e]=function(n){n=n===i?1:fe(G(n),0);var u=this.__filtered__&&!t?new V(this):this.clone();return u.__filtered__?u.__takeCount__=Ee(n,u.__takeCount__):u.__views__.push({size:Ee(n,at),type:e+(u.__dir__<0?"Right":"")}),u},V.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Ge(["filter","map","takeWhile"],function(e,t){var n=t+1,u=n==Fu||n==uh;V.prototype[e]=function(l){var h=this.clone();return h.__iteratees__.push({iteratee:F(l,3),type:n}),h.__filtered__=h.__filtered__||u,h}}),Ge(["head","last"],function(e,t){var n="take"+(t?"Right":"");V.prototype[e]=function(){return this[n](1).value()[0]}}),Ge(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");V.prototype[e]=function(){return this.__filtered__?new V(this):this[n](1)}}),V.prototype.compact=function(){return this.filter(Le)},V.prototype.find=function(e){return this.filter(e).head()},V.prototype.findLast=function(e){return this.reverse().find(e)},V.prototype.invokeMap=X(function(e,t){return typeof e=="function"?new V(this):this.map(function(n){return er(n,e,t)})}),V.prototype.reject=function(e){return this.filter(di(F(e)))},V.prototype.slice=function(e,t){e=G(e);var n=this;return n.__filtered__&&(e>0||t<0)?new V(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=G(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},V.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},V.prototype.toArray=function(){return this.take(at)},lt(V.prototype,function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),u=/^(?:head|last)$/.test(t),l=c[u?"take"+(t=="last"?"Right":""):t],h=u||/^find/.test(t);!l||(c.prototype[t]=function(){var g=this.__wrapped__,_=u?[1]:arguments,v=g instanceof V,O=_[0],b=v||U(g),S=function(z){var Y=l.apply(c,Tt([z],_));return u&&C?Y[0]:Y};b&&n&&typeof O=="function"&&O.length!=1&&(v=b=!1);var C=this.__chain__,N=!!this.__actions__.length,M=h&&!C,B=v&&!N;if(!h&&b){g=B?g:new V(this);var H=e.apply(g,_);return H.__actions__.push({func:ci,args:[S],thisArg:i}),new je(H,C)}return M&&B?e.apply(this,_):(H=this.thru(S),M?u?H.value()[0]:H.value():H)})}),Ge(["pop","push","shift","sort","splice","unshift"],function(e){var t=Fr[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",u=/^(?:pop|shift)$/.test(e);c.prototype[e]=function(){var l=arguments;if(u&&!this.__chain__){var h=this.value();return t.apply(U(h)?h:[],l)}return this[n](function(g){return t.apply(U(g)?g:[],l)})}}),lt(V.prototype,function(e,t){var n=c[t];if(n){var u=n.name+"";J.call(vn,u)||(vn[u]=[]),vn[u].push({name:t,func:n})}}),vn[ii(i,et).name]=[{name:"wrapper",func:i}],V.prototype.clone=lg,V.prototype.reverse=fg,V.prototype.value=cg,c.prototype.at=W_,c.prototype.chain=U_,c.prototype.commit=G_,c.prototype.next=B_,c.prototype.plant=X_,c.prototype.reverse=z_,c.prototype.toJSON=c.prototype.valueOf=c.prototype.value=V_,c.prototype.first=c.prototype.head,Vn&&(c.prototype[Vn]=j_),c},Dt=Gp();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(he._=Dt,define(function(){return Dt})):jt?((jt.exports=Dt)._=Dt,ts._=Dt):he._=Dt}).call(Cn)});var Cu=L(Te=>{"use strict";var gy=Te&&Te.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function E(x){try{p(o.next(x))}catch(R){d(R)}}function y(x){try{p(o.throw(x))}catch(R){d(R)}}function p(x){x.done?a(x.value):f(x.value).then(E,y)}p((o=o.apply(i,r||[])).next())})},dy=Te&&Te.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,f,a,d;return d={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function E(p){return function(x){return y([p,x])}}function y(p){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(a=p[0]&2?f.return:p[0]?f.throw||((a=f.return)&&a.call(f),0):f.next)&&!(a=a.call(f,p[1])).done)return a;switch(f=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,f=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Rc=Te&&Te.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Te,"__esModule",{value:!0});Te.handlerProfileFile=Te.getConfig=Te.setConfig=void 0;var Cc=Rc(require("path")),Su=Rc(ht()),pt=Su.default.fse,Di=Su.default.jsyaml,Ru=Su.default.getRootHome;function _y(i){var r=Lc();pt.writeFileSync(r,Di.dump(i))}function Ic(){var i=Lc();if(!pt.existsSync(i))return{};try{var r=Di.load(pt.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function Lc(){var i=Cc.default.join(Ru(),"set-config.yml");return pt.existsSync(i)||pt.createFileSync(i),i}function my(i,r){var s=Ic();s[i]=r,_y(s)}Te.setConfig=my;function vy(i,r){var s=Ic();return s[i]||r}Te.getConfig=vy;function Ey(i){return gy(this,void 0,void 0,function(){var r,s,o,f,a,d,E;return dy(this,function(y){switch(y.label){case 0:if(r=i.filePath||"set-config.yml",s=Cc.default.join(Ru(),r),o=pt.existsSync(s),f={},o)return[3,5];a=Ru(),y.label=1;case 1:return y.trys.push([1,2,,4]),pt.statSync(a),[3,4];case 2:return d=y.sent(),[4,pt.mkdirSync(a)];case 3:return y.sent(),[3,4];case 4:return[3,6];case 5:try{f=Di.load(pt.readFileSync(s,"utf8"))||{}}catch(p){throw p}y.label=6;case 6:return i.read?[2,f]:(E=i.configKey||"",f[E]=i.data,[4,pt.writeFileSync(s,Di.dump(f))]);case 7:return y.sent(),[2,f]}})})}Te.handlerProfileFile=Ey});var Tc=L((eA,yy)=>{yy.exports={name:"@serverless-devs/s",version:"2.0.100-beta.5",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"MIT",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./shell/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.0.0","@types/jest":"^27.4.0","@types/lodash":"^4.14.168","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2",husky:"^4.2.3",inquirer:"^8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",lodash:"^4.17.20","os-locale":"5.0.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"beta"}}});var Ni=L(q=>{"use strict";var wy=q&&q.__createBinding||(Object.create?function(i,r,s,o){o===void 0&&(o=s),Object.defineProperty(i,o,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,o){o===void 0&&(o=s),i[o]=r[s]}),xy=q&&q.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),Ay=q&&q.__importStar||function(i){if(i&&i.__esModule)return i;var r={};if(i!=null)for(var s in i)s!=="default"&&Object.prototype.hasOwnProperty.call(i,s)&&wy(r,i,s);return xy(r,i),r},In=q&&q.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function E(x){try{p(o.next(x))}catch(R){d(R)}}function y(x){try{p(o.throw(x))}catch(R){d(R)}}function p(x){x.done?a(x.value):f(x.value).then(E,y)}p((o=o.apply(i,r||[])).next())})},Ln=q&&q.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,f,a,d;return d={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function E(p){return function(x){return y([p,x])}}function y(p){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(a=p[0]&2?f.return:p[0]?f.throw||((a=f.return)&&a.call(f),0):f.next)&&!(a=a.call(f,p[1])).done)return a;switch(f=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,f=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Iu=q&&q.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(q,"__esModule",{value:!0});q.emoji=q.mark=q.replaceTemplate=q.getTemplatekey=q.replaceFun=q.getLang=q.printn=q.getFolderSize=q.getVersion=q.getPid=q.aiRequest=q.getCredentialWithAll=q.getCredentialWithExisted=q.getCredentialAliasList=q.getProcessArgv=q.bgRed=q.yellow=q.red=void 0;var $c=Iu(require("path")),Ar=Iu(require("fs")),Je=bu(),Oy=Iu(require("os")),Qe=Ay(ht()),by=Cu(),Dc=Tc(),Pi=Qe.default.colors,Sy=Qe.default.got,Ry=Qe.default.getMAC,Cy=Qe.default.isDocker,Iy=Qe.default.isCiCdEnv,Ly=Qe.default.getGlobalArgs,Ty=Qe.default.getYamlContent,$y=Qe.default.getRootHome,Pc=Qe.default.getCredential,Dy=Qe.default.getCredentialFromEnv;q.red=Pi.hex("#fd5750");q.yellow=Pi.hex("#F3F99D");q.bgRed=Pi.hex("#000").bgHex("#fd5750");var Py=function(){var i=process.env.serverless_devs_temp_argv;try{var r=JSON.parse(i),s=Ly(r);return process.argv=process.argv.slice(0,2).concat(s._argsObj),(0,Je.assign)({},s,{noHelpArgv:process.argv.slice(0,2).concat((0,Je.filter)(s._argsObj,function(o){return!(0,Je.includes)(["-h","--help"],o)}))})}catch{return{}}};q.getProcessArgv=Py;var Ny=function(){return In(void 0,void 0,void 0,function(){var i,r,s;return Ln(this,function(o){switch(o.label){case 0:return i=[],[4,Ty($c.default.join($y(),"access.yaml"))];case 1:return r=o.sent(),r&&(i=(0,Je.keys)(r)),[4,Dy()];case 2:return s=o.sent(),s&&(i=(0,Je.filter)(i,function(f){return f!==s.Alias}),i.push(s.Alias)),[2,i]}})})};q.getCredentialAliasList=Ny;var qy=function(i){return In(void 0,void 0,void 0,function(){var r,s;return Ln(this,function(o){switch(o.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:return r=o.sent(),(0,Je.includes)(r,i)?[4,Pc(i)]:[3,3];case 2:return s=o.sent(),[2,(0,Je.omit)(s,"Alias")];case 3:return[2]}})})};q.getCredentialWithExisted=qy;var Fy=function(){return In(void 0,void 0,void 0,function(){var i,r,s,o,f,a;return Ln(this,function(d){switch(d.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:if(i=d.sent(),!(i.length>0))return[3,6];r={},s=0,o=i,d.label=2;case 2:return s<o.length?(f=o[s],[4,Pc(f)]):[3,5];case 3:a=d.sent(),r[a.Alias]=(0,Je.omit)(a,"Alias"),d.label=4;case 4:return s++,[3,2];case 5:return[2,r];case 6:return[2]}})})};q.getCredentialWithAll=Fy;var My=function(i,r){return r===void 0&&(r="unknow"),In(void 0,void 0,void 0,function(){var s,o,f,a;return Ln(this,function(d){switch(d.label){case 0:return d.trys.push([0,2,,3]),s=(0,by.getConfig)("analysis"),s!=="enable"?[2]:Cy()||Iy()?[2]:[4,Sy("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(r,"&code=TypeError&s=").concat(i),{timeout:2e3,json:!0})];case 1:return o=d.sent(),f=(0,Je.get)(o.body,"shorturl"),f&&console.log(`AI Tips:
35
35
  You can try to solve the problem through: `.concat(Pi.underline(f),`
36
36
  `)),[3,3];case 2:return a=d.sent(),[3,3];case 3:return[2]}})})};q.aiRequest=My;var Hy=function(){try{return Ry().replace(/:/g,"")}catch{return"unknown"}};q.getPid=Hy;function Wy(){var i=(0,Qe.getCoreVersion)(),r="".concat(process.platform,"-").concat(process.arch),s="node-".concat(process.version),o="core: ".concat(i),f="s-home: ".concat(Qe.default.getRootHome()),a="".concat(Dc.name,": ").concat(Dc.version);return i?"".concat(a,", ").concat(o,", ").concat(f,", ").concat(r,", ").concat(s):"".concat(a,", ").concat(f,", ").concat(r,", ").concat(s)}q.getVersion=Wy;function Uy(i){return In(this,void 0,void 0,function(){function r(f){return In(this,void 0,void 0,function(){var a,d;return Ln(this,function(E){switch(E.label){case 0:return a=Ar.default.lstatSync(f),typeof a!="object"?[2]:(s.set(a.ino,a.size),a.isDirectory()?(d=Ar.default.readdirSync(f),typeof d!="object"?[2]:[4,Promise.all(d.map(function(y){return r($c.default.join(f,y))}))]):[3,2]);case 1:E.sent(),E.label=2;case 2:return[2]}})})}var s,o;return Ln(this,function(f){switch(f.label){case 0:return s=new Map,[4,r(i)];case 1:return f.sent(),o=Array.from(s.values()).reduce(function(a,d){return a+d},0),[2,o]}})})}q.getFolderSize=Uy;function Gy(i,r){r===void 0&&(r=" ");for(var s="",o=0;o<i;o++)s=s+r;return s}q.printn=Gy;function By(){return"en"}q.getLang=By;function Nc(i,r){var s=/\{\{(.*?)\}\}/g,o=i.match(s);if(o)for(var f=0;f<o.length;f++){var a=o[f].replace(/{{|}}/g,""),d=(0,Je.trim)(a.split("|")[0]);r[d]&&(i=i.replace(o[f],r[d]))}return i}q.replaceFun=Nc;function jy(i){var r=/\{\{(.*?)\}\}/g,s=i.match(r);return s?s.filter(function(o){return o}).map(function(o){var f=o.replace(/{{|}}/g,""),a=f.split("|");return{name:(0,Je.trim)(a[0]),desc:(0,Je.trim)(a[1])}}):[]}q.getTemplatekey=jy;function Xy(i,r){i.forEach(function(s){if(Ar.default.existsSync(s)){var o=Ar.default.readFileSync(s,"utf-8"),f=Nc(o,r);Ar.default.writeFileSync(s,f,"utf-8")}})}q.replaceTemplate=Xy;function zy(i){if(!i)return i;var r=i.slice(-4);return"***********".concat(r)}q.mark=zy;function Vy(i,r){return Oy.default.platform()==="win32"?r||"\u25C6":"".concat(i," ")}q.emoji=Vy});var qc=L(Lu=>{"use strict";Object.defineProperty(Lu,"__esModule",{value:!0});Lu.default={clean_up_the_environment:"\u6E05\u7406\u73AF\u5883",display_help_for_command:"\u663E\u793A\u547D\u4EE4\u5E2E\u52A9",remove_components:"\u5220\u9664\u7EC4\u4EF6",delete_the_file_under_the_cache:"\u5220\u9664\u7F13\u5B58\u91CC\u7684\u7684<dirname>\u6587\u4EF6",record_your_log_information:"\u662F\u5426\u8BB0\u5F55\u60A8\u7684\u65E5\u5FD7\u4FE1\u606F\uFF1F",init_pproject_deploy_tip:"\u662F\u5426\u7ACB\u5373\u90E8\u7F72\u8BE5\u9879\u76EE\uFF1F",tip_for_a_serverless_project:"\u68C0\u6D4B\u5230\u5F53\u524D\u76EE\u5F55\u4E0B\u5DF2\u5B58\u5728\u4E00\u4E2AServerless-Devs\u9879\u76EE\uFF0C\u8BF7\u901A\u8FC7 's deploy' \u8FDB\u884C\u90E8\u7F72\u6216\u901A\u8FC7 's -h' \u83B7\u53D6\u66F4\u591A\u4FE1\u606F",create_a_new_project:"\u672A\u68C0\u6D4B\u5230 Serverless-Devs \u9879\u76EE\uFF0C\u662F\u5426\u65B0\u5EFA\u4E00\u4E2A\u9879\u76EE\uFF1F",en:"English (en)",zh:"\u4E2D\u6587 (zh)",select_current_language:"\u8BF7\u9009\u62E9\u5F53\u524D\u8BED\u8A00","app-tip":"\u8BF7\u9009\u62E9\u60A8\u5E0C\u671B\u521B\u5EFA\u7684 Serverless-Devs \u5E94\u7528","template-tip":"\u8BF7\u9009\u62E9\u60A8\u559C\u6B22\u7684\u6A21\u7248","fc-runtime-starter":"fc-runtime-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A FC \u51FD\u6570","fc-custom-container-stater":"fc-custom-container-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A custom-container \u5E94\u7528",web:"web-framework-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Web \u6846\u67B6","static-site":"static-website-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","best-practice":"serverless-best-practice - \u5FEB\u901F\u4F53\u9A8C Serverless \u6700\u4F73\u5B9E\u8DF5","devs-template":"Serverless Devs \u5F00\u53D1\u6A21\u677F","fc-http-nodejs":"fc-http-nodejs - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nodejs12 \u51FD\u6570","fc-http-python":"fc-http-python - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A python3 \u51FD\u6570","fc-http-java":"fc-http-java - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A java8 \u51FD\u6570","fc-custom-container-event-python3":"fc-custom-container-event-python3 - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 python3 \u5E94\u7528","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 cpp \u5E94\u7528","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 springboot \u5E94\u7528","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 aspdotnetcore \u5E94\u7528","express-starter":"express-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A express \u57FA\u7840\u5E94\u7528","koa-starter":"koa-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A koa \u57FA\u7840\u5E94\u7528","nuxtjs-starter":"nuxtjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nuxtjs \u57FA\u7840\u5E94\u7528","eggjs-starter":"eggjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A eggjs \u57FA\u7840\u5E94\u7528","flask-starter":"flask-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A flask \u57FA\u7840\u5E94\u7528","SpringBoot-starter":"SpringBoot-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A SpringBoot \u57FA\u7840\u5E94\u7528","Zblog-starter":"Zblog-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Zblog \u57FA\u7840\u5E94\u7528","website-starter":"website-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","react-starter":"react-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A React.js \u5E94\u7528","vue-starter":"vue-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Vue.js \u5E94\u7528",puppeteer:"puppeteer - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E puppeteer \u622A\u56FE\u7684 Web \u5E94\u7528",ffmpeg:"ffmpeg - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E ffmpeg \u5B9E\u73B0\u97F3\u89C6\u9891\u5904\u7406\u5E94\u7528",pdf2Img:"pdf2Img - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A pdf \u8F6C\u56FE\u7247\u5E94\u7528",tensorflow:"tensorflow - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A tensorflow \u5E94\u7528",todoList:"todoList - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E nodejs \u7684\u7F51\u9875 TodoList \u5E94\u7528"}});var Fc=L(Tu=>{"use strict";Object.defineProperty(Tu,"__esModule",{value:!0});Tu.default={clean_up_the_environment:"Clean up the environment",display_help_for_command:"Display help for command",remove_components:"Remove component (like: fc, fc@0.0.1)",delete_the_file_under_the_cache:"Delete the <dirname> file in the cache",record_your_log_information:"Do you record your log information?",init_pproject_deploy_tip:"Do you want to deploy the project immediately?",tip_for_a_serverless_project:"A Serverless-Devs project is detected in the current directory, please deploy via 's deploy' or get more information via 's -h'",create_a_new_project:"No Serverless-Devs project is currently detected. Do you want to create a new project?",en:"English (en)",zh:"Chinese (zh)",select_current_language:"Please select current language","app-tip":"Hello, serverlesser. Which template do you like?","template-tip":"Which template do you like?","fc-runtime-starter":"fc-runtime-starter - Deploy FC function in 5 minutes","fc-custom-container-stater":"fc-custom-container-stater - Deploy FC function with custom-container",web:"web-framework-stater-Quickly deploy a web framework","static-site":"static-website-stater-Quickly deploy a static website","best-practice":"serverless-best-practice-Quickly experience serverless best practices","devs-template":"Serverless Develop scaffold","fc-http-nodejs":"fc-http-nodejs - Deploy FC nodejs12 runtime function","fc-http-python":"fc-http-python - Deploy FC python3 runtime function","fc-http-java":"fc-http-java - Deploy FC java8 runtime function","fc-custom-container-event-python3":"fc-custom-container-event-python3 - Deploy python3 event-triggered application","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - Deploy cpp event-triggered application","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - Deploy springboot HTTP Request-triggered application","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - Deploy dotnetcore HTTP Request-triggered application","express-starter":"express-starter - Deploy express application","koa-starter":"koa-starter - Deploy koa application","nuxtjs-starter":"nuxtjs-starter - Deploy nuxtjs application","eggjs-starter":"eggjs-starter - Deploy eggjs application","flask-starter":"flask-starter - Deploy flask application","SpringBoot-starter":"SpringBoot-starter - Deploy SpringBoot application","Zblog-starter":"Zblog-starter - Deploy Zblog application","website-starter":"website-starter - Deploy static website","react-starter":"react-starter - Deploy React.js application","vue-starter":"vue-starter - Deploy Vue.js application",puppeteer:"puppeteer - Deploy screenshot application base on puppeteer + fc",ffmpeg:"ffmpeg - Deploy audio and video processing application base on ffmpeg + fc",pdf2Img:"pdf2Img - Deploy pdf to images application",tensorflow:"tensorflow - Deploy tensorflow application",todoList:"todoList - Deploy todoList application"}});var Hc=L(Or=>{"use strict";var Mc=Or&&Or.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Or,"__esModule",{value:!0});var Yy=Ni(),Ky=Mc(qc()),Zy=Mc(Fc()),$u={en:Zy.default,zh:Ky.default},ky=function(i){var r=(0,Yy.getLang)(),s=$u[r]?$u[r][i]:$u.en[i];return s||i};Or.default=ky});var Du=L(de=>{"use strict";var Jy=de&&de.__createBinding||(Object.create?function(i,r,s,o){o===void 0&&(o=s),Object.defineProperty(i,o,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,o){o===void 0&&(o=s),i[o]=r[s]}),Wc=de&&de.__exportStar||function(i,r){for(var s in i)s!=="default"&&!Object.prototype.hasOwnProperty.call(r,s)&&Jy(r,i,s)},br=de&&de.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(de,"__esModule",{value:!0});de.registerCommandChecker=de.getYamlPath=de.i18n=de.logger=void 0;var Uc=br(require("path")),Qy=br(Ou()),ew=br(ht()),Gc=ew.default.fse;Wc(Ni(),de);Wc(Cu(),de);var tw=Ou();Object.defineProperty(de,"logger",{enumerable:!0,get:function(){return br(tw).default}});var nw=Hc();Object.defineProperty(de,"i18n",{enumerable:!0,get:function(){return br(nw).default}});var rw=function(i,r){var s=Uc.default.join(i,"".concat(r,".yaml")),o=Uc.default.join(i,"".concat(r,".yml")),f=Gc.existsSync(s)?s:Gc.existsSync(o)?o:void 0;return f};de.getYamlPath=rw;function iw(i){i.on("command:*",function(r){var s=i.commands.map(function(o){return o.name()});s.includes(r[0])||(Qy.default.error(" error: unknown command ".concat(r[0])),i.help())})}de.registerCommandChecker=iw});var on=L(Tn=>{"use strict";var sw=Tn&&Tn.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Tn,"__esModule",{value:!0});Tn.ServerlessError=void 0;var uw=sw(ht()),ow=uw.default.Logger,aw=new ow("S-CLI-ERROR"),lw=function(){function i(r,s,o){aw.error(r+": "+s,o),process.exit(1)}return i}();Tn.ServerlessError=lw});var Bc=L($n=>{"use strict";var fw=$n&&$n.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,f){o.__proto__=f}||function(o,f){for(var a in f)Object.prototype.hasOwnProperty.call(f,a)&&(o[a]=f[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function o(){this.constructor=r}r.prototype=s===null?Object.create(s):(o.prototype=s.prototype,new o)}}();Object.defineProperty($n,"__esModule",{value:!0});$n.CommandError=void 0;var cw=on(),hw=function(i){fw(r,i);function r(s,o){return i.call(this,"Error",s,o)||this}return r}(cw.ServerlessError);$n.CommandError=hw});var jc=L(Dn=>{"use strict";var pw=Dn&&Dn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,f){o.__proto__=f}||function(o,f){for(var a in f)Object.prototype.hasOwnProperty.call(f,a)&&(o[a]=f[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function o(){this.constructor=r}r.prototype=s===null?Object.create(s):(o.prototype=s.prototype,new o)}}();Object.defineProperty(Dn,"__esModule",{value:!0});Dn.ConfigDeleteError=void 0;var gw=on(),dw=function(i){pw(r,i);function r(s,o){return i.call(this,"Deletion failed",s,o)||this}return r}(gw.ServerlessError);Dn.ConfigDeleteError=dw});var Xc=L(Pn=>{"use strict";var _w=Pn&&Pn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,f){o.__proto__=f}||function(o,f){for(var a in f)Object.prototype.hasOwnProperty.call(f,a)&&(o[a]=f[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function o(){this.constructor=r}r.prototype=s===null?Object.create(s):(o.prototype=s.prototype,new o)}}();Object.defineProperty(Pn,"__esModule",{value:!0});Pn.ConfigError=void 0;var mw=on(),vw=function(i){_w(r,i);function r(s,o){return i.call(this,"Config failed",s,o)||this}return r}(mw.ServerlessError);Pn.ConfigError=vw});var zc=L(Nn=>{"use strict";var Ew=Nn&&Nn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,f){o.__proto__=f}||function(o,f){for(var a in f)Object.prototype.hasOwnProperty.call(f,a)&&(o[a]=f[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function o(){this.constructor=r}r.prototype=s===null?Object.create(s):(o.prototype=s.prototype,new o)}}();Object.defineProperty(Nn,"__esModule",{value:!0});Nn.ConfigGetError=void 0;var yw=on(),ww=function(i){Ew(r,i);function r(s,o){return i.call(this,"Get failed",s,o)||this}return r}(yw.ServerlessError);Nn.ConfigGetError=ww});var Vc=L(qn=>{"use strict";var xw=qn&&qn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,f){o.__proto__=f}||function(o,f){for(var a in f)Object.prototype.hasOwnProperty.call(f,a)&&(o[a]=f[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function o(){this.constructor=r}r.prototype=s===null?Object.create(s):(o.prototype=s.prototype,new o)}}();Object.defineProperty(qn,"__esModule",{value:!0});qn.InitError=void 0;var Aw=on(),Ow=function(i){xw(r,i);function r(s,o){return i.call(this,"Initialization failed",s,o)||this}return r}(Aw.ServerlessError);qn.InitError=Ow});var Kc=L(gt=>{"use strict";var bw=gt&&gt.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function E(x){try{p(o.next(x))}catch(R){d(R)}}function y(x){try{p(o.throw(x))}catch(R){d(R)}}function p(x){x.done?a(x.value):f(x.value).then(E,y)}p((o=o.apply(i,r||[])).next())})},Sw=gt&&gt.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,f,a,d;return d={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function E(p){return function(x){return y([p,x])}}function y(p){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,f&&(a=p[0]&2?f.return:p[0]?f.throw||((a=f.return)&&a.call(f),0):f.next)&&!(a=a.call(f,p[1])).done)return a;switch(f=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,f=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Rw=gt&&gt.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(gt,"__esModule",{value:!0});gt.HumanError=void 0;var Yc=Rw(ht()),Cw=Ni(),Iw=Yc.default.colors,Lw=function(){function i(r){var s=r.errorMessage,o=r.tips;this.errorMessage=s,console.log(`
37
37
  `.concat((0,Cw.bgRed)("ERROR:"))),console.log("TypeError: ".concat(s,`
@@ -31,7 +31,7 @@ __p += '`),Y&&(O+=`' +
31
31
  function print() { __p += __j.call(arguments, '') }
32
32
  `:`;
33
33
  `)+O+`return __p
34
- }`;var U=Al(function(){return J(h,N+"return "+O).apply(i,g)});if(U.source=O,co(U))throw U;return U}function fv(e){return k(e).toLowerCase()}function hv(e){return k(e).toUpperCase()}function pv(e,t,n){if(e=k(e),e&&(n||t===i))return Pu(e);if(!e||!(t=We(t)))return e;var o=ut(e),l=ut(t),h=$u(o,l),g=Nu(o,l)+1;return Vt(o,h,g).join("")}function gv(e,t,n){if(e=k(e),e&&(n||t===i))return e.slice(0,Fu(e)+1);if(!e||!(t=We(t)))return e;var o=ut(e),l=Nu(o,ut(t))+1;return Vt(o,0,l).join("")}function dv(e,t,n){if(e=k(e),e&&(n||t===i))return e.replace(cs,"");if(!e||!(t=We(t)))return e;var o=ut(e),l=$u(o,ut(t));return Vt(o,l).join("")}function _v(e,t){var n=Wr,o=Qt;if(oe(t)){var l="separator"in t?t.separator:l;n="length"in t?B(t.length):n,o="omission"in t?We(t.omission):o}e=k(e);var h=e.length;if(An(e)){var g=ut(e);h=g.length}if(n>=h)return e;var _=n-Sn(o);if(_<1)return o;var v=g?Vt(g,0,_).join(""):e.slice(0,_);if(l===i)return v+o;if(g&&(_+=v.length-_),fo(l)){if(e.slice(_).search(l)){var A,S=v;for(l.global||(l=Cs(l.source,k(tu.exec(l))+"g")),l.lastIndex=0;A=l.exec(S);)var O=A.index;v=v.slice(0,O===i?_:O)}}else if(e.indexOf(We(l),_)!=_){var R=v.lastIndexOf(l);R>-1&&(v=v.slice(0,R))}return v+o}function mv(e){return e=k(e),e&&Rh.test(e)?e.replace(ko,Vp):e}var vv=Tn(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),go=Sa("toUpperCase");function bl(e,t,n){return e=k(e),t=n?i:t,t===i?Gp(e)?Kp(e):Dp(e):e.match(t)||[]}var Al=z(function(e,t){try{return Me(e,i,t)}catch(n){return co(n)?n:new W(n)}}),yv=Tt(function(e,t){return Xe(t,function(n){n=wt(n),It(e,n,ao(e[n],e))}),e});function Ev(e){var t=e==null?0:e.length,n=F();return e=t?se(e,function(o){if(typeof o[1]!="function")throw new Ye(c);return[n(o[0]),o[1]]}):[],z(function(o){for(var l=-1;++l<t;){var h=e[l];if(Me(h[0],this,o))return Me(h[1],this,o)}})}function wv(e){return Vg(Ze(e,p))}function _o(e){return function(){return e}}function xv(e,t){return e==null||e!==e?t:e}var bv=Ca(),Av=Ca(!0);function Ne(e){return e}function mo(e){return ra(typeof e=="function"?e:Ze(e,p))}function Sv(e){return sa(Ze(e,p))}function Ov(e,t){return oa(e,Ze(t,p))}var Cv=z(function(e,t){return function(n){return fr(n,e,t)}}),Rv=z(function(e,t){return function(n){return fr(e,n,t)}});function vo(e,t,n){var o=me(t),l=gi(t,o);n==null&&!(oe(t)&&(l.length||!o.length))&&(n=t,t=e,e=this,l=gi(t,me(t)));var h=!(oe(n)&&"chain"in n)||!!n.chain,g=Pt(e);return Xe(l,function(_){var v=t[_];e[_]=v,g&&(e.prototype[_]=function(){var A=this.__chain__;if(h||A){var S=e(this.__wrapped__),O=S.__actions__=De(this.__actions__);return O.push({func:v,args:arguments,thisArg:e}),S.__chain__=A,S}return v.apply(e,Ht([this.value()],arguments))})}),e}function Iv(){return _e._===this&&(_e._=tg),this}function yo(){}function Lv(e){return e=B(e),z(function(t){return ua(t,e)})}var Tv=Ks(se),Dv=Ks(Ru),Pv=Ks(Es);function Sl(e){return no(e)?ws(wt(e)):ld(e)}function $v(e){return function(t){return e==null?i:un(e,t)}}var Nv=Ia(),qv=Ia(!0);function Eo(){return[]}function wo(){return!1}function Fv(){return{}}function Mv(){return""}function Hv(){return!0}function Wv(e,t){if(e=B(e),e<1||e>K)return[];var n=vt,o=be(e,vt);t=F(t),e-=vt;for(var l=As(o,t);++n<e;)t(n);return l}function Gv(e){return G(e)?se(e,wt):Ge(e)?[e]:De(za(k(e)))}function Bv(e){var t=++Qp;return k(e)+t}var Uv=Ei(function(e,t){return e+t},0),jv=Zs("ceil"),zv=Ei(function(e,t){return e/t},1),Vv=Zs("floor");function Xv(e){return e&&e.length?pi(e,Ne,Ns):i}function Yv(e,t){return e&&e.length?pi(e,F(t,2),Ns):i}function Kv(e){return Tu(e,Ne)}function Zv(e,t){return Tu(e,F(t,2))}function Jv(e){return e&&e.length?pi(e,Ne,Hs):i}function kv(e,t){return e&&e.length?pi(e,F(t,2),Hs):i}var Qv=Ei(function(e,t){return e*t},1),e1=Zs("round"),t1=Ei(function(e,t){return e-t},0);function n1(e){return e&&e.length?bs(e,Ne):0}function r1(e,t){return e&&e.length?bs(e,F(t,2)):0}return f.after=S0,f.ary=nl,f.assign=hm,f.assignIn=_l,f.assignInWith=Pi,f.assignWith=pm,f.at=gm,f.before=rl,f.bind=ao,f.bindAll=yv,f.bindKey=il,f.castArray=F0,f.chain=Qa,f.chunk=Vd,f.compact=Xd,f.concat=Yd,f.cond=Ev,f.conforms=wv,f.constant=_o,f.countBy=n0,f.create=dm,f.curry=sl,f.curryRight=ol,f.debounce=ul,f.defaults=_m,f.defaultsDeep=mm,f.defer=O0,f.delay=C0,f.difference=Kd,f.differenceBy=Zd,f.differenceWith=Jd,f.drop=kd,f.dropRight=Qd,f.dropRightWhile=e_,f.dropWhile=t_,f.fill=n_,f.filter=i0,f.flatMap=u0,f.flatMapDeep=a0,f.flatMapDepth=l0,f.flatten=Ka,f.flattenDeep=r_,f.flattenDepth=i_,f.flip=R0,f.flow=bv,f.flowRight=Av,f.fromPairs=s_,f.functions=Am,f.functionsIn=Sm,f.groupBy=c0,f.initial=u_,f.intersection=a_,f.intersectionBy=l_,f.intersectionWith=c_,f.invert=Cm,f.invertBy=Rm,f.invokeMap=h0,f.iteratee=mo,f.keyBy=p0,f.keys=me,f.keysIn=$e,f.map=Ci,f.mapKeys=Lm,f.mapValues=Tm,f.matches=Sv,f.matchesProperty=Ov,f.memoize=Ii,f.merge=Dm,f.mergeWith=ml,f.method=Cv,f.methodOf=Rv,f.mixin=vo,f.negate=Li,f.nthArg=Lv,f.omit=Pm,f.omitBy=$m,f.once=I0,f.orderBy=g0,f.over=Tv,f.overArgs=L0,f.overEvery=Dv,f.overSome=Pv,f.partial=lo,f.partialRight=al,f.partition=d0,f.pick=Nm,f.pickBy=vl,f.property=Sl,f.propertyOf=$v,f.pull=g_,f.pullAll=Ja,f.pullAllBy=d_,f.pullAllWith=__,f.pullAt=m_,f.range=Nv,f.rangeRight=qv,f.rearg=T0,f.reject=v0,f.remove=v_,f.rest=D0,f.reverse=oo,f.sampleSize=E0,f.set=Fm,f.setWith=Mm,f.shuffle=w0,f.slice=y_,f.sortBy=A0,f.sortedUniq=O_,f.sortedUniqBy=C_,f.split=uv,f.spread=P0,f.tail=R_,f.take=I_,f.takeRight=L_,f.takeRightWhile=T_,f.takeWhile=D_,f.tap=X_,f.throttle=$0,f.thru=Oi,f.toArray=pl,f.toPairs=yl,f.toPairsIn=El,f.toPath=Gv,f.toPlainObject=dl,f.transform=Hm,f.unary=N0,f.union=P_,f.unionBy=$_,f.unionWith=N_,f.uniq=q_,f.uniqBy=F_,f.uniqWith=M_,f.unset=Wm,f.unzip=uo,f.unzipWith=ka,f.update=Gm,f.updateWith=Bm,f.values=$n,f.valuesIn=Um,f.without=H_,f.words=bl,f.wrap=q0,f.xor=W_,f.xorBy=G_,f.xorWith=B_,f.zip=U_,f.zipObject=j_,f.zipObjectDeep=z_,f.zipWith=V_,f.entries=yl,f.entriesIn=El,f.extend=_l,f.extendWith=Pi,vo(f,f),f.add=Uv,f.attempt=Al,f.camelCase=Xm,f.capitalize=wl,f.ceil=jv,f.clamp=jm,f.clone=M0,f.cloneDeep=W0,f.cloneDeepWith=G0,f.cloneWith=H0,f.conformsTo=B0,f.deburr=xl,f.defaultTo=xv,f.divide=zv,f.endsWith=Ym,f.eq=lt,f.escape=Km,f.escapeRegExp=Zm,f.every=r0,f.find=s0,f.findIndex=Xa,f.findKey=vm,f.findLast=o0,f.findLastIndex=Ya,f.findLastKey=ym,f.floor=Vv,f.forEach=el,f.forEachRight=tl,f.forIn=Em,f.forInRight=wm,f.forOwn=xm,f.forOwnRight=bm,f.get=ho,f.gt=U0,f.gte=j0,f.has=Om,f.hasIn=po,f.head=Za,f.identity=Ne,f.includes=f0,f.indexOf=o_,f.inRange=zm,f.invoke=Im,f.isArguments=cn,f.isArray=G,f.isArrayBuffer=z0,f.isArrayLike=Pe,f.isArrayLikeObject=le,f.isBoolean=V0,f.isBuffer=Xt,f.isDate=X0,f.isElement=Y0,f.isEmpty=K0,f.isEqual=Z0,f.isEqualWith=J0,f.isError=co,f.isFinite=k0,f.isFunction=Pt,f.isInteger=ll,f.isLength=Ti,f.isMap=cl,f.isMatch=Q0,f.isMatchWith=em,f.isNaN=tm,f.isNative=nm,f.isNil=im,f.isNull=rm,f.isNumber=fl,f.isObject=oe,f.isObjectLike=ue,f.isPlainObject=mr,f.isRegExp=fo,f.isSafeInteger=sm,f.isSet=hl,f.isString=Di,f.isSymbol=Ge,f.isTypedArray=Pn,f.isUndefined=om,f.isWeakMap=um,f.isWeakSet=am,f.join=f_,f.kebabCase=Jm,f.last=ke,f.lastIndexOf=h_,f.lowerCase=km,f.lowerFirst=Qm,f.lt=lm,f.lte=cm,f.max=Xv,f.maxBy=Yv,f.mean=Kv,f.meanBy=Zv,f.min=Jv,f.minBy=kv,f.stubArray=Eo,f.stubFalse=wo,f.stubObject=Fv,f.stubString=Mv,f.stubTrue=Hv,f.multiply=Qv,f.nth=p_,f.noConflict=Iv,f.noop=yo,f.now=Ri,f.pad=ev,f.padEnd=tv,f.padStart=nv,f.parseInt=rv,f.random=Vm,f.reduce=_0,f.reduceRight=m0,f.repeat=iv,f.replace=sv,f.result=qm,f.round=e1,f.runInContext=m,f.sample=y0,f.size=x0,f.snakeCase=ov,f.some=b0,f.sortedIndex=E_,f.sortedIndexBy=w_,f.sortedIndexOf=x_,f.sortedLastIndex=b_,f.sortedLastIndexBy=A_,f.sortedLastIndexOf=S_,f.startCase=av,f.startsWith=lv,f.subtract=t1,f.sum=n1,f.sumBy=r1,f.template=cv,f.times=Wv,f.toFinite=$t,f.toInteger=B,f.toLength=gl,f.toLower=fv,f.toNumber=Qe,f.toSafeInteger=fm,f.toString=k,f.toUpper=hv,f.trim=pv,f.trimEnd=gv,f.trimStart=dv,f.truncate=_v,f.unescape=mv,f.uniqueId=Bv,f.upperCase=vv,f.upperFirst=go,f.each=el,f.eachRight=tl,f.first=Za,vo(f,function(){var e={};return yt(f,function(t,n){Q.call(f.prototype,n)||(e[n]=t)}),e}(),{chain:!1}),f.VERSION=r,Xe(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){f[e].placeholder=f}),Xe(["drop","take"],function(e,t){X.prototype[e]=function(n){n=n===i?1:de(B(n),0);var o=this.__filtered__&&!t?new X(this):this.clone();return o.__filtered__?o.__takeCount__=be(n,o.__takeCount__):o.__views__.push({size:be(n,vt),type:e+(o.__dir__<0?"Right":"")}),o},X.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Xe(["filter","map","takeWhile"],function(e,t){var n=t+1,o=n==te||n==xe;X.prototype[e]=function(l){var h=this.clone();return h.__iteratees__.push({iteratee:F(l,3),type:n}),h.__filtered__=h.__filtered__||o,h}}),Xe(["head","last"],function(e,t){var n="take"+(t?"Right":"");X.prototype[e]=function(){return this[n](1).value()[0]}}),Xe(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");X.prototype[e]=function(){return this.__filtered__?new X(this):this[n](1)}}),X.prototype.compact=function(){return this.filter(Ne)},X.prototype.find=function(e){return this.filter(e).head()},X.prototype.findLast=function(e){return this.reverse().find(e)},X.prototype.invokeMap=z(function(e,t){return typeof e=="function"?new X(this):this.map(function(n){return fr(n,e,t)})}),X.prototype.reject=function(e){return this.filter(Li(F(e)))},X.prototype.slice=function(e,t){e=B(e);var n=this;return n.__filtered__&&(e>0||t<0)?new X(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=B(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},X.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},X.prototype.toArray=function(){return this.take(vt)},yt(X.prototype,function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),o=/^(?:head|last)$/.test(t),l=f[o?"take"+(t=="last"?"Right":""):t],h=o||/^find/.test(t);!l||(f.prototype[t]=function(){var g=this.__wrapped__,_=o?[1]:arguments,v=g instanceof X,A=_[0],S=v||G(g),O=function(V){var Y=l.apply(f,Ht([V],_));return o&&R?Y[0]:Y};S&&n&&typeof A=="function"&&A.length!=1&&(v=S=!1);var R=this.__chain__,N=!!this.__actions__.length,M=h&&!R,U=v&&!N;if(!h&&S){g=U?g:new X(this);var H=e.apply(g,_);return H.__actions__.push({func:Oi,args:[O],thisArg:i}),new Ke(H,R)}return M&&U?e.apply(this,_):(H=this.thru(O),M?o?H.value()[0]:H.value():H)})}),Xe(["pop","push","shift","sort","splice","unshift"],function(e){var t=kr[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",o=/^(?:pop|shift)$/.test(e);f.prototype[e]=function(){var l=arguments;if(o&&!this.__chain__){var h=this.value();return t.apply(G(h)?h:[],l)}return this[n](function(g){return t.apply(G(g)?g:[],l)})}}),yt(X.prototype,function(e,t){var n=f[t];if(n){var o=n.name+"";Q.call(Rn,o)||(Rn[o]=[]),Rn[o].push({name:t,func:n})}}),Rn[yi(i,pt).name]=[{name:"wrapper",func:i}],X.prototype.clone=mg,X.prototype.reverse=vg,X.prototype.value=yg,f.prototype.at=Y_,f.prototype.chain=K_,f.prototype.commit=Z_,f.prototype.next=J_,f.prototype.plant=Q_,f.prototype.reverse=e0,f.prototype.toJSON=f.prototype.valueOf=f.prototype.value=t0,f.prototype.first=f.prototype.head,ir&&(f.prototype[ir]=k_),f},Gt=Zp();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(_e._=Gt,define(function(){return Gt})):tn?((tn.exports=Gt)._=Gt,_s._=Gt):_e._=Gt}).call(Mn)});var Ki=L(qe=>{"use strict";var yE=qe&&qe.__awaiter||function(i,r,s,u){function c(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function y(x){try{p(u.next(x))}catch(C){d(C)}}function E(x){try{p(u.throw(x))}catch(C){d(C)}}function p(x){x.done?a(x.value):c(x.value).then(y,E)}p((u=u.apply(i,r||[])).next())})},EE=qe&&qe.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},u,c,a,d;return d={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function y(p){return function(x){return E([p,x])}}function E(p){if(u)throw new TypeError("Generator is already executing.");for(;s;)try{if(u=1,c&&(a=p[0]&2?c.return:p[0]?c.throw||((a=c.return)&&a.call(c),0):c.next)&&!(a=a.call(c,p[1])).done)return a;switch(c=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,c=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],c=0}finally{u=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Mf=qe&&qe.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(qe,"__esModule",{value:!0});qe.handlerProfileFile=qe.getConfig=qe.setConfig=void 0;var Hf=Mf(require("path")),Wo=Mf(xt()),bt=Wo.default.fse,Yi=Wo.default.jsyaml,Go=Wo.default.getRootHome;function wE(i){var r=Gf();bt.writeFileSync(r,Yi.dump(i))}function Wf(){var i=Gf();if(!bt.existsSync(i))return{};try{var r=Yi.load(bt.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function Gf(){var i=Hf.default.join(Go(),"set-config.yml");return bt.existsSync(i)||bt.createFileSync(i),i}function xE(i,r){var s=Wf();s[i]=r,wE(s)}qe.setConfig=xE;function bE(i,r){var s=Wf();return s[i]||r}qe.getConfig=bE;function AE(i){return yE(this,void 0,void 0,function(){var r,s,u,c,a,d,y;return EE(this,function(E){switch(E.label){case 0:if(r=i.filePath||"set-config.yml",s=Hf.default.join(Go(),r),u=bt.existsSync(s),c={},u)return[3,5];a=Go(),E.label=1;case 1:return E.trys.push([1,2,,4]),bt.statSync(a),[3,4];case 2:return d=E.sent(),[4,bt.mkdirSync(a)];case 3:return E.sent(),[3,4];case 4:return[3,6];case 5:try{c=Yi.load(bt.readFileSync(s,"utf8"))||{}}catch(p){throw p}E.label=6;case 6:return i.read?[2,c]:(y=i.configKey||"",c[y]=i.data,[4,bt.writeFileSync(s,Yi.dump(c))]);case 7:return E.sent(),[2,c]}})})}qe.handlerProfileFile=AE});var Bf=L((ub,SE)=>{SE.exports={name:"@serverless-devs/s",version:"2.0.100-beta.4",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"MIT",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./shell/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.0.0","@types/jest":"^27.4.0","@types/lodash":"^4.14.168","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2",husky:"^4.2.3",inquirer:"^8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",lodash:"^4.17.20","os-locale":"5.0.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"beta"}}});var Gn=L(q=>{"use strict";var OE=q&&q.__createBinding||(Object.create?function(i,r,s,u){u===void 0&&(u=s),Object.defineProperty(i,u,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,u){u===void 0&&(u=s),i[u]=r[s]}),CE=q&&q.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),RE=q&&q.__importStar||function(i){if(i&&i.__esModule)return i;var r={};if(i!=null)for(var s in i)s!=="default"&&Object.prototype.hasOwnProperty.call(i,s)&&OE(r,i,s);return CE(r,i),r},Hn=q&&q.__awaiter||function(i,r,s,u){function c(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function y(x){try{p(u.next(x))}catch(C){d(C)}}function E(x){try{p(u.throw(x))}catch(C){d(C)}}function p(x){x.done?a(x.value):c(x.value).then(y,E)}p((u=u.apply(i,r||[])).next())})},Wn=q&&q.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},u,c,a,d;return d={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function y(p){return function(x){return E([p,x])}}function E(p){if(u)throw new TypeError("Generator is already executing.");for(;s;)try{if(u=1,c&&(a=p[0]&2?c.return:p[0]?c.throw||((a=c.return)&&a.call(c),0):c.next)&&!(a=a.call(c,p[1])).done)return a;switch(c=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,c=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],c=0}finally{u=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Bo=q&&q.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(q,"__esModule",{value:!0});q.emoji=q.mark=q.replaceTemplate=q.getTemplatekey=q.replaceFun=q.getLang=q.printn=q.getFolderSize=q.getVersion=q.getPid=q.aiRequest=q.getCredentialWithAll=q.getCredentialWithExisted=q.getCredentialAliasList=q.getProcessArgv=q.bgRed=q.yellow=q.red=void 0;var Uf=Bo(require("path")),Pr=Bo(require("fs")),rt=Ho(),IE=Bo(require("os")),it=RE(xt()),LE=Ki(),jf=Bf(),Zi=it.default.colors,TE=it.default.got,DE=it.default.getMAC,PE=it.default.isDocker,$E=it.default.isCiCdEnv,NE=it.default.getGlobalArgs,qE=it.default.getYamlContent,FE=it.default.getRootHome,zf=it.default.getCredential,ME=it.default.getCredentialFromEnv;q.red=Zi.hex("#fd5750");q.yellow=Zi.hex("#F3F99D");q.bgRed=Zi.hex("#000").bgHex("#fd5750");var HE=function(){var i=process.env.serverless_devs_temp_argv;try{var r=JSON.parse(i),s=NE(r);return process.argv=process.argv.slice(0,2).concat(s._argsObj),(0,rt.assign)({},s,{noHelpArgv:process.argv.slice(0,2).concat((0,rt.filter)(s._argsObj,function(u){return!(0,rt.includes)(["-h","--help"],u)}))})}catch{return{}}};q.getProcessArgv=HE;var WE=function(){return Hn(void 0,void 0,void 0,function(){var i,r,s;return Wn(this,function(u){switch(u.label){case 0:return i=[],[4,qE(Uf.default.join(FE(),"access.yaml"))];case 1:return r=u.sent(),r&&(i=(0,rt.keys)(r)),[4,ME()];case 2:return s=u.sent(),s&&(i=(0,rt.filter)(i,function(c){return c!==s.Alias}),i.push(s.Alias)),[2,i]}})})};q.getCredentialAliasList=WE;var GE=function(i){return Hn(void 0,void 0,void 0,function(){var r,s;return Wn(this,function(u){switch(u.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:return r=u.sent(),(0,rt.includes)(r,i)?[4,zf(i)]:[3,3];case 2:return s=u.sent(),[2,(0,rt.omit)(s,"Alias")];case 3:return[2]}})})};q.getCredentialWithExisted=GE;var BE=function(){return Hn(void 0,void 0,void 0,function(){var i,r,s,u,c,a;return Wn(this,function(d){switch(d.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:if(i=d.sent(),!(i.length>0))return[3,6];r={},s=0,u=i,d.label=2;case 2:return s<u.length?(c=u[s],[4,zf(c)]):[3,5];case 3:a=d.sent(),r[a.Alias]=(0,rt.omit)(a,"Alias"),d.label=4;case 4:return s++,[3,2];case 5:return[2,r];case 6:return[2]}})})};q.getCredentialWithAll=BE;var UE=function(i,r){return r===void 0&&(r="unknow"),Hn(void 0,void 0,void 0,function(){var s,u,c,a;return Wn(this,function(d){switch(d.label){case 0:return d.trys.push([0,2,,3]),s=(0,LE.getConfig)("analysis"),s!=="enable"?[2]:PE()||$E()?[2]:[4,TE("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(r,"&code=TypeError&s=").concat(i),{timeout:2e3,json:!0})];case 1:return u=d.sent(),c=(0,rt.get)(u.body,"shorturl"),c&&console.log(`AI Tips:
34
+ }`;var U=Al(function(){return J(h,N+"return "+O).apply(i,g)});if(U.source=O,co(U))throw U;return U}function fv(e){return k(e).toLowerCase()}function hv(e){return k(e).toUpperCase()}function pv(e,t,n){if(e=k(e),e&&(n||t===i))return Pu(e);if(!e||!(t=We(t)))return e;var o=ut(e),l=ut(t),h=$u(o,l),g=Nu(o,l)+1;return Vt(o,h,g).join("")}function gv(e,t,n){if(e=k(e),e&&(n||t===i))return e.slice(0,Fu(e)+1);if(!e||!(t=We(t)))return e;var o=ut(e),l=Nu(o,ut(t))+1;return Vt(o,0,l).join("")}function dv(e,t,n){if(e=k(e),e&&(n||t===i))return e.replace(cs,"");if(!e||!(t=We(t)))return e;var o=ut(e),l=$u(o,ut(t));return Vt(o,l).join("")}function _v(e,t){var n=Wr,o=Qt;if(oe(t)){var l="separator"in t?t.separator:l;n="length"in t?B(t.length):n,o="omission"in t?We(t.omission):o}e=k(e);var h=e.length;if(An(e)){var g=ut(e);h=g.length}if(n>=h)return e;var _=n-Sn(o);if(_<1)return o;var v=g?Vt(g,0,_).join(""):e.slice(0,_);if(l===i)return v+o;if(g&&(_+=v.length-_),fo(l)){if(e.slice(_).search(l)){var A,S=v;for(l.global||(l=Cs(l.source,k(tu.exec(l))+"g")),l.lastIndex=0;A=l.exec(S);)var O=A.index;v=v.slice(0,O===i?_:O)}}else if(e.indexOf(We(l),_)!=_){var R=v.lastIndexOf(l);R>-1&&(v=v.slice(0,R))}return v+o}function mv(e){return e=k(e),e&&Rh.test(e)?e.replace(ko,Vp):e}var vv=Tn(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),go=Sa("toUpperCase");function bl(e,t,n){return e=k(e),t=n?i:t,t===i?Gp(e)?Kp(e):Dp(e):e.match(t)||[]}var Al=z(function(e,t){try{return Me(e,i,t)}catch(n){return co(n)?n:new W(n)}}),yv=Tt(function(e,t){return Xe(t,function(n){n=wt(n),It(e,n,ao(e[n],e))}),e});function Ev(e){var t=e==null?0:e.length,n=F();return e=t?se(e,function(o){if(typeof o[1]!="function")throw new Ye(c);return[n(o[0]),o[1]]}):[],z(function(o){for(var l=-1;++l<t;){var h=e[l];if(Me(h[0],this,o))return Me(h[1],this,o)}})}function wv(e){return Vg(Ze(e,p))}function _o(e){return function(){return e}}function xv(e,t){return e==null||e!==e?t:e}var bv=Ca(),Av=Ca(!0);function Ne(e){return e}function mo(e){return ra(typeof e=="function"?e:Ze(e,p))}function Sv(e){return sa(Ze(e,p))}function Ov(e,t){return oa(e,Ze(t,p))}var Cv=z(function(e,t){return function(n){return fr(n,e,t)}}),Rv=z(function(e,t){return function(n){return fr(e,n,t)}});function vo(e,t,n){var o=me(t),l=gi(t,o);n==null&&!(oe(t)&&(l.length||!o.length))&&(n=t,t=e,e=this,l=gi(t,me(t)));var h=!(oe(n)&&"chain"in n)||!!n.chain,g=Pt(e);return Xe(l,function(_){var v=t[_];e[_]=v,g&&(e.prototype[_]=function(){var A=this.__chain__;if(h||A){var S=e(this.__wrapped__),O=S.__actions__=De(this.__actions__);return O.push({func:v,args:arguments,thisArg:e}),S.__chain__=A,S}return v.apply(e,Ht([this.value()],arguments))})}),e}function Iv(){return _e._===this&&(_e._=tg),this}function yo(){}function Lv(e){return e=B(e),z(function(t){return ua(t,e)})}var Tv=Ks(se),Dv=Ks(Ru),Pv=Ks(Es);function Sl(e){return no(e)?ws(wt(e)):ld(e)}function $v(e){return function(t){return e==null?i:un(e,t)}}var Nv=Ia(),qv=Ia(!0);function Eo(){return[]}function wo(){return!1}function Fv(){return{}}function Mv(){return""}function Hv(){return!0}function Wv(e,t){if(e=B(e),e<1||e>K)return[];var n=vt,o=be(e,vt);t=F(t),e-=vt;for(var l=As(o,t);++n<e;)t(n);return l}function Gv(e){return G(e)?se(e,wt):Ge(e)?[e]:De(za(k(e)))}function Bv(e){var t=++Qp;return k(e)+t}var Uv=Ei(function(e,t){return e+t},0),jv=Zs("ceil"),zv=Ei(function(e,t){return e/t},1),Vv=Zs("floor");function Xv(e){return e&&e.length?pi(e,Ne,Ns):i}function Yv(e,t){return e&&e.length?pi(e,F(t,2),Ns):i}function Kv(e){return Tu(e,Ne)}function Zv(e,t){return Tu(e,F(t,2))}function Jv(e){return e&&e.length?pi(e,Ne,Hs):i}function kv(e,t){return e&&e.length?pi(e,F(t,2),Hs):i}var Qv=Ei(function(e,t){return e*t},1),e1=Zs("round"),t1=Ei(function(e,t){return e-t},0);function n1(e){return e&&e.length?bs(e,Ne):0}function r1(e,t){return e&&e.length?bs(e,F(t,2)):0}return f.after=S0,f.ary=nl,f.assign=hm,f.assignIn=_l,f.assignInWith=Pi,f.assignWith=pm,f.at=gm,f.before=rl,f.bind=ao,f.bindAll=yv,f.bindKey=il,f.castArray=F0,f.chain=Qa,f.chunk=Vd,f.compact=Xd,f.concat=Yd,f.cond=Ev,f.conforms=wv,f.constant=_o,f.countBy=n0,f.create=dm,f.curry=sl,f.curryRight=ol,f.debounce=ul,f.defaults=_m,f.defaultsDeep=mm,f.defer=O0,f.delay=C0,f.difference=Kd,f.differenceBy=Zd,f.differenceWith=Jd,f.drop=kd,f.dropRight=Qd,f.dropRightWhile=e_,f.dropWhile=t_,f.fill=n_,f.filter=i0,f.flatMap=u0,f.flatMapDeep=a0,f.flatMapDepth=l0,f.flatten=Ka,f.flattenDeep=r_,f.flattenDepth=i_,f.flip=R0,f.flow=bv,f.flowRight=Av,f.fromPairs=s_,f.functions=Am,f.functionsIn=Sm,f.groupBy=c0,f.initial=u_,f.intersection=a_,f.intersectionBy=l_,f.intersectionWith=c_,f.invert=Cm,f.invertBy=Rm,f.invokeMap=h0,f.iteratee=mo,f.keyBy=p0,f.keys=me,f.keysIn=$e,f.map=Ci,f.mapKeys=Lm,f.mapValues=Tm,f.matches=Sv,f.matchesProperty=Ov,f.memoize=Ii,f.merge=Dm,f.mergeWith=ml,f.method=Cv,f.methodOf=Rv,f.mixin=vo,f.negate=Li,f.nthArg=Lv,f.omit=Pm,f.omitBy=$m,f.once=I0,f.orderBy=g0,f.over=Tv,f.overArgs=L0,f.overEvery=Dv,f.overSome=Pv,f.partial=lo,f.partialRight=al,f.partition=d0,f.pick=Nm,f.pickBy=vl,f.property=Sl,f.propertyOf=$v,f.pull=g_,f.pullAll=Ja,f.pullAllBy=d_,f.pullAllWith=__,f.pullAt=m_,f.range=Nv,f.rangeRight=qv,f.rearg=T0,f.reject=v0,f.remove=v_,f.rest=D0,f.reverse=oo,f.sampleSize=E0,f.set=Fm,f.setWith=Mm,f.shuffle=w0,f.slice=y_,f.sortBy=A0,f.sortedUniq=O_,f.sortedUniqBy=C_,f.split=uv,f.spread=P0,f.tail=R_,f.take=I_,f.takeRight=L_,f.takeRightWhile=T_,f.takeWhile=D_,f.tap=X_,f.throttle=$0,f.thru=Oi,f.toArray=pl,f.toPairs=yl,f.toPairsIn=El,f.toPath=Gv,f.toPlainObject=dl,f.transform=Hm,f.unary=N0,f.union=P_,f.unionBy=$_,f.unionWith=N_,f.uniq=q_,f.uniqBy=F_,f.uniqWith=M_,f.unset=Wm,f.unzip=uo,f.unzipWith=ka,f.update=Gm,f.updateWith=Bm,f.values=$n,f.valuesIn=Um,f.without=H_,f.words=bl,f.wrap=q0,f.xor=W_,f.xorBy=G_,f.xorWith=B_,f.zip=U_,f.zipObject=j_,f.zipObjectDeep=z_,f.zipWith=V_,f.entries=yl,f.entriesIn=El,f.extend=_l,f.extendWith=Pi,vo(f,f),f.add=Uv,f.attempt=Al,f.camelCase=Xm,f.capitalize=wl,f.ceil=jv,f.clamp=jm,f.clone=M0,f.cloneDeep=W0,f.cloneDeepWith=G0,f.cloneWith=H0,f.conformsTo=B0,f.deburr=xl,f.defaultTo=xv,f.divide=zv,f.endsWith=Ym,f.eq=lt,f.escape=Km,f.escapeRegExp=Zm,f.every=r0,f.find=s0,f.findIndex=Xa,f.findKey=vm,f.findLast=o0,f.findLastIndex=Ya,f.findLastKey=ym,f.floor=Vv,f.forEach=el,f.forEachRight=tl,f.forIn=Em,f.forInRight=wm,f.forOwn=xm,f.forOwnRight=bm,f.get=ho,f.gt=U0,f.gte=j0,f.has=Om,f.hasIn=po,f.head=Za,f.identity=Ne,f.includes=f0,f.indexOf=o_,f.inRange=zm,f.invoke=Im,f.isArguments=cn,f.isArray=G,f.isArrayBuffer=z0,f.isArrayLike=Pe,f.isArrayLikeObject=le,f.isBoolean=V0,f.isBuffer=Xt,f.isDate=X0,f.isElement=Y0,f.isEmpty=K0,f.isEqual=Z0,f.isEqualWith=J0,f.isError=co,f.isFinite=k0,f.isFunction=Pt,f.isInteger=ll,f.isLength=Ti,f.isMap=cl,f.isMatch=Q0,f.isMatchWith=em,f.isNaN=tm,f.isNative=nm,f.isNil=im,f.isNull=rm,f.isNumber=fl,f.isObject=oe,f.isObjectLike=ue,f.isPlainObject=mr,f.isRegExp=fo,f.isSafeInteger=sm,f.isSet=hl,f.isString=Di,f.isSymbol=Ge,f.isTypedArray=Pn,f.isUndefined=om,f.isWeakMap=um,f.isWeakSet=am,f.join=f_,f.kebabCase=Jm,f.last=ke,f.lastIndexOf=h_,f.lowerCase=km,f.lowerFirst=Qm,f.lt=lm,f.lte=cm,f.max=Xv,f.maxBy=Yv,f.mean=Kv,f.meanBy=Zv,f.min=Jv,f.minBy=kv,f.stubArray=Eo,f.stubFalse=wo,f.stubObject=Fv,f.stubString=Mv,f.stubTrue=Hv,f.multiply=Qv,f.nth=p_,f.noConflict=Iv,f.noop=yo,f.now=Ri,f.pad=ev,f.padEnd=tv,f.padStart=nv,f.parseInt=rv,f.random=Vm,f.reduce=_0,f.reduceRight=m0,f.repeat=iv,f.replace=sv,f.result=qm,f.round=e1,f.runInContext=m,f.sample=y0,f.size=x0,f.snakeCase=ov,f.some=b0,f.sortedIndex=E_,f.sortedIndexBy=w_,f.sortedIndexOf=x_,f.sortedLastIndex=b_,f.sortedLastIndexBy=A_,f.sortedLastIndexOf=S_,f.startCase=av,f.startsWith=lv,f.subtract=t1,f.sum=n1,f.sumBy=r1,f.template=cv,f.times=Wv,f.toFinite=$t,f.toInteger=B,f.toLength=gl,f.toLower=fv,f.toNumber=Qe,f.toSafeInteger=fm,f.toString=k,f.toUpper=hv,f.trim=pv,f.trimEnd=gv,f.trimStart=dv,f.truncate=_v,f.unescape=mv,f.uniqueId=Bv,f.upperCase=vv,f.upperFirst=go,f.each=el,f.eachRight=tl,f.first=Za,vo(f,function(){var e={};return yt(f,function(t,n){Q.call(f.prototype,n)||(e[n]=t)}),e}(),{chain:!1}),f.VERSION=r,Xe(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){f[e].placeholder=f}),Xe(["drop","take"],function(e,t){X.prototype[e]=function(n){n=n===i?1:de(B(n),0);var o=this.__filtered__&&!t?new X(this):this.clone();return o.__filtered__?o.__takeCount__=be(n,o.__takeCount__):o.__views__.push({size:be(n,vt),type:e+(o.__dir__<0?"Right":"")}),o},X.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Xe(["filter","map","takeWhile"],function(e,t){var n=t+1,o=n==te||n==xe;X.prototype[e]=function(l){var h=this.clone();return h.__iteratees__.push({iteratee:F(l,3),type:n}),h.__filtered__=h.__filtered__||o,h}}),Xe(["head","last"],function(e,t){var n="take"+(t?"Right":"");X.prototype[e]=function(){return this[n](1).value()[0]}}),Xe(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");X.prototype[e]=function(){return this.__filtered__?new X(this):this[n](1)}}),X.prototype.compact=function(){return this.filter(Ne)},X.prototype.find=function(e){return this.filter(e).head()},X.prototype.findLast=function(e){return this.reverse().find(e)},X.prototype.invokeMap=z(function(e,t){return typeof e=="function"?new X(this):this.map(function(n){return fr(n,e,t)})}),X.prototype.reject=function(e){return this.filter(Li(F(e)))},X.prototype.slice=function(e,t){e=B(e);var n=this;return n.__filtered__&&(e>0||t<0)?new X(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=B(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},X.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},X.prototype.toArray=function(){return this.take(vt)},yt(X.prototype,function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),o=/^(?:head|last)$/.test(t),l=f[o?"take"+(t=="last"?"Right":""):t],h=o||/^find/.test(t);!l||(f.prototype[t]=function(){var g=this.__wrapped__,_=o?[1]:arguments,v=g instanceof X,A=_[0],S=v||G(g),O=function(V){var Y=l.apply(f,Ht([V],_));return o&&R?Y[0]:Y};S&&n&&typeof A=="function"&&A.length!=1&&(v=S=!1);var R=this.__chain__,N=!!this.__actions__.length,M=h&&!R,U=v&&!N;if(!h&&S){g=U?g:new X(this);var H=e.apply(g,_);return H.__actions__.push({func:Oi,args:[O],thisArg:i}),new Ke(H,R)}return M&&U?e.apply(this,_):(H=this.thru(O),M?o?H.value()[0]:H.value():H)})}),Xe(["pop","push","shift","sort","splice","unshift"],function(e){var t=kr[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",o=/^(?:pop|shift)$/.test(e);f.prototype[e]=function(){var l=arguments;if(o&&!this.__chain__){var h=this.value();return t.apply(G(h)?h:[],l)}return this[n](function(g){return t.apply(G(g)?g:[],l)})}}),yt(X.prototype,function(e,t){var n=f[t];if(n){var o=n.name+"";Q.call(Rn,o)||(Rn[o]=[]),Rn[o].push({name:t,func:n})}}),Rn[yi(i,pt).name]=[{name:"wrapper",func:i}],X.prototype.clone=mg,X.prototype.reverse=vg,X.prototype.value=yg,f.prototype.at=Y_,f.prototype.chain=K_,f.prototype.commit=Z_,f.prototype.next=J_,f.prototype.plant=Q_,f.prototype.reverse=e0,f.prototype.toJSON=f.prototype.valueOf=f.prototype.value=t0,f.prototype.first=f.prototype.head,ir&&(f.prototype[ir]=k_),f},Gt=Zp();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(_e._=Gt,define(function(){return Gt})):tn?((tn.exports=Gt)._=Gt,_s._=Gt):_e._=Gt}).call(Mn)});var Ki=L(qe=>{"use strict";var yE=qe&&qe.__awaiter||function(i,r,s,u){function c(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function y(x){try{p(u.next(x))}catch(C){d(C)}}function E(x){try{p(u.throw(x))}catch(C){d(C)}}function p(x){x.done?a(x.value):c(x.value).then(y,E)}p((u=u.apply(i,r||[])).next())})},EE=qe&&qe.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},u,c,a,d;return d={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function y(p){return function(x){return E([p,x])}}function E(p){if(u)throw new TypeError("Generator is already executing.");for(;s;)try{if(u=1,c&&(a=p[0]&2?c.return:p[0]?c.throw||((a=c.return)&&a.call(c),0):c.next)&&!(a=a.call(c,p[1])).done)return a;switch(c=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,c=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],c=0}finally{u=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Mf=qe&&qe.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(qe,"__esModule",{value:!0});qe.handlerProfileFile=qe.getConfig=qe.setConfig=void 0;var Hf=Mf(require("path")),Wo=Mf(xt()),bt=Wo.default.fse,Yi=Wo.default.jsyaml,Go=Wo.default.getRootHome;function wE(i){var r=Gf();bt.writeFileSync(r,Yi.dump(i))}function Wf(){var i=Gf();if(!bt.existsSync(i))return{};try{var r=Yi.load(bt.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function Gf(){var i=Hf.default.join(Go(),"set-config.yml");return bt.existsSync(i)||bt.createFileSync(i),i}function xE(i,r){var s=Wf();s[i]=r,wE(s)}qe.setConfig=xE;function bE(i,r){var s=Wf();return s[i]||r}qe.getConfig=bE;function AE(i){return yE(this,void 0,void 0,function(){var r,s,u,c,a,d,y;return EE(this,function(E){switch(E.label){case 0:if(r=i.filePath||"set-config.yml",s=Hf.default.join(Go(),r),u=bt.existsSync(s),c={},u)return[3,5];a=Go(),E.label=1;case 1:return E.trys.push([1,2,,4]),bt.statSync(a),[3,4];case 2:return d=E.sent(),[4,bt.mkdirSync(a)];case 3:return E.sent(),[3,4];case 4:return[3,6];case 5:try{c=Yi.load(bt.readFileSync(s,"utf8"))||{}}catch(p){throw p}E.label=6;case 6:return i.read?[2,c]:(y=i.configKey||"",c[y]=i.data,[4,bt.writeFileSync(s,Yi.dump(c))]);case 7:return E.sent(),[2,c]}})})}qe.handlerProfileFile=AE});var Bf=L((ub,SE)=>{SE.exports={name:"@serverless-devs/s",version:"2.0.100-beta.5",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"MIT",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./shell/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.0.0","@types/jest":"^27.4.0","@types/lodash":"^4.14.168","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2",husky:"^4.2.3",inquirer:"^8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",lodash:"^4.17.20","os-locale":"5.0.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"beta"}}});var Gn=L(q=>{"use strict";var OE=q&&q.__createBinding||(Object.create?function(i,r,s,u){u===void 0&&(u=s),Object.defineProperty(i,u,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,u){u===void 0&&(u=s),i[u]=r[s]}),CE=q&&q.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),RE=q&&q.__importStar||function(i){if(i&&i.__esModule)return i;var r={};if(i!=null)for(var s in i)s!=="default"&&Object.prototype.hasOwnProperty.call(i,s)&&OE(r,i,s);return CE(r,i),r},Hn=q&&q.__awaiter||function(i,r,s,u){function c(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function y(x){try{p(u.next(x))}catch(C){d(C)}}function E(x){try{p(u.throw(x))}catch(C){d(C)}}function p(x){x.done?a(x.value):c(x.value).then(y,E)}p((u=u.apply(i,r||[])).next())})},Wn=q&&q.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},u,c,a,d;return d={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function y(p){return function(x){return E([p,x])}}function E(p){if(u)throw new TypeError("Generator is already executing.");for(;s;)try{if(u=1,c&&(a=p[0]&2?c.return:p[0]?c.throw||((a=c.return)&&a.call(c),0):c.next)&&!(a=a.call(c,p[1])).done)return a;switch(c=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,c=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],c=0}finally{u=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Bo=q&&q.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(q,"__esModule",{value:!0});q.emoji=q.mark=q.replaceTemplate=q.getTemplatekey=q.replaceFun=q.getLang=q.printn=q.getFolderSize=q.getVersion=q.getPid=q.aiRequest=q.getCredentialWithAll=q.getCredentialWithExisted=q.getCredentialAliasList=q.getProcessArgv=q.bgRed=q.yellow=q.red=void 0;var Uf=Bo(require("path")),Pr=Bo(require("fs")),rt=Ho(),IE=Bo(require("os")),it=RE(xt()),LE=Ki(),jf=Bf(),Zi=it.default.colors,TE=it.default.got,DE=it.default.getMAC,PE=it.default.isDocker,$E=it.default.isCiCdEnv,NE=it.default.getGlobalArgs,qE=it.default.getYamlContent,FE=it.default.getRootHome,zf=it.default.getCredential,ME=it.default.getCredentialFromEnv;q.red=Zi.hex("#fd5750");q.yellow=Zi.hex("#F3F99D");q.bgRed=Zi.hex("#000").bgHex("#fd5750");var HE=function(){var i=process.env.serverless_devs_temp_argv;try{var r=JSON.parse(i),s=NE(r);return process.argv=process.argv.slice(0,2).concat(s._argsObj),(0,rt.assign)({},s,{noHelpArgv:process.argv.slice(0,2).concat((0,rt.filter)(s._argsObj,function(u){return!(0,rt.includes)(["-h","--help"],u)}))})}catch{return{}}};q.getProcessArgv=HE;var WE=function(){return Hn(void 0,void 0,void 0,function(){var i,r,s;return Wn(this,function(u){switch(u.label){case 0:return i=[],[4,qE(Uf.default.join(FE(),"access.yaml"))];case 1:return r=u.sent(),r&&(i=(0,rt.keys)(r)),[4,ME()];case 2:return s=u.sent(),s&&(i=(0,rt.filter)(i,function(c){return c!==s.Alias}),i.push(s.Alias)),[2,i]}})})};q.getCredentialAliasList=WE;var GE=function(i){return Hn(void 0,void 0,void 0,function(){var r,s;return Wn(this,function(u){switch(u.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:return r=u.sent(),(0,rt.includes)(r,i)?[4,zf(i)]:[3,3];case 2:return s=u.sent(),[2,(0,rt.omit)(s,"Alias")];case 3:return[2]}})})};q.getCredentialWithExisted=GE;var BE=function(){return Hn(void 0,void 0,void 0,function(){var i,r,s,u,c,a;return Wn(this,function(d){switch(d.label){case 0:return[4,(0,q.getCredentialAliasList)()];case 1:if(i=d.sent(),!(i.length>0))return[3,6];r={},s=0,u=i,d.label=2;case 2:return s<u.length?(c=u[s],[4,zf(c)]):[3,5];case 3:a=d.sent(),r[a.Alias]=(0,rt.omit)(a,"Alias"),d.label=4;case 4:return s++,[3,2];case 5:return[2,r];case 6:return[2]}})})};q.getCredentialWithAll=BE;var UE=function(i,r){return r===void 0&&(r="unknow"),Hn(void 0,void 0,void 0,function(){var s,u,c,a;return Wn(this,function(d){switch(d.label){case 0:return d.trys.push([0,2,,3]),s=(0,LE.getConfig)("analysis"),s!=="enable"?[2]:PE()||$E()?[2]:[4,TE("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(r,"&code=TypeError&s=").concat(i),{timeout:2e3,json:!0})];case 1:return u=d.sent(),c=(0,rt.get)(u.body,"shorturl"),c&&console.log(`AI Tips:
35
35
  You can try to solve the problem through: `.concat(Zi.underline(c),`
36
36
  `)),[3,3];case 2:return a=d.sent(),[3,3];case 3:return[2]}})})};q.aiRequest=UE;var jE=function(){try{return DE().replace(/:/g,"")}catch{return"unknown"}};q.getPid=jE;function zE(){var i=(0,it.getCoreVersion)(),r="".concat(process.platform,"-").concat(process.arch),s="node-".concat(process.version),u="core: ".concat(i),c="s-home: ".concat(it.default.getRootHome()),a="".concat(jf.name,": ").concat(jf.version);return i?"".concat(a,", ").concat(u,", ").concat(c,", ").concat(r,", ").concat(s):"".concat(a,", ").concat(c,", ").concat(r,", ").concat(s)}q.getVersion=zE;function VE(i){return Hn(this,void 0,void 0,function(){function r(c){return Hn(this,void 0,void 0,function(){var a,d;return Wn(this,function(y){switch(y.label){case 0:return a=Pr.default.lstatSync(c),typeof a!="object"?[2]:(s.set(a.ino,a.size),a.isDirectory()?(d=Pr.default.readdirSync(c),typeof d!="object"?[2]:[4,Promise.all(d.map(function(E){return r(Uf.default.join(c,E))}))]):[3,2]);case 1:y.sent(),y.label=2;case 2:return[2]}})})}var s,u;return Wn(this,function(c){switch(c.label){case 0:return s=new Map,[4,r(i)];case 1:return c.sent(),u=Array.from(s.values()).reduce(function(a,d){return a+d},0),[2,u]}})})}q.getFolderSize=VE;function XE(i,r){r===void 0&&(r=" ");for(var s="",u=0;u<i;u++)s=s+r;return s}q.printn=XE;function YE(){return"en"}q.getLang=YE;function Vf(i,r){var s=/\{\{(.*?)\}\}/g,u=i.match(s);if(u)for(var c=0;c<u.length;c++){var a=u[c].replace(/{{|}}/g,""),d=(0,rt.trim)(a.split("|")[0]);r[d]&&(i=i.replace(u[c],r[d]))}return i}q.replaceFun=Vf;function KE(i){var r=/\{\{(.*?)\}\}/g,s=i.match(r);return s?s.filter(function(u){return u}).map(function(u){var c=u.replace(/{{|}}/g,""),a=c.split("|");return{name:(0,rt.trim)(a[0]),desc:(0,rt.trim)(a[1])}}):[]}q.getTemplatekey=KE;function ZE(i,r){i.forEach(function(s){if(Pr.default.existsSync(s)){var u=Pr.default.readFileSync(s,"utf-8"),c=Vf(u,r);Pr.default.writeFileSync(s,c,"utf-8")}})}q.replaceTemplate=ZE;function JE(i){if(!i)return i;var r=i.slice(-4);return"***********".concat(r)}q.mark=JE;function kE(i,r){return IE.default.platform()==="win32"?r||"\u25C6":"".concat(i," ")}q.emoji=kE});var Xf=L(Uo=>{"use strict";Object.defineProperty(Uo,"__esModule",{value:!0});Uo.default={clean_up_the_environment:"\u6E05\u7406\u73AF\u5883",display_help_for_command:"\u663E\u793A\u547D\u4EE4\u5E2E\u52A9",remove_components:"\u5220\u9664\u7EC4\u4EF6",delete_the_file_under_the_cache:"\u5220\u9664\u7F13\u5B58\u91CC\u7684\u7684<dirname>\u6587\u4EF6",record_your_log_information:"\u662F\u5426\u8BB0\u5F55\u60A8\u7684\u65E5\u5FD7\u4FE1\u606F\uFF1F",init_pproject_deploy_tip:"\u662F\u5426\u7ACB\u5373\u90E8\u7F72\u8BE5\u9879\u76EE\uFF1F",tip_for_a_serverless_project:"\u68C0\u6D4B\u5230\u5F53\u524D\u76EE\u5F55\u4E0B\u5DF2\u5B58\u5728\u4E00\u4E2AServerless-Devs\u9879\u76EE\uFF0C\u8BF7\u901A\u8FC7 's deploy' \u8FDB\u884C\u90E8\u7F72\u6216\u901A\u8FC7 's -h' \u83B7\u53D6\u66F4\u591A\u4FE1\u606F",create_a_new_project:"\u672A\u68C0\u6D4B\u5230 Serverless-Devs \u9879\u76EE\uFF0C\u662F\u5426\u65B0\u5EFA\u4E00\u4E2A\u9879\u76EE\uFF1F",en:"English (en)",zh:"\u4E2D\u6587 (zh)",select_current_language:"\u8BF7\u9009\u62E9\u5F53\u524D\u8BED\u8A00","app-tip":"\u8BF7\u9009\u62E9\u60A8\u5E0C\u671B\u521B\u5EFA\u7684 Serverless-Devs \u5E94\u7528","template-tip":"\u8BF7\u9009\u62E9\u60A8\u559C\u6B22\u7684\u6A21\u7248","fc-runtime-starter":"fc-runtime-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A FC \u51FD\u6570","fc-custom-container-stater":"fc-custom-container-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A custom-container \u5E94\u7528",web:"web-framework-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Web \u6846\u67B6","static-site":"static-website-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","best-practice":"serverless-best-practice - \u5FEB\u901F\u4F53\u9A8C Serverless \u6700\u4F73\u5B9E\u8DF5","devs-template":"Serverless Devs \u5F00\u53D1\u6A21\u677F","fc-http-nodejs":"fc-http-nodejs - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nodejs12 \u51FD\u6570","fc-http-python":"fc-http-python - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A python3 \u51FD\u6570","fc-http-java":"fc-http-java - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A java8 \u51FD\u6570","fc-custom-container-event-python3":"fc-custom-container-event-python3 - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 python3 \u5E94\u7528","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 cpp \u5E94\u7528","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 springboot \u5E94\u7528","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 aspdotnetcore \u5E94\u7528","express-starter":"express-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A express \u57FA\u7840\u5E94\u7528","koa-starter":"koa-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A koa \u57FA\u7840\u5E94\u7528","nuxtjs-starter":"nuxtjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nuxtjs \u57FA\u7840\u5E94\u7528","eggjs-starter":"eggjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A eggjs \u57FA\u7840\u5E94\u7528","flask-starter":"flask-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A flask \u57FA\u7840\u5E94\u7528","SpringBoot-starter":"SpringBoot-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A SpringBoot \u57FA\u7840\u5E94\u7528","Zblog-starter":"Zblog-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Zblog \u57FA\u7840\u5E94\u7528","website-starter":"website-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","react-starter":"react-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A React.js \u5E94\u7528","vue-starter":"vue-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Vue.js \u5E94\u7528",puppeteer:"puppeteer - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E puppeteer \u622A\u56FE\u7684 Web \u5E94\u7528",ffmpeg:"ffmpeg - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E ffmpeg \u5B9E\u73B0\u97F3\u89C6\u9891\u5904\u7406\u5E94\u7528",pdf2Img:"pdf2Img - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A pdf \u8F6C\u56FE\u7247\u5E94\u7528",tensorflow:"tensorflow - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A tensorflow \u5E94\u7528",todoList:"todoList - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E nodejs \u7684\u7F51\u9875 TodoList \u5E94\u7528"}});var Yf=L(jo=>{"use strict";Object.defineProperty(jo,"__esModule",{value:!0});jo.default={clean_up_the_environment:"Clean up the environment",display_help_for_command:"Display help for command",remove_components:"Remove component (like: fc, fc@0.0.1)",delete_the_file_under_the_cache:"Delete the <dirname> file in the cache",record_your_log_information:"Do you record your log information?",init_pproject_deploy_tip:"Do you want to deploy the project immediately?",tip_for_a_serverless_project:"A Serverless-Devs project is detected in the current directory, please deploy via 's deploy' or get more information via 's -h'",create_a_new_project:"No Serverless-Devs project is currently detected. Do you want to create a new project?",en:"English (en)",zh:"Chinese (zh)",select_current_language:"Please select current language","app-tip":"Hello, serverlesser. Which template do you like?","template-tip":"Which template do you like?","fc-runtime-starter":"fc-runtime-starter - Deploy FC function in 5 minutes","fc-custom-container-stater":"fc-custom-container-stater - Deploy FC function with custom-container",web:"web-framework-stater-Quickly deploy a web framework","static-site":"static-website-stater-Quickly deploy a static website","best-practice":"serverless-best-practice-Quickly experience serverless best practices","devs-template":"Serverless Develop scaffold","fc-http-nodejs":"fc-http-nodejs - Deploy FC nodejs12 runtime function","fc-http-python":"fc-http-python - Deploy FC python3 runtime function","fc-http-java":"fc-http-java - Deploy FC java8 runtime function","fc-custom-container-event-python3":"fc-custom-container-event-python3 - Deploy python3 event-triggered application","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - Deploy cpp event-triggered application","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - Deploy springboot HTTP Request-triggered application","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - Deploy dotnetcore HTTP Request-triggered application","express-starter":"express-starter - Deploy express application","koa-starter":"koa-starter - Deploy koa application","nuxtjs-starter":"nuxtjs-starter - Deploy nuxtjs application","eggjs-starter":"eggjs-starter - Deploy eggjs application","flask-starter":"flask-starter - Deploy flask application","SpringBoot-starter":"SpringBoot-starter - Deploy SpringBoot application","Zblog-starter":"Zblog-starter - Deploy Zblog application","website-starter":"website-starter - Deploy static website","react-starter":"react-starter - Deploy React.js application","vue-starter":"vue-starter - Deploy Vue.js application",puppeteer:"puppeteer - Deploy screenshot application base on puppeteer + fc",ffmpeg:"ffmpeg - Deploy audio and video processing application base on ffmpeg + fc",pdf2Img:"pdf2Img - Deploy pdf to images application",tensorflow:"tensorflow - Deploy tensorflow application",todoList:"todoList - Deploy todoList application"}});var Vo=L($r=>{"use strict";var Kf=$r&&$r.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty($r,"__esModule",{value:!0});var QE=Gn(),ew=Kf(Xf()),tw=Kf(Yf()),zo={en:tw.default,zh:ew.default},nw=function(i){var r=(0,QE.getLang)(),s=zo[r]?zo[r][i]:zo.en[i];return s||i};$r.default=nw});var Ji=L(Nr=>{"use strict";var rw=Nr&&Nr.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Nr,"__esModule",{value:!0});var iw=rw(xt()),sw=iw.default.Logger,Xo=new sw("S-CLI");Xo.success=function(i){return Xo.log(i,"green")};Nr.default=Xo});var Qf=L(ye=>{"use strict";var ow=ye&&ye.__createBinding||(Object.create?function(i,r,s,u){u===void 0&&(u=s),Object.defineProperty(i,u,{enumerable:!0,get:function(){return r[s]}})}:function(i,r,s,u){u===void 0&&(u=s),i[u]=r[s]}),Zf=ye&&ye.__exportStar||function(i,r){for(var s in i)s!=="default"&&!Object.prototype.hasOwnProperty.call(r,s)&&ow(r,i,s)},qr=ye&&ye.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(ye,"__esModule",{value:!0});ye.registerCommandChecker=ye.getYamlPath=ye.i18n=ye.logger=void 0;var Jf=qr(require("path")),uw=qr(Ji()),aw=qr(xt()),kf=aw.default.fse;Zf(Gn(),ye);Zf(Ki(),ye);var lw=Ji();Object.defineProperty(ye,"logger",{enumerable:!0,get:function(){return qr(lw).default}});var cw=Vo();Object.defineProperty(ye,"i18n",{enumerable:!0,get:function(){return qr(cw).default}});var fw=function(i,r){var s=Jf.default.join(i,"".concat(r,".yaml")),u=Jf.default.join(i,"".concat(r,".yml")),c=kf.existsSync(s)?s:kf.existsSync(u)?u:void 0;return c};ye.getYamlPath=fw;function hw(i){i.on("command:*",function(r){var s=i.commands.map(function(u){return u.name()});s.includes(r[0])||(uw.default.error(" error: unknown command ".concat(r[0])),i.help())})}ye.registerCommandChecker=hw});var vn=L(Bn=>{"use strict";var pw=Bn&&Bn.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Bn,"__esModule",{value:!0});Bn.ServerlessError=void 0;var gw=pw(xt()),dw=gw.default.Logger,_w=new dw("S-CLI-ERROR"),mw=function(){function i(r,s,u){_w.error(r+": "+s,u),process.exit(1)}return i}();Bn.ServerlessError=mw});var eh=L(Un=>{"use strict";var vw=Un&&Un.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var a in c)Object.prototype.hasOwnProperty.call(c,a)&&(u[a]=c[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function u(){this.constructor=r}r.prototype=s===null?Object.create(s):(u.prototype=s.prototype,new u)}}();Object.defineProperty(Un,"__esModule",{value:!0});Un.CommandError=void 0;var yw=vn(),Ew=function(i){vw(r,i);function r(s,u){return i.call(this,"Error",s,u)||this}return r}(yw.ServerlessError);Un.CommandError=Ew});var th=L(jn=>{"use strict";var ww=jn&&jn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var a in c)Object.prototype.hasOwnProperty.call(c,a)&&(u[a]=c[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function u(){this.constructor=r}r.prototype=s===null?Object.create(s):(u.prototype=s.prototype,new u)}}();Object.defineProperty(jn,"__esModule",{value:!0});jn.ConfigDeleteError=void 0;var xw=vn(),bw=function(i){ww(r,i);function r(s,u){return i.call(this,"Deletion failed",s,u)||this}return r}(xw.ServerlessError);jn.ConfigDeleteError=bw});var nh=L(zn=>{"use strict";var Aw=zn&&zn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var a in c)Object.prototype.hasOwnProperty.call(c,a)&&(u[a]=c[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function u(){this.constructor=r}r.prototype=s===null?Object.create(s):(u.prototype=s.prototype,new u)}}();Object.defineProperty(zn,"__esModule",{value:!0});zn.ConfigError=void 0;var Sw=vn(),Ow=function(i){Aw(r,i);function r(s,u){return i.call(this,"Config failed",s,u)||this}return r}(Sw.ServerlessError);zn.ConfigError=Ow});var rh=L(Vn=>{"use strict";var Cw=Vn&&Vn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var a in c)Object.prototype.hasOwnProperty.call(c,a)&&(u[a]=c[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function u(){this.constructor=r}r.prototype=s===null?Object.create(s):(u.prototype=s.prototype,new u)}}();Object.defineProperty(Vn,"__esModule",{value:!0});Vn.ConfigGetError=void 0;var Rw=vn(),Iw=function(i){Cw(r,i);function r(s,u){return i.call(this,"Get failed",s,u)||this}return r}(Rw.ServerlessError);Vn.ConfigGetError=Iw});var ih=L(Xn=>{"use strict";var Lw=Xn&&Xn.__extends||function(){var i=function(r,s){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var a in c)Object.prototype.hasOwnProperty.call(c,a)&&(u[a]=c[a])},i(r,s)};return function(r,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");i(r,s);function u(){this.constructor=r}r.prototype=s===null?Object.create(s):(u.prototype=s.prototype,new u)}}();Object.defineProperty(Xn,"__esModule",{value:!0});Xn.InitError=void 0;var Tw=vn(),Dw=function(i){Lw(r,i);function r(s,u){return i.call(this,"Initialization failed",s,u)||this}return r}(Tw.ServerlessError);Xn.InitError=Dw});var oh=L(At=>{"use strict";var Pw=At&&At.__awaiter||function(i,r,s,u){function c(a){return a instanceof s?a:new s(function(d){d(a)})}return new(s||(s=Promise))(function(a,d){function y(x){try{p(u.next(x))}catch(C){d(C)}}function E(x){try{p(u.throw(x))}catch(C){d(C)}}function p(x){x.done?a(x.value):c(x.value).then(y,E)}p((u=u.apply(i,r||[])).next())})},$w=At&&At.__generator||function(i,r){var s={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},u,c,a,d;return d={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(d[Symbol.iterator]=function(){return this}),d;function y(p){return function(x){return E([p,x])}}function E(p){if(u)throw new TypeError("Generator is already executing.");for(;s;)try{if(u=1,c&&(a=p[0]&2?c.return:p[0]?c.throw||((a=c.return)&&a.call(c),0):c.next)&&!(a=a.call(c,p[1])).done)return a;switch(c=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return s.label++,{value:p[1],done:!1};case 5:s.label++,c=p[1],p=[0];continue;case 7:p=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){s=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){s.label=p[1];break}if(p[0]===6&&s.label<a[1]){s.label=a[1],a=p;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(p);break}a[2]&&s.ops.pop(),s.trys.pop();continue}p=r.call(i,s)}catch(x){p=[6,x],c=0}finally{u=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Nw=At&&At.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(At,"__esModule",{value:!0});At.HumanError=void 0;var sh=Nw(xt()),qw=Gn(),Fw=sh.default.colors,Mw=function(){function i(r){var s=r.errorMessage,u=r.tips;this.errorMessage=s,console.log(`
37
37
  `.concat((0,qw.bgRed)("ERROR:"))),console.log("TypeError: ".concat(s,`