@serverless-devs/s 2.0.96 → 2.0.97-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/clean/index.js +1 -1
- package/lib/cli/index.js +1 -1
- package/lib/component/index.js +1 -1
- package/lib/config/add/index.js +1 -1
- package/lib/config/delete/index.js +1 -1
- package/lib/config/get/index.js +1 -1
- package/lib/config/index.js +1 -1
- package/lib/index.js +1 -1
- package/lib/init/index.js +1 -1
- package/lib/set/analysis/index.js +1 -1
- package/lib/set/index.js +1 -1
- package/lib/set/locale/index.js +1 -1
- package/lib/set/registry/index.js +1 -1
- package/lib/set/workspace/index.js +1 -1
- package/lib/update-notifier/index.js +1 -1
- package/package.json +2 -2
- package/CODE_OF_CONDUCT.md +0 -5
- package/CONTRIBUTING.md +0 -189
- package/CONTRIBUTORS.md +0 -148
- package/docs/readme.md +0 -100
- package/docs/zh/awesome.md +0 -20
- package/docs/zh/cicd.md +0 -231
- package/docs/zh/cli_design.md +0 -100
- package/docs/zh/command/clean.md +0 -63
- package/docs/zh/command/cli.md +0 -92
- package/docs/zh/command/component.md +0 -75
- package/docs/zh/command/config.md +0 -274
- package/docs/zh/command/custom.md +0 -73
- package/docs/zh/command/init.md +0 -149
- package/docs/zh/command/readme.md +0 -76
- package/docs/zh/command/set.md +0 -195
- package/docs/zh/default_provider_config/alibabacloud.md +0 -82
- package/docs/zh/default_provider_config/aws.md +0 -12
- package/docs/zh/default_provider_config/azure.md +0 -9
- package/docs/zh/default_provider_config/baiducloud.md +0 -8
- package/docs/zh/default_provider_config/gcp.md +0 -21
- package/docs/zh/default_provider_config/huaweicloud.md +0 -52
- package/docs/zh/default_provider_config/readme.md +0 -9
- package/docs/zh/default_provider_config/tencentcloud.md +0 -41
- package/docs/zh/install.md +0 -52
- package/docs/zh/package_dev.md +0 -142
- package/docs/zh/quick_start.md +0 -297
- package/docs/zh/readme.md +0 -92
- package/docs/zh/tool.md +0 -101
- package/docs/zh/yaml.md +0 -207
- package/docs/zh/yaml_and_cli.md +0 -67
- package/jest.setup.ts +0 -37
- package/spec/readme.md +0 -59
- package/spec/zh/0.0.1/readme.md +0 -47
- package/spec/zh/0.0.1/serverless_package_model/1.purpose_and_goals.md +0 -3
- package/spec/zh/0.0.1/serverless_package_model/2.overview_and_terminology.md +0 -14
- package/spec/zh/0.0.1/serverless_package_model/3.package_model.md +0 -434
- package/spec/zh/0.0.1/serverless_package_model/4.application_scopes.md +0 -3
- package/spec/zh/0.0.1/serverless_package_model/5.design_principles.md +0 -3
- package/spec/zh/0.0.1/serverless_package_model/readme.md +0 -12
- package/spec/zh/0.0.1/serverless_registry_model/1.purpose_and_goals.md +0 -18
- package/spec/zh/0.0.1/serverless_registry_model/2.overview_and_terminology.md +0 -18
- package/spec/zh/0.0.1/serverless_registry_model/3.registry_model.md +0 -61
- package/spec/zh/0.0.1/serverless_registry_model/4.application_scopes.md +0 -6
- package/spec/zh/0.0.1/serverless_registry_model/5.design_principles.md +0 -3
- package/spec/zh/0.0.1/serverless_registry_model/readme.md +0 -12
- package/spec/zh/0.0.1/serverless_user_model/1.purpose_and_goals.md +0 -3
- package/spec/zh/0.0.1/serverless_user_model/2.overview_and_terminology.md +0 -16
- package/spec/zh/0.0.1/serverless_user_model/3.user_model.md +0 -218
- package/spec/zh/0.0.1/serverless_user_model/4.application_scopes.md +0 -4
- package/spec/zh/0.0.1/serverless_user_model/5.design_principles.md +0 -3
- package/spec/zh/0.0.1/serverless_user_model/readme.md +0 -12
- package/test/ci.sh +0 -33
- package/test/cli/cli-manager.test.ts +0 -64
- package/test/config/get.test.ts +0 -12
- package/test/helloworld.test.ts +0 -7
- package/test/start-fc-http-nodejs12/code/index.js +0 -47
- package/test/start-fc-http-nodejs12/s.yaml +0 -38
- package/test/utils/index.test.ts +0 -8
- package/test/utils/storage.test.ts +0 -19
- package/tsconfig.json +0 -37
package/lib/component/index.js
CHANGED
|
@@ -42,7 +42,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
42
42
|
`)),console.log((0,rc.bgRed)("ERROR:")+`
|
|
43
43
|
`+t+`
|
|
44
44
|
`),a!=="disable"&&console.log(Nn.gray("Please copy traceId: "+this.traceId+" and join Dingding group: 33947367 for consultation.")),console.log(Nn.gray("You can run 's clean --cache' to prune Serverless devs.")),console.log(Nn.gray(`And run again with the '--debug' option or 's -h' to get more logs.
|
|
45
|
-
`))}return r.prototype.report=function(e){return WI(this,void 0,void 0,function(){return GI(this,function(t){return zI({type:"jsError",content:e.message+"||"+e.stack,traceId:this.traceId}),[2]})})},r}();Ke.HandleError=n8});var Cm=C((wN,i8)=>{i8.exports={name:"@serverless-devs/s",version:"2.0.96",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:{prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"npx jest",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:{"@types/jest":"^27.0.1","@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",commander:"^6.0.0",dotenv:"^10.0.0",esbuild:"^0.13.6",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.1.0","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.0.1","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},jest:{coverageDirectory:"coverage",testEnvironment:"node",coverageProvider:"v8",preset:"ts-jest",testMatch:["**/test/**/*test.[jt]s"],setupFilesAfterEnv:["./jest.setup.ts"]},dependencies:{"@serverless-devs/core":"latest"}}});var Fi=C(be=>{"use strict";var s8=be&&be.__createBinding||(Object.create?function(r,e,t,s){s===void 0&&(s=t),Object.defineProperty(r,s,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,s){s===void 0&&(s=t),r[s]=e[t]}),o8=be&&be.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),u8=be&&be.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&s8(e,r,t);return o8(e,r),e},Am=be&&be.__awaiter||function(r,e,t,s){function o(a){return a instanceof t?a:new t(function(c){c(a)})}return new(t||(t=Promise))(function(a,c){function f(m){try{p(s.next(m))}catch(b){c(b)}}function d(m){try{p(s.throw(m))}catch(b){c(b)}}function p(m){m.done?a(m.value):o(m.value).then(f,d)}p((s=s.apply(r,e||[])).next())})},Om=be&&be.__generator||function(r,e){var t={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},s,o,a,c;return c={next:f(0),throw:f(1),return:f(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function f(p){return function(m){return d([p,m])}}function d(p){if(s)throw new TypeError("Generator is already executing.");for(;t;)try{if(s=1,o&&(a=p[0]&2?o.return:p[0]?o.throw||((a=o.return)&&a.call(o),0):o.next)&&!(a=a.call(o,p[1])).done)return a;switch(o=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return t.label++,{value:p[1],done:!1};case 5:t.label++,o=p[1],p=[0];continue;case 7:p=t.ops.pop(),t.trys.pop();continue;default:if(a=t.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){t=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){t.label=p[1];break}if(p[0]===6&&t.label<a[1]){t.label=a[1],a=p;break}if(a&&t.label<a[2]){t.label=a[2],t.ops.push(p);break}a[2]&&t.ops.pop(),t.trys.pop();continue}p=e.call(r,t)}catch(m){p=[6,m],o=0}finally{s=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},gu=be&&be.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(be,"__esModule",{value:!0});be.emoji=be.mark=be.replaceTemplate=be.getTemplatekey=be.replaceFun=be.getLang=be.printn=be.checkTemplateFile=be.checkAndReturnTemplateFile=be.yamlLoad=be.getFolderSize=be.getVersion=be.bgRed=be.red=void 0;var vt=gu(require("path")),Vt=gu(require("fs")),oc=gu(im()),a8=gu(require("os")),l8=sc(),mu=u8(Fr()),uc=mu.default.colors,c8=mu.default.jsyaml,yu=Cm();be.red=uc.hex("#fd5750");be.bgRed=uc.hex("#000").bgHex("#fd5750");function f8(){return(0,mu.getCoreVersion)()?yu.name+": "+yu.version+", @serverless-devs/core: "+(0,mu.getCoreVersion)()+", "+process.platform+"-"+process.arch+", node-"+process.version:yu.name+": "+yu.version+", "+process.platform+"-"+process.arch+", node-"+process.version}be.getVersion=f8;function h8(r){return Am(this,void 0,void 0,function(){function e(o){return Am(this,void 0,void 0,function(){var a,c;return Om(this,function(f){switch(f.label){case 0:return a=Vt.default.lstatSync(o),typeof a!="object"?[2]:(t.set(a.ino,a.size),a.isDirectory()?(c=Vt.default.readdirSync(o),typeof c!="object"?[2]:[4,Promise.all(c.map(function(d){return e(vt.default.join(o,d))}))]):[3,2]);case 1:f.sent(),f.label=2;case 2:return[2]}})})}var t,s;return Om(this,function(o){switch(o.label){case 0:return t=new Map,[4,e(r)];case 1:return o.sent(),s=Array.from(t.values()).reduce(function(a,c){return a+c},0),[2,s]}})})}be.getFolderSize=h8;function Fm(r){var e=Vt.default.readFileSync(r,"utf8");try{return c8.load(e)}catch{if(["-h","--help"].includes(process.argv[2]))return;var t=vt.default.basename(r);new l8.HumanError({errorMessage:t+" format is incorrect",tips:"Please check the configuration of "+t+", Serverless Devs' Yaml specification document can refer to\uFF1A"+uc.underline("https://github.com/Serverless-Devs/Serverless-Devs/blob/master/docs/zh/yaml.md")}),process.exit(1)}}be.yamlLoad=Fm;function Is(r,e){e===void 0&&(e=!1);var t=Vt.default.readFileSync(r,"utf8"),s=e?JSON.parse(t):Fm(r);if(!s)return!1;for(var o in s)if(s[o].Component&&s[o].Provider&&s[o].Properties)return!0;return s.hasOwnProperty("edition")}function Sm(){if(process.env.serverless_devs_temp_template)return process.env.serverless_devs_temp_template;var r=process.cwd(),e=process.argv.includes("-t")?"-t":process.argv.includes("--template")?"--template":null,t=e?process.argv.indexOf(e):-1;if(t!==-1){var s=t+1,o=process.argv[s];if(o&&(o.endsWith(".yaml")||o.endsWith(".yml")||o.endsWith(".json"))){var a=!!o.endsWith(".json");if(Vt.default.existsSync(vt.default.join(r,o))&&Is(vt.default.join(r,o),a)){process.argv.splice(t,2);var c=JSON.parse(process.env.serverless_devs_temp_argv);return c.splice(c.indexOf(e),2),process.env.serverless_devs_temp_argv=JSON.stringify(c),process.env.serverless_devs_temp_template=vt.default.join(r,o),vt.default.join(r,o)}else if(Vt.default.existsSync(o)&&Is(o,a)){process.argv.splice(t,2);var c=JSON.parse(process.env.serverless_devs_temp_argv);return c.splice(c.indexOf(e),2),process.env.serverless_devs_temp_argv=JSON.stringify(c),process.env.serverless_devs_temp_template=o,o}}}return Vt.default.existsSync(vt.default.join(r,"s.yaml"))&&Is(vt.default.join(r,"s.yaml"))?(process.env.serverless_devs_temp_template=vt.default.join(r,"s.yaml"),vt.default.join(r,"s.yaml")):Vt.default.existsSync(vt.default.join(r,"s.yml"))&&Is(vt.default.join(r,"s.yml"))?(process.env.serverless_devs_temp_template=vt.default.join(r,"s.yml"),vt.default.join(r,"s.yml")):Vt.default.existsSync(vt.default.join(r,"s.json"))&&Is(vt.default.join(r,"s.json"),!0)?(process.env.serverless_devs_temp_template=vt.default.join(r,"s.json"),vt.default.join(r,"s.json")):null}be.checkAndReturnTemplateFile=Sm;function Im(r){return Vt.default.existsSync(r)?r:null}be.checkTemplateFile=Im;function Rm(r,e){e===void 0&&(e=" ");for(var t="",s=0;s<r;s++)t=t+e;return t}be.printn=Rm;function Tm(){return"en"}be.getLang=Tm;function ac(r,e){var t=/\{\{(.*?)\}\}/g,s=r.match(t);if(s)for(var o=0;o<s.length;o++){var a=s[o].replace(/{{|}}/g,""),c=oc.default.trim(a.split("|")[0]);e[c]&&(r=r.replace(s[o],e[c]))}return r}be.replaceFun=ac;function qm(r){var e=/\{\{(.*?)\}\}/g,t=r.match(e);return t?t.filter(function(s){return s}).map(function(s){var o=s.replace(/{{|}}/g,""),a=o.split("|");return{name:oc.default.trim(a[0]),desc:oc.default.trim(a[1])}}):[]}be.getTemplatekey=qm;function Pm(r,e){r.forEach(function(t){if(Vt.default.existsSync(t)){var s=Vt.default.readFileSync(t,"utf-8"),o=ac(s,e);Vt.default.writeFileSync(t,o,"utf-8")}})}be.replaceTemplate=Pm;function $m(r){if(!r)return r;var e=r.slice(-4);return"***********"+e}be.mark=$m;function p8(r){return a8.default.platform()==="win32"?"":r}be.emoji=p8;be.default={checkAndReturnTemplateFile:Sm,checkTemplateFile:Im,printn:Rm,mark:$m,getLang:Tm,replaceTemplate:Pm,replaceFun:ac,getTemplatekey:qm}});var Bm=C(lc=>{"use strict";Object.defineProperty(lc,"__esModule",{value:!0});lc.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 Nm=C(cc=>{"use strict";Object.defineProperty(cc,"__esModule",{value:!0});cc.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 Lm=C(Rs=>{"use strict";var jm=Rs&&Rs.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Rs,"__esModule",{value:!0});var d8=Fi(),g8=jm(Bm()),m8=jm(Nm()),fc={en:m8.default,zh:g8.default},y8=function(r){var e=(0,d8.getLang)(),t=fc[e]?fc[e][r]:fc.en[r];return t||r};Rs.default=y8});var km=C(Ts=>{"use strict";var D8=Ts&&Ts.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ts,"__esModule",{value:!0});var Mm=D8(Fr()),v8=Mm.default.Logger,_8=Mm.default.spinner,jn=new v8("S-CLI"),b8=function(){function r(){}return r.log=function(e){jn.log(e)},r.info=function(e){jn.info(e)},r.debug=function(e){jn.debug(e)},r.error=function(e){jn.error(e)},r.warning=function(e){jn.warn(e)},r.success=function(e){jn.log(e,"green")},r.spinner=function(e){return _8(e)},r.output=function(e){return jn.output(e)},r}();Ts.default=b8});var Gm=C((SN,hc)=>{var Wm=require("stream"),E8=require("util");hc.exports=function(){let r,e;arguments.length===2?(r=arguments[0],e=arguments[1]):arguments.length===1?typeof arguments[0]=="function"?(r={},e=arguments[0]):r=arguments[0]:arguments.length===0&&(r={});let t=new Generator(r);if(e){let s=[];t.on("readable",function(){let o;for(;o=t.read();)s.push(o)}),t.on("error",e),t.on("end",function(){t.options.objectMode?e(null,s):t.options.encoding?e(null,s.join("")):e(null,Buffer.concat(s))})}return t};Generator=function(r={}){r.high_water_mark&&(r.highWaterMark=r.high_water_mark),r.object_mode&&(r.objectMode=r.object_mode),Wm.Readable.call(this,r),this.options={};for(let s in r)this.options[Generator.camelize(s)]=r[s];let e={columns:8,delimiter:",",duration:null,encoding:null,end:null,eof:!1,fixedSize:!1,length:-1,maxWordLength:16,rowDelimiter:`
|
|
45
|
+
`))}return r.prototype.report=function(e){return WI(this,void 0,void 0,function(){return GI(this,function(t){return zI({type:"jsError",content:e.message+"||"+e.stack,traceId:this.traceId}),[2]})})},r}();Ke.HandleError=n8});var Cm=C((wN,i8)=>{i8.exports={name:"@serverless-devs/s",version:"2.0.97-beta.1",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:{prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"npx jest",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:{"@types/jest":"^27.0.1","@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",commander:"^6.0.0",dotenv:"^10.0.0",esbuild:"^0.13.6",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.1.0","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.0.1","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},jest:{coverageDirectory:"coverage",testEnvironment:"node",coverageProvider:"v8",preset:"ts-jest",testMatch:["**/test/**/*test.[jt]s"],setupFilesAfterEnv:["./jest.setup.ts"]},dependencies:{"@serverless-devs/core":"beta"}}});var Fi=C(be=>{"use strict";var s8=be&&be.__createBinding||(Object.create?function(r,e,t,s){s===void 0&&(s=t),Object.defineProperty(r,s,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,s){s===void 0&&(s=t),r[s]=e[t]}),o8=be&&be.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),u8=be&&be.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&s8(e,r,t);return o8(e,r),e},Am=be&&be.__awaiter||function(r,e,t,s){function o(a){return a instanceof t?a:new t(function(c){c(a)})}return new(t||(t=Promise))(function(a,c){function f(m){try{p(s.next(m))}catch(b){c(b)}}function d(m){try{p(s.throw(m))}catch(b){c(b)}}function p(m){m.done?a(m.value):o(m.value).then(f,d)}p((s=s.apply(r,e||[])).next())})},Om=be&&be.__generator||function(r,e){var t={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},s,o,a,c;return c={next:f(0),throw:f(1),return:f(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function f(p){return function(m){return d([p,m])}}function d(p){if(s)throw new TypeError("Generator is already executing.");for(;t;)try{if(s=1,o&&(a=p[0]&2?o.return:p[0]?o.throw||((a=o.return)&&a.call(o),0):o.next)&&!(a=a.call(o,p[1])).done)return a;switch(o=0,a&&(p=[p[0]&2,a.value]),p[0]){case 0:case 1:a=p;break;case 4:return t.label++,{value:p[1],done:!1};case 5:t.label++,o=p[1],p=[0];continue;case 7:p=t.ops.pop(),t.trys.pop();continue;default:if(a=t.trys,!(a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){t=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){t.label=p[1];break}if(p[0]===6&&t.label<a[1]){t.label=a[1],a=p;break}if(a&&t.label<a[2]){t.label=a[2],t.ops.push(p);break}a[2]&&t.ops.pop(),t.trys.pop();continue}p=e.call(r,t)}catch(m){p=[6,m],o=0}finally{s=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},gu=be&&be.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(be,"__esModule",{value:!0});be.emoji=be.mark=be.replaceTemplate=be.getTemplatekey=be.replaceFun=be.getLang=be.printn=be.checkTemplateFile=be.checkAndReturnTemplateFile=be.yamlLoad=be.getFolderSize=be.getVersion=be.bgRed=be.red=void 0;var vt=gu(require("path")),Vt=gu(require("fs")),oc=gu(im()),a8=gu(require("os")),l8=sc(),mu=u8(Fr()),uc=mu.default.colors,c8=mu.default.jsyaml,yu=Cm();be.red=uc.hex("#fd5750");be.bgRed=uc.hex("#000").bgHex("#fd5750");function f8(){return(0,mu.getCoreVersion)()?yu.name+": "+yu.version+", @serverless-devs/core: "+(0,mu.getCoreVersion)()+", "+process.platform+"-"+process.arch+", node-"+process.version:yu.name+": "+yu.version+", "+process.platform+"-"+process.arch+", node-"+process.version}be.getVersion=f8;function h8(r){return Am(this,void 0,void 0,function(){function e(o){return Am(this,void 0,void 0,function(){var a,c;return Om(this,function(f){switch(f.label){case 0:return a=Vt.default.lstatSync(o),typeof a!="object"?[2]:(t.set(a.ino,a.size),a.isDirectory()?(c=Vt.default.readdirSync(o),typeof c!="object"?[2]:[4,Promise.all(c.map(function(d){return e(vt.default.join(o,d))}))]):[3,2]);case 1:f.sent(),f.label=2;case 2:return[2]}})})}var t,s;return Om(this,function(o){switch(o.label){case 0:return t=new Map,[4,e(r)];case 1:return o.sent(),s=Array.from(t.values()).reduce(function(a,c){return a+c},0),[2,s]}})})}be.getFolderSize=h8;function Fm(r){var e=Vt.default.readFileSync(r,"utf8");try{return c8.load(e)}catch{if(["-h","--help"].includes(process.argv[2]))return;var t=vt.default.basename(r);new l8.HumanError({errorMessage:t+" format is incorrect",tips:"Please check the configuration of "+t+", Serverless Devs' Yaml specification document can refer to\uFF1A"+uc.underline("https://github.com/Serverless-Devs/Serverless-Devs/blob/master/docs/zh/yaml.md")}),process.exit(1)}}be.yamlLoad=Fm;function Is(r,e){e===void 0&&(e=!1);var t=Vt.default.readFileSync(r,"utf8"),s=e?JSON.parse(t):Fm(r);if(!s)return!1;for(var o in s)if(s[o].Component&&s[o].Provider&&s[o].Properties)return!0;return s.hasOwnProperty("edition")}function Sm(){if(process.env.serverless_devs_temp_template)return process.env.serverless_devs_temp_template;var r=process.cwd(),e=process.argv.includes("-t")?"-t":process.argv.includes("--template")?"--template":null,t=e?process.argv.indexOf(e):-1;if(t!==-1){var s=t+1,o=process.argv[s];if(o&&(o.endsWith(".yaml")||o.endsWith(".yml")||o.endsWith(".json"))){var a=!!o.endsWith(".json");if(Vt.default.existsSync(vt.default.join(r,o))&&Is(vt.default.join(r,o),a)){process.argv.splice(t,2);var c=JSON.parse(process.env.serverless_devs_temp_argv);return c.splice(c.indexOf(e),2),process.env.serverless_devs_temp_argv=JSON.stringify(c),process.env.serverless_devs_temp_template=vt.default.join(r,o),vt.default.join(r,o)}else if(Vt.default.existsSync(o)&&Is(o,a)){process.argv.splice(t,2);var c=JSON.parse(process.env.serverless_devs_temp_argv);return c.splice(c.indexOf(e),2),process.env.serverless_devs_temp_argv=JSON.stringify(c),process.env.serverless_devs_temp_template=o,o}}}return Vt.default.existsSync(vt.default.join(r,"s.yaml"))&&Is(vt.default.join(r,"s.yaml"))?(process.env.serverless_devs_temp_template=vt.default.join(r,"s.yaml"),vt.default.join(r,"s.yaml")):Vt.default.existsSync(vt.default.join(r,"s.yml"))&&Is(vt.default.join(r,"s.yml"))?(process.env.serverless_devs_temp_template=vt.default.join(r,"s.yml"),vt.default.join(r,"s.yml")):Vt.default.existsSync(vt.default.join(r,"s.json"))&&Is(vt.default.join(r,"s.json"),!0)?(process.env.serverless_devs_temp_template=vt.default.join(r,"s.json"),vt.default.join(r,"s.json")):null}be.checkAndReturnTemplateFile=Sm;function Im(r){return Vt.default.existsSync(r)?r:null}be.checkTemplateFile=Im;function Rm(r,e){e===void 0&&(e=" ");for(var t="",s=0;s<r;s++)t=t+e;return t}be.printn=Rm;function Tm(){return"en"}be.getLang=Tm;function ac(r,e){var t=/\{\{(.*?)\}\}/g,s=r.match(t);if(s)for(var o=0;o<s.length;o++){var a=s[o].replace(/{{|}}/g,""),c=oc.default.trim(a.split("|")[0]);e[c]&&(r=r.replace(s[o],e[c]))}return r}be.replaceFun=ac;function qm(r){var e=/\{\{(.*?)\}\}/g,t=r.match(e);return t?t.filter(function(s){return s}).map(function(s){var o=s.replace(/{{|}}/g,""),a=o.split("|");return{name:oc.default.trim(a[0]),desc:oc.default.trim(a[1])}}):[]}be.getTemplatekey=qm;function Pm(r,e){r.forEach(function(t){if(Vt.default.existsSync(t)){var s=Vt.default.readFileSync(t,"utf-8"),o=ac(s,e);Vt.default.writeFileSync(t,o,"utf-8")}})}be.replaceTemplate=Pm;function $m(r){if(!r)return r;var e=r.slice(-4);return"***********"+e}be.mark=$m;function p8(r){return a8.default.platform()==="win32"?"":r}be.emoji=p8;be.default={checkAndReturnTemplateFile:Sm,checkTemplateFile:Im,printn:Rm,mark:$m,getLang:Tm,replaceTemplate:Pm,replaceFun:ac,getTemplatekey:qm}});var Bm=C(lc=>{"use strict";Object.defineProperty(lc,"__esModule",{value:!0});lc.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 Nm=C(cc=>{"use strict";Object.defineProperty(cc,"__esModule",{value:!0});cc.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 Lm=C(Rs=>{"use strict";var jm=Rs&&Rs.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Rs,"__esModule",{value:!0});var d8=Fi(),g8=jm(Bm()),m8=jm(Nm()),fc={en:m8.default,zh:g8.default},y8=function(r){var e=(0,d8.getLang)(),t=fc[e]?fc[e][r]:fc.en[r];return t||r};Rs.default=y8});var km=C(Ts=>{"use strict";var D8=Ts&&Ts.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ts,"__esModule",{value:!0});var Mm=D8(Fr()),v8=Mm.default.Logger,_8=Mm.default.spinner,jn=new v8("S-CLI"),b8=function(){function r(){}return r.log=function(e){jn.log(e)},r.info=function(e){jn.info(e)},r.debug=function(e){jn.debug(e)},r.error=function(e){jn.error(e)},r.warning=function(e){jn.warn(e)},r.success=function(e){jn.log(e,"green")},r.spinner=function(e){return _8(e)},r.output=function(e){return jn.output(e)},r}();Ts.default=b8});var Gm=C((SN,hc)=>{var Wm=require("stream"),E8=require("util");hc.exports=function(){let r,e;arguments.length===2?(r=arguments[0],e=arguments[1]):arguments.length===1?typeof arguments[0]=="function"?(r={},e=arguments[0]):r=arguments[0]:arguments.length===0&&(r={});let t=new Generator(r);if(e){let s=[];t.on("readable",function(){let o;for(;o=t.read();)s.push(o)}),t.on("error",e),t.on("end",function(){t.options.objectMode?e(null,s):t.options.encoding?e(null,s.join("")):e(null,Buffer.concat(s))})}return t};Generator=function(r={}){r.high_water_mark&&(r.highWaterMark=r.high_water_mark),r.object_mode&&(r.objectMode=r.object_mode),Wm.Readable.call(this,r),this.options={};for(let s in r)this.options[Generator.camelize(s)]=r[s];let e={columns:8,delimiter:",",duration:null,encoding:null,end:null,eof:!1,fixedSize:!1,length:-1,maxWordLength:16,rowDelimiter:`
|
|
46
46
|
`,seed:!1,sleep:0};for(let s in e)this.options[s]===void 0&&(this.options[s]=e[s]);this.options.eof===!0&&(this.options.eof=this.options.rowDelimiter),this._={start_time:this.options.duration?Date.now():null,fixed_size_buffer:"",count_written:0,count_created:0},typeof this.options.columns=="number"&&(this.options.columns=new Array(this.options.columns));let t=Object.keys(Generator).filter(s=>!["super_","camelize"].includes(s));for(let s=0;s<this.options.columns.length;s++){let o=this.options.columns[s]||"ascii";if(typeof o=="string"){if(!t.includes(o))throw Error(`Invalid column type: got "${o}", default values are ${JSON.stringify(t)}`);this.options.columns[s]=Generator[o]}}return this};E8.inherits(Generator,Wm.Readable);hc.exports.Generator=Generator;Generator.prototype.random=function(){return this.options.seed?this.options.seed=this.options.seed*Math.PI*100%100/100:Math.random()};Generator.prototype.end=function(){this.push(null)};Generator.prototype._read=function(r){let e=[],t=this._.fixed_size_buffer.length;for(t!==0&&e.push(this._.fixed_size_buffer);;){if(this._.count_created===this.options.length||this.options.end&&Date.now()>this.options.end||this.options.duration&&Date.now()>this._.start_time+this.options.duration){if(e.length)if(this.options.objectMode)for(let a of e)this.__push(a);else this.__push(e.join("")+(this.options.eof?this.options.eof:""));return this.push(null)}let s=[],o;if(this.options.columns.forEach(a=>{s.push(a(this))}),this.options.objectMode){o=0;for(let a of s)o+=a.length}else s=(this._.count_created===0?"":this.options.rowDelimiter)+s.join(this.options.delimiter),o=s.length;if(this._.count_created++,t+o>r){if(this.options.objectMode){e.push(s);for(let a of e)this.__push(a)}else this.options.fixedSize?(this._.fixed_size_buffer=s.substr(r-t),e.push(s.substr(0,r-t))):e.push(s),this.__push(e.join(""));return}t+=o,e.push(s)}};Generator.prototype.__push=function(r){this._.count_written++,this.options.sleep>0?setTimeout(()=>{this.push(r)},this.options.sleep):this.push(r)};Generator.ascii=function(r){let e=[],t=Math.ceil(r.random()*r.options.maxWordLength);for(let s=0;s<t;s++){let o=Math.floor(r.random()*32);e.push(String.fromCharCode(o+(o<16?65:97-16)))}return e.join("")};Generator.int=function(r){return Math.floor(r.random()*Math.pow(2,52))};Generator.bool=function(r){return Math.floor(r.random()*2)};Generator.camelize=function(r){return r.replace(/_([a-z])/gi,function(e,t,s){return t.toUpperCase()})}});var zm=C((IN,Hm)=>{var Um=class{constructor(e=100){this.size=e,this.length=0,this.buf=Buffer.alloc(e)}prepend(e){if(Buffer.isBuffer(e)){let t=this.length+e.length;if(t>=this.size&&(this.resize(),t>=this.size))throw Error("INVALID_BUFFER_STATE");let s=this.buf;this.buf=Buffer.alloc(this.size),e.copy(this.buf,0),s.copy(this.buf,e.length),this.length+=e.length}else{let t=this.length++;t===this.size&&this.resize();let s=this.clone();this.buf[0]=e,s.copy(this.buf,1,0,t)}}append(e){let t=this.length++;t===this.size&&this.resize(),this.buf[t]=e}clone(){return Buffer.from(this.buf.slice(0,this.length))}resize(){let e=this.length;this.size=this.size*2;let t=Buffer.alloc(this.size);this.buf.copy(t,0,0,e),this.buf=t}toString(e){return e?this.buf.slice(0,this.length).toString(e):Uint8Array.prototype.slice.call(this.buf.slice(0,this.length))}toJSON(){return this.toString("utf8")}reset(){this.length=0}};Hm.exports=Um});var Zm=C((RN,Xm)=>{var{Transform:w8}=require("stream"),Vm=zm(),x8=9,Du=10,C8=12,pc=13,A8=32,vu={utf8:Buffer.from([239,187,191]),utf16le:Buffer.from([255,254])},dc=class extends w8{constructor(e={}){super(sn(qt({readableObjectMode:!0},e),{encoding:null}));this.__originalOptions=e,this.__normalizeOptions(e)}__normalizeOptions(e){let t={};for(let c in e)t[O8(c)]=e[c];if(t.encoding===void 0||t.encoding===!0)t.encoding="utf8";else if(t.encoding===null||t.encoding===!1)t.encoding=null;else if(typeof t.encoding!="string"&&t.encoding!==null)throw new Ue("CSV_INVALID_OPTION_ENCODING",["Invalid option encoding:","encoding must be a string or null to return a buffer,",`got ${JSON.stringify(t.encoding)}`],t);if(t.bom===void 0||t.bom===null||t.bom===!1)t.bom=!1;else if(t.bom!==!0)throw new Ue("CSV_INVALID_OPTION_BOM",["Invalid option bom:","bom must be true,",`got ${JSON.stringify(t.bom)}`],t);let s=null;if(t.cast===void 0||t.cast===null||t.cast===!1||t.cast==="")t.cast=void 0;else if(typeof t.cast=="function")s=t.cast,t.cast=!0;else if(t.cast!==!0)throw new Ue("CSV_INVALID_OPTION_CAST",["Invalid option cast:","cast must be true or a function,",`got ${JSON.stringify(t.cast)}`],t);if(t.cast_date===void 0||t.cast_date===null||t.cast_date===!1||t.cast_date==="")t.cast_date=!1;else if(t.cast_date===!0)t.cast_date=function(c){let f=Date.parse(c);return isNaN(f)?c:new Date(f)};else throw new Ue("CSV_INVALID_OPTION_CAST_DATE",["Invalid option cast_date:","cast_date must be true or a function,",`got ${JSON.stringify(t.cast_date)}`],t);let o=null;if(t.columns===!0)o=void 0;else if(typeof t.columns=="function")o=t.columns,t.columns=!0;else if(Array.isArray(t.columns))t.columns=Ym(t.columns);else if(t.columns===void 0||t.columns===null||t.columns===!1)t.columns=!1;else throw new Ue("CSV_INVALID_OPTION_COLUMNS",["Invalid option columns:","expect an array, a function or true,",`got ${JSON.stringify(t.columns)}`],t);if(t.columns_duplicates_to_array===void 0||t.columns_duplicates_to_array===null||t.columns_duplicates_to_array===!1)t.columns_duplicates_to_array=!1;else{if(t.columns_duplicates_to_array!==!0)throw new Ue("CSV_INVALID_OPTION_COLUMNS_DUPLICATES_TO_ARRAY",["Invalid option columns_duplicates_to_array:","expect an boolean,",`got ${JSON.stringify(t.columns_duplicates_to_array)}`],t);if(t.columns===!1)throw new Ue("CSV_INVALID_OPTION_COLUMNS_DUPLICATES_TO_ARRAY",["Invalid option columns_duplicates_to_array:","the `columns` mode must be activated."],t)}if(t.comment===void 0||t.comment===null||t.comment===!1||t.comment==="")t.comment=null;else if(typeof t.comment=="string"&&(t.comment=Buffer.from(t.comment,t.encoding)),!Buffer.isBuffer(t.comment))throw new Ue("CSV_INVALID_OPTION_COMMENT",["Invalid option comment:","comment must be a buffer or a string,",`got ${JSON.stringify(t.comment)}`],t);let a=JSON.stringify(t.delimiter);if(Array.isArray(t.delimiter)||(t.delimiter=[t.delimiter]),t.delimiter.length===0)throw new Ue("CSV_INVALID_OPTION_DELIMITER",["Invalid option delimiter:","delimiter must be a non empty string or buffer or array of string|buffer,",`got ${a}`],t);if(t.delimiter=t.delimiter.map(function(c){if(c==null||c===!1)return Buffer.from(",",t.encoding);if(typeof c=="string"&&(c=Buffer.from(c,t.encoding)),!Buffer.isBuffer(c)||c.length===0)throw new Ue("CSV_INVALID_OPTION_DELIMITER",["Invalid option delimiter:","delimiter must be a non empty string or buffer or array of string|buffer,",`got ${a}`],t);return c}),t.escape===void 0||t.escape===!0?t.escape=Buffer.from('"',t.encoding):typeof t.escape=="string"?t.escape=Buffer.from(t.escape,t.encoding):(t.escape===null||t.escape===!1)&&(t.escape=null),t.escape!==null&&!Buffer.isBuffer(t.escape))throw new Error(`Invalid Option: escape must be a buffer, a string or a boolean, got ${JSON.stringify(t.escape)}`);if(t.from===void 0||t.from===null)t.from=1;else if(typeof t.from=="string"&&/\d+/.test(t.from)&&(t.from=parseInt(t.from)),Number.isInteger(t.from)){if(t.from<0)throw new Error(`Invalid Option: from must be a positive integer, got ${JSON.stringify(e.from)}`)}else throw new Error(`Invalid Option: from must be an integer, got ${JSON.stringify(t.from)}`);if(t.from_line===void 0||t.from_line===null)t.from_line=1;else if(typeof t.from_line=="string"&&/\d+/.test(t.from_line)&&(t.from_line=parseInt(t.from_line)),Number.isInteger(t.from_line)){if(t.from_line<=0)throw new Error(`Invalid Option: from_line must be a positive integer greater than 0, got ${JSON.stringify(e.from_line)}`)}else throw new Error(`Invalid Option: from_line must be an integer, got ${JSON.stringify(e.from_line)}`);if(t.ignore_last_delimiters===void 0||t.ignore_last_delimiters===null)t.ignore_last_delimiters=!1;else if(typeof t.ignore_last_delimiters=="number")t.ignore_last_delimiters=Math.floor(t.ignore_last_delimiters),t.ignore_last_delimiters===0&&(t.ignore_last_delimiters=!1);else if(typeof t.ignore_last_delimiters!="boolean")throw new Ue("CSV_INVALID_OPTION_IGNORE_LAST_DELIMITERS",["Invalid option `ignore_last_delimiters`:","the value must be a boolean value or an integer,",`got ${JSON.stringify(t.ignore_last_delimiters)}`],t);if(t.ignore_last_delimiters===!0&&t.columns===!1)throw new Ue("CSV_IGNORE_LAST_DELIMITERS_REQUIRES_COLUMNS",["The option `ignore_last_delimiters`","requires the activation of the `columns` option"],t);if(t.info===void 0||t.info===null||t.info===!1)t.info=!1;else if(t.info!==!0)throw new Error(`Invalid Option: info must be true, got ${JSON.stringify(t.info)}`);if(t.max_record_size===void 0||t.max_record_size===null||t.max_record_size===!1)t.max_record_size=0;else if(!(Number.isInteger(t.max_record_size)&&t.max_record_size>=0))if(typeof t.max_record_size=="string"&&/\d+/.test(t.max_record_size))t.max_record_size=parseInt(t.max_record_size);else throw new Error(`Invalid Option: max_record_size must be a positive integer, got ${JSON.stringify(t.max_record_size)}`);if(t.objname===void 0||t.objname===null||t.objname===!1)t.objname=void 0;else if(Buffer.isBuffer(t.objname)){if(t.objname.length===0)throw new Error("Invalid Option: objname must be a non empty buffer");t.encoding===null||(t.objname=t.objname.toString(t.encoding))}else if(typeof t.objname=="string"){if(t.objname.length===0)throw new Error("Invalid Option: objname must be a non empty string")}else throw new Error(`Invalid Option: objname must be a string or a buffer, got ${t.objname}`);if(t.on_record===void 0||t.on_record===null)t.on_record=void 0;else if(typeof t.on_record!="function")throw new Ue("CSV_INVALID_OPTION_ON_RECORD",["Invalid option `on_record`:","expect a function,",`got ${JSON.stringify(t.on_record)}`],t);if(t.quote===null||t.quote===!1||t.quote==="")t.quote=null;else if(t.quote===void 0||t.quote===!0?t.quote=Buffer.from('"',t.encoding):typeof t.quote=="string"&&(t.quote=Buffer.from(t.quote,t.encoding)),!Buffer.isBuffer(t.quote))throw new Error(`Invalid Option: quote must be a buffer or a string, got ${JSON.stringify(t.quote)}`);if(t.raw===void 0||t.raw===null||t.raw===!1)t.raw=!1;else if(t.raw!==!0)throw new Error(`Invalid Option: raw must be true, got ${JSON.stringify(t.raw)}`);if(t.record_delimiter?Array.isArray(t.record_delimiter)||(t.record_delimiter=[t.record_delimiter]):t.record_delimiter=[],t.record_delimiter=t.record_delimiter.map(function(c){return typeof c=="string"&&(c=Buffer.from(c,t.encoding)),c}),typeof t.relax!="boolean")if(t.relax===void 0||t.relax===null)t.relax=!1;else throw new Error(`Invalid Option: relax must be a boolean, got ${JSON.stringify(t.relax)}`);if(typeof t.relax_column_count!="boolean")if(t.relax_column_count===void 0||t.relax_column_count===null)t.relax_column_count=!1;else throw new Error(`Invalid Option: relax_column_count must be a boolean, got ${JSON.stringify(t.relax_column_count)}`);if(typeof t.relax_column_count_less!="boolean")if(t.relax_column_count_less===void 0||t.relax_column_count_less===null)t.relax_column_count_less=!1;else throw new Error(`Invalid Option: relax_column_count_less must be a boolean, got ${JSON.stringify(t.relax_column_count_less)}`);if(typeof t.relax_column_count_more!="boolean")if(t.relax_column_count_more===void 0||t.relax_column_count_more===null)t.relax_column_count_more=!1;else throw new Error(`Invalid Option: relax_column_count_more must be a boolean, got ${JSON.stringify(t.relax_column_count_more)}`);if(typeof t.skip_empty_lines!="boolean")if(t.skip_empty_lines===void 0||t.skip_empty_lines===null)t.skip_empty_lines=!1;else throw new Error(`Invalid Option: skip_empty_lines must be a boolean, got ${JSON.stringify(t.skip_empty_lines)}`);if(typeof t.skip_lines_with_empty_values!="boolean")if(t.skip_lines_with_empty_values===void 0||t.skip_lines_with_empty_values===null)t.skip_lines_with_empty_values=!1;else throw new Error(`Invalid Option: skip_lines_with_empty_values must be a boolean, got ${JSON.stringify(t.skip_lines_with_empty_values)}`);if(typeof t.skip_lines_with_error!="boolean")if(t.skip_lines_with_error===void 0||t.skip_lines_with_error===null)t.skip_lines_with_error=!1;else throw new Error(`Invalid Option: skip_lines_with_error must be a boolean, got ${JSON.stringify(t.skip_lines_with_error)}`);if(t.rtrim===void 0||t.rtrim===null||t.rtrim===!1)t.rtrim=!1;else if(t.rtrim!==!0)throw new Error(`Invalid Option: rtrim must be a boolean, got ${JSON.stringify(t.rtrim)}`);if(t.ltrim===void 0||t.ltrim===null||t.ltrim===!1)t.ltrim=!1;else if(t.ltrim!==!0)throw new Error(`Invalid Option: ltrim must be a boolean, got ${JSON.stringify(t.ltrim)}`);if(t.trim===void 0||t.trim===null||t.trim===!1)t.trim=!1;else if(t.trim!==!0)throw new Error(`Invalid Option: trim must be a boolean, got ${JSON.stringify(t.trim)}`);if(t.trim===!0&&e.ltrim!==!1?t.ltrim=!0:t.ltrim!==!0&&(t.ltrim=!1),t.trim===!0&&e.rtrim!==!1?t.rtrim=!0:t.rtrim!==!0&&(t.rtrim=!1),t.to===void 0||t.to===null)t.to=-1;else if(typeof t.to=="string"&&/\d+/.test(t.to)&&(t.to=parseInt(t.to)),Number.isInteger(t.to)){if(t.to<=0)throw new Error(`Invalid Option: to must be a positive integer greater than 0, got ${JSON.stringify(e.to)}`)}else throw new Error(`Invalid Option: to must be an integer, got ${JSON.stringify(e.to)}`);if(t.to_line===void 0||t.to_line===null)t.to_line=-1;else if(typeof t.to_line=="string"&&/\d+/.test(t.to_line)&&(t.to_line=parseInt(t.to_line)),Number.isInteger(t.to_line)){if(t.to_line<=0)throw new Error(`Invalid Option: to_line must be a positive integer greater than 0, got ${JSON.stringify(e.to_line)}`)}else throw new Error(`Invalid Option: to_line must be an integer, got ${JSON.stringify(e.to_line)}`);this.info={bytes:0,comment_lines:0,empty_lines:0,invalid_field_length:0,lines:1,records:0},this.options=t,this.state={bomSkipped:!1,bufBytesStart:0,castField:s,commenting:!1,error:void 0,enabled:t.from_line===1,escaping:!1,escapeIsQuote:Buffer.isBuffer(t.escape)&&Buffer.isBuffer(t.quote)&&Buffer.compare(t.escape,t.quote)===0,expectedRecordLength:Array.isArray(t.columns)?t.columns.length:void 0,field:new Vm(20),firstLineToHeaders:o,needMoreDataSize:Math.max(t.comment!==null?t.comment.length:0,...t.delimiter.map(c=>c.length),t.quote!==null?t.quote.length:0),previousBuf:void 0,quoting:!1,stop:!1,rawBuffer:new Vm(100),record:[],recordHasError:!1,record_length:0,recordDelimiterMaxLength:t.record_delimiter.length===0?2:Math.max(...t.record_delimiter.map(c=>c.length)),trimChars:[Buffer.from(" ",t.encoding)[0],Buffer.from(" ",t.encoding)[0]],wasQuoting:!1,wasRowDelimiter:!1}}_transform(e,t,s){if(this.state.stop===!0)return;let o=this.__parse(e,!1);o!==void 0&&(this.state.stop=!0),s(o)}_flush(e){if(this.state.stop===!0)return;let t=this.__parse(void 0,!0);e(t)}__parse(e,t){let{bom:s,comment:o,escape:a,from_line:c,ltrim:f,max_record_size:d,quote:p,raw:m,relax:b,rtrim:w,skip_empty_lines:q,to:I,to_line:_}=this.options,{record_delimiter:T}=this.options,{bomSkipped:M,previousBuf:W,rawBuffer:K,escapeIsQuote:Y}=this.state,Q;if(W===void 0)if(e===void 0){this.push(null);return}else Q=e;else W!==void 0&&e===void 0?Q=W:Q=Buffer.concat([W,e]);if(M===!1)if(s===!1)this.state.bomSkipped=!0;else if(Q.length<3){if(t===!1){this.state.previousBuf=Q;return}}else{for(let $ in vu)if(vu[$].compare(Q,0,vu[$].length)===0){let G=vu[$].length;this.state.bufBytesStart+=G,Q=Q.slice(G),this.__normalizeOptions(sn(qt({},this.__originalOptions),{encoding:$}));break}this.state.bomSkipped=!0}let Pe=Q.length,X;for(X=0;X<Pe&&!this.__needMoreData(X,Pe,t);X++){if(this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1),_!==-1&&this.info.lines>_){this.state.stop=!0,this.push(null);return}this.state.quoting===!1&&T.length===0&&this.__autoDiscoverRecordDelimiter(Q,X)&&(T=this.options.record_delimiter);let $=Q[X];if(m===!0&&K.append($),($===pc||$===Du)&&this.state.wasRowDelimiter===!1&&(this.state.wasRowDelimiter=!0),this.state.escaping===!0)this.state.escaping=!1;else{if(a!==null&&this.state.quoting===!0&&this.__isEscape(Q,X,$)&&X+a.length<Pe)if(Y){if(this.__isQuote(Q,X+a.length)){this.state.escaping=!0,X+=a.length-1;continue}}else{this.state.escaping=!0,X+=a.length-1;continue}if(this.state.commenting===!1&&this.__isQuote(Q,X))if(this.state.quoting===!0){let ee=Q[X+p.length],Se=w&&this.__isCharTrimable(ee),Oe=o!==null&&this.__compareBytes(o,Q,X+p.length,ee),Ie=this.__isDelimiter(Q,X+p.length,ee),ze=T.length===0?this.__autoDiscoverRecordDelimiter(Q,X+p.length):this.__isRecordDelimiter(ee,Q,X+p.length);if(a!==null&&this.__isEscape(Q,X,$)&&this.__isQuote(Q,X+a.length))X+=a.length-1;else if(!ee||Ie||ze||Oe||Se){this.state.quoting=!1,this.state.wasQuoting=!0,X+=p.length-1;continue}else if(b===!1){let ye=this.__error(new Ue("CSV_INVALID_CLOSING_QUOTE",["Invalid Closing Quote:",`got "${String.fromCharCode(ee)}"`,`at line ${this.info.lines}`,"instead of delimiter, record delimiter, trimable character","(if activated) or comment"],this.options,this.__infoField()));if(ye!==void 0)return ye}else this.state.quoting=!1,this.state.wasQuoting=!0,this.state.field.prepend(p),X+=p.length-1}else if(this.state.field.length!==0){if(b===!1){let ee=this.__error(new Ue("INVALID_OPENING_QUOTE",["Invalid Opening Quote:",`a quote is found inside a field at line ${this.info.lines}`],this.options,this.__infoField(),{field:this.state.field}));if(ee!==void 0)return ee}}else{this.state.quoting=!0,X+=p.length-1;continue}if(this.state.quoting===!1){let ee=this.__isRecordDelimiter($,Q,X);if(ee!==0){if(this.state.commenting&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0)this.info.comment_lines++;else{if(this.state.enabled===!1&&this.info.lines+(this.state.wasRowDelimiter===!0?1:0)>=c){this.state.enabled=!0,this.__resetField(),this.__resetRecord(),X+=ee-1;continue}if(q===!0&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0){this.info.empty_lines++,X+=ee-1;continue}this.info.bytes=this.state.bufBytesStart+X;let ze=this.__onField();if(ze!==void 0)return ze;this.info.bytes=this.state.bufBytesStart+X+ee;let ye=this.__onRecord();if(ye!==void 0)return ye;if(I!==-1&&this.info.records>=I){this.state.stop=!0,this.push(null);return}}this.state.commenting=!1,X+=ee-1;continue}if(this.state.commenting)continue;if((o===null?0:this.__compareBytes(o,Q,X,$))!==0){this.state.commenting=!0;continue}let Oe=this.__isDelimiter(Q,X,$);if(Oe!==0){this.info.bytes=this.state.bufBytesStart+X;let Ie=this.__onField();if(Ie!==void 0)return Ie;X+=Oe-1;continue}}}if(this.state.commenting===!1&&d!==0&&this.state.record_length+this.state.field.length>d){let ee=this.__error(new Ue("CSV_MAX_RECORD_SIZE",["Max Record Size:","record exceed the maximum number of tolerated bytes",`of ${d}`,`at line ${this.info.lines}`],this.options,this.__infoField()));if(ee!==void 0)return ee}let G=f===!1||this.state.quoting===!0||this.state.field.length!==0||!this.__isCharTrimable($),fe=w===!1||this.state.wasQuoting===!1;if(G===!0&&fe===!0)this.state.field.append($);else if(w===!0&&!this.__isCharTrimable($)){let ee=this.__error(new Ue("CSV_NON_TRIMABLE_CHAR_AFTER_CLOSING_QUOTE",["Invalid Closing Quote:","found non trimable byte after quote",`at line ${this.info.lines}`],this.options,this.__infoField()));if(ee!==void 0)return ee}}if(t===!0)if(this.state.quoting===!0){let $=this.__error(new Ue("CSV_QUOTE_NOT_CLOSED",["Quote Not Closed:",`the parsing is finished with an opening quote at line ${this.info.lines}`],this.options,this.__infoField()));if($!==void 0)return $}else if(this.state.wasQuoting===!0||this.state.record.length!==0||this.state.field.length!==0){this.info.bytes=this.state.bufBytesStart+X;let $=this.__onField();if($!==void 0)return $;let G=this.__onRecord();if(G!==void 0)return G}else this.state.wasRowDelimiter===!0?this.info.empty_lines++:this.state.commenting===!0&&this.info.comment_lines++;else this.state.bufBytesStart+=X,this.state.previousBuf=Q.slice(X);this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1)}__onRecord(){let{columns:e,columns_duplicates_to_array:t,encoding:s,info:o,from:a,relax_column_count:c,relax_column_count_less:f,relax_column_count_more:d,raw:p,skip_lines_with_empty_values:m}=this.options,{enabled:b,record:w}=this.state;if(b===!1)return this.__resetRecord();let q=w.length;if(e===!0){if(m===!0&&Km(w)){this.__resetRecord();return}return this.__firstLineToColumns(w)}if(e===!1&&this.info.records===0&&(this.state.expectedRecordLength=q),q!==this.state.expectedRecordLength){let I=e===!1?new Ue("CSV_INCONSISTENT_RECORD_LENGTH",["Invalid Record Length:",`expect ${this.state.expectedRecordLength},`,`got ${q} on line ${this.info.lines}`],this.options,this.__infoField(),{record:w}):new Ue("CSV_RECORD_DONT_MATCH_COLUMNS_LENGTH",["Invalid Record Length:",`columns length is ${e.length},`,`got ${q} on line ${this.info.lines}`],this.options,this.__infoField(),{record:w});if(c===!0||f===!0&&q<this.state.expectedRecordLength||d===!0&&q>this.state.expectedRecordLength)this.info.invalid_field_length++,this.state.error=I;else{let _=this.__error(I);if(_)return _}}if(m===!0&&Km(w)){this.__resetRecord();return}if(this.state.recordHasError===!0){this.__resetRecord(),this.state.recordHasError=!1;return}if(this.info.records++,a===1||this.info.records>=a)if(e!==!1){let I={};for(let T=0,M=w.length;T<M;T++)e[T]===void 0||e[T].disabled||(t===!0&&I[e[T].name]!==void 0?Array.isArray(I[e[T].name])?I[e[T].name]=I[e[T].name].concat(w[T]):I[e[T].name]=[I[e[T].name],w[T]]:I[e[T].name]=w[T]);let{objname:_}=this.options;if(_===void 0)if(p===!0||o===!0){let T=this.__push(Object.assign({record:I},p===!0?{raw:this.state.rawBuffer.toString(s)}:{},o===!0?{info:this.__infoRecord()}:{}));if(T)return T}else{let T=this.__push(I);if(T)return T}else if(p===!0||o===!0){let T=this.__push(Object.assign({record:[I[_],I]},p===!0?{raw:this.state.rawBuffer.toString(s)}:{},o===!0?{info:this.__infoRecord()}:{}));if(T)return T}else{let T=this.__push([I[_],I]);if(T)return T}}else if(p===!0||o===!0){let I=this.__push(Object.assign({record:w},p===!0?{raw:this.state.rawBuffer.toString(s)}:{},o===!0?{info:this.__infoRecord()}:{}));if(I)return I}else{let I=this.__push(w);if(I)return I}this.__resetRecord()}__firstLineToColumns(e){let{firstLineToHeaders:t}=this.state;try{let s=t===void 0?e:t.call(null,e);if(!Array.isArray(s))return this.__error(new Ue("CSV_INVALID_COLUMN_MAPPING",["Invalid Column Mapping:","expect an array from column function,",`got ${JSON.stringify(s)}`],this.options,this.__infoField(),{headers:s}));let o=Ym(s);this.state.expectedRecordLength=o.length,this.options.columns=o,this.__resetRecord();return}catch(s){return s}}__resetRecord(){this.options.raw===!0&&this.state.rawBuffer.reset(),this.state.error=void 0,this.state.record=[],this.state.record_length=0}__onField(){let{cast:e,encoding:t,rtrim:s,max_record_size:o}=this.options,{enabled:a,wasQuoting:c}=this.state;if(a===!1)return this.__resetField();let f=this.state.field.toString(t);if(s===!0&&c===!1&&(f=f.trimRight()),e===!0){let[d,p]=this.__cast(f);if(d!==void 0)return d;f=p}this.state.record.push(f),o!==0&&typeof f=="string"&&(this.state.record_length+=f.length),this.__resetField()}__resetField(){this.state.field.reset(),this.state.wasQuoting=!1}__push(e){let{on_record:t}=this.options;if(t!==void 0){let s=this.__infoRecord();try{e=t.call(null,e,s)}catch(o){return o}if(e==null)return}this.push(e)}__cast(e){let{columns:t,relax_column_count:s}=this.options;if(Array.isArray(t)===!0&&s&&this.options.columns.length<=this.state.record.length)return[void 0,void 0];if(this.state.castField!==null)try{let a=this.__infoField();return[void 0,this.state.castField.call(null,e,a)]}catch(a){return[a]}if(this.__isFloat(e))return[void 0,parseFloat(e)];if(this.options.cast_date!==!1){let a=this.__infoField();return[void 0,this.options.cast_date.call(null,e,a)]}return[void 0,e]}__isCharTrimable(e){return e===A8||e===x8||e===pc||e===Du||e===C8}__isFloat(e){return e-parseFloat(e)+1>=0}__compareBytes(e,t,s,o){if(e[0]!==o)return 0;let a=e.length;for(let c=1;c<a;c++)if(e[c]!==t[s+c])return 0;return a}__needMoreData(e,t,s){if(s)return!1;let{quote:o}=this.options,{quoting:a,needMoreDataSize:c,recordDelimiterMaxLength:f}=this.state,d=t-e-1,p=Math.max(c,f,a?o.length+f:0);return d<p}__isDelimiter(e,t,s){let{delimiter:o,ignore_last_delimiters:a}=this.options;if(a===!0&&this.state.record.length===this.options.columns.length-1)return 0;if(a!==!1&&typeof a=="number"&&this.state.record.length===a-1)return 0;e:for(let c=0;c<o.length;c++){let f=o[c];if(f[0]===s){for(let d=1;d<f.length;d++)if(f[d]!==e[t+d])continue e;return f.length}}return 0}__isRecordDelimiter(e,t,s){let{record_delimiter:o}=this.options,a=o.length;e:for(let c=0;c<a;c++){let f=o[c],d=f.length;if(f[0]===e){for(let p=1;p<d;p++)if(f[p]!==t[s+p])continue e;return f.length}}return 0}__isEscape(e,t,s){let{escape:o}=this.options;if(o===null)return!1;let a=o.length;if(o[0]===s){for(let c=0;c<a;c++)if(o[c]!==e[t+c])return!1;return!0}return!1}__isQuote(e,t){let{quote:s}=this.options;if(s===null)return!1;let o=s.length;for(let a=0;a<o;a++)if(s[a]!==e[t+a])return!1;return!0}__autoDiscoverRecordDelimiter(e,t){let{encoding:s}=this.options,o=e[t];return o===pc?e[t+1]===Du?(this.options.record_delimiter.push(Buffer.from(`\r
|
|
47
47
|
`,s)),this.state.recordDelimiterMaxLength=2,2):(this.options.record_delimiter.push(Buffer.from("\r",s)),this.state.recordDelimiterMaxLength=1,1):o===Du?(this.options.record_delimiter.push(Buffer.from(`
|
|
48
48
|
`,s)),this.state.recordDelimiterMaxLength=1,1):0}__error(e){let{skip_lines_with_error:t}=this.options,s=typeof e=="string"?new Error(e):e;if(t){this.state.recordHasError=!0,this.emit("skip",s);return}else return s}__infoDataSet(){return sn(qt({},this.info),{columns:this.options.columns})}__infoRecord(){let{columns:e}=this.options;return sn(qt({},this.__infoDataSet()),{error:this.state.error,header:e===!0,index:this.state.record.length})}__infoField(){let{columns:e}=this.options,t=Array.isArray(e);return sn(qt({},this.__infoRecord()),{column:t===!0?e.length>this.state.record.length?e[this.state.record.length].name:null:this.state.record.length,quoting:this.state.wasQuoting})}},gc=function(){let r,e,t;for(let o in arguments){let a=arguments[o],c=typeof a;if(r===void 0&&(typeof a=="string"||Buffer.isBuffer(a)))r=a;else if(e===void 0&&Jm(a))e=a;else if(t===void 0&&c==="function")t=a;else throw new Ue("CSV_INVALID_ARGUMENT",["Invalid argument:",`got ${JSON.stringify(a)} at index ${o}`],e||{})}let s=new dc(e);if(t){let o=e===void 0||e.objname===void 0?[]:{};s.on("readable",function(){let a;for(;(a=this.read())!==null;)e===void 0||e.objname===void 0?o.push(a):o[a[0]]=a[1]}),s.on("error",function(a){t(a,void 0,s.__infoDataSet())}),s.on("end",function(){t(void 0,o,s.__infoDataSet())})}return r!==void 0&&(typeof setImmediate=="function"?setImmediate(function(){s.write(r),s.end()}):(s.write(r),s.end())),s},Ue=class extends Error{constructor(e,t,s,...o){Array.isArray(t)&&(t=t.join(" "));super(t);Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,Ue),this.code=e;for(let a of o)for(let c in a){let f=a[c];this[c]=Buffer.isBuffer(f)?f.toString(s.encoding):f==null?f:JSON.parse(JSON.stringify(f))}}};gc.Parser=dc;gc.CsvError=Ue;Xm.exports=gc;var O8=function(r){return r.replace(/([A-Z])/g,function(e,t){return"_"+t.toLowerCase()})},Jm=function(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)},Km=function(r){return r.every(e=>e==null||e.toString&&e.toString().trim()==="")},Ym=function(r){let e=[];for(let t=0,s=r.length;t<s;t++){let o=r[t];if(o==null||o===!1)e[t]={disabled:!0};else if(typeof o=="string")e[t]={name:o};else if(Jm(o)){if(typeof o.name!="string")throw new Ue("CSV_OPTION_COLUMNS_MISSING_NAME",["Option columns missing name:",`property "name" is required at position ${t}`,"when column is an object literal"]);e[t]=o}else throw new Ue("CSV_INVALID_COLUMN_DEFINITION",["Invalid column definition:","expect a string or a literal object,",`got ${JSON.stringify(o)} at position ${t}`])}return e}});var ey=C(We=>{"use strict";Object.defineProperty(We,"__esModule",{value:!0});function Ii(r){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ii=function(e){return typeof e}:Ii=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ii(r)}var Qm;We.clone=void 0;We.compare=void 0;We.is_object=void 0;We.is_object_literal=void 0;We.merge=void 0;We.mutate=void 0;We.snake_case=void 0;We.merge=function(){return We.mutate.apply(void 0,[{}].concat(Array.prototype.slice.call(arguments)))};We.clone=function(e){return Array.isArray(e)?e.map(function(t){return We.clone(t)}):e&&Ii(e)==="object"?We.mutate({},e):e};We.mutate=function(){var e,t,s,o,a,c,f;for(c=arguments[0],e=t=1,o=arguments.length;1<=o?t<o:t>o;e=1<=o?++t:--t)if(a=arguments[e],We.is_object_literal(a)){We.is_object_literal(c)||(c={});for(s in a)/__proto__|prototype/.test(s)||(c[s]=We.mutate(c[s],a[s]))}else Array.isArray(a)?c=function(){var d,p,m;for(m=[],d=0,p=a.length;d<p;d++)f=a[d],m.push(We.mutate(void 0,f));return m}():a!==void 0&&(c=a);return c};We.snake_case=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,s,o,a,c;if(a={},We.is_object_literal(e)){c=typeof t=="number"&&t>0?t-1:t;for(s in e)o=e[s],t&&(s=Qm(s)),a[s]=We.snake_case(o,c)}else a=e;return a};We.compare=function(e,t){var s,o,a,c,f,d,p,m;if(We.is_object_literal(e)){if(!We.is_object_literal(t)||(f=Object.keys(e).sort(),d=Object.keys(t).sort(),f.length!==d.length))return!1;for(s=o=0,p=f.length;o<p;s=++o)if(c=f[s],c!==d[s]||!We.compare(e[c],t[c]))return!1}else if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(s=a=0,m=e.length;0<=m?a<m:a>m;s=0<=m?++a:--a)if(!We.compare(e[s],t[s]))return!1}else if(e!==t)return!1;return!0};Qm=function(e){return e.replace(/([A-Z])/g,function(t,s,o){return"_"+s.toLowerCase()})};We.is_object=function(e){return e&&Ii(e)==="object"&&!Array.isArray(e)};We.is_object_literal=function(e){var t;if(t=e,Ii(e)!=="object"||e===null)return!1;if(Object.getPrototypeOf(t)===null)return!0;for(;Object.getPrototypeOf(t=Object.getPrototypeOf(t))!==null;);return Object.getPrototypeOf(e)===t}});var ny=C((qN,yc)=>{var Ln,ty,mc,ry;mc=require("stream");ry=require("util");({clone:ty}=ey());yc.exports=function(){var r,e,t,s,o,a,c,f,d,p,m,b;for(f={},o=a=0,c=arguments.length;a<c;o=++a)if(r=arguments[o],b=typeof r,r===null?b="null":b==="object"&&Array.isArray(r)&&(b="array"),b==="array")d=r;else if(b==="object")f=ty(r);else if(b==="function")s&&o===arguments.length-1?e=r:s=r;else if(b!=="null")throw new Error(`Invalid Arguments: got ${JSON.stringify(r)} at position ${o}`);return m=new Ln(f,s),t=!1,d&&setImmediate(function(){var w,q,I;for(w=0,q=d.length;w<q&&(I=d[w],!t);w++)m.write(I);return m.end()}),(e||f.consume)&&(p=[],m.on("readable",function(){var w,q;for(q=[];w=m.read();)e?q.push(p.push(w)):q.push(void 0);return q}),m.on("error",function(w){if(t=!0,e)return e(w)}),m.on("end",function(){if(e&&!t)return e(null,p)})),m};Ln=function(r={},e){var t,s;return this.options=r,this.handler=e,(t=this.options).consume==null&&(t.consume=!1),this.options.objectMode=!0,(s=this.options).parallel==null&&(s.parallel=100),mc.Transform.call(this,this.options),this.state={running:0,started:0,finished:0},this};ry.inherits(Ln,mc.Transform);yc.exports.Transformer=Ln;Ln.prototype._transform=function(r,e,t){var s,o,a;this.state.started++,this.state.running++,this.state.running<this.options.parallel&&(t(),t=null);try{if(a=this.handler.length,this.options.params!=null&&a--,a===1)this.__done(null,[this.handler.call(this,r,this.options.params)],t);else if(a===2)s=(c,...f)=>this.__done(c,f,t),this.handler.call(this,r,s,this.options.params);else throw Error("Invalid handler arguments");return!1}catch(c){return o=c,this.__done(o)}};Ln.prototype._flush=function(r){return this._ending=function(){if(this.state.running===0)return this._ending=void 0,r()},this._ending()};Ln.prototype.__done=function(r,e,t){var s,o,a;if(this.state.running--,r)return this.emit("error",r);for(this.state.finished++,o=0,a=e.length;o<a;o++)s=e[o],typeof s=="number"&&(s=`${s}`),s!=null&&s!==""&&this.push(s);if(t&&t(),this._ending)return this._ending()}});var uy=C((PN,oy)=>{var{Transform:F8}=require("stream"),S8=Buffer.from([239,187,191]),Dc=class extends F8{constructor(e={}){super(qt({writableObjectMode:!0},e));let t={},s;for(let o in e)t[I8(o)]=e[o];if(s=this.normalize(t))throw s;switch(t.record_delimiter){case"auto":t.record_delimiter=null;break;case"unix":t.record_delimiter=`
|
package/lib/config/add/index.js
CHANGED
|
@@ -31,7 +31,7 @@ __p += '`),z&&(I+=`' +
|
|
|
31
31
|
function print() { __p += __j.call(arguments, '') }
|
|
32
32
|
`:`;
|
|
33
33
|
`)+I+`return __p
|
|
34
|
-
}`;var B=il(function(){return Y(h,N+"return "+I).apply(i,d)});if(B.source=I,Ks(B))throw B;return B}function t0(e){return Z(e).toLowerCase()}function n0(e){return Z(e).toUpperCase()}function r0(e,t,n){if(e=Z(e),e&&(n||t===i))return ho(e);if(!e||!(t=De(t)))return e;var u=et(e),l=et(t),h=po(u,l),d=go(u,l)+1;return Ft(u,h,d).join("")}function i0(e,t,n){if(e=Z(e),e&&(n||t===i))return e.slice(0,vo(e)+1);if(!e||!(t=De(t)))return e;var u=et(e),l=go(u,et(t))+1;return Ft(u,0,l).join("")}function s0(e,t,n){if(e=Z(e),e&&(n||t===i))return e.replace(Ki,"");if(!e||!(t=De(t)))return e;var u=et(e),l=po(u,et(t));return Ft(u,l).join("")}function u0(e,t){var n=Qc,u=eh;if(ie(t)){var l="separator"in t?t.separator:l;n="length"in t?U(t.length):n,u="omission"in t?De(t.omission):u}e=Z(e);var h=e.length;if(pn(e)){var d=et(e);h=d.length}if(n>=h)return e;var g=n-dn(u);if(g<1)return u;var m=d?Ft(d,0,g).join(""):e.slice(0,g);if(l===i)return m+u;if(d&&(g+=m.length-g),Xs(l)){if(e.slice(g).search(l)){var S,O=m;for(l.global||(l=os(l.source,Z(Pu.exec(l))+"g")),l.lastIndex=0;S=l.exec(O);)var I=S.index;m=m.slice(0,I===i?g:I)}}else if(e.indexOf(De(l),g)!=g){var C=m.lastIndexOf(l);C>-1&&(m=m.slice(0,C))}return m+u}function o0(e){return e=Z(e),e&&mh.test(e)?e.replace(Lu,qp):e}var a0=En(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),zs=sa("toUpperCase");function rl(e,t,n){return e=Z(e),t=n?i:t,t===i?Lp(e)?Hp(e):Ap(e):e.match(t)||[]}var il=X(function(e,t){try{return Le(e,i,t)}catch(n){return Ks(n)?n:new H(n)}}),l0=mt(function(e,t){return Ge(t,function(n){n=lt(n),_t(e,n,Us(e[n],e))}),e});function f0(e){var t=e==null?0:e.length,n=q();return e=t?re(e,function(u){if(typeof u[1]!="function")throw new We(f);return[n(u[0]),u[1]]}):[],X(function(u){for(var l=-1;++l<t;){var h=e[l];if(Le(h[0],this,u))return Le(h[1],this,u)}})}function c0(e){return qd(Be(e,p))}function Vs(e){return function(){return e}}function h0(e,t){return e==null||e!==e?t:e}var p0=oa(),d0=oa(!0);function Te(e){return e}function Ys(e){return Fo(typeof e=="function"?e:Be(e,p))}function g0(e){return Ho(Be(e,p))}function _0(e,t){return Go(e,Be(t,p))}var v0=X(function(e,t){return function(n){return Zn(n,e,t)}}),m0=X(function(e,t){return function(n){return Zn(e,n,t)}});function Zs(e,t,n){var u=pe(t),l=kr(t,u);n==null&&!(ie(t)&&(l.length||!u.length))&&(n=t,t=e,e=this,l=kr(t,pe(t)));var h=!(ie(n)&&"chain"in n)||!!n.chain,d=Et(e);return Ge(l,function(g){var m=t[g];e[g]=m,d&&(e.prototype[g]=function(){var S=this.__chain__;if(h||S){var O=e(this.__wrapped__),I=O.__actions__=Re(this.__actions__);return I.push({func:m,args:arguments,thisArg:e}),O.__chain__=S,O}return m.apply(e,Tt([this.value()],arguments))})}),e}function y0(){return he._===this&&(he._=Xp),this}function Js(){}function E0(e){return e=U(e),X(function(t){return Wo(t,e)})}var w0=bs(re),A0=bs(oo),x0=bs(es);function sl(e){return qs(e)?ts(lt(e)):Qd(e)}function S0(e){return function(t){return e==null?i:jt(e,t)}}var O0=la(),I0=la(!0);function Qs(){return[]}function eu(){return!1}function R0(){return{}}function C0(){return""}function b0(){return!0}function T0(e,t){if(e=U(e),e<1||e>Ct)return[];var n=ut,u=me(e,ut);t=q(t),e-=ut;for(var l=is(u,t);++n<e;)t(n);return l}function L0(e){return G(e)?re(e,lt):Pe(e)?[e]:Re(Oa(Z(e)))}function $0(e){var t=++Bp;return Z(e)+t}var D0=Qr(function(e,t){return e+t},0),P0=Ts("ceil"),N0=Qr(function(e,t){return e/t},1),q0=Ts("floor");function F0(e){return e&&e.length?jr(e,Te,gs):i}function M0(e,t){return e&&e.length?jr(e,q(t,2),gs):i}function H0(e){return fo(e,Te)}function G0(e,t){return fo(e,q(t,2))}function W0(e){return e&&e.length?jr(e,Te,ys):i}function U0(e,t){return e&&e.length?jr(e,q(t,2),ys):i}var B0=Qr(function(e,t){return e*t},1),K0=Ts("round"),X0=Qr(function(e,t){return e-t},0);function j0(e){return e&&e.length?rs(e,Te):0}function k0(e,t){return e&&e.length?rs(e,q(t,2)):0}return c.after=gv,c.ary=qa,c.assign=nm,c.assignIn=Ya,c.assignInWith=hi,c.assignWith=rm,c.at=im,c.before=Fa,c.bind=Us,c.bindAll=l0,c.bindKey=Ma,c.castArray=Rv,c.chain=Da,c.chunk=qg,c.compact=Fg,c.concat=Mg,c.cond=f0,c.conforms=c0,c.constant=Vs,c.countBy=j_,c.create=sm,c.curry=Ha,c.curryRight=Ga,c.debounce=Wa,c.defaults=um,c.defaultsDeep=om,c.defer=_v,c.delay=vv,c.difference=Hg,c.differenceBy=Gg,c.differenceWith=Wg,c.drop=Ug,c.dropRight=Bg,c.dropRightWhile=Kg,c.dropWhile=Xg,c.fill=jg,c.filter=z_,c.flatMap=Z_,c.flatMapDeep=J_,c.flatMapDepth=Q_,c.flatten=ba,c.flattenDeep=kg,c.flattenDepth=zg,c.flip=mv,c.flow=p0,c.flowRight=d0,c.fromPairs=Vg,c.functions=dm,c.functionsIn=gm,c.groupBy=ev,c.initial=Zg,c.intersection=Jg,c.intersectionBy=Qg,c.intersectionWith=e_,c.invert=vm,c.invertBy=mm,c.invokeMap=nv,c.iteratee=Ys,c.keyBy=rv,c.keys=pe,c.keysIn=be,c.map=ui,c.mapKeys=Em,c.mapValues=wm,c.matches=g0,c.matchesProperty=_0,c.memoize=ai,c.merge=Am,c.mergeWith=Za,c.method=v0,c.methodOf=m0,c.mixin=Zs,c.negate=li,c.nthArg=E0,c.omit=xm,c.omitBy=Sm,c.once=yv,c.orderBy=iv,c.over=w0,c.overArgs=Ev,c.overEvery=A0,c.overSome=x0,c.partial=Bs,c.partialRight=Ua,c.partition=sv,c.pick=Om,c.pickBy=Ja,c.property=sl,c.propertyOf=S0,c.pull=i_,c.pullAll=La,c.pullAllBy=s_,c.pullAllWith=u_,c.pullAt=o_,c.range=O0,c.rangeRight=I0,c.rearg=wv,c.reject=av,c.remove=a_,c.rest=Av,c.reverse=Gs,c.sampleSize=fv,c.set=Rm,c.setWith=Cm,c.shuffle=cv,c.slice=l_,c.sortBy=dv,c.sortedUniq=__,c.sortedUniqBy=v_,c.split=Zm,c.spread=xv,c.tail=m_,c.take=y_,c.takeRight=E_,c.takeRightWhile=w_,c.takeWhile=A_,c.tap=F_,c.throttle=Sv,c.thru=si,c.toArray=ka,c.toPairs=Qa,c.toPairsIn=el,c.toPath=L0,c.toPlainObject=Va,c.transform=bm,c.unary=Ov,c.union=x_,c.unionBy=S_,c.unionWith=O_,c.uniq=I_,c.uniqBy=R_,c.uniqWith=C_,c.unset=Tm,c.unzip=Ws,c.unzipWith=$a,c.update=Lm,c.updateWith=$m,c.values=xn,c.valuesIn=Dm,c.without=b_,c.words=rl,c.wrap=Iv,c.xor=T_,c.xorBy=L_,c.xorWith=$_,c.zip=D_,c.zipObject=P_,c.zipObjectDeep=N_,c.zipWith=q_,c.entries=Qa,c.entriesIn=el,c.extend=Ya,c.extendWith=hi,Zs(c,c),c.add=D0,c.attempt=il,c.camelCase=Fm,c.capitalize=tl,c.ceil=P0,c.clamp=Pm,c.clone=Cv,c.cloneDeep=Tv,c.cloneDeepWith=Lv,c.cloneWith=bv,c.conformsTo=$v,c.deburr=nl,c.defaultTo=h0,c.divide=N0,c.endsWith=Mm,c.eq=nt,c.escape=Hm,c.escapeRegExp=Gm,c.every=k_,c.find=V_,c.findIndex=Ra,c.findKey=am,c.findLast=Y_,c.findLastIndex=Ca,c.findLastKey=lm,c.floor=q0,c.forEach=Pa,c.forEachRight=Na,c.forIn=fm,c.forInRight=cm,c.forOwn=hm,c.forOwnRight=pm,c.get=js,c.gt=Dv,c.gte=Pv,c.has=_m,c.hasIn=ks,c.head=Ta,c.identity=Te,c.includes=tv,c.indexOf=Yg,c.inRange=Nm,c.invoke=ym,c.isArguments=Vt,c.isArray=G,c.isArrayBuffer=Nv,c.isArrayLike=Ce,c.isArrayLikeObject=ue,c.isBoolean=qv,c.isBuffer=Mt,c.isDate=Fv,c.isElement=Mv,c.isEmpty=Hv,c.isEqual=Gv,c.isEqualWith=Wv,c.isError=Ks,c.isFinite=Uv,c.isFunction=Et,c.isInteger=Ba,c.isLength=fi,c.isMap=Ka,c.isMatch=Bv,c.isMatchWith=Kv,c.isNaN=Xv,c.isNative=jv,c.isNil=zv,c.isNull=kv,c.isNumber=Xa,c.isObject=ie,c.isObjectLike=se,c.isPlainObject=rr,c.isRegExp=Xs,c.isSafeInteger=Vv,c.isSet=ja,c.isString=ci,c.isSymbol=Pe,c.isTypedArray=An,c.isUndefined=Yv,c.isWeakMap=Zv,c.isWeakSet=Jv,c.join=t_,c.kebabCase=Wm,c.last=Xe,c.lastIndexOf=n_,c.lowerCase=Um,c.lowerFirst=Bm,c.lt=Qv,c.lte=em,c.max=F0,c.maxBy=M0,c.mean=H0,c.meanBy=G0,c.min=W0,c.minBy=U0,c.stubArray=Qs,c.stubFalse=eu,c.stubObject=R0,c.stubString=C0,c.stubTrue=b0,c.multiply=B0,c.nth=r_,c.noConflict=y0,c.noop=Js,c.now=oi,c.pad=Km,c.padEnd=Xm,c.padStart=jm,c.parseInt=km,c.random=qm,c.reduce=uv,c.reduceRight=ov,c.repeat=zm,c.replace=Vm,c.result=Im,c.round=K0,c.runInContext=v,c.sample=lv,c.size=hv,c.snakeCase=Ym,c.some=pv,c.sortedIndex=f_,c.sortedIndexBy=c_,c.sortedIndexOf=h_,c.sortedLastIndex=p_,c.sortedLastIndexBy=d_,c.sortedLastIndexOf=g_,c.startCase=Jm,c.startsWith=Qm,c.subtract=X0,c.sum=j0,c.sumBy=k0,c.template=e0,c.times=T0,c.toFinite=wt,c.toInteger=U,c.toLength=za,c.toLower=t0,c.toNumber=je,c.toSafeInteger=tm,c.toString=Z,c.toUpper=n0,c.trim=r0,c.trimEnd=i0,c.trimStart=s0,c.truncate=u0,c.unescape=o0,c.uniqueId=$0,c.upperCase=a0,c.upperFirst=zs,c.each=Pa,c.eachRight=Na,c.first=Ta,Zs(c,function(){var e={};return ot(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){k.prototype[e]=function(n){n=n===i?1:ce(U(n),0);var u=this.__filtered__&&!t?new k(this):this.clone();return u.__filtered__?u.__takeCount__=me(n,u.__takeCount__):u.__views__.push({size:me(n,ut),type:e+(u.__dir__<0?"Right":"")}),u},k.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Ge(["filter","map","takeWhile"],function(e,t){var n=t+1,u=n==Cu||n==ih;k.prototype[e]=function(l){var h=this.clone();return h.__iteratees__.push({iteratee:q(l,3),type:n}),h.__filtered__=h.__filtered__||u,h}}),Ge(["head","last"],function(e,t){var n="take"+(t?"Right":"");k.prototype[e]=function(){return this[n](1).value()[0]}}),Ge(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");k.prototype[e]=function(){return this.__filtered__?new k(this):this[n](1)}}),k.prototype.compact=function(){return this.filter(Te)},k.prototype.find=function(e){return this.filter(e).head()},k.prototype.findLast=function(e){return this.reverse().find(e)},k.prototype.invokeMap=X(function(e,t){return typeof e=="function"?new k(this):this.map(function(n){return Zn(n,e,t)})}),k.prototype.reject=function(e){return this.filter(li(q(e)))},k.prototype.slice=function(e,t){e=U(e);var n=this;return n.__filtered__&&(e>0||t<0)?new k(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=U(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},k.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},k.prototype.toArray=function(){return this.take(ut)},ot(k.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 d=this.__wrapped__,g=u?[1]:arguments,m=d instanceof k,S=g[0],O=m||G(d),I=function(j){var z=l.apply(c,Tt([j],g));return u&&C?z[0]:z};O&&n&&typeof S=="function"&&S.length!=1&&(m=O=!1);var C=this.__chain__,N=!!this.__actions__.length,F=h&&!C,B=m&&!N;if(!h&&O){d=B?d:new k(this);var M=e.apply(d,g);return M.__actions__.push({func:si,args:[I],thisArg:i}),new Ue(M,C)}return F&&B?e.apply(this,g):(M=this.thru(I),F?u?M.value()[0]:M.value():M)})}),Ge(["pop","push","shift","sort","splice","unshift"],function(e){var t=Lr[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(G(h)?h:[],l)}return this[n](function(d){return t.apply(G(d)?d:[],l)})}}),ot(k.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[Jr(i,Ye).name]=[{name:"wrapper",func:i}],k.prototype.clone=od,k.prototype.reverse=ad,k.prototype.value=ld,c.prototype.at=M_,c.prototype.chain=H_,c.prototype.commit=G_,c.prototype.next=W_,c.prototype.plant=B_,c.prototype.reverse=K_,c.prototype.toJSON=c.prototype.valueOf=c.prototype.value=X_,c.prototype.first=c.prototype.head,Kn&&(c.prototype[Kn]=U_),c},$t=Gp();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(he._=$t,define(function(){return $t})):Wt?((Wt.exports=$t)._=$t,Yi._=$t):he._=$t}).call(Sn)});var or=$((Aw,_l)=>{var Y0="2.0.0",Z0=256,J0=Number.MAX_SAFE_INTEGER||9007199254740991,Q0=16;_l.exports={SEMVER_SPEC_VERSION:Y0,MAX_LENGTH:Z0,MAX_SAFE_INTEGER:J0,MAX_SAFE_COMPONENT_LENGTH:Q0}});var ar=$((xw,vl)=>{var e1=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...i)=>console.error("SEMVER",...i):()=>{};vl.exports=e1});var Jt=$((Ht,ml)=>{var{MAX_SAFE_COMPONENT_LENGTH:iu}=or(),t1=ar();Ht=ml.exports={};var n1=Ht.re=[],D=Ht.src=[],P=Ht.t={},r1=0,K=(i,r,s)=>{let o=r1++;t1(o,r),P[i]=o,D[o]=r,n1[o]=new RegExp(r,s?"g":void 0)};K("NUMERICIDENTIFIER","0|[1-9]\\d*");K("NUMERICIDENTIFIERLOOSE","[0-9]+");K("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");K("MAINVERSION",`(${D[P.NUMERICIDENTIFIER]})\\.(${D[P.NUMERICIDENTIFIER]})\\.(${D[P.NUMERICIDENTIFIER]})`);K("MAINVERSIONLOOSE",`(${D[P.NUMERICIDENTIFIERLOOSE]})\\.(${D[P.NUMERICIDENTIFIERLOOSE]})\\.(${D[P.NUMERICIDENTIFIERLOOSE]})`);K("PRERELEASEIDENTIFIER",`(?:${D[P.NUMERICIDENTIFIER]}|${D[P.NONNUMERICIDENTIFIER]})`);K("PRERELEASEIDENTIFIERLOOSE",`(?:${D[P.NUMERICIDENTIFIERLOOSE]}|${D[P.NONNUMERICIDENTIFIER]})`);K("PRERELEASE",`(?:-(${D[P.PRERELEASEIDENTIFIER]}(?:\\.${D[P.PRERELEASEIDENTIFIER]})*))`);K("PRERELEASELOOSE",`(?:-?(${D[P.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${D[P.PRERELEASEIDENTIFIERLOOSE]})*))`);K("BUILDIDENTIFIER","[0-9A-Za-z-]+");K("BUILD",`(?:\\+(${D[P.BUILDIDENTIFIER]}(?:\\.${D[P.BUILDIDENTIFIER]})*))`);K("FULLPLAIN",`v?${D[P.MAINVERSION]}${D[P.PRERELEASE]}?${D[P.BUILD]}?`);K("FULL",`^${D[P.FULLPLAIN]}$`);K("LOOSEPLAIN",`[v=\\s]*${D[P.MAINVERSIONLOOSE]}${D[P.PRERELEASELOOSE]}?${D[P.BUILD]}?`);K("LOOSE",`^${D[P.LOOSEPLAIN]}$`);K("GTLT","((?:<|>)?=?)");K("XRANGEIDENTIFIERLOOSE",`${D[P.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);K("XRANGEIDENTIFIER",`${D[P.NUMERICIDENTIFIER]}|x|X|\\*`);K("XRANGEPLAIN",`[v=\\s]*(${D[P.XRANGEIDENTIFIER]})(?:\\.(${D[P.XRANGEIDENTIFIER]})(?:\\.(${D[P.XRANGEIDENTIFIER]})(?:${D[P.PRERELEASE]})?${D[P.BUILD]}?)?)?`);K("XRANGEPLAINLOOSE",`[v=\\s]*(${D[P.XRANGEIDENTIFIERLOOSE]})(?:\\.(${D[P.XRANGEIDENTIFIERLOOSE]})(?:\\.(${D[P.XRANGEIDENTIFIERLOOSE]})(?:${D[P.PRERELEASELOOSE]})?${D[P.BUILD]}?)?)?`);K("XRANGE",`^${D[P.GTLT]}\\s*${D[P.XRANGEPLAIN]}$`);K("XRANGELOOSE",`^${D[P.GTLT]}\\s*${D[P.XRANGEPLAINLOOSE]}$`);K("COERCE",`(^|[^\\d])(\\d{1,${iu}})(?:\\.(\\d{1,${iu}}))?(?:\\.(\\d{1,${iu}}))?(?:$|[^\\d])`);K("COERCERTL",D[P.COERCE],!0);K("LONETILDE","(?:~>?)");K("TILDETRIM",`(\\s*)${D[P.LONETILDE]}\\s+`,!0);Ht.tildeTrimReplace="$1~";K("TILDE",`^${D[P.LONETILDE]}${D[P.XRANGEPLAIN]}$`);K("TILDELOOSE",`^${D[P.LONETILDE]}${D[P.XRANGEPLAINLOOSE]}$`);K("LONECARET","(?:\\^)");K("CARETTRIM",`(\\s*)${D[P.LONECARET]}\\s+`,!0);Ht.caretTrimReplace="$1^";K("CARET",`^${D[P.LONECARET]}${D[P.XRANGEPLAIN]}$`);K("CARETLOOSE",`^${D[P.LONECARET]}${D[P.XRANGEPLAINLOOSE]}$`);K("COMPARATORLOOSE",`^${D[P.GTLT]}\\s*(${D[P.LOOSEPLAIN]})$|^$`);K("COMPARATOR",`^${D[P.GTLT]}\\s*(${D[P.FULLPLAIN]})$|^$`);K("COMPARATORTRIM",`(\\s*)${D[P.GTLT]}\\s*(${D[P.LOOSEPLAIN]}|${D[P.XRANGEPLAIN]})`,!0);Ht.comparatorTrimReplace="$1$2$3";K("HYPHENRANGE",`^\\s*(${D[P.XRANGEPLAIN]})\\s+-\\s+(${D[P.XRANGEPLAIN]})\\s*$`);K("HYPHENRANGELOOSE",`^\\s*(${D[P.XRANGEPLAINLOOSE]})\\s+-\\s+(${D[P.XRANGEPLAINLOOSE]})\\s*$`);K("STAR","(<|>)?=?\\s*\\*");K("GTE0","^\\s*>=\\s*0.0.0\\s*$");K("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$")});var lr=$((Sw,yl)=>{var i1=["includePrerelease","loose","rtl"],s1=i=>i?typeof i!="object"?{loose:!0}:i1.filter(r=>i[r]).reduce((r,s)=>(r[s]=!0,r),{}):{};yl.exports=s1});var di=$((Ow,Al)=>{var El=/^[0-9]+$/,wl=(i,r)=>{let s=El.test(i),o=El.test(r);return s&&o&&(i=+i,r=+r),i===r?0:s&&!o?-1:o&&!s?1:i<r?-1:1},u1=(i,r)=>wl(r,i);Al.exports={compareIdentifiers:wl,rcompareIdentifiers:u1}});var Ee=$((Iw,Il)=>{var gi=ar(),{MAX_LENGTH:xl,MAX_SAFE_INTEGER:_i}=or(),{re:Sl,t:Ol}=Jt(),o1=lr(),{compareIdentifiers:fr}=di(),ke=class{constructor(r,s){if(s=o1(s),r instanceof ke){if(r.loose===!!s.loose&&r.includePrerelease===!!s.includePrerelease)return r;r=r.version}else if(typeof r!="string")throw new TypeError(`Invalid Version: ${r}`);if(r.length>xl)throw new TypeError(`version is longer than ${xl} characters`);gi("SemVer",r,s),this.options=s,this.loose=!!s.loose,this.includePrerelease=!!s.includePrerelease;let o=r.trim().match(s.loose?Sl[Ol.LOOSE]:Sl[Ol.FULL]);if(!o)throw new TypeError(`Invalid Version: ${r}`);if(this.raw=r,this.major=+o[1],this.minor=+o[2],this.patch=+o[3],this.major>_i||this.major<0)throw new TypeError("Invalid major version");if(this.minor>_i||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>_i||this.patch<0)throw new TypeError("Invalid patch version");o[4]?this.prerelease=o[4].split(".").map(f=>{if(/^[0-9]+$/.test(f)){let a=+f;if(a>=0&&a<_i)return a}return f}):this.prerelease=[],this.build=o[5]?o[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(r){if(gi("SemVer.compare",this.version,this.options,r),!(r instanceof ke)){if(typeof r=="string"&&r===this.version)return 0;r=new ke(r,this.options)}return r.version===this.version?0:this.compareMain(r)||this.comparePre(r)}compareMain(r){return r instanceof ke||(r=new ke(r,this.options)),fr(this.major,r.major)||fr(this.minor,r.minor)||fr(this.patch,r.patch)}comparePre(r){if(r instanceof ke||(r=new ke(r,this.options)),this.prerelease.length&&!r.prerelease.length)return-1;if(!this.prerelease.length&&r.prerelease.length)return 1;if(!this.prerelease.length&&!r.prerelease.length)return 0;let s=0;do{let o=this.prerelease[s],f=r.prerelease[s];if(gi("prerelease compare",s,o,f),o===void 0&&f===void 0)return 0;if(f===void 0)return 1;if(o===void 0)return-1;if(o===f)continue;return fr(o,f)}while(++s)}compareBuild(r){r instanceof ke||(r=new ke(r,this.options));let s=0;do{let o=this.build[s],f=r.build[s];if(gi("prerelease compare",s,o,f),o===void 0&&f===void 0)return 0;if(f===void 0)return 1;if(o===void 0)return-1;if(o===f)continue;return fr(o,f)}while(++s)}inc(r,s){switch(r){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",s);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",s);break;case"prepatch":this.prerelease.length=0,this.inc("patch",s),this.inc("pre",s);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",s),this.inc("pre",s);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let o=this.prerelease.length;for(;--o>=0;)typeof this.prerelease[o]=="number"&&(this.prerelease[o]++,o=-2);o===-1&&this.prerelease.push(0)}s&&(this.prerelease[0]===s?isNaN(this.prerelease[1])&&(this.prerelease=[s,0]):this.prerelease=[s,0]);break;default:throw new Error(`invalid increment argument: ${r}`)}return this.format(),this.raw=this.version,this}};Il.exports=ke});var Qt=$((Rw,Tl)=>{var{MAX_LENGTH:a1}=or(),{re:Rl,t:Cl}=Jt(),bl=Ee(),l1=lr(),f1=(i,r)=>{if(r=l1(r),i instanceof bl)return i;if(typeof i!="string"||i.length>a1||!(r.loose?Rl[Cl.LOOSE]:Rl[Cl.FULL]).test(i))return null;try{return new bl(i,r)}catch{return null}};Tl.exports=f1});var $l=$((Cw,Ll)=>{var c1=Qt(),h1=(i,r)=>{let s=c1(i,r);return s?s.version:null};Ll.exports=h1});var Pl=$((bw,Dl)=>{var p1=Qt(),d1=(i,r)=>{let s=p1(i.trim().replace(/^[=v]+/,""),r);return s?s.version:null};Dl.exports=d1});var ql=$((Tw,Nl)=>{var g1=Ee(),_1=(i,r,s,o)=>{typeof s=="string"&&(o=s,s=void 0);try{return new g1(i,s).inc(r,o).version}catch{return null}};Nl.exports=_1});var ze=$((Lw,Ml)=>{var Fl=Ee(),v1=(i,r,s)=>new Fl(i,s).compare(new Fl(r,s));Ml.exports=v1});var vi=$(($w,Hl)=>{var m1=ze(),y1=(i,r,s)=>m1(i,r,s)===0;Hl.exports=y1});var Ul=$((Dw,Wl)=>{var Gl=Qt(),E1=vi(),w1=(i,r)=>{if(E1(i,r))return null;{let s=Gl(i),o=Gl(r),f=s.prerelease.length||o.prerelease.length,a=f?"pre":"",_=f?"prerelease":"";for(let y in s)if((y==="major"||y==="minor"||y==="patch")&&s[y]!==o[y])return a+y;return _}};Wl.exports=w1});var Kl=$((Pw,Bl)=>{var A1=Ee(),x1=(i,r)=>new A1(i,r).major;Bl.exports=x1});var jl=$((Nw,Xl)=>{var S1=Ee(),O1=(i,r)=>new S1(i,r).minor;Xl.exports=O1});var zl=$((qw,kl)=>{var I1=Ee(),R1=(i,r)=>new I1(i,r).patch;kl.exports=R1});var Yl=$((Fw,Vl)=>{var C1=Qt(),b1=(i,r)=>{let s=C1(i,r);return s&&s.prerelease.length?s.prerelease:null};Vl.exports=b1});var Jl=$((Mw,Zl)=>{var T1=ze(),L1=(i,r,s)=>T1(r,i,s);Zl.exports=L1});var ef=$((Hw,Ql)=>{var $1=ze(),D1=(i,r)=>$1(i,r,!0);Ql.exports=D1});var mi=$((Gw,nf)=>{var tf=Ee(),P1=(i,r,s)=>{let o=new tf(i,s),f=new tf(r,s);return o.compare(f)||o.compareBuild(f)};nf.exports=P1});var sf=$((Ww,rf)=>{var N1=mi(),q1=(i,r)=>i.sort((s,o)=>N1(s,o,r));rf.exports=q1});var of=$((Uw,uf)=>{var F1=mi(),M1=(i,r)=>i.sort((s,o)=>F1(o,s,r));uf.exports=M1});var cr=$((Bw,af)=>{var H1=ze(),G1=(i,r,s)=>H1(i,r,s)>0;af.exports=G1});var yi=$((Kw,lf)=>{var W1=ze(),U1=(i,r,s)=>W1(i,r,s)<0;lf.exports=U1});var su=$((Xw,ff)=>{var B1=ze(),K1=(i,r,s)=>B1(i,r,s)!==0;ff.exports=K1});var Ei=$((jw,cf)=>{var X1=ze(),j1=(i,r,s)=>X1(i,r,s)>=0;cf.exports=j1});var wi=$((kw,hf)=>{var k1=ze(),z1=(i,r,s)=>k1(i,r,s)<=0;hf.exports=z1});var uu=$((zw,pf)=>{var V1=vi(),Y1=su(),Z1=cr(),J1=Ei(),Q1=yi(),ey=wi(),ty=(i,r,s,o)=>{switch(r){case"===":return typeof i=="object"&&(i=i.version),typeof s=="object"&&(s=s.version),i===s;case"!==":return typeof i=="object"&&(i=i.version),typeof s=="object"&&(s=s.version),i!==s;case"":case"=":case"==":return V1(i,s,o);case"!=":return Y1(i,s,o);case">":return Z1(i,s,o);case">=":return J1(i,s,o);case"<":return Q1(i,s,o);case"<=":return ey(i,s,o);default:throw new TypeError(`Invalid operator: ${r}`)}};pf.exports=ty});var gf=$((Vw,df)=>{var ny=Ee(),ry=Qt(),{re:Ai,t:xi}=Jt(),iy=(i,r)=>{if(i instanceof ny)return i;if(typeof i=="number"&&(i=String(i)),typeof i!="string")return null;r=r||{};let s=null;if(!r.rtl)s=i.match(Ai[xi.COERCE]);else{let o;for(;(o=Ai[xi.COERCERTL].exec(i))&&(!s||s.index+s[0].length!==i.length);)(!s||o.index+o[0].length!==s.index+s[0].length)&&(s=o),Ai[xi.COERCERTL].lastIndex=o.index+o[1].length+o[2].length;Ai[xi.COERCERTL].lastIndex=-1}return s===null?null:ry(`${s[2]}.${s[3]||"0"}.${s[4]||"0"}`,r)};df.exports=iy});var vf=$((Yw,_f)=>{"use strict";_f.exports=function(i){i.prototype[Symbol.iterator]=function*(){for(let r=this.head;r;r=r.next)yield r.value}}});var yf=$((Zw,mf)=>{"use strict";mf.exports=V;V.Node=en;V.create=V;function V(i){var r=this;if(r instanceof V||(r=new V),r.tail=null,r.head=null,r.length=0,i&&typeof i.forEach=="function")i.forEach(function(f){r.push(f)});else if(arguments.length>0)for(var s=0,o=arguments.length;s<o;s++)r.push(arguments[s]);return r}V.prototype.removeNode=function(i){if(i.list!==this)throw new Error("removing node which does not belong to this list");var r=i.next,s=i.prev;return r&&(r.prev=s),s&&(s.next=r),i===this.head&&(this.head=r),i===this.tail&&(this.tail=s),i.list.length--,i.next=null,i.prev=null,i.list=null,r};V.prototype.unshiftNode=function(i){if(i!==this.head){i.list&&i.list.removeNode(i);var r=this.head;i.list=this,i.next=r,r&&(r.prev=i),this.head=i,this.tail||(this.tail=i),this.length++}};V.prototype.pushNode=function(i){if(i!==this.tail){i.list&&i.list.removeNode(i);var r=this.tail;i.list=this,i.prev=r,r&&(r.next=i),this.tail=i,this.head||(this.head=i),this.length++}};V.prototype.push=function(){for(var i=0,r=arguments.length;i<r;i++)uy(this,arguments[i]);return this.length};V.prototype.unshift=function(){for(var i=0,r=arguments.length;i<r;i++)oy(this,arguments[i]);return this.length};V.prototype.pop=function(){if(!!this.tail){var i=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,i}};V.prototype.shift=function(){if(!!this.head){var i=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,i}};V.prototype.forEach=function(i,r){r=r||this;for(var s=this.head,o=0;s!==null;o++)i.call(r,s.value,o,this),s=s.next};V.prototype.forEachReverse=function(i,r){r=r||this;for(var s=this.tail,o=this.length-1;s!==null;o--)i.call(r,s.value,o,this),s=s.prev};V.prototype.get=function(i){for(var r=0,s=this.head;s!==null&&r<i;r++)s=s.next;if(r===i&&s!==null)return s.value};V.prototype.getReverse=function(i){for(var r=0,s=this.tail;s!==null&&r<i;r++)s=s.prev;if(r===i&&s!==null)return s.value};V.prototype.map=function(i,r){r=r||this;for(var s=new V,o=this.head;o!==null;)s.push(i.call(r,o.value,this)),o=o.next;return s};V.prototype.mapReverse=function(i,r){r=r||this;for(var s=new V,o=this.tail;o!==null;)s.push(i.call(r,o.value,this)),o=o.prev;return s};V.prototype.reduce=function(i,r){var s,o=this.head;if(arguments.length>1)s=r;else if(this.head)o=this.head.next,s=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=0;o!==null;f++)s=i(s,o.value,f),o=o.next;return s};V.prototype.reduceReverse=function(i,r){var s,o=this.tail;if(arguments.length>1)s=r;else if(this.tail)o=this.tail.prev,s=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=this.length-1;o!==null;f--)s=i(s,o.value,f),o=o.prev;return s};V.prototype.toArray=function(){for(var i=new Array(this.length),r=0,s=this.head;s!==null;r++)i[r]=s.value,s=s.next;return i};V.prototype.toArrayReverse=function(){for(var i=new Array(this.length),r=0,s=this.tail;s!==null;r++)i[r]=s.value,s=s.prev;return i};V.prototype.slice=function(i,r){r=r||this.length,r<0&&(r+=this.length),i=i||0,i<0&&(i+=this.length);var s=new V;if(r<i||r<0)return s;i<0&&(i=0),r>this.length&&(r=this.length);for(var o=0,f=this.head;f!==null&&o<i;o++)f=f.next;for(;f!==null&&o<r;o++,f=f.next)s.push(f.value);return s};V.prototype.sliceReverse=function(i,r){r=r||this.length,r<0&&(r+=this.length),i=i||0,i<0&&(i+=this.length);var s=new V;if(r<i||r<0)return s;i<0&&(i=0),r>this.length&&(r=this.length);for(var o=this.length,f=this.tail;f!==null&&o>r;o--)f=f.prev;for(;f!==null&&o>i;o--,f=f.prev)s.push(f.value);return s};V.prototype.splice=function(i,r,...s){i>this.length&&(i=this.length-1),i<0&&(i=this.length+i);for(var o=0,f=this.head;f!==null&&o<i;o++)f=f.next;for(var a=[],o=0;f&&o<r;o++)a.push(f.value),f=this.removeNode(f);f===null&&(f=this.tail),f!==this.head&&f!==this.tail&&(f=f.prev);for(var o=0;o<s.length;o++)f=sy(this,f,s[o]);return a};V.prototype.reverse=function(){for(var i=this.head,r=this.tail,s=i;s!==null;s=s.prev){var o=s.prev;s.prev=s.next,s.next=o}return this.head=r,this.tail=i,this};function sy(i,r,s){var o=r===i.head?new en(s,null,r,i):new en(s,r,r.next,i);return o.next===null&&(i.tail=o),o.prev===null&&(i.head=o),i.length++,o}function uy(i,r){i.tail=new en(r,i.tail,null,i),i.head||(i.head=i.tail),i.length++}function oy(i,r){i.head=new en(r,null,i.head,i),i.tail||(i.tail=i.head),i.length++}function en(i,r,s,o){if(!(this instanceof en))return new en(i,r,s,o);this.list=o,this.value=i,r?(r.next=this,this.prev=r):this.prev=null,s?(s.prev=this,this.next=s):this.next=null}try{vf()(V)}catch{}});var If=$((Jw,Of)=>{"use strict";var ay=yf(),tn=Symbol("max"),xt=Symbol("length"),On=Symbol("lengthCalculator"),hr=Symbol("allowStale"),nn=Symbol("maxAge"),St=Symbol("dispose"),Ef=Symbol("noDisposeOnSet"),de=Symbol("lruList"),it=Symbol("cache"),wf=Symbol("updateAgeOnGet"),ou=()=>1,Af=class{constructor(r){if(typeof r=="number"&&(r={max:r}),r||(r={}),r.max&&(typeof r.max!="number"||r.max<0))throw new TypeError("max must be a non-negative number");let s=this[tn]=r.max||1/0,o=r.length||ou;if(this[On]=typeof o!="function"?ou:o,this[hr]=r.stale||!1,r.maxAge&&typeof r.maxAge!="number")throw new TypeError("maxAge must be a number");this[nn]=r.maxAge||0,this[St]=r.dispose,this[Ef]=r.noDisposeOnSet||!1,this[wf]=r.updateAgeOnGet||!1,this.reset()}set max(r){if(typeof r!="number"||r<0)throw new TypeError("max must be a non-negative number");this[tn]=r||1/0,pr(this)}get max(){return this[tn]}set allowStale(r){this[hr]=!!r}get allowStale(){return this[hr]}set maxAge(r){if(typeof r!="number")throw new TypeError("maxAge must be a non-negative number");this[nn]=r,pr(this)}get maxAge(){return this[nn]}set lengthCalculator(r){typeof r!="function"&&(r=ou),r!==this[On]&&(this[On]=r,this[xt]=0,this[de].forEach(s=>{s.length=this[On](s.value,s.key),this[xt]+=s.length})),pr(this)}get lengthCalculator(){return this[On]}get length(){return this[xt]}get itemCount(){return this[de].length}rforEach(r,s){s=s||this;for(let o=this[de].tail;o!==null;){let f=o.prev;Sf(this,r,o,s),o=f}}forEach(r,s){s=s||this;for(let o=this[de].head;o!==null;){let f=o.next;Sf(this,r,o,s),o=f}}keys(){return this[de].toArray().map(r=>r.key)}values(){return this[de].toArray().map(r=>r.value)}reset(){this[St]&&this[de]&&this[de].length&&this[de].forEach(r=>this[St](r.key,r.value)),this[it]=new Map,this[de]=new ay,this[xt]=0}dump(){return this[de].map(r=>Si(this,r)?!1:{k:r.key,v:r.value,e:r.now+(r.maxAge||0)}).toArray().filter(r=>r)}dumpLru(){return this[de]}set(r,s,o){if(o=o||this[nn],o&&typeof o!="number")throw new TypeError("maxAge must be a number");let f=o?Date.now():0,a=this[On](s,r);if(this[it].has(r)){if(a>this[tn])return In(this,this[it].get(r)),!1;let E=this[it].get(r).value;return this[St]&&(this[Ef]||this[St](r,E.value)),E.now=f,E.maxAge=o,E.value=s,this[xt]+=a-E.length,E.length=a,this.get(r),pr(this),!0}let _=new xf(r,s,a,f,o);return _.length>this[tn]?(this[St]&&this[St](r,s),!1):(this[xt]+=_.length,this[de].unshift(_),this[it].set(r,this[de].head),pr(this),!0)}has(r){if(!this[it].has(r))return!1;let s=this[it].get(r).value;return!Si(this,s)}get(r){return au(this,r,!0)}peek(r){return au(this,r,!1)}pop(){let r=this[de].tail;return r?(In(this,r),r.value):null}del(r){In(this,this[it].get(r))}load(r){this.reset();let s=Date.now();for(let o=r.length-1;o>=0;o--){let f=r[o],a=f.e||0;if(a===0)this.set(f.k,f.v);else{let _=a-s;_>0&&this.set(f.k,f.v,_)}}}prune(){this[it].forEach((r,s)=>au(this,s,!1))}},au=(i,r,s)=>{let o=i[it].get(r);if(o){let f=o.value;if(Si(i,f)){if(In(i,o),!i[hr])return}else s&&(i[wf]&&(o.value.now=Date.now()),i[de].unshiftNode(o));return f.value}},Si=(i,r)=>{if(!r||!r.maxAge&&!i[nn])return!1;let s=Date.now()-r.now;return r.maxAge?s>r.maxAge:i[nn]&&s>i[nn]},pr=i=>{if(i[xt]>i[tn])for(let r=i[de].tail;i[xt]>i[tn]&&r!==null;){let s=r.prev;In(i,r),r=s}},In=(i,r)=>{if(r){let s=r.value;i[St]&&i[St](s.key,s.value),i[xt]-=s.length,i[it].delete(s.key),i[de].removeNode(r)}},xf=class{constructor(r,s,o,f,a){this.key=r,this.value=s,this.length=o,this.now=f,this.maxAge=a||0}},Sf=(i,r,s,o)=>{let f=s.value;Si(i,f)&&(In(i,s),i[hr]||(f=void 0)),f&&r.call(o,f.value,f.key,i)};Of.exports=Af});var Ve=$((Qw,Tf)=>{var Rn=class{constructor(r,s){if(s=fy(s),r instanceof Rn)return r.loose===!!s.loose&&r.includePrerelease===!!s.includePrerelease?r:new Rn(r.raw,s);if(r instanceof lu)return this.raw=r.value,this.set=[[r]],this.format(),this;if(this.options=s,this.loose=!!s.loose,this.includePrerelease=!!s.includePrerelease,this.raw=r,this.set=r.split(/\s*\|\|\s*/).map(o=>this.parseRange(o.trim())).filter(o=>o.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${r}`);if(this.set.length>1){let o=this.set[0];if(this.set=this.set.filter(f=>!Cf(f[0])),this.set.length===0)this.set=[o];else if(this.set.length>1){for(let f of this.set)if(f.length===1&&gy(f[0])){this.set=[f];break}}}this.format()}format(){return this.range=this.set.map(r=>r.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(r){r=r.trim();let o=`parseRange:${Object.keys(this.options).join(",")}:${r}`,f=Rf.get(o);if(f)return f;let a=this.options.loose,_=a?we[ve.HYPHENRANGELOOSE]:we[ve.HYPHENRANGE];r=r.replace(_,Oy(this.options.includePrerelease)),ae("hyphen replace",r),r=r.replace(we[ve.COMPARATORTRIM],hy),ae("comparator trim",r,we[ve.COMPARATORTRIM]),r=r.replace(we[ve.TILDETRIM],py),r=r.replace(we[ve.CARETTRIM],dy),r=r.split(/\s+/).join(" ");let y=a?we[ve.COMPARATORLOOSE]:we[ve.COMPARATOR],E=r.split(" ").map(L=>_y(L,this.options)).join(" ").split(/\s+/).map(L=>Sy(L,this.options)).filter(this.options.loose?L=>!!L.match(y):()=>!0).map(L=>new lu(L,this.options)),p=E.length,A=new Map;for(let L of E){if(Cf(L))return[L];A.set(L.value,L)}A.size>1&&A.has("")&&A.delete("");let R=[...A.values()];return Rf.set(o,R),R}intersects(r,s){if(!(r instanceof Rn))throw new TypeError("a Range is required");return this.set.some(o=>bf(o,s)&&r.set.some(f=>bf(f,s)&&o.every(a=>f.every(_=>a.intersects(_,s)))))}test(r){if(!r)return!1;if(typeof r=="string")try{r=new cy(r,this.options)}catch{return!1}for(let s=0;s<this.set.length;s++)if(Iy(this.set[s],r,this.options))return!0;return!1}};Tf.exports=Rn;var ly=If(),Rf=new ly({max:1e3}),fy=lr(),lu=dr(),ae=ar(),cy=Ee(),{re:we,t:ve,comparatorTrimReplace:hy,tildeTrimReplace:py,caretTrimReplace:dy}=Jt(),Cf=i=>i.value==="<0.0.0-0",gy=i=>i.value==="",bf=(i,r)=>{let s=!0,o=i.slice(),f=o.pop();for(;s&&o.length;)s=o.every(a=>f.intersects(a,r)),f=o.pop();return s},_y=(i,r)=>(ae("comp",i,r),i=yy(i,r),ae("caret",i),i=vy(i,r),ae("tildes",i),i=wy(i,r),ae("xrange",i),i=xy(i,r),ae("stars",i),i),Oe=i=>!i||i.toLowerCase()==="x"||i==="*",vy=(i,r)=>i.trim().split(/\s+/).map(s=>my(s,r)).join(" "),my=(i,r)=>{let s=r.loose?we[ve.TILDELOOSE]:we[ve.TILDE];return i.replace(s,(o,f,a,_,y)=>{ae("tilde",i,o,f,a,_,y);let E;return Oe(f)?E="":Oe(a)?E=`>=${f}.0.0 <${+f+1}.0.0-0`:Oe(_)?E=`>=${f}.${a}.0 <${f}.${+a+1}.0-0`:y?(ae("replaceTilde pr",y),E=`>=${f}.${a}.${_}-${y} <${f}.${+a+1}.0-0`):E=`>=${f}.${a}.${_} <${f}.${+a+1}.0-0`,ae("tilde return",E),E})},yy=(i,r)=>i.trim().split(/\s+/).map(s=>Ey(s,r)).join(" "),Ey=(i,r)=>{ae("caret",i,r);let s=r.loose?we[ve.CARETLOOSE]:we[ve.CARET],o=r.includePrerelease?"-0":"";return i.replace(s,(f,a,_,y,E)=>{ae("caret",i,f,a,_,y,E);let p;return Oe(a)?p="":Oe(_)?p=`>=${a}.0.0${o} <${+a+1}.0.0-0`:Oe(y)?a==="0"?p=`>=${a}.${_}.0${o} <${a}.${+_+1}.0-0`:p=`>=${a}.${_}.0${o} <${+a+1}.0.0-0`:E?(ae("replaceCaret pr",E),a==="0"?_==="0"?p=`>=${a}.${_}.${y}-${E} <${a}.${_}.${+y+1}-0`:p=`>=${a}.${_}.${y}-${E} <${a}.${+_+1}.0-0`:p=`>=${a}.${_}.${y}-${E} <${+a+1}.0.0-0`):(ae("no pr"),a==="0"?_==="0"?p=`>=${a}.${_}.${y}${o} <${a}.${_}.${+y+1}-0`:p=`>=${a}.${_}.${y}${o} <${a}.${+_+1}.0-0`:p=`>=${a}.${_}.${y} <${+a+1}.0.0-0`),ae("caret return",p),p})},wy=(i,r)=>(ae("replaceXRanges",i,r),i.split(/\s+/).map(s=>Ay(s,r)).join(" ")),Ay=(i,r)=>{i=i.trim();let s=r.loose?we[ve.XRANGELOOSE]:we[ve.XRANGE];return i.replace(s,(o,f,a,_,y,E)=>{ae("xRange",i,o,f,a,_,y,E);let p=Oe(a),A=p||Oe(_),R=A||Oe(y),L=R;return f==="="&&L&&(f=""),E=r.includePrerelease?"-0":"",p?f===">"||f==="<"?o="<0.0.0-0":o="*":f&&L?(A&&(_=0),y=0,f===">"?(f=">=",A?(a=+a+1,_=0,y=0):(_=+_+1,y=0)):f==="<="&&(f="<",A?a=+a+1:_=+_+1),f==="<"&&(E="-0"),o=`${f+a}.${_}.${y}${E}`):A?o=`>=${a}.0.0${E} <${+a+1}.0.0-0`:R&&(o=`>=${a}.${_}.0${E} <${a}.${+_+1}.0-0`),ae("xRange return",o),o})},xy=(i,r)=>(ae("replaceStars",i,r),i.trim().replace(we[ve.STAR],"")),Sy=(i,r)=>(ae("replaceGTE0",i,r),i.trim().replace(we[r.includePrerelease?ve.GTE0PRE:ve.GTE0],"")),Oy=i=>(r,s,o,f,a,_,y,E,p,A,R,L,b)=>(Oe(o)?s="":Oe(f)?s=`>=${o}.0.0${i?"-0":""}`:Oe(a)?s=`>=${o}.${f}.0${i?"-0":""}`:_?s=`>=${s}`:s=`>=${s}${i?"-0":""}`,Oe(p)?E="":Oe(A)?E=`<${+p+1}.0.0-0`:Oe(R)?E=`<${p}.${+A+1}.0-0`:L?E=`<=${p}.${A}.${R}-${L}`:i?E=`<${p}.${A}.${+R+1}-0`:E=`<=${E}`,`${s} ${E}`.trim()),Iy=(i,r,s)=>{for(let o=0;o<i.length;o++)if(!i[o].test(r))return!1;if(r.prerelease.length&&!s.includePrerelease){for(let o=0;o<i.length;o++)if(ae(i[o].semver),i[o].semver!==lu.ANY&&i[o].semver.prerelease.length>0){let f=i[o].semver;if(f.major===r.major&&f.minor===r.minor&&f.patch===r.patch)return!0}return!1}return!0}});var dr=$((eA,Nf)=>{var gr=Symbol("SemVer ANY"),_r=class{static get ANY(){return gr}constructor(r,s){if(s=Ry(s),r instanceof _r){if(r.loose===!!s.loose)return r;r=r.value}cu("comparator",r,s),this.options=s,this.loose=!!s.loose,this.parse(r),this.semver===gr?this.value="":this.value=this.operator+this.semver.version,cu("comp",this)}parse(r){let s=this.options.loose?Lf[$f.COMPARATORLOOSE]:Lf[$f.COMPARATOR],o=r.match(s);if(!o)throw new TypeError(`Invalid comparator: ${r}`);this.operator=o[1]!==void 0?o[1]:"",this.operator==="="&&(this.operator=""),o[2]?this.semver=new Df(o[2],this.options.loose):this.semver=gr}toString(){return this.value}test(r){if(cu("Comparator.test",r,this.options.loose),this.semver===gr||r===gr)return!0;if(typeof r=="string")try{r=new Df(r,this.options)}catch{return!1}return fu(r,this.operator,this.semver,this.options)}intersects(r,s){if(!(r instanceof _r))throw new TypeError("a Comparator is required");if((!s||typeof s!="object")&&(s={loose:!!s,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Pf(r.value,s).test(this.value);if(r.operator==="")return r.value===""?!0:new Pf(this.value,s).test(r.semver);let o=(this.operator===">="||this.operator===">")&&(r.operator===">="||r.operator===">"),f=(this.operator==="<="||this.operator==="<")&&(r.operator==="<="||r.operator==="<"),a=this.semver.version===r.semver.version,_=(this.operator===">="||this.operator==="<=")&&(r.operator===">="||r.operator==="<="),y=fu(this.semver,"<",r.semver,s)&&(this.operator===">="||this.operator===">")&&(r.operator==="<="||r.operator==="<"),E=fu(this.semver,">",r.semver,s)&&(this.operator==="<="||this.operator==="<")&&(r.operator===">="||r.operator===">");return o||f||a&&_||y||E}};Nf.exports=_r;var Ry=lr(),{re:Lf,t:$f}=Jt(),fu=uu(),cu=ar(),Df=Ee(),Pf=Ve()});var vr=$((tA,qf)=>{var Cy=Ve(),by=(i,r,s)=>{try{r=new Cy(r,s)}catch{return!1}return r.test(i)};qf.exports=by});var Mf=$((nA,Ff)=>{var Ty=Ve(),Ly=(i,r)=>new Ty(i,r).set.map(s=>s.map(o=>o.value).join(" ").trim().split(" "));Ff.exports=Ly});var Gf=$((rA,Hf)=>{var $y=Ee(),Dy=Ve(),Py=(i,r,s)=>{let o=null,f=null,a=null;try{a=new Dy(r,s)}catch{return null}return i.forEach(_=>{a.test(_)&&(!o||f.compare(_)===-1)&&(o=_,f=new $y(o,s))}),o};Hf.exports=Py});var Uf=$((iA,Wf)=>{var Ny=Ee(),qy=Ve(),Fy=(i,r,s)=>{let o=null,f=null,a=null;try{a=new qy(r,s)}catch{return null}return i.forEach(_=>{a.test(_)&&(!o||f.compare(_)===1)&&(o=_,f=new Ny(o,s))}),o};Wf.exports=Fy});var Xf=$((sA,Kf)=>{var hu=Ee(),My=Ve(),Bf=cr(),Hy=(i,r)=>{i=new My(i,r);let s=new hu("0.0.0");if(i.test(s)||(s=new hu("0.0.0-0"),i.test(s)))return s;s=null;for(let o=0;o<i.set.length;++o){let f=i.set[o],a=null;f.forEach(_=>{let y=new hu(_.semver.version);switch(_.operator){case">":y.prerelease.length===0?y.patch++:y.prerelease.push(0),y.raw=y.format();case"":case">=":(!a||Bf(y,a))&&(a=y);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${_.operator}`)}}),a&&(!s||Bf(s,a))&&(s=a)}return s&&i.test(s)?s:null};Kf.exports=Hy});var kf=$((uA,jf)=>{var Gy=Ve(),Wy=(i,r)=>{try{return new Gy(i,r).range||"*"}catch{return null}};jf.exports=Wy});var Oi=$((oA,Zf)=>{var Uy=Ee(),zf=dr(),{ANY:By}=zf,Ky=Ve(),Xy=vr(),Vf=cr(),Yf=yi(),jy=wi(),ky=Ei(),zy=(i,r,s,o)=>{i=new Uy(i,o),r=new Ky(r,o);let f,a,_,y,E;switch(s){case">":f=Vf,a=jy,_=Yf,y=">",E=">=";break;case"<":f=Yf,a=ky,_=Vf,y="<",E="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Xy(i,r,o))return!1;for(let p=0;p<r.set.length;++p){let A=r.set[p],R=null,L=null;if(A.forEach(b=>{b.semver===By&&(b=new zf(">=0.0.0")),R=R||b,L=L||b,f(b.semver,R.semver,o)?R=b:_(b.semver,L.semver,o)&&(L=b)}),R.operator===y||R.operator===E||(!L.operator||L.operator===y)&&a(i,L.semver))return!1;if(L.operator===E&&_(i,L.semver))return!1}return!0};Zf.exports=zy});var Qf=$((aA,Jf)=>{var Vy=Oi(),Yy=(i,r,s)=>Vy(i,r,">",s);Jf.exports=Yy});var tc=$((lA,ec)=>{var Zy=Oi(),Jy=(i,r,s)=>Zy(i,r,"<",s);ec.exports=Jy});var ic=$((fA,rc)=>{var nc=Ve(),Qy=(i,r,s)=>(i=new nc(i,s),r=new nc(r,s),i.intersects(r));rc.exports=Qy});var uc=$((cA,sc)=>{var eE=vr(),tE=ze();sc.exports=(i,r,s)=>{let o=[],f=null,a=null,_=i.sort((A,R)=>tE(A,R,s));for(let A of _)eE(A,r,s)?(a=A,f||(f=A)):(a&&o.push([f,a]),a=null,f=null);f&&o.push([f,null]);let y=[];for(let[A,R]of o)A===R?y.push(A):!R&&A===_[0]?y.push("*"):R?A===_[0]?y.push(`<=${R}`):y.push(`${A} - ${R}`):y.push(`>=${A}`);let E=y.join(" || "),p=typeof r.raw=="string"?r.raw:String(r);return E.length<p.length?E:r}});var cc=$((hA,fc)=>{var oc=Ve(),Ii=dr(),{ANY:pu}=Ii,mr=vr(),du=ze(),nE=(i,r,s={})=>{if(i===r)return!0;i=new oc(i,s),r=new oc(r,s);let o=!1;e:for(let f of i.set){for(let a of r.set){let _=rE(f,a,s);if(o=o||_!==null,_)continue e}if(o)return!1}return!0},rE=(i,r,s)=>{if(i===r)return!0;if(i.length===1&&i[0].semver===pu){if(r.length===1&&r[0].semver===pu)return!0;s.includePrerelease?i=[new Ii(">=0.0.0-0")]:i=[new Ii(">=0.0.0")]}if(r.length===1&&r[0].semver===pu){if(s.includePrerelease)return!0;r=[new Ii(">=0.0.0")]}let o=new Set,f,a;for(let b of i)b.operator===">"||b.operator===">="?f=ac(f,b,s):b.operator==="<"||b.operator==="<="?a=lc(a,b,s):o.add(b.semver);if(o.size>1)return null;let _;if(f&&a){if(_=du(f.semver,a.semver,s),_>0)return null;if(_===0&&(f.operator!==">="||a.operator!=="<="))return null}for(let b of o){if(f&&!mr(b,String(f),s)||a&&!mr(b,String(a),s))return null;for(let le of r)if(!mr(b,String(le),s))return!1;return!0}let y,E,p,A,R=a&&!s.includePrerelease&&a.semver.prerelease.length?a.semver:!1,L=f&&!s.includePrerelease&&f.semver.prerelease.length?f.semver:!1;R&&R.prerelease.length===1&&a.operator==="<"&&R.prerelease[0]===0&&(R=!1);for(let b of r){if(A=A||b.operator===">"||b.operator===">=",p=p||b.operator==="<"||b.operator==="<=",f){if(L&&b.semver.prerelease&&b.semver.prerelease.length&&b.semver.major===L.major&&b.semver.minor===L.minor&&b.semver.patch===L.patch&&(L=!1),b.operator===">"||b.operator===">="){if(y=ac(f,b,s),y===b&&y!==f)return!1}else if(f.operator===">="&&!mr(f.semver,String(b),s))return!1}if(a){if(R&&b.semver.prerelease&&b.semver.prerelease.length&&b.semver.major===R.major&&b.semver.minor===R.minor&&b.semver.patch===R.patch&&(R=!1),b.operator==="<"||b.operator==="<="){if(E=lc(a,b,s),E===b&&E!==a)return!1}else if(a.operator==="<="&&!mr(a.semver,String(b),s))return!1}if(!b.operator&&(a||f)&&_!==0)return!1}return!(f&&p&&!a&&_!==0||a&&A&&!f&&_!==0||L||R)},ac=(i,r,s)=>{if(!i)return r;let o=du(i.semver,r.semver,s);return o>0?i:o<0||r.operator===">"&&i.operator===">="?r:i},lc=(i,r,s)=>{if(!i)return r;let o=du(i.semver,r.semver,s);return o<0?i:o>0||r.operator==="<"&&i.operator==="<="?r:i};fc.exports=nE});var pc=$((pA,hc)=>{var gu=Jt();hc.exports={re:gu.re,src:gu.src,tokens:gu.t,SEMVER_SPEC_VERSION:or().SEMVER_SPEC_VERSION,SemVer:Ee(),compareIdentifiers:di().compareIdentifiers,rcompareIdentifiers:di().rcompareIdentifiers,parse:Qt(),valid:$l(),clean:Pl(),inc:ql(),diff:Ul(),major:Kl(),minor:jl(),patch:zl(),prerelease:Yl(),compare:ze(),rcompare:Jl(),compareLoose:ef(),compareBuild:mi(),sort:sf(),rsort:of(),gt:cr(),lt:yi(),eq:vi(),neq:su(),gte:Ei(),lte:wi(),cmp:uu(),coerce:gf(),Comparator:dr(),Range:Ve(),satisfies:vr(),toComparators:Mf(),maxSatisfying:Gf(),minSatisfying:Uf(),minVersion:Xf(),validRange:kf(),outside:Oi(),gtr:Qf(),ltr:tc(),intersects:ic(),simplifyRange:uc(),subset:cc()}});var Ot=$(rn=>{"use strict";var dc=rn&&rn.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(rn,"__esModule",{value:!0});rn.getCoreVersion=void 0;var gc=dc(require("path")),_c=dc(require("fs")),iE=pc(),sE=require("@serverless-devs/core"),_u=gc.default.join(sE.getRootHome(),"cache","core"),vc=gc.default.join(_u,"package.json");function uE(){if(_c.default.existsSync(vc)){var i=require("@serverless-devs/core/package.json").version,r=mc();return iE.gt(r,i)?require(_u):require("@serverless-devs/core")}return require("@serverless-devs/core")}function mc(){return _c.default.existsSync(_u)?require(vc).version:void 0}rn.getCoreVersion=mc;rn.default=uE()});var yc=$((gA,oE)=>{oE.exports={name:"@serverless-devs/s",version:"2.0.96",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:{prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"npx jest",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:{"@types/jest":"^27.0.1","@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",commander:"^6.0.0",dotenv:"^10.0.0",esbuild:"^0.13.6",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.1.0","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.0.1","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},jest:{coverageDirectory:"coverage",testEnvironment:"node",coverageProvider:"v8",preset:"ts-jest",testMatch:["**/test/**/*test.[jt]s"],setupFilesAfterEnv:["./jest.setup.ts"]},dependencies:{"@serverless-devs/core":"latest"}}});var Ti=$(W=>{"use strict";var aE=W&&W.__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]}),lE=W&&W.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),fE=W&&W.__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)&&aE(r,i,s);return lE(r,i),r},Ec=W&&W.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(_){_(a)})}return new(s||(s=Promise))(function(a,_){function y(A){try{p(o.next(A))}catch(R){_(R)}}function E(A){try{p(o.throw(A))}catch(R){_(R)}}function p(A){A.done?a(A.value):f(A.value).then(y,E)}p((o=o.apply(i,r||[])).next())})},wc=W&&W.__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,_;return _={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(_[Symbol.iterator]=function(){return this}),_;function y(p){return function(A){return E([p,A])}}function E(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(A){p=[6,A],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Ri=W&&W.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(W,"__esModule",{value:!0});W.emoji=W.mark=W.replaceTemplate=W.getTemplatekey=W.replaceFun=W.getLang=W.printn=W.checkTemplateFile=W.checkAndReturnTemplateFile=W.yamlLoad=W.getFolderSize=W.getVersion=W.bgRed=W.red=void 0;var ge=Ri(require("path")),Fe=Ri(require("fs")),vu=Ri(gl()),cE=Ri(require("os")),hE=Eu(),Ci=fE(Ot()),mu=Ci.default.colors,pE=Ci.default.jsyaml,bi=yc();W.red=mu.hex("#fd5750");W.bgRed=mu.hex("#000").bgHex("#fd5750");function dE(){return(0,Ci.getCoreVersion)()?bi.name+": "+bi.version+", @serverless-devs/core: "+(0,Ci.getCoreVersion)()+", "+process.platform+"-"+process.arch+", node-"+process.version:bi.name+": "+bi.version+", "+process.platform+"-"+process.arch+", node-"+process.version}W.getVersion=dE;function gE(i){return Ec(this,void 0,void 0,function(){function r(f){return Ec(this,void 0,void 0,function(){var a,_;return wc(this,function(y){switch(y.label){case 0:return a=Fe.default.lstatSync(f),typeof a!="object"?[2]:(s.set(a.ino,a.size),a.isDirectory()?(_=Fe.default.readdirSync(f),typeof _!="object"?[2]:[4,Promise.all(_.map(function(E){return r(ge.default.join(f,E))}))]):[3,2]);case 1:y.sent(),y.label=2;case 2:return[2]}})})}var s,o;return wc(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,_){return a+_},0),[2,o]}})})}W.getFolderSize=gE;function Ac(i){var r=Fe.default.readFileSync(i,"utf8");try{return pE.load(r)}catch{if(["-h","--help"].includes(process.argv[2]))return;var s=ge.default.basename(i);new hE.HumanError({errorMessage:s+" format is incorrect",tips:"Please check the configuration of "+s+", Serverless Devs' Yaml specification document can refer to\uFF1A"+mu.underline("https://github.com/Serverless-Devs/Serverless-Devs/blob/master/docs/zh/yaml.md")}),process.exit(1)}}W.yamlLoad=Ac;function yr(i,r){r===void 0&&(r=!1);var s=Fe.default.readFileSync(i,"utf8"),o=r?JSON.parse(s):Ac(i);if(!o)return!1;for(var f in o)if(o[f].Component&&o[f].Provider&&o[f].Properties)return!0;return o.hasOwnProperty("edition")}function xc(){if(process.env.serverless_devs_temp_template)return process.env.serverless_devs_temp_template;var i=process.cwd(),r=process.argv.includes("-t")?"-t":process.argv.includes("--template")?"--template":null,s=r?process.argv.indexOf(r):-1;if(s!==-1){var o=s+1,f=process.argv[o];if(f&&(f.endsWith(".yaml")||f.endsWith(".yml")||f.endsWith(".json"))){var a=!!f.endsWith(".json");if(Fe.default.existsSync(ge.default.join(i,f))&&yr(ge.default.join(i,f),a)){process.argv.splice(s,2);var _=JSON.parse(process.env.serverless_devs_temp_argv);return _.splice(_.indexOf(r),2),process.env.serverless_devs_temp_argv=JSON.stringify(_),process.env.serverless_devs_temp_template=ge.default.join(i,f),ge.default.join(i,f)}else if(Fe.default.existsSync(f)&&yr(f,a)){process.argv.splice(s,2);var _=JSON.parse(process.env.serverless_devs_temp_argv);return _.splice(_.indexOf(r),2),process.env.serverless_devs_temp_argv=JSON.stringify(_),process.env.serverless_devs_temp_template=f,f}}}return Fe.default.existsSync(ge.default.join(i,"s.yaml"))&&yr(ge.default.join(i,"s.yaml"))?(process.env.serverless_devs_temp_template=ge.default.join(i,"s.yaml"),ge.default.join(i,"s.yaml")):Fe.default.existsSync(ge.default.join(i,"s.yml"))&&yr(ge.default.join(i,"s.yml"))?(process.env.serverless_devs_temp_template=ge.default.join(i,"s.yml"),ge.default.join(i,"s.yml")):Fe.default.existsSync(ge.default.join(i,"s.json"))&&yr(ge.default.join(i,"s.json"),!0)?(process.env.serverless_devs_temp_template=ge.default.join(i,"s.json"),ge.default.join(i,"s.json")):null}W.checkAndReturnTemplateFile=xc;function Sc(i){return Fe.default.existsSync(i)?i:null}W.checkTemplateFile=Sc;function Oc(i,r){r===void 0&&(r=" ");for(var s="",o=0;o<i;o++)s=s+r;return s}W.printn=Oc;function Ic(){return"en"}W.getLang=Ic;function yu(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,""),_=vu.default.trim(a.split("|")[0]);r[_]&&(i=i.replace(o[f],r[_]))}return i}W.replaceFun=yu;function Rc(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:vu.default.trim(a[0]),desc:vu.default.trim(a[1])}}):[]}W.getTemplatekey=Rc;function Cc(i,r){i.forEach(function(s){if(Fe.default.existsSync(s)){var o=Fe.default.readFileSync(s,"utf-8"),f=yu(o,r);Fe.default.writeFileSync(s,f,"utf-8")}})}W.replaceTemplate=Cc;function bc(i){if(!i)return i;var r=i.slice(-4);return"***********"+r}W.mark=bc;function _E(i){return cE.default.platform()==="win32"?"":i}W.emoji=_E;W.default={checkAndReturnTemplateFile:xc,checkTemplateFile:Sc,printn:Oc,mark:bc,getLang:Ic,replaceTemplate:Cc,replaceFun:yu,getTemplatekey:Rc}});var Dc=$(It=>{"use strict";var Tc=It&&It.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(It,"__esModule",{value:!0});It.getHistoryFile=It.getHomeDir=void 0;var vE=Tc(require("path")),Lc=Tc(Ot()),Li=Lc.default.fse,mE=Lc.default.getRootHome;function wu(){var i=mE();return Li.existsSync(i)||Li.mkdirSync(i),i}It.getHomeDir=wu;function $c(){var i=vE.default.join(wu(),"history");return Li.existsSync(i)||Li.createFileSync(i),i}It.getHistoryFile=$c;It.default={getHomeDir:wu,getHistoryFile:$c}});var Wc=$(Ie=>{"use strict";var yE=Ie&&Ie.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(_){_(a)})}return new(s||(s=Promise))(function(a,_){function y(A){try{p(o.next(A))}catch(R){_(R)}}function E(A){try{p(o.throw(A))}catch(R){_(R)}}function p(A){A.done?a(A.value):f(A.value).then(y,E)}p((o=o.apply(i,r||[])).next())})},EE=Ie&&Ie.__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,_;return _={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(_[Symbol.iterator]=function(){return this}),_;function y(p){return function(A){return E([p,A])}}function E(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(A){p=[6,A],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Au=Ie&&Ie.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Ie,"__esModule",{value:!0});Ie.handlerProfileFile=Ie.getConfig=Ie.setConfig=void 0;var Pc=Au(require("path")),wE=Au(Dc()),xu=Au(Ot()),ft=xu.default.fse,$i=xu.default.jsyaml,Nc=xu.default.getRootHome;function AE(i){var r=Fc();ft.writeFileSync(r,$i.dump(i))}function qc(){var i=Fc();if(!ft.existsSync(i))return{};try{var r=$i.load(ft.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function Fc(){var i=Pc.default.join(wE.default.getHomeDir(),"set-config.yml");return ft.existsSync(i)||ft.createFileSync(i),i}function Mc(i,r){var s=qc();s[i]=r,AE(s)}Ie.setConfig=Mc;function Hc(i,r){var s=qc();return s[i]||r}Ie.getConfig=Hc;function Gc(i){return yE(this,void 0,void 0,function(){var r,s,o,f,a,_,y;return EE(this,function(E){switch(E.label){case 0:if(r=i.filePath||"set-config.yml",s=Pc.default.join(Nc(),r),o=ft.existsSync(s),f={},o)return[3,5];a=Nc(),E.label=1;case 1:return E.trys.push([1,2,,4]),ft.statSync(a),[3,4];case 2:return _=E.sent(),[4,ft.mkdirSync(a)];case 3:return E.sent(),[3,4];case 4:return[3,6];case 5:try{f=$i.load(ft.readFileSync(s,"utf8"))||{}}catch(p){throw p}E.label=6;case 6:return i.read?[2,f]:(y=i.configKey||"",f[y]=i.data,[4,ft.writeFileSync(s,$i.dump(f))]);case 7:return E.sent(),[2,f]}})})}Ie.handlerProfileFile=Gc;Ie.default={setConfig:Mc,getConfig:Hc,handlerProfileFile:Gc}});var sn=$(Cn=>{"use strict";var xE=Cn&&Cn.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Cn,"__esModule",{value:!0});Cn.ServerlessError=void 0;var SE=xE(Ot()),OE=SE.default.Logger,IE=new OE("S-CLI-ERROR"),RE=function(){function i(r,s,o){IE.error(r+": "+s,o),process.exit(1)}return i}();Cn.ServerlessError=RE});var Uc=$(bn=>{"use strict";var CE=bn&&bn.__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(bn,"__esModule",{value:!0});bn.CommandError=void 0;var bE=sn(),TE=function(i){CE(r,i);function r(s,o){return i.call(this,"Error",s,o)||this}return r}(bE.ServerlessError);bn.CommandError=TE});var Bc=$(Tn=>{"use strict";var LE=Tn&&Tn.__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(Tn,"__esModule",{value:!0});Tn.ConfigDeleteError=void 0;var $E=sn(),DE=function(i){LE(r,i);function r(s,o){return i.call(this,"Deletion failed",s,o)||this}return r}($E.ServerlessError);Tn.ConfigDeleteError=DE});var Kc=$(Ln=>{"use strict";var PE=Ln&&Ln.__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(Ln,"__esModule",{value:!0});Ln.ConfigError=void 0;var NE=sn(),qE=function(i){PE(r,i);function r(s,o){return i.call(this,"Config failed",s,o)||this}return r}(NE.ServerlessError);Ln.ConfigError=qE});var Xc=$($n=>{"use strict";var FE=$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.ConfigGetError=void 0;var ME=sn(),HE=function(i){FE(r,i);function r(s,o){return i.call(this,"Get failed",s,o)||this}return r}(ME.ServerlessError);$n.ConfigGetError=HE});var jc=$(Dn=>{"use strict";var GE=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.InitError=void 0;var WE=sn(),UE=function(i){GE(r,i);function r(s,o){return i.call(this,"Initialization failed",s,o)||this}return r}(WE.ServerlessError);Dn.InitError=UE});var zc=$(ct=>{"use strict";var BE=ct&&ct.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(_){_(a)})}return new(s||(s=Promise))(function(a,_){function y(A){try{p(o.next(A))}catch(R){_(R)}}function E(A){try{p(o.throw(A))}catch(R){_(R)}}function p(A){A.done?a(A.value):f(A.value).then(y,E)}p((o=o.apply(i,r||[])).next())})},KE=ct&&ct.__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,_;return _={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(_[Symbol.iterator]=function(){return this}),_;function y(p){return function(A){return E([p,A])}}function E(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(A){p=[6,A],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},XE=ct&&ct.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(ct,"__esModule",{value:!0});ct.HumanError=void 0;var kc=XE(Ot()),jE=Ti(),kE=kc.default.colors,zE=function(){function i(r){var s=r.errorMessage,o=r.tips;this.errorMessage=s,console.log(`
|
|
34
|
+
}`;var B=il(function(){return Y(h,N+"return "+I).apply(i,d)});if(B.source=I,Ks(B))throw B;return B}function t0(e){return Z(e).toLowerCase()}function n0(e){return Z(e).toUpperCase()}function r0(e,t,n){if(e=Z(e),e&&(n||t===i))return ho(e);if(!e||!(t=De(t)))return e;var u=et(e),l=et(t),h=po(u,l),d=go(u,l)+1;return Ft(u,h,d).join("")}function i0(e,t,n){if(e=Z(e),e&&(n||t===i))return e.slice(0,vo(e)+1);if(!e||!(t=De(t)))return e;var u=et(e),l=go(u,et(t))+1;return Ft(u,0,l).join("")}function s0(e,t,n){if(e=Z(e),e&&(n||t===i))return e.replace(Ki,"");if(!e||!(t=De(t)))return e;var u=et(e),l=po(u,et(t));return Ft(u,l).join("")}function u0(e,t){var n=Qc,u=eh;if(ie(t)){var l="separator"in t?t.separator:l;n="length"in t?U(t.length):n,u="omission"in t?De(t.omission):u}e=Z(e);var h=e.length;if(pn(e)){var d=et(e);h=d.length}if(n>=h)return e;var g=n-dn(u);if(g<1)return u;var m=d?Ft(d,0,g).join(""):e.slice(0,g);if(l===i)return m+u;if(d&&(g+=m.length-g),Xs(l)){if(e.slice(g).search(l)){var S,O=m;for(l.global||(l=os(l.source,Z(Pu.exec(l))+"g")),l.lastIndex=0;S=l.exec(O);)var I=S.index;m=m.slice(0,I===i?g:I)}}else if(e.indexOf(De(l),g)!=g){var C=m.lastIndexOf(l);C>-1&&(m=m.slice(0,C))}return m+u}function o0(e){return e=Z(e),e&&mh.test(e)?e.replace(Lu,qp):e}var a0=En(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),zs=sa("toUpperCase");function rl(e,t,n){return e=Z(e),t=n?i:t,t===i?Lp(e)?Hp(e):Ap(e):e.match(t)||[]}var il=X(function(e,t){try{return Le(e,i,t)}catch(n){return Ks(n)?n:new H(n)}}),l0=mt(function(e,t){return Ge(t,function(n){n=lt(n),_t(e,n,Us(e[n],e))}),e});function f0(e){var t=e==null?0:e.length,n=q();return e=t?re(e,function(u){if(typeof u[1]!="function")throw new We(f);return[n(u[0]),u[1]]}):[],X(function(u){for(var l=-1;++l<t;){var h=e[l];if(Le(h[0],this,u))return Le(h[1],this,u)}})}function c0(e){return qd(Be(e,p))}function Vs(e){return function(){return e}}function h0(e,t){return e==null||e!==e?t:e}var p0=oa(),d0=oa(!0);function Te(e){return e}function Ys(e){return Fo(typeof e=="function"?e:Be(e,p))}function g0(e){return Ho(Be(e,p))}function _0(e,t){return Go(e,Be(t,p))}var v0=X(function(e,t){return function(n){return Zn(n,e,t)}}),m0=X(function(e,t){return function(n){return Zn(e,n,t)}});function Zs(e,t,n){var u=pe(t),l=kr(t,u);n==null&&!(ie(t)&&(l.length||!u.length))&&(n=t,t=e,e=this,l=kr(t,pe(t)));var h=!(ie(n)&&"chain"in n)||!!n.chain,d=Et(e);return Ge(l,function(g){var m=t[g];e[g]=m,d&&(e.prototype[g]=function(){var S=this.__chain__;if(h||S){var O=e(this.__wrapped__),I=O.__actions__=Re(this.__actions__);return I.push({func:m,args:arguments,thisArg:e}),O.__chain__=S,O}return m.apply(e,Tt([this.value()],arguments))})}),e}function y0(){return he._===this&&(he._=Xp),this}function Js(){}function E0(e){return e=U(e),X(function(t){return Wo(t,e)})}var w0=bs(re),A0=bs(oo),x0=bs(es);function sl(e){return qs(e)?ts(lt(e)):Qd(e)}function S0(e){return function(t){return e==null?i:jt(e,t)}}var O0=la(),I0=la(!0);function Qs(){return[]}function eu(){return!1}function R0(){return{}}function C0(){return""}function b0(){return!0}function T0(e,t){if(e=U(e),e<1||e>Ct)return[];var n=ut,u=me(e,ut);t=q(t),e-=ut;for(var l=is(u,t);++n<e;)t(n);return l}function L0(e){return G(e)?re(e,lt):Pe(e)?[e]:Re(Oa(Z(e)))}function $0(e){var t=++Bp;return Z(e)+t}var D0=Qr(function(e,t){return e+t},0),P0=Ts("ceil"),N0=Qr(function(e,t){return e/t},1),q0=Ts("floor");function F0(e){return e&&e.length?jr(e,Te,gs):i}function M0(e,t){return e&&e.length?jr(e,q(t,2),gs):i}function H0(e){return fo(e,Te)}function G0(e,t){return fo(e,q(t,2))}function W0(e){return e&&e.length?jr(e,Te,ys):i}function U0(e,t){return e&&e.length?jr(e,q(t,2),ys):i}var B0=Qr(function(e,t){return e*t},1),K0=Ts("round"),X0=Qr(function(e,t){return e-t},0);function j0(e){return e&&e.length?rs(e,Te):0}function k0(e,t){return e&&e.length?rs(e,q(t,2)):0}return c.after=gv,c.ary=qa,c.assign=nm,c.assignIn=Ya,c.assignInWith=hi,c.assignWith=rm,c.at=im,c.before=Fa,c.bind=Us,c.bindAll=l0,c.bindKey=Ma,c.castArray=Rv,c.chain=Da,c.chunk=qg,c.compact=Fg,c.concat=Mg,c.cond=f0,c.conforms=c0,c.constant=Vs,c.countBy=j_,c.create=sm,c.curry=Ha,c.curryRight=Ga,c.debounce=Wa,c.defaults=um,c.defaultsDeep=om,c.defer=_v,c.delay=vv,c.difference=Hg,c.differenceBy=Gg,c.differenceWith=Wg,c.drop=Ug,c.dropRight=Bg,c.dropRightWhile=Kg,c.dropWhile=Xg,c.fill=jg,c.filter=z_,c.flatMap=Z_,c.flatMapDeep=J_,c.flatMapDepth=Q_,c.flatten=ba,c.flattenDeep=kg,c.flattenDepth=zg,c.flip=mv,c.flow=p0,c.flowRight=d0,c.fromPairs=Vg,c.functions=dm,c.functionsIn=gm,c.groupBy=ev,c.initial=Zg,c.intersection=Jg,c.intersectionBy=Qg,c.intersectionWith=e_,c.invert=vm,c.invertBy=mm,c.invokeMap=nv,c.iteratee=Ys,c.keyBy=rv,c.keys=pe,c.keysIn=be,c.map=ui,c.mapKeys=Em,c.mapValues=wm,c.matches=g0,c.matchesProperty=_0,c.memoize=ai,c.merge=Am,c.mergeWith=Za,c.method=v0,c.methodOf=m0,c.mixin=Zs,c.negate=li,c.nthArg=E0,c.omit=xm,c.omitBy=Sm,c.once=yv,c.orderBy=iv,c.over=w0,c.overArgs=Ev,c.overEvery=A0,c.overSome=x0,c.partial=Bs,c.partialRight=Ua,c.partition=sv,c.pick=Om,c.pickBy=Ja,c.property=sl,c.propertyOf=S0,c.pull=i_,c.pullAll=La,c.pullAllBy=s_,c.pullAllWith=u_,c.pullAt=o_,c.range=O0,c.rangeRight=I0,c.rearg=wv,c.reject=av,c.remove=a_,c.rest=Av,c.reverse=Gs,c.sampleSize=fv,c.set=Rm,c.setWith=Cm,c.shuffle=cv,c.slice=l_,c.sortBy=dv,c.sortedUniq=__,c.sortedUniqBy=v_,c.split=Zm,c.spread=xv,c.tail=m_,c.take=y_,c.takeRight=E_,c.takeRightWhile=w_,c.takeWhile=A_,c.tap=F_,c.throttle=Sv,c.thru=si,c.toArray=ka,c.toPairs=Qa,c.toPairsIn=el,c.toPath=L0,c.toPlainObject=Va,c.transform=bm,c.unary=Ov,c.union=x_,c.unionBy=S_,c.unionWith=O_,c.uniq=I_,c.uniqBy=R_,c.uniqWith=C_,c.unset=Tm,c.unzip=Ws,c.unzipWith=$a,c.update=Lm,c.updateWith=$m,c.values=xn,c.valuesIn=Dm,c.without=b_,c.words=rl,c.wrap=Iv,c.xor=T_,c.xorBy=L_,c.xorWith=$_,c.zip=D_,c.zipObject=P_,c.zipObjectDeep=N_,c.zipWith=q_,c.entries=Qa,c.entriesIn=el,c.extend=Ya,c.extendWith=hi,Zs(c,c),c.add=D0,c.attempt=il,c.camelCase=Fm,c.capitalize=tl,c.ceil=P0,c.clamp=Pm,c.clone=Cv,c.cloneDeep=Tv,c.cloneDeepWith=Lv,c.cloneWith=bv,c.conformsTo=$v,c.deburr=nl,c.defaultTo=h0,c.divide=N0,c.endsWith=Mm,c.eq=nt,c.escape=Hm,c.escapeRegExp=Gm,c.every=k_,c.find=V_,c.findIndex=Ra,c.findKey=am,c.findLast=Y_,c.findLastIndex=Ca,c.findLastKey=lm,c.floor=q0,c.forEach=Pa,c.forEachRight=Na,c.forIn=fm,c.forInRight=cm,c.forOwn=hm,c.forOwnRight=pm,c.get=js,c.gt=Dv,c.gte=Pv,c.has=_m,c.hasIn=ks,c.head=Ta,c.identity=Te,c.includes=tv,c.indexOf=Yg,c.inRange=Nm,c.invoke=ym,c.isArguments=Vt,c.isArray=G,c.isArrayBuffer=Nv,c.isArrayLike=Ce,c.isArrayLikeObject=ue,c.isBoolean=qv,c.isBuffer=Mt,c.isDate=Fv,c.isElement=Mv,c.isEmpty=Hv,c.isEqual=Gv,c.isEqualWith=Wv,c.isError=Ks,c.isFinite=Uv,c.isFunction=Et,c.isInteger=Ba,c.isLength=fi,c.isMap=Ka,c.isMatch=Bv,c.isMatchWith=Kv,c.isNaN=Xv,c.isNative=jv,c.isNil=zv,c.isNull=kv,c.isNumber=Xa,c.isObject=ie,c.isObjectLike=se,c.isPlainObject=rr,c.isRegExp=Xs,c.isSafeInteger=Vv,c.isSet=ja,c.isString=ci,c.isSymbol=Pe,c.isTypedArray=An,c.isUndefined=Yv,c.isWeakMap=Zv,c.isWeakSet=Jv,c.join=t_,c.kebabCase=Wm,c.last=Xe,c.lastIndexOf=n_,c.lowerCase=Um,c.lowerFirst=Bm,c.lt=Qv,c.lte=em,c.max=F0,c.maxBy=M0,c.mean=H0,c.meanBy=G0,c.min=W0,c.minBy=U0,c.stubArray=Qs,c.stubFalse=eu,c.stubObject=R0,c.stubString=C0,c.stubTrue=b0,c.multiply=B0,c.nth=r_,c.noConflict=y0,c.noop=Js,c.now=oi,c.pad=Km,c.padEnd=Xm,c.padStart=jm,c.parseInt=km,c.random=qm,c.reduce=uv,c.reduceRight=ov,c.repeat=zm,c.replace=Vm,c.result=Im,c.round=K0,c.runInContext=v,c.sample=lv,c.size=hv,c.snakeCase=Ym,c.some=pv,c.sortedIndex=f_,c.sortedIndexBy=c_,c.sortedIndexOf=h_,c.sortedLastIndex=p_,c.sortedLastIndexBy=d_,c.sortedLastIndexOf=g_,c.startCase=Jm,c.startsWith=Qm,c.subtract=X0,c.sum=j0,c.sumBy=k0,c.template=e0,c.times=T0,c.toFinite=wt,c.toInteger=U,c.toLength=za,c.toLower=t0,c.toNumber=je,c.toSafeInteger=tm,c.toString=Z,c.toUpper=n0,c.trim=r0,c.trimEnd=i0,c.trimStart=s0,c.truncate=u0,c.unescape=o0,c.uniqueId=$0,c.upperCase=a0,c.upperFirst=zs,c.each=Pa,c.eachRight=Na,c.first=Ta,Zs(c,function(){var e={};return ot(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){k.prototype[e]=function(n){n=n===i?1:ce(U(n),0);var u=this.__filtered__&&!t?new k(this):this.clone();return u.__filtered__?u.__takeCount__=me(n,u.__takeCount__):u.__views__.push({size:me(n,ut),type:e+(u.__dir__<0?"Right":"")}),u},k.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}}),Ge(["filter","map","takeWhile"],function(e,t){var n=t+1,u=n==Cu||n==ih;k.prototype[e]=function(l){var h=this.clone();return h.__iteratees__.push({iteratee:q(l,3),type:n}),h.__filtered__=h.__filtered__||u,h}}),Ge(["head","last"],function(e,t){var n="take"+(t?"Right":"");k.prototype[e]=function(){return this[n](1).value()[0]}}),Ge(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");k.prototype[e]=function(){return this.__filtered__?new k(this):this[n](1)}}),k.prototype.compact=function(){return this.filter(Te)},k.prototype.find=function(e){return this.filter(e).head()},k.prototype.findLast=function(e){return this.reverse().find(e)},k.prototype.invokeMap=X(function(e,t){return typeof e=="function"?new k(this):this.map(function(n){return Zn(n,e,t)})}),k.prototype.reject=function(e){return this.filter(li(q(e)))},k.prototype.slice=function(e,t){e=U(e);var n=this;return n.__filtered__&&(e>0||t<0)?new k(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=U(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},k.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},k.prototype.toArray=function(){return this.take(ut)},ot(k.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 d=this.__wrapped__,g=u?[1]:arguments,m=d instanceof k,S=g[0],O=m||G(d),I=function(j){var z=l.apply(c,Tt([j],g));return u&&C?z[0]:z};O&&n&&typeof S=="function"&&S.length!=1&&(m=O=!1);var C=this.__chain__,N=!!this.__actions__.length,F=h&&!C,B=m&&!N;if(!h&&O){d=B?d:new k(this);var M=e.apply(d,g);return M.__actions__.push({func:si,args:[I],thisArg:i}),new Ue(M,C)}return F&&B?e.apply(this,g):(M=this.thru(I),F?u?M.value()[0]:M.value():M)})}),Ge(["pop","push","shift","sort","splice","unshift"],function(e){var t=Lr[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(G(h)?h:[],l)}return this[n](function(d){return t.apply(G(d)?d:[],l)})}}),ot(k.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[Jr(i,Ye).name]=[{name:"wrapper",func:i}],k.prototype.clone=od,k.prototype.reverse=ad,k.prototype.value=ld,c.prototype.at=M_,c.prototype.chain=H_,c.prototype.commit=G_,c.prototype.next=W_,c.prototype.plant=B_,c.prototype.reverse=K_,c.prototype.toJSON=c.prototype.valueOf=c.prototype.value=X_,c.prototype.first=c.prototype.head,Kn&&(c.prototype[Kn]=U_),c},$t=Gp();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(he._=$t,define(function(){return $t})):Wt?((Wt.exports=$t)._=$t,Yi._=$t):he._=$t}).call(Sn)});var or=$((Aw,_l)=>{var Y0="2.0.0",Z0=256,J0=Number.MAX_SAFE_INTEGER||9007199254740991,Q0=16;_l.exports={SEMVER_SPEC_VERSION:Y0,MAX_LENGTH:Z0,MAX_SAFE_INTEGER:J0,MAX_SAFE_COMPONENT_LENGTH:Q0}});var ar=$((xw,vl)=>{var e1=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...i)=>console.error("SEMVER",...i):()=>{};vl.exports=e1});var Jt=$((Ht,ml)=>{var{MAX_SAFE_COMPONENT_LENGTH:iu}=or(),t1=ar();Ht=ml.exports={};var n1=Ht.re=[],D=Ht.src=[],P=Ht.t={},r1=0,K=(i,r,s)=>{let o=r1++;t1(o,r),P[i]=o,D[o]=r,n1[o]=new RegExp(r,s?"g":void 0)};K("NUMERICIDENTIFIER","0|[1-9]\\d*");K("NUMERICIDENTIFIERLOOSE","[0-9]+");K("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");K("MAINVERSION",`(${D[P.NUMERICIDENTIFIER]})\\.(${D[P.NUMERICIDENTIFIER]})\\.(${D[P.NUMERICIDENTIFIER]})`);K("MAINVERSIONLOOSE",`(${D[P.NUMERICIDENTIFIERLOOSE]})\\.(${D[P.NUMERICIDENTIFIERLOOSE]})\\.(${D[P.NUMERICIDENTIFIERLOOSE]})`);K("PRERELEASEIDENTIFIER",`(?:${D[P.NUMERICIDENTIFIER]}|${D[P.NONNUMERICIDENTIFIER]})`);K("PRERELEASEIDENTIFIERLOOSE",`(?:${D[P.NUMERICIDENTIFIERLOOSE]}|${D[P.NONNUMERICIDENTIFIER]})`);K("PRERELEASE",`(?:-(${D[P.PRERELEASEIDENTIFIER]}(?:\\.${D[P.PRERELEASEIDENTIFIER]})*))`);K("PRERELEASELOOSE",`(?:-?(${D[P.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${D[P.PRERELEASEIDENTIFIERLOOSE]})*))`);K("BUILDIDENTIFIER","[0-9A-Za-z-]+");K("BUILD",`(?:\\+(${D[P.BUILDIDENTIFIER]}(?:\\.${D[P.BUILDIDENTIFIER]})*))`);K("FULLPLAIN",`v?${D[P.MAINVERSION]}${D[P.PRERELEASE]}?${D[P.BUILD]}?`);K("FULL",`^${D[P.FULLPLAIN]}$`);K("LOOSEPLAIN",`[v=\\s]*${D[P.MAINVERSIONLOOSE]}${D[P.PRERELEASELOOSE]}?${D[P.BUILD]}?`);K("LOOSE",`^${D[P.LOOSEPLAIN]}$`);K("GTLT","((?:<|>)?=?)");K("XRANGEIDENTIFIERLOOSE",`${D[P.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);K("XRANGEIDENTIFIER",`${D[P.NUMERICIDENTIFIER]}|x|X|\\*`);K("XRANGEPLAIN",`[v=\\s]*(${D[P.XRANGEIDENTIFIER]})(?:\\.(${D[P.XRANGEIDENTIFIER]})(?:\\.(${D[P.XRANGEIDENTIFIER]})(?:${D[P.PRERELEASE]})?${D[P.BUILD]}?)?)?`);K("XRANGEPLAINLOOSE",`[v=\\s]*(${D[P.XRANGEIDENTIFIERLOOSE]})(?:\\.(${D[P.XRANGEIDENTIFIERLOOSE]})(?:\\.(${D[P.XRANGEIDENTIFIERLOOSE]})(?:${D[P.PRERELEASELOOSE]})?${D[P.BUILD]}?)?)?`);K("XRANGE",`^${D[P.GTLT]}\\s*${D[P.XRANGEPLAIN]}$`);K("XRANGELOOSE",`^${D[P.GTLT]}\\s*${D[P.XRANGEPLAINLOOSE]}$`);K("COERCE",`(^|[^\\d])(\\d{1,${iu}})(?:\\.(\\d{1,${iu}}))?(?:\\.(\\d{1,${iu}}))?(?:$|[^\\d])`);K("COERCERTL",D[P.COERCE],!0);K("LONETILDE","(?:~>?)");K("TILDETRIM",`(\\s*)${D[P.LONETILDE]}\\s+`,!0);Ht.tildeTrimReplace="$1~";K("TILDE",`^${D[P.LONETILDE]}${D[P.XRANGEPLAIN]}$`);K("TILDELOOSE",`^${D[P.LONETILDE]}${D[P.XRANGEPLAINLOOSE]}$`);K("LONECARET","(?:\\^)");K("CARETTRIM",`(\\s*)${D[P.LONECARET]}\\s+`,!0);Ht.caretTrimReplace="$1^";K("CARET",`^${D[P.LONECARET]}${D[P.XRANGEPLAIN]}$`);K("CARETLOOSE",`^${D[P.LONECARET]}${D[P.XRANGEPLAINLOOSE]}$`);K("COMPARATORLOOSE",`^${D[P.GTLT]}\\s*(${D[P.LOOSEPLAIN]})$|^$`);K("COMPARATOR",`^${D[P.GTLT]}\\s*(${D[P.FULLPLAIN]})$|^$`);K("COMPARATORTRIM",`(\\s*)${D[P.GTLT]}\\s*(${D[P.LOOSEPLAIN]}|${D[P.XRANGEPLAIN]})`,!0);Ht.comparatorTrimReplace="$1$2$3";K("HYPHENRANGE",`^\\s*(${D[P.XRANGEPLAIN]})\\s+-\\s+(${D[P.XRANGEPLAIN]})\\s*$`);K("HYPHENRANGELOOSE",`^\\s*(${D[P.XRANGEPLAINLOOSE]})\\s+-\\s+(${D[P.XRANGEPLAINLOOSE]})\\s*$`);K("STAR","(<|>)?=?\\s*\\*");K("GTE0","^\\s*>=\\s*0.0.0\\s*$");K("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$")});var lr=$((Sw,yl)=>{var i1=["includePrerelease","loose","rtl"],s1=i=>i?typeof i!="object"?{loose:!0}:i1.filter(r=>i[r]).reduce((r,s)=>(r[s]=!0,r),{}):{};yl.exports=s1});var di=$((Ow,Al)=>{var El=/^[0-9]+$/,wl=(i,r)=>{let s=El.test(i),o=El.test(r);return s&&o&&(i=+i,r=+r),i===r?0:s&&!o?-1:o&&!s?1:i<r?-1:1},u1=(i,r)=>wl(r,i);Al.exports={compareIdentifiers:wl,rcompareIdentifiers:u1}});var Ee=$((Iw,Il)=>{var gi=ar(),{MAX_LENGTH:xl,MAX_SAFE_INTEGER:_i}=or(),{re:Sl,t:Ol}=Jt(),o1=lr(),{compareIdentifiers:fr}=di(),ke=class{constructor(r,s){if(s=o1(s),r instanceof ke){if(r.loose===!!s.loose&&r.includePrerelease===!!s.includePrerelease)return r;r=r.version}else if(typeof r!="string")throw new TypeError(`Invalid Version: ${r}`);if(r.length>xl)throw new TypeError(`version is longer than ${xl} characters`);gi("SemVer",r,s),this.options=s,this.loose=!!s.loose,this.includePrerelease=!!s.includePrerelease;let o=r.trim().match(s.loose?Sl[Ol.LOOSE]:Sl[Ol.FULL]);if(!o)throw new TypeError(`Invalid Version: ${r}`);if(this.raw=r,this.major=+o[1],this.minor=+o[2],this.patch=+o[3],this.major>_i||this.major<0)throw new TypeError("Invalid major version");if(this.minor>_i||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>_i||this.patch<0)throw new TypeError("Invalid patch version");o[4]?this.prerelease=o[4].split(".").map(f=>{if(/^[0-9]+$/.test(f)){let a=+f;if(a>=0&&a<_i)return a}return f}):this.prerelease=[],this.build=o[5]?o[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(r){if(gi("SemVer.compare",this.version,this.options,r),!(r instanceof ke)){if(typeof r=="string"&&r===this.version)return 0;r=new ke(r,this.options)}return r.version===this.version?0:this.compareMain(r)||this.comparePre(r)}compareMain(r){return r instanceof ke||(r=new ke(r,this.options)),fr(this.major,r.major)||fr(this.minor,r.minor)||fr(this.patch,r.patch)}comparePre(r){if(r instanceof ke||(r=new ke(r,this.options)),this.prerelease.length&&!r.prerelease.length)return-1;if(!this.prerelease.length&&r.prerelease.length)return 1;if(!this.prerelease.length&&!r.prerelease.length)return 0;let s=0;do{let o=this.prerelease[s],f=r.prerelease[s];if(gi("prerelease compare",s,o,f),o===void 0&&f===void 0)return 0;if(f===void 0)return 1;if(o===void 0)return-1;if(o===f)continue;return fr(o,f)}while(++s)}compareBuild(r){r instanceof ke||(r=new ke(r,this.options));let s=0;do{let o=this.build[s],f=r.build[s];if(gi("prerelease compare",s,o,f),o===void 0&&f===void 0)return 0;if(f===void 0)return 1;if(o===void 0)return-1;if(o===f)continue;return fr(o,f)}while(++s)}inc(r,s){switch(r){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",s);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",s);break;case"prepatch":this.prerelease.length=0,this.inc("patch",s),this.inc("pre",s);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",s),this.inc("pre",s);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let o=this.prerelease.length;for(;--o>=0;)typeof this.prerelease[o]=="number"&&(this.prerelease[o]++,o=-2);o===-1&&this.prerelease.push(0)}s&&(this.prerelease[0]===s?isNaN(this.prerelease[1])&&(this.prerelease=[s,0]):this.prerelease=[s,0]);break;default:throw new Error(`invalid increment argument: ${r}`)}return this.format(),this.raw=this.version,this}};Il.exports=ke});var Qt=$((Rw,Tl)=>{var{MAX_LENGTH:a1}=or(),{re:Rl,t:Cl}=Jt(),bl=Ee(),l1=lr(),f1=(i,r)=>{if(r=l1(r),i instanceof bl)return i;if(typeof i!="string"||i.length>a1||!(r.loose?Rl[Cl.LOOSE]:Rl[Cl.FULL]).test(i))return null;try{return new bl(i,r)}catch{return null}};Tl.exports=f1});var $l=$((Cw,Ll)=>{var c1=Qt(),h1=(i,r)=>{let s=c1(i,r);return s?s.version:null};Ll.exports=h1});var Pl=$((bw,Dl)=>{var p1=Qt(),d1=(i,r)=>{let s=p1(i.trim().replace(/^[=v]+/,""),r);return s?s.version:null};Dl.exports=d1});var ql=$((Tw,Nl)=>{var g1=Ee(),_1=(i,r,s,o)=>{typeof s=="string"&&(o=s,s=void 0);try{return new g1(i,s).inc(r,o).version}catch{return null}};Nl.exports=_1});var ze=$((Lw,Ml)=>{var Fl=Ee(),v1=(i,r,s)=>new Fl(i,s).compare(new Fl(r,s));Ml.exports=v1});var vi=$(($w,Hl)=>{var m1=ze(),y1=(i,r,s)=>m1(i,r,s)===0;Hl.exports=y1});var Ul=$((Dw,Wl)=>{var Gl=Qt(),E1=vi(),w1=(i,r)=>{if(E1(i,r))return null;{let s=Gl(i),o=Gl(r),f=s.prerelease.length||o.prerelease.length,a=f?"pre":"",_=f?"prerelease":"";for(let y in s)if((y==="major"||y==="minor"||y==="patch")&&s[y]!==o[y])return a+y;return _}};Wl.exports=w1});var Kl=$((Pw,Bl)=>{var A1=Ee(),x1=(i,r)=>new A1(i,r).major;Bl.exports=x1});var jl=$((Nw,Xl)=>{var S1=Ee(),O1=(i,r)=>new S1(i,r).minor;Xl.exports=O1});var zl=$((qw,kl)=>{var I1=Ee(),R1=(i,r)=>new I1(i,r).patch;kl.exports=R1});var Yl=$((Fw,Vl)=>{var C1=Qt(),b1=(i,r)=>{let s=C1(i,r);return s&&s.prerelease.length?s.prerelease:null};Vl.exports=b1});var Jl=$((Mw,Zl)=>{var T1=ze(),L1=(i,r,s)=>T1(r,i,s);Zl.exports=L1});var ef=$((Hw,Ql)=>{var $1=ze(),D1=(i,r)=>$1(i,r,!0);Ql.exports=D1});var mi=$((Gw,nf)=>{var tf=Ee(),P1=(i,r,s)=>{let o=new tf(i,s),f=new tf(r,s);return o.compare(f)||o.compareBuild(f)};nf.exports=P1});var sf=$((Ww,rf)=>{var N1=mi(),q1=(i,r)=>i.sort((s,o)=>N1(s,o,r));rf.exports=q1});var of=$((Uw,uf)=>{var F1=mi(),M1=(i,r)=>i.sort((s,o)=>F1(o,s,r));uf.exports=M1});var cr=$((Bw,af)=>{var H1=ze(),G1=(i,r,s)=>H1(i,r,s)>0;af.exports=G1});var yi=$((Kw,lf)=>{var W1=ze(),U1=(i,r,s)=>W1(i,r,s)<0;lf.exports=U1});var su=$((Xw,ff)=>{var B1=ze(),K1=(i,r,s)=>B1(i,r,s)!==0;ff.exports=K1});var Ei=$((jw,cf)=>{var X1=ze(),j1=(i,r,s)=>X1(i,r,s)>=0;cf.exports=j1});var wi=$((kw,hf)=>{var k1=ze(),z1=(i,r,s)=>k1(i,r,s)<=0;hf.exports=z1});var uu=$((zw,pf)=>{var V1=vi(),Y1=su(),Z1=cr(),J1=Ei(),Q1=yi(),ey=wi(),ty=(i,r,s,o)=>{switch(r){case"===":return typeof i=="object"&&(i=i.version),typeof s=="object"&&(s=s.version),i===s;case"!==":return typeof i=="object"&&(i=i.version),typeof s=="object"&&(s=s.version),i!==s;case"":case"=":case"==":return V1(i,s,o);case"!=":return Y1(i,s,o);case">":return Z1(i,s,o);case">=":return J1(i,s,o);case"<":return Q1(i,s,o);case"<=":return ey(i,s,o);default:throw new TypeError(`Invalid operator: ${r}`)}};pf.exports=ty});var gf=$((Vw,df)=>{var ny=Ee(),ry=Qt(),{re:Ai,t:xi}=Jt(),iy=(i,r)=>{if(i instanceof ny)return i;if(typeof i=="number"&&(i=String(i)),typeof i!="string")return null;r=r||{};let s=null;if(!r.rtl)s=i.match(Ai[xi.COERCE]);else{let o;for(;(o=Ai[xi.COERCERTL].exec(i))&&(!s||s.index+s[0].length!==i.length);)(!s||o.index+o[0].length!==s.index+s[0].length)&&(s=o),Ai[xi.COERCERTL].lastIndex=o.index+o[1].length+o[2].length;Ai[xi.COERCERTL].lastIndex=-1}return s===null?null:ry(`${s[2]}.${s[3]||"0"}.${s[4]||"0"}`,r)};df.exports=iy});var vf=$((Yw,_f)=>{"use strict";_f.exports=function(i){i.prototype[Symbol.iterator]=function*(){for(let r=this.head;r;r=r.next)yield r.value}}});var yf=$((Zw,mf)=>{"use strict";mf.exports=V;V.Node=en;V.create=V;function V(i){var r=this;if(r instanceof V||(r=new V),r.tail=null,r.head=null,r.length=0,i&&typeof i.forEach=="function")i.forEach(function(f){r.push(f)});else if(arguments.length>0)for(var s=0,o=arguments.length;s<o;s++)r.push(arguments[s]);return r}V.prototype.removeNode=function(i){if(i.list!==this)throw new Error("removing node which does not belong to this list");var r=i.next,s=i.prev;return r&&(r.prev=s),s&&(s.next=r),i===this.head&&(this.head=r),i===this.tail&&(this.tail=s),i.list.length--,i.next=null,i.prev=null,i.list=null,r};V.prototype.unshiftNode=function(i){if(i!==this.head){i.list&&i.list.removeNode(i);var r=this.head;i.list=this,i.next=r,r&&(r.prev=i),this.head=i,this.tail||(this.tail=i),this.length++}};V.prototype.pushNode=function(i){if(i!==this.tail){i.list&&i.list.removeNode(i);var r=this.tail;i.list=this,i.prev=r,r&&(r.next=i),this.tail=i,this.head||(this.head=i),this.length++}};V.prototype.push=function(){for(var i=0,r=arguments.length;i<r;i++)uy(this,arguments[i]);return this.length};V.prototype.unshift=function(){for(var i=0,r=arguments.length;i<r;i++)oy(this,arguments[i]);return this.length};V.prototype.pop=function(){if(!!this.tail){var i=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,i}};V.prototype.shift=function(){if(!!this.head){var i=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,i}};V.prototype.forEach=function(i,r){r=r||this;for(var s=this.head,o=0;s!==null;o++)i.call(r,s.value,o,this),s=s.next};V.prototype.forEachReverse=function(i,r){r=r||this;for(var s=this.tail,o=this.length-1;s!==null;o--)i.call(r,s.value,o,this),s=s.prev};V.prototype.get=function(i){for(var r=0,s=this.head;s!==null&&r<i;r++)s=s.next;if(r===i&&s!==null)return s.value};V.prototype.getReverse=function(i){for(var r=0,s=this.tail;s!==null&&r<i;r++)s=s.prev;if(r===i&&s!==null)return s.value};V.prototype.map=function(i,r){r=r||this;for(var s=new V,o=this.head;o!==null;)s.push(i.call(r,o.value,this)),o=o.next;return s};V.prototype.mapReverse=function(i,r){r=r||this;for(var s=new V,o=this.tail;o!==null;)s.push(i.call(r,o.value,this)),o=o.prev;return s};V.prototype.reduce=function(i,r){var s,o=this.head;if(arguments.length>1)s=r;else if(this.head)o=this.head.next,s=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=0;o!==null;f++)s=i(s,o.value,f),o=o.next;return s};V.prototype.reduceReverse=function(i,r){var s,o=this.tail;if(arguments.length>1)s=r;else if(this.tail)o=this.tail.prev,s=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var f=this.length-1;o!==null;f--)s=i(s,o.value,f),o=o.prev;return s};V.prototype.toArray=function(){for(var i=new Array(this.length),r=0,s=this.head;s!==null;r++)i[r]=s.value,s=s.next;return i};V.prototype.toArrayReverse=function(){for(var i=new Array(this.length),r=0,s=this.tail;s!==null;r++)i[r]=s.value,s=s.prev;return i};V.prototype.slice=function(i,r){r=r||this.length,r<0&&(r+=this.length),i=i||0,i<0&&(i+=this.length);var s=new V;if(r<i||r<0)return s;i<0&&(i=0),r>this.length&&(r=this.length);for(var o=0,f=this.head;f!==null&&o<i;o++)f=f.next;for(;f!==null&&o<r;o++,f=f.next)s.push(f.value);return s};V.prototype.sliceReverse=function(i,r){r=r||this.length,r<0&&(r+=this.length),i=i||0,i<0&&(i+=this.length);var s=new V;if(r<i||r<0)return s;i<0&&(i=0),r>this.length&&(r=this.length);for(var o=this.length,f=this.tail;f!==null&&o>r;o--)f=f.prev;for(;f!==null&&o>i;o--,f=f.prev)s.push(f.value);return s};V.prototype.splice=function(i,r,...s){i>this.length&&(i=this.length-1),i<0&&(i=this.length+i);for(var o=0,f=this.head;f!==null&&o<i;o++)f=f.next;for(var a=[],o=0;f&&o<r;o++)a.push(f.value),f=this.removeNode(f);f===null&&(f=this.tail),f!==this.head&&f!==this.tail&&(f=f.prev);for(var o=0;o<s.length;o++)f=sy(this,f,s[o]);return a};V.prototype.reverse=function(){for(var i=this.head,r=this.tail,s=i;s!==null;s=s.prev){var o=s.prev;s.prev=s.next,s.next=o}return this.head=r,this.tail=i,this};function sy(i,r,s){var o=r===i.head?new en(s,null,r,i):new en(s,r,r.next,i);return o.next===null&&(i.tail=o),o.prev===null&&(i.head=o),i.length++,o}function uy(i,r){i.tail=new en(r,i.tail,null,i),i.head||(i.head=i.tail),i.length++}function oy(i,r){i.head=new en(r,null,i.head,i),i.tail||(i.tail=i.head),i.length++}function en(i,r,s,o){if(!(this instanceof en))return new en(i,r,s,o);this.list=o,this.value=i,r?(r.next=this,this.prev=r):this.prev=null,s?(s.prev=this,this.next=s):this.next=null}try{vf()(V)}catch{}});var If=$((Jw,Of)=>{"use strict";var ay=yf(),tn=Symbol("max"),xt=Symbol("length"),On=Symbol("lengthCalculator"),hr=Symbol("allowStale"),nn=Symbol("maxAge"),St=Symbol("dispose"),Ef=Symbol("noDisposeOnSet"),de=Symbol("lruList"),it=Symbol("cache"),wf=Symbol("updateAgeOnGet"),ou=()=>1,Af=class{constructor(r){if(typeof r=="number"&&(r={max:r}),r||(r={}),r.max&&(typeof r.max!="number"||r.max<0))throw new TypeError("max must be a non-negative number");let s=this[tn]=r.max||1/0,o=r.length||ou;if(this[On]=typeof o!="function"?ou:o,this[hr]=r.stale||!1,r.maxAge&&typeof r.maxAge!="number")throw new TypeError("maxAge must be a number");this[nn]=r.maxAge||0,this[St]=r.dispose,this[Ef]=r.noDisposeOnSet||!1,this[wf]=r.updateAgeOnGet||!1,this.reset()}set max(r){if(typeof r!="number"||r<0)throw new TypeError("max must be a non-negative number");this[tn]=r||1/0,pr(this)}get max(){return this[tn]}set allowStale(r){this[hr]=!!r}get allowStale(){return this[hr]}set maxAge(r){if(typeof r!="number")throw new TypeError("maxAge must be a non-negative number");this[nn]=r,pr(this)}get maxAge(){return this[nn]}set lengthCalculator(r){typeof r!="function"&&(r=ou),r!==this[On]&&(this[On]=r,this[xt]=0,this[de].forEach(s=>{s.length=this[On](s.value,s.key),this[xt]+=s.length})),pr(this)}get lengthCalculator(){return this[On]}get length(){return this[xt]}get itemCount(){return this[de].length}rforEach(r,s){s=s||this;for(let o=this[de].tail;o!==null;){let f=o.prev;Sf(this,r,o,s),o=f}}forEach(r,s){s=s||this;for(let o=this[de].head;o!==null;){let f=o.next;Sf(this,r,o,s),o=f}}keys(){return this[de].toArray().map(r=>r.key)}values(){return this[de].toArray().map(r=>r.value)}reset(){this[St]&&this[de]&&this[de].length&&this[de].forEach(r=>this[St](r.key,r.value)),this[it]=new Map,this[de]=new ay,this[xt]=0}dump(){return this[de].map(r=>Si(this,r)?!1:{k:r.key,v:r.value,e:r.now+(r.maxAge||0)}).toArray().filter(r=>r)}dumpLru(){return this[de]}set(r,s,o){if(o=o||this[nn],o&&typeof o!="number")throw new TypeError("maxAge must be a number");let f=o?Date.now():0,a=this[On](s,r);if(this[it].has(r)){if(a>this[tn])return In(this,this[it].get(r)),!1;let E=this[it].get(r).value;return this[St]&&(this[Ef]||this[St](r,E.value)),E.now=f,E.maxAge=o,E.value=s,this[xt]+=a-E.length,E.length=a,this.get(r),pr(this),!0}let _=new xf(r,s,a,f,o);return _.length>this[tn]?(this[St]&&this[St](r,s),!1):(this[xt]+=_.length,this[de].unshift(_),this[it].set(r,this[de].head),pr(this),!0)}has(r){if(!this[it].has(r))return!1;let s=this[it].get(r).value;return!Si(this,s)}get(r){return au(this,r,!0)}peek(r){return au(this,r,!1)}pop(){let r=this[de].tail;return r?(In(this,r),r.value):null}del(r){In(this,this[it].get(r))}load(r){this.reset();let s=Date.now();for(let o=r.length-1;o>=0;o--){let f=r[o],a=f.e||0;if(a===0)this.set(f.k,f.v);else{let _=a-s;_>0&&this.set(f.k,f.v,_)}}}prune(){this[it].forEach((r,s)=>au(this,s,!1))}},au=(i,r,s)=>{let o=i[it].get(r);if(o){let f=o.value;if(Si(i,f)){if(In(i,o),!i[hr])return}else s&&(i[wf]&&(o.value.now=Date.now()),i[de].unshiftNode(o));return f.value}},Si=(i,r)=>{if(!r||!r.maxAge&&!i[nn])return!1;let s=Date.now()-r.now;return r.maxAge?s>r.maxAge:i[nn]&&s>i[nn]},pr=i=>{if(i[xt]>i[tn])for(let r=i[de].tail;i[xt]>i[tn]&&r!==null;){let s=r.prev;In(i,r),r=s}},In=(i,r)=>{if(r){let s=r.value;i[St]&&i[St](s.key,s.value),i[xt]-=s.length,i[it].delete(s.key),i[de].removeNode(r)}},xf=class{constructor(r,s,o,f,a){this.key=r,this.value=s,this.length=o,this.now=f,this.maxAge=a||0}},Sf=(i,r,s,o)=>{let f=s.value;Si(i,f)&&(In(i,s),i[hr]||(f=void 0)),f&&r.call(o,f.value,f.key,i)};Of.exports=Af});var Ve=$((Qw,Tf)=>{var Rn=class{constructor(r,s){if(s=fy(s),r instanceof Rn)return r.loose===!!s.loose&&r.includePrerelease===!!s.includePrerelease?r:new Rn(r.raw,s);if(r instanceof lu)return this.raw=r.value,this.set=[[r]],this.format(),this;if(this.options=s,this.loose=!!s.loose,this.includePrerelease=!!s.includePrerelease,this.raw=r,this.set=r.split(/\s*\|\|\s*/).map(o=>this.parseRange(o.trim())).filter(o=>o.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${r}`);if(this.set.length>1){let o=this.set[0];if(this.set=this.set.filter(f=>!Cf(f[0])),this.set.length===0)this.set=[o];else if(this.set.length>1){for(let f of this.set)if(f.length===1&&gy(f[0])){this.set=[f];break}}}this.format()}format(){return this.range=this.set.map(r=>r.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(r){r=r.trim();let o=`parseRange:${Object.keys(this.options).join(",")}:${r}`,f=Rf.get(o);if(f)return f;let a=this.options.loose,_=a?we[ve.HYPHENRANGELOOSE]:we[ve.HYPHENRANGE];r=r.replace(_,Oy(this.options.includePrerelease)),ae("hyphen replace",r),r=r.replace(we[ve.COMPARATORTRIM],hy),ae("comparator trim",r,we[ve.COMPARATORTRIM]),r=r.replace(we[ve.TILDETRIM],py),r=r.replace(we[ve.CARETTRIM],dy),r=r.split(/\s+/).join(" ");let y=a?we[ve.COMPARATORLOOSE]:we[ve.COMPARATOR],E=r.split(" ").map(L=>_y(L,this.options)).join(" ").split(/\s+/).map(L=>Sy(L,this.options)).filter(this.options.loose?L=>!!L.match(y):()=>!0).map(L=>new lu(L,this.options)),p=E.length,A=new Map;for(let L of E){if(Cf(L))return[L];A.set(L.value,L)}A.size>1&&A.has("")&&A.delete("");let R=[...A.values()];return Rf.set(o,R),R}intersects(r,s){if(!(r instanceof Rn))throw new TypeError("a Range is required");return this.set.some(o=>bf(o,s)&&r.set.some(f=>bf(f,s)&&o.every(a=>f.every(_=>a.intersects(_,s)))))}test(r){if(!r)return!1;if(typeof r=="string")try{r=new cy(r,this.options)}catch{return!1}for(let s=0;s<this.set.length;s++)if(Iy(this.set[s],r,this.options))return!0;return!1}};Tf.exports=Rn;var ly=If(),Rf=new ly({max:1e3}),fy=lr(),lu=dr(),ae=ar(),cy=Ee(),{re:we,t:ve,comparatorTrimReplace:hy,tildeTrimReplace:py,caretTrimReplace:dy}=Jt(),Cf=i=>i.value==="<0.0.0-0",gy=i=>i.value==="",bf=(i,r)=>{let s=!0,o=i.slice(),f=o.pop();for(;s&&o.length;)s=o.every(a=>f.intersects(a,r)),f=o.pop();return s},_y=(i,r)=>(ae("comp",i,r),i=yy(i,r),ae("caret",i),i=vy(i,r),ae("tildes",i),i=wy(i,r),ae("xrange",i),i=xy(i,r),ae("stars",i),i),Oe=i=>!i||i.toLowerCase()==="x"||i==="*",vy=(i,r)=>i.trim().split(/\s+/).map(s=>my(s,r)).join(" "),my=(i,r)=>{let s=r.loose?we[ve.TILDELOOSE]:we[ve.TILDE];return i.replace(s,(o,f,a,_,y)=>{ae("tilde",i,o,f,a,_,y);let E;return Oe(f)?E="":Oe(a)?E=`>=${f}.0.0 <${+f+1}.0.0-0`:Oe(_)?E=`>=${f}.${a}.0 <${f}.${+a+1}.0-0`:y?(ae("replaceTilde pr",y),E=`>=${f}.${a}.${_}-${y} <${f}.${+a+1}.0-0`):E=`>=${f}.${a}.${_} <${f}.${+a+1}.0-0`,ae("tilde return",E),E})},yy=(i,r)=>i.trim().split(/\s+/).map(s=>Ey(s,r)).join(" "),Ey=(i,r)=>{ae("caret",i,r);let s=r.loose?we[ve.CARETLOOSE]:we[ve.CARET],o=r.includePrerelease?"-0":"";return i.replace(s,(f,a,_,y,E)=>{ae("caret",i,f,a,_,y,E);let p;return Oe(a)?p="":Oe(_)?p=`>=${a}.0.0${o} <${+a+1}.0.0-0`:Oe(y)?a==="0"?p=`>=${a}.${_}.0${o} <${a}.${+_+1}.0-0`:p=`>=${a}.${_}.0${o} <${+a+1}.0.0-0`:E?(ae("replaceCaret pr",E),a==="0"?_==="0"?p=`>=${a}.${_}.${y}-${E} <${a}.${_}.${+y+1}-0`:p=`>=${a}.${_}.${y}-${E} <${a}.${+_+1}.0-0`:p=`>=${a}.${_}.${y}-${E} <${+a+1}.0.0-0`):(ae("no pr"),a==="0"?_==="0"?p=`>=${a}.${_}.${y}${o} <${a}.${_}.${+y+1}-0`:p=`>=${a}.${_}.${y}${o} <${a}.${+_+1}.0-0`:p=`>=${a}.${_}.${y} <${+a+1}.0.0-0`),ae("caret return",p),p})},wy=(i,r)=>(ae("replaceXRanges",i,r),i.split(/\s+/).map(s=>Ay(s,r)).join(" ")),Ay=(i,r)=>{i=i.trim();let s=r.loose?we[ve.XRANGELOOSE]:we[ve.XRANGE];return i.replace(s,(o,f,a,_,y,E)=>{ae("xRange",i,o,f,a,_,y,E);let p=Oe(a),A=p||Oe(_),R=A||Oe(y),L=R;return f==="="&&L&&(f=""),E=r.includePrerelease?"-0":"",p?f===">"||f==="<"?o="<0.0.0-0":o="*":f&&L?(A&&(_=0),y=0,f===">"?(f=">=",A?(a=+a+1,_=0,y=0):(_=+_+1,y=0)):f==="<="&&(f="<",A?a=+a+1:_=+_+1),f==="<"&&(E="-0"),o=`${f+a}.${_}.${y}${E}`):A?o=`>=${a}.0.0${E} <${+a+1}.0.0-0`:R&&(o=`>=${a}.${_}.0${E} <${a}.${+_+1}.0-0`),ae("xRange return",o),o})},xy=(i,r)=>(ae("replaceStars",i,r),i.trim().replace(we[ve.STAR],"")),Sy=(i,r)=>(ae("replaceGTE0",i,r),i.trim().replace(we[r.includePrerelease?ve.GTE0PRE:ve.GTE0],"")),Oy=i=>(r,s,o,f,a,_,y,E,p,A,R,L,b)=>(Oe(o)?s="":Oe(f)?s=`>=${o}.0.0${i?"-0":""}`:Oe(a)?s=`>=${o}.${f}.0${i?"-0":""}`:_?s=`>=${s}`:s=`>=${s}${i?"-0":""}`,Oe(p)?E="":Oe(A)?E=`<${+p+1}.0.0-0`:Oe(R)?E=`<${p}.${+A+1}.0-0`:L?E=`<=${p}.${A}.${R}-${L}`:i?E=`<${p}.${A}.${+R+1}-0`:E=`<=${E}`,`${s} ${E}`.trim()),Iy=(i,r,s)=>{for(let o=0;o<i.length;o++)if(!i[o].test(r))return!1;if(r.prerelease.length&&!s.includePrerelease){for(let o=0;o<i.length;o++)if(ae(i[o].semver),i[o].semver!==lu.ANY&&i[o].semver.prerelease.length>0){let f=i[o].semver;if(f.major===r.major&&f.minor===r.minor&&f.patch===r.patch)return!0}return!1}return!0}});var dr=$((eA,Nf)=>{var gr=Symbol("SemVer ANY"),_r=class{static get ANY(){return gr}constructor(r,s){if(s=Ry(s),r instanceof _r){if(r.loose===!!s.loose)return r;r=r.value}cu("comparator",r,s),this.options=s,this.loose=!!s.loose,this.parse(r),this.semver===gr?this.value="":this.value=this.operator+this.semver.version,cu("comp",this)}parse(r){let s=this.options.loose?Lf[$f.COMPARATORLOOSE]:Lf[$f.COMPARATOR],o=r.match(s);if(!o)throw new TypeError(`Invalid comparator: ${r}`);this.operator=o[1]!==void 0?o[1]:"",this.operator==="="&&(this.operator=""),o[2]?this.semver=new Df(o[2],this.options.loose):this.semver=gr}toString(){return this.value}test(r){if(cu("Comparator.test",r,this.options.loose),this.semver===gr||r===gr)return!0;if(typeof r=="string")try{r=new Df(r,this.options)}catch{return!1}return fu(r,this.operator,this.semver,this.options)}intersects(r,s){if(!(r instanceof _r))throw new TypeError("a Comparator is required");if((!s||typeof s!="object")&&(s={loose:!!s,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Pf(r.value,s).test(this.value);if(r.operator==="")return r.value===""?!0:new Pf(this.value,s).test(r.semver);let o=(this.operator===">="||this.operator===">")&&(r.operator===">="||r.operator===">"),f=(this.operator==="<="||this.operator==="<")&&(r.operator==="<="||r.operator==="<"),a=this.semver.version===r.semver.version,_=(this.operator===">="||this.operator==="<=")&&(r.operator===">="||r.operator==="<="),y=fu(this.semver,"<",r.semver,s)&&(this.operator===">="||this.operator===">")&&(r.operator==="<="||r.operator==="<"),E=fu(this.semver,">",r.semver,s)&&(this.operator==="<="||this.operator==="<")&&(r.operator===">="||r.operator===">");return o||f||a&&_||y||E}};Nf.exports=_r;var Ry=lr(),{re:Lf,t:$f}=Jt(),fu=uu(),cu=ar(),Df=Ee(),Pf=Ve()});var vr=$((tA,qf)=>{var Cy=Ve(),by=(i,r,s)=>{try{r=new Cy(r,s)}catch{return!1}return r.test(i)};qf.exports=by});var Mf=$((nA,Ff)=>{var Ty=Ve(),Ly=(i,r)=>new Ty(i,r).set.map(s=>s.map(o=>o.value).join(" ").trim().split(" "));Ff.exports=Ly});var Gf=$((rA,Hf)=>{var $y=Ee(),Dy=Ve(),Py=(i,r,s)=>{let o=null,f=null,a=null;try{a=new Dy(r,s)}catch{return null}return i.forEach(_=>{a.test(_)&&(!o||f.compare(_)===-1)&&(o=_,f=new $y(o,s))}),o};Hf.exports=Py});var Uf=$((iA,Wf)=>{var Ny=Ee(),qy=Ve(),Fy=(i,r,s)=>{let o=null,f=null,a=null;try{a=new qy(r,s)}catch{return null}return i.forEach(_=>{a.test(_)&&(!o||f.compare(_)===1)&&(o=_,f=new Ny(o,s))}),o};Wf.exports=Fy});var Xf=$((sA,Kf)=>{var hu=Ee(),My=Ve(),Bf=cr(),Hy=(i,r)=>{i=new My(i,r);let s=new hu("0.0.0");if(i.test(s)||(s=new hu("0.0.0-0"),i.test(s)))return s;s=null;for(let o=0;o<i.set.length;++o){let f=i.set[o],a=null;f.forEach(_=>{let y=new hu(_.semver.version);switch(_.operator){case">":y.prerelease.length===0?y.patch++:y.prerelease.push(0),y.raw=y.format();case"":case">=":(!a||Bf(y,a))&&(a=y);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${_.operator}`)}}),a&&(!s||Bf(s,a))&&(s=a)}return s&&i.test(s)?s:null};Kf.exports=Hy});var kf=$((uA,jf)=>{var Gy=Ve(),Wy=(i,r)=>{try{return new Gy(i,r).range||"*"}catch{return null}};jf.exports=Wy});var Oi=$((oA,Zf)=>{var Uy=Ee(),zf=dr(),{ANY:By}=zf,Ky=Ve(),Xy=vr(),Vf=cr(),Yf=yi(),jy=wi(),ky=Ei(),zy=(i,r,s,o)=>{i=new Uy(i,o),r=new Ky(r,o);let f,a,_,y,E;switch(s){case">":f=Vf,a=jy,_=Yf,y=">",E=">=";break;case"<":f=Yf,a=ky,_=Vf,y="<",E="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Xy(i,r,o))return!1;for(let p=0;p<r.set.length;++p){let A=r.set[p],R=null,L=null;if(A.forEach(b=>{b.semver===By&&(b=new zf(">=0.0.0")),R=R||b,L=L||b,f(b.semver,R.semver,o)?R=b:_(b.semver,L.semver,o)&&(L=b)}),R.operator===y||R.operator===E||(!L.operator||L.operator===y)&&a(i,L.semver))return!1;if(L.operator===E&&_(i,L.semver))return!1}return!0};Zf.exports=zy});var Qf=$((aA,Jf)=>{var Vy=Oi(),Yy=(i,r,s)=>Vy(i,r,">",s);Jf.exports=Yy});var tc=$((lA,ec)=>{var Zy=Oi(),Jy=(i,r,s)=>Zy(i,r,"<",s);ec.exports=Jy});var ic=$((fA,rc)=>{var nc=Ve(),Qy=(i,r,s)=>(i=new nc(i,s),r=new nc(r,s),i.intersects(r));rc.exports=Qy});var uc=$((cA,sc)=>{var eE=vr(),tE=ze();sc.exports=(i,r,s)=>{let o=[],f=null,a=null,_=i.sort((A,R)=>tE(A,R,s));for(let A of _)eE(A,r,s)?(a=A,f||(f=A)):(a&&o.push([f,a]),a=null,f=null);f&&o.push([f,null]);let y=[];for(let[A,R]of o)A===R?y.push(A):!R&&A===_[0]?y.push("*"):R?A===_[0]?y.push(`<=${R}`):y.push(`${A} - ${R}`):y.push(`>=${A}`);let E=y.join(" || "),p=typeof r.raw=="string"?r.raw:String(r);return E.length<p.length?E:r}});var cc=$((hA,fc)=>{var oc=Ve(),Ii=dr(),{ANY:pu}=Ii,mr=vr(),du=ze(),nE=(i,r,s={})=>{if(i===r)return!0;i=new oc(i,s),r=new oc(r,s);let o=!1;e:for(let f of i.set){for(let a of r.set){let _=rE(f,a,s);if(o=o||_!==null,_)continue e}if(o)return!1}return!0},rE=(i,r,s)=>{if(i===r)return!0;if(i.length===1&&i[0].semver===pu){if(r.length===1&&r[0].semver===pu)return!0;s.includePrerelease?i=[new Ii(">=0.0.0-0")]:i=[new Ii(">=0.0.0")]}if(r.length===1&&r[0].semver===pu){if(s.includePrerelease)return!0;r=[new Ii(">=0.0.0")]}let o=new Set,f,a;for(let b of i)b.operator===">"||b.operator===">="?f=ac(f,b,s):b.operator==="<"||b.operator==="<="?a=lc(a,b,s):o.add(b.semver);if(o.size>1)return null;let _;if(f&&a){if(_=du(f.semver,a.semver,s),_>0)return null;if(_===0&&(f.operator!==">="||a.operator!=="<="))return null}for(let b of o){if(f&&!mr(b,String(f),s)||a&&!mr(b,String(a),s))return null;for(let le of r)if(!mr(b,String(le),s))return!1;return!0}let y,E,p,A,R=a&&!s.includePrerelease&&a.semver.prerelease.length?a.semver:!1,L=f&&!s.includePrerelease&&f.semver.prerelease.length?f.semver:!1;R&&R.prerelease.length===1&&a.operator==="<"&&R.prerelease[0]===0&&(R=!1);for(let b of r){if(A=A||b.operator===">"||b.operator===">=",p=p||b.operator==="<"||b.operator==="<=",f){if(L&&b.semver.prerelease&&b.semver.prerelease.length&&b.semver.major===L.major&&b.semver.minor===L.minor&&b.semver.patch===L.patch&&(L=!1),b.operator===">"||b.operator===">="){if(y=ac(f,b,s),y===b&&y!==f)return!1}else if(f.operator===">="&&!mr(f.semver,String(b),s))return!1}if(a){if(R&&b.semver.prerelease&&b.semver.prerelease.length&&b.semver.major===R.major&&b.semver.minor===R.minor&&b.semver.patch===R.patch&&(R=!1),b.operator==="<"||b.operator==="<="){if(E=lc(a,b,s),E===b&&E!==a)return!1}else if(a.operator==="<="&&!mr(a.semver,String(b),s))return!1}if(!b.operator&&(a||f)&&_!==0)return!1}return!(f&&p&&!a&&_!==0||a&&A&&!f&&_!==0||L||R)},ac=(i,r,s)=>{if(!i)return r;let o=du(i.semver,r.semver,s);return o>0?i:o<0||r.operator===">"&&i.operator===">="?r:i},lc=(i,r,s)=>{if(!i)return r;let o=du(i.semver,r.semver,s);return o<0?i:o>0||r.operator==="<"&&i.operator==="<="?r:i};fc.exports=nE});var pc=$((pA,hc)=>{var gu=Jt();hc.exports={re:gu.re,src:gu.src,tokens:gu.t,SEMVER_SPEC_VERSION:or().SEMVER_SPEC_VERSION,SemVer:Ee(),compareIdentifiers:di().compareIdentifiers,rcompareIdentifiers:di().rcompareIdentifiers,parse:Qt(),valid:$l(),clean:Pl(),inc:ql(),diff:Ul(),major:Kl(),minor:jl(),patch:zl(),prerelease:Yl(),compare:ze(),rcompare:Jl(),compareLoose:ef(),compareBuild:mi(),sort:sf(),rsort:of(),gt:cr(),lt:yi(),eq:vi(),neq:su(),gte:Ei(),lte:wi(),cmp:uu(),coerce:gf(),Comparator:dr(),Range:Ve(),satisfies:vr(),toComparators:Mf(),maxSatisfying:Gf(),minSatisfying:Uf(),minVersion:Xf(),validRange:kf(),outside:Oi(),gtr:Qf(),ltr:tc(),intersects:ic(),simplifyRange:uc(),subset:cc()}});var Ot=$(rn=>{"use strict";var dc=rn&&rn.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(rn,"__esModule",{value:!0});rn.getCoreVersion=void 0;var gc=dc(require("path")),_c=dc(require("fs")),iE=pc(),sE=require("@serverless-devs/core"),_u=gc.default.join(sE.getRootHome(),"cache","core"),vc=gc.default.join(_u,"package.json");function uE(){if(_c.default.existsSync(vc)){var i=require("@serverless-devs/core/package.json").version,r=mc();return iE.gt(r,i)?require(_u):require("@serverless-devs/core")}return require("@serverless-devs/core")}function mc(){return _c.default.existsSync(_u)?require(vc).version:void 0}rn.getCoreVersion=mc;rn.default=uE()});var yc=$((gA,oE)=>{oE.exports={name:"@serverless-devs/s",version:"2.0.97-beta.1",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:{prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"npx jest",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:{"@types/jest":"^27.0.1","@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",commander:"^6.0.0",dotenv:"^10.0.0",esbuild:"^0.13.6",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.1.0","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.0.1","ts-node":"^9.1.1","tty-table":"^4.1.5",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},jest:{coverageDirectory:"coverage",testEnvironment:"node",coverageProvider:"v8",preset:"ts-jest",testMatch:["**/test/**/*test.[jt]s"],setupFilesAfterEnv:["./jest.setup.ts"]},dependencies:{"@serverless-devs/core":"beta"}}});var Ti=$(W=>{"use strict";var aE=W&&W.__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]}),lE=W&&W.__setModuleDefault||(Object.create?function(i,r){Object.defineProperty(i,"default",{enumerable:!0,value:r})}:function(i,r){i.default=r}),fE=W&&W.__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)&&aE(r,i,s);return lE(r,i),r},Ec=W&&W.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(_){_(a)})}return new(s||(s=Promise))(function(a,_){function y(A){try{p(o.next(A))}catch(R){_(R)}}function E(A){try{p(o.throw(A))}catch(R){_(R)}}function p(A){A.done?a(A.value):f(A.value).then(y,E)}p((o=o.apply(i,r||[])).next())})},wc=W&&W.__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,_;return _={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(_[Symbol.iterator]=function(){return this}),_;function y(p){return function(A){return E([p,A])}}function E(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(A){p=[6,A],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Ri=W&&W.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(W,"__esModule",{value:!0});W.emoji=W.mark=W.replaceTemplate=W.getTemplatekey=W.replaceFun=W.getLang=W.printn=W.checkTemplateFile=W.checkAndReturnTemplateFile=W.yamlLoad=W.getFolderSize=W.getVersion=W.bgRed=W.red=void 0;var ge=Ri(require("path")),Fe=Ri(require("fs")),vu=Ri(gl()),cE=Ri(require("os")),hE=Eu(),Ci=fE(Ot()),mu=Ci.default.colors,pE=Ci.default.jsyaml,bi=yc();W.red=mu.hex("#fd5750");W.bgRed=mu.hex("#000").bgHex("#fd5750");function dE(){return(0,Ci.getCoreVersion)()?bi.name+": "+bi.version+", @serverless-devs/core: "+(0,Ci.getCoreVersion)()+", "+process.platform+"-"+process.arch+", node-"+process.version:bi.name+": "+bi.version+", "+process.platform+"-"+process.arch+", node-"+process.version}W.getVersion=dE;function gE(i){return Ec(this,void 0,void 0,function(){function r(f){return Ec(this,void 0,void 0,function(){var a,_;return wc(this,function(y){switch(y.label){case 0:return a=Fe.default.lstatSync(f),typeof a!="object"?[2]:(s.set(a.ino,a.size),a.isDirectory()?(_=Fe.default.readdirSync(f),typeof _!="object"?[2]:[4,Promise.all(_.map(function(E){return r(ge.default.join(f,E))}))]):[3,2]);case 1:y.sent(),y.label=2;case 2:return[2]}})})}var s,o;return wc(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,_){return a+_},0),[2,o]}})})}W.getFolderSize=gE;function Ac(i){var r=Fe.default.readFileSync(i,"utf8");try{return pE.load(r)}catch{if(["-h","--help"].includes(process.argv[2]))return;var s=ge.default.basename(i);new hE.HumanError({errorMessage:s+" format is incorrect",tips:"Please check the configuration of "+s+", Serverless Devs' Yaml specification document can refer to\uFF1A"+mu.underline("https://github.com/Serverless-Devs/Serverless-Devs/blob/master/docs/zh/yaml.md")}),process.exit(1)}}W.yamlLoad=Ac;function yr(i,r){r===void 0&&(r=!1);var s=Fe.default.readFileSync(i,"utf8"),o=r?JSON.parse(s):Ac(i);if(!o)return!1;for(var f in o)if(o[f].Component&&o[f].Provider&&o[f].Properties)return!0;return o.hasOwnProperty("edition")}function xc(){if(process.env.serverless_devs_temp_template)return process.env.serverless_devs_temp_template;var i=process.cwd(),r=process.argv.includes("-t")?"-t":process.argv.includes("--template")?"--template":null,s=r?process.argv.indexOf(r):-1;if(s!==-1){var o=s+1,f=process.argv[o];if(f&&(f.endsWith(".yaml")||f.endsWith(".yml")||f.endsWith(".json"))){var a=!!f.endsWith(".json");if(Fe.default.existsSync(ge.default.join(i,f))&&yr(ge.default.join(i,f),a)){process.argv.splice(s,2);var _=JSON.parse(process.env.serverless_devs_temp_argv);return _.splice(_.indexOf(r),2),process.env.serverless_devs_temp_argv=JSON.stringify(_),process.env.serverless_devs_temp_template=ge.default.join(i,f),ge.default.join(i,f)}else if(Fe.default.existsSync(f)&&yr(f,a)){process.argv.splice(s,2);var _=JSON.parse(process.env.serverless_devs_temp_argv);return _.splice(_.indexOf(r),2),process.env.serverless_devs_temp_argv=JSON.stringify(_),process.env.serverless_devs_temp_template=f,f}}}return Fe.default.existsSync(ge.default.join(i,"s.yaml"))&&yr(ge.default.join(i,"s.yaml"))?(process.env.serverless_devs_temp_template=ge.default.join(i,"s.yaml"),ge.default.join(i,"s.yaml")):Fe.default.existsSync(ge.default.join(i,"s.yml"))&&yr(ge.default.join(i,"s.yml"))?(process.env.serverless_devs_temp_template=ge.default.join(i,"s.yml"),ge.default.join(i,"s.yml")):Fe.default.existsSync(ge.default.join(i,"s.json"))&&yr(ge.default.join(i,"s.json"),!0)?(process.env.serverless_devs_temp_template=ge.default.join(i,"s.json"),ge.default.join(i,"s.json")):null}W.checkAndReturnTemplateFile=xc;function Sc(i){return Fe.default.existsSync(i)?i:null}W.checkTemplateFile=Sc;function Oc(i,r){r===void 0&&(r=" ");for(var s="",o=0;o<i;o++)s=s+r;return s}W.printn=Oc;function Ic(){return"en"}W.getLang=Ic;function yu(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,""),_=vu.default.trim(a.split("|")[0]);r[_]&&(i=i.replace(o[f],r[_]))}return i}W.replaceFun=yu;function Rc(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:vu.default.trim(a[0]),desc:vu.default.trim(a[1])}}):[]}W.getTemplatekey=Rc;function Cc(i,r){i.forEach(function(s){if(Fe.default.existsSync(s)){var o=Fe.default.readFileSync(s,"utf-8"),f=yu(o,r);Fe.default.writeFileSync(s,f,"utf-8")}})}W.replaceTemplate=Cc;function bc(i){if(!i)return i;var r=i.slice(-4);return"***********"+r}W.mark=bc;function _E(i){return cE.default.platform()==="win32"?"":i}W.emoji=_E;W.default={checkAndReturnTemplateFile:xc,checkTemplateFile:Sc,printn:Oc,mark:bc,getLang:Ic,replaceTemplate:Cc,replaceFun:yu,getTemplatekey:Rc}});var Dc=$(It=>{"use strict";var Tc=It&&It.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(It,"__esModule",{value:!0});It.getHistoryFile=It.getHomeDir=void 0;var vE=Tc(require("path")),Lc=Tc(Ot()),Li=Lc.default.fse,mE=Lc.default.getRootHome;function wu(){var i=mE();return Li.existsSync(i)||Li.mkdirSync(i),i}It.getHomeDir=wu;function $c(){var i=vE.default.join(wu(),"history");return Li.existsSync(i)||Li.createFileSync(i),i}It.getHistoryFile=$c;It.default={getHomeDir:wu,getHistoryFile:$c}});var Wc=$(Ie=>{"use strict";var yE=Ie&&Ie.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(_){_(a)})}return new(s||(s=Promise))(function(a,_){function y(A){try{p(o.next(A))}catch(R){_(R)}}function E(A){try{p(o.throw(A))}catch(R){_(R)}}function p(A){A.done?a(A.value):f(A.value).then(y,E)}p((o=o.apply(i,r||[])).next())})},EE=Ie&&Ie.__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,_;return _={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(_[Symbol.iterator]=function(){return this}),_;function y(p){return function(A){return E([p,A])}}function E(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(A){p=[6,A],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},Au=Ie&&Ie.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Ie,"__esModule",{value:!0});Ie.handlerProfileFile=Ie.getConfig=Ie.setConfig=void 0;var Pc=Au(require("path")),wE=Au(Dc()),xu=Au(Ot()),ft=xu.default.fse,$i=xu.default.jsyaml,Nc=xu.default.getRootHome;function AE(i){var r=Fc();ft.writeFileSync(r,$i.dump(i))}function qc(){var i=Fc();if(!ft.existsSync(i))return{};try{var r=$i.load(ft.readFileSync(i,"utf8"))||{};return r}catch(s){throw s}}function Fc(){var i=Pc.default.join(wE.default.getHomeDir(),"set-config.yml");return ft.existsSync(i)||ft.createFileSync(i),i}function Mc(i,r){var s=qc();s[i]=r,AE(s)}Ie.setConfig=Mc;function Hc(i,r){var s=qc();return s[i]||r}Ie.getConfig=Hc;function Gc(i){return yE(this,void 0,void 0,function(){var r,s,o,f,a,_,y;return EE(this,function(E){switch(E.label){case 0:if(r=i.filePath||"set-config.yml",s=Pc.default.join(Nc(),r),o=ft.existsSync(s),f={},o)return[3,5];a=Nc(),E.label=1;case 1:return E.trys.push([1,2,,4]),ft.statSync(a),[3,4];case 2:return _=E.sent(),[4,ft.mkdirSync(a)];case 3:return E.sent(),[3,4];case 4:return[3,6];case 5:try{f=$i.load(ft.readFileSync(s,"utf8"))||{}}catch(p){throw p}E.label=6;case 6:return i.read?[2,f]:(y=i.configKey||"",f[y]=i.data,[4,ft.writeFileSync(s,$i.dump(f))]);case 7:return E.sent(),[2,f]}})})}Ie.handlerProfileFile=Gc;Ie.default={setConfig:Mc,getConfig:Hc,handlerProfileFile:Gc}});var sn=$(Cn=>{"use strict";var xE=Cn&&Cn.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Cn,"__esModule",{value:!0});Cn.ServerlessError=void 0;var SE=xE(Ot()),OE=SE.default.Logger,IE=new OE("S-CLI-ERROR"),RE=function(){function i(r,s,o){IE.error(r+": "+s,o),process.exit(1)}return i}();Cn.ServerlessError=RE});var Uc=$(bn=>{"use strict";var CE=bn&&bn.__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(bn,"__esModule",{value:!0});bn.CommandError=void 0;var bE=sn(),TE=function(i){CE(r,i);function r(s,o){return i.call(this,"Error",s,o)||this}return r}(bE.ServerlessError);bn.CommandError=TE});var Bc=$(Tn=>{"use strict";var LE=Tn&&Tn.__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(Tn,"__esModule",{value:!0});Tn.ConfigDeleteError=void 0;var $E=sn(),DE=function(i){LE(r,i);function r(s,o){return i.call(this,"Deletion failed",s,o)||this}return r}($E.ServerlessError);Tn.ConfigDeleteError=DE});var Kc=$(Ln=>{"use strict";var PE=Ln&&Ln.__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(Ln,"__esModule",{value:!0});Ln.ConfigError=void 0;var NE=sn(),qE=function(i){PE(r,i);function r(s,o){return i.call(this,"Config failed",s,o)||this}return r}(NE.ServerlessError);Ln.ConfigError=qE});var Xc=$($n=>{"use strict";var FE=$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.ConfigGetError=void 0;var ME=sn(),HE=function(i){FE(r,i);function r(s,o){return i.call(this,"Get failed",s,o)||this}return r}(ME.ServerlessError);$n.ConfigGetError=HE});var jc=$(Dn=>{"use strict";var GE=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.InitError=void 0;var WE=sn(),UE=function(i){GE(r,i);function r(s,o){return i.call(this,"Initialization failed",s,o)||this}return r}(WE.ServerlessError);Dn.InitError=UE});var zc=$(ct=>{"use strict";var BE=ct&&ct.__awaiter||function(i,r,s,o){function f(a){return a instanceof s?a:new s(function(_){_(a)})}return new(s||(s=Promise))(function(a,_){function y(A){try{p(o.next(A))}catch(R){_(R)}}function E(A){try{p(o.throw(A))}catch(R){_(R)}}function p(A){A.done?a(A.value):f(A.value).then(y,E)}p((o=o.apply(i,r||[])).next())})},KE=ct&&ct.__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,_;return _={next:y(0),throw:y(1),return:y(2)},typeof Symbol=="function"&&(_[Symbol.iterator]=function(){return this}),_;function y(p){return function(A){return E([p,A])}}function E(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(A){p=[6,A],f=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:!0}}},XE=ct&&ct.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(ct,"__esModule",{value:!0});ct.HumanError=void 0;var kc=XE(Ot()),jE=Ti(),kE=kc.default.colors,zE=function(){function i(r){var s=r.errorMessage,o=r.tips;this.errorMessage=s,console.log(`
|
|
35
35
|
`+(0,jE.bgRed)("ERROR:")),console.log("TypeError: "+s+`
|
|
36
36
|
`),console.log(kE.gray(o)+`
|
|
37
37
|
`)}return i.prototype.report=function(r){return BE(this,void 0,void 0,function(){var s;return KE(this,function(o){switch(o.label){case 0:return s=r.error,[4,kc.default.report({type:"jsError",content:this.errorMessage+"||"+s.stack})];case 1:return o.sent(),[2]}})})},i}();ct.HumanError=zE});var Yc=$(Pn=>{"use strict";var VE=Pn&&Pn.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Pn,"__esModule",{value:!0});Pn.HumanWarning=void 0;var YE=VE(Ot()),Vc=YE.default.colors,ZE=function(){function i(r){var s=r.warningMessage,o=r.tips;console.log(`
|