From d927006cfb356c7fc25f3889e1bdef182fcfe224 Mon Sep 17 00:00:00 2001 From: Nikita Elfimov Date: Mon, 18 Nov 2024 11:37:36 +0300 Subject: [PATCH] fix(essentials): short naming --- README.md | 2 +- README_RU.md | 2 +- yarn/cli/dist/yarn.mjs | 4 ++-- .../plugin-essentials/sources/commands/set-version.command.ts | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 6f3f0015..6ce75ad8 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ First time: Upgrade already installed bundle: -- `yarn set version atlantis` - updates bundle to latest version and updates `@atls/code-runtime` dependency to latest +- `yarn set version atls` - updates bundle to latest version and updates `@atls/code-runtime` dependency to latest ## Commonly used scrips `yarn` diff --git a/README_RU.md b/README_RU.md index ca62436f..dc4dc0c0 100644 --- a/README_RU.md +++ b/README_RU.md @@ -24,7 +24,7 @@ Обновление бандла в уже установленном проекте: -- `yarn set version atlantis` - обновление бандла и обновление `@atls/code-runtime` до последней версии +- `yarn set version atls` - обновление бандла и обновление `@atls/code-runtime` до последней версии ## Основные скрипты `yarn` для нашей работы diff --git a/yarn/cli/dist/yarn.mjs b/yarn/cli/dist/yarn.mjs index e1576d6f..37e6714f 100755 --- a/yarn/cli/dist/yarn.mjs +++ b/yarn/cli/dist/yarn.mjs @@ -191,7 +191,7 @@ Please report this to https://github.com/szmarczak/http2-wrapper/`);x(J)}return} `),_e.end()}),_e});break;case"<&":x(()=>F7r(Number(e[ce]),zN.Readable,r));break;case">":case">>":{let _e=aj.ppath.resolve(r.cwd,aj.npath.toPortablePath(e[ce]));J(_e==="/dev/null"?new p5.Writable({autoDestroy:!0,emitClose:!0,write(me,Ee,ge){setImmediate(ge)}}):t.baseFs.createWriteStream(_e,b===">>"?{flags:"a"}:void 0))}break;case">&":J(F7r(Number(e[ce]),zN.Writable,r));break;default:throw new Error(`Assertion failed: Unsupported redirection type: "${b}"`)}}if(f.length>0){let w=new p5.PassThrough;s=w;let b=U=>{if(U===f.length)w.end();else{let x=f[U]();x.pipe(w,{end:!1}),x.on("end",()=>{b(U+1)})}};b(0)}if(A.length>0){let w=new p5.PassThrough;c=w;for(let b of A)w.pipe(b)}if(h.length>0){let w=new p5.PassThrough;o=w;for(let b of h)w.pipe(b)}let T=await(0,nB.start)(VNe(e.slice(y+1),t,r),{stdin:new nB.ProtectedStream(s),stdout:new nB.ProtectedStream(c),stderr:new nB.ProtectedStream(o)}).run();return await Promise.all(A.map(w=>new Promise((b,U)=>{w.on("error",x=>{U(x)}),w.on("close",()=>{b()}),w.end()}))),await Promise.all(h.map(w=>new Promise((b,U)=>{w.on("error",x=>{U(x)}),w.on("close",()=>{b()}),w.end()}))),T}]]);async function Als(e,t,r){let s=[],c=new p5.PassThrough;return c.on("data",o=>s.push(o)),await Lze(e,t,Fze(r,{stdout:c})),Buffer.concat(s).toString().replace(/[\r\n]+$/,"")}async function L7r(e,t,r){let s=e.map(async o=>{let f=await Uae(o.args,t,r);return{name:o.name,value:f.join(" ")}});return(await Promise.all(s)).reduce((o,f)=>(o[f.name]=f.value,o),{})}function Oze(e){return e.match(/[^ \r\n\t]+/g)||[]}async function G7r(e,t,r,s,c=s){switch(e.name){case"$":s(String(process.pid));break;case"#":s(String(t.args.length));break;case"@":if(e.quoted)for(let o of t.args)c(o);else for(let o of t.args){let f=Oze(o);for(let A=0;A=0&&o"u"&&(e.defaultValue?f=(await Uae(e.defaultValue,t,r)).join(" "):e.alternativeValue&&(f="")),typeof f>"u")throw A?new cj.ShellError(`Unbound argument #${o}`):new cj.ShellError(`Unbound variable "${e.name}"`);if(e.quoted)s(f);else{let h=Oze(f);for(let T=0;Te+t,subtraction:(e,t)=>e-t,multiplication:(e,t)=>e*t,division:(e,t)=>Math.trunc(e/t)};async function JNe(e,t,r){if(e.type==="number"){if(Number.isInteger(e.value))return e.value;throw new Error(`Invalid number: "${e.value}", only integers are allowed`)}else if(e.type==="variable"){let s=[];await G7r({...e,quoted:!0},t,r,o=>s.push(o));let c=Number(s.join(" "));return Number.isNaN(c)?JNe({type:"variable",name:s.join(" ")},t,r):JNe({type:"number",value:c},t,r)}else return hls[e.type](await JNe(e.left,t,r),await JNe(e.right,t,r))}async function Uae(e,t,r){let s=new Map,c=[],o=[],f=T=>{o.push(T)},A=()=>{o.length>0&&c.push(o.join("")),o=[]},h=T=>{f(T),A()},y=(T,w,b)=>{let U=JSON.stringify({type:T,fd:w}),x=s.get(U);typeof x>"u"&&s.set(U,x=[]),x.push(b)};for(let T of e){let w=!1;switch(T.type){case"redirection":{let b=await Uae(T.args,t,r);for(let U of b)y(T.subtype,T.fd,U)}break;case"argument":for(let b of T.segments)switch(b.type){case"text":f(b.text);break;case"glob":f(b.pattern),w=!0;break;case"shell":{let U=await Als(b.shell,t,r);if(b.quoted)f(U);else{let x=Oze(U);for(let J=0;J"u")throw new Error("Assertion failed: Expected a glob pattern to have been set");let U=await t.glob.match(b,{cwd:r.cwd,baseFs:t.baseFs});if(U.length===0){let x=Zkt.isBraceExpansion(b)?". Note: Brace expansion of arbitrary strings isn't currently supported. For more details, please read this issue: https://github.com/yarnpkg/berry/issues/22":"";throw new cj.ShellError(`No matches found: "${b}"${x}`)}for(let x of U.sort())h(x)}}if(s.size>0){let T=[];for(let[w,b]of s.entries())T.splice(T.length,0,w,String(b.length),...b);c.splice(0,0,"__ysh_set_redirects",...T,"--")}return c}function VNe(e,t,r){t.builtins.has(e[0])||(e=["command",...e]);let s=aj.npath.fromPortablePath(r.cwd),c=r.environment;typeof c.PWD<"u"&&(c={...c,PWD:s});let[o,...f]=e;if(o==="command")return(0,zkt.makeProcess)(f[0],f.slice(1),t,{cwd:s,env:c});let A=t.builtins.get(o);if(typeof A>"u")throw new Error(`Assertion failed: A builtin should exist for "${o}"`);return(0,zkt.makeBuiltin)(async({stdin:h,stdout:y,stderr:T})=>{let{stdin:w,stdout:b,stderr:U}=r;r.stdin=h,r.stdout=y,r.stderr=T;try{return await A(f,t,r)}finally{r.stdin=w,r.stdout=b,r.stderr=U}})}function mls(e,t,r){return s=>{let c=new p5.PassThrough,o=Lze(e,t,Fze(r,{stdin:c}));return{stdin:c,promise:o}}}function gls(e,t,r){return s=>{let c=new p5.PassThrough,o=Lze(e,t,r);return{stdin:c,promise:o}}}function Q7r(e,t,r,s){if(t.length===0)return e;{let c;do c=String(Math.random());while(Object.hasOwn(s.procedures,c));return s.procedures={...s.procedures},s.procedures[c]=e,VNe([...t,"__ysh_run_procedure",c],r,s)}}async function M7r(e,t,r){let s=e,c=null,o=null;for(;s;){let f=s.then?{...r}:r,A;switch(s.type){case"command":{let h=await Uae(s.args,t,r),y=await L7r(s.envs,t,r);A=s.envs.length?VNe(h,t,Fze(f,{environment:y})):VNe(h,t,f)}break;case"subshell":{let h=await Uae(s.args,t,r),y=mls(s.subshell,t,f);A=Q7r(y,h,t,f)}break;case"group":{let h=await Uae(s.args,t,r),y=gls(s.group,t,f);A=Q7r(y,h,t,f)}break;case"envs":{let h=await L7r(s.envs,t,r);f.environment={...f.environment,...h},A=VNe(["true"],t,f)}break}if(typeof A>"u")throw new Error("Assertion failed: An action should have been generated");if(c===null)o=(0,nB.start)(A,{stdin:new nB.ProtectedStream(f.stdin),stdout:new nB.ProtectedStream(f.stdout),stderr:new nB.ProtectedStream(f.stderr)});else{if(o===null)throw new Error("Assertion failed: The execution pipeline should have been setup");switch(c){case"|":o=o.pipeTo(A,nB.Pipe.STDOUT);break;case"|&":o=o.pipeTo(A,nB.Pipe.STDOUT|nB.Pipe.STDERR);break}}s.then?(c=s.then.type,s=s.then.chain):s=null}if(o===null)throw new Error("Assertion failed: The execution pipeline should have been setup");return await o.run()}async function Els(e,t,r,{background:s=!1}={}){function c(o){let f=["#2E86AB","#A23B72","#F18F01","#C73E1D","#CCE2A3"],A=f[o%f.length];return uls.default.hex(A)}if(s){let o=r.nextBackgroundJobIndex++,f=c(o),A=`[${o}]`,h=f(A),{stdout:y,stderr:T}=(0,zkt.createOutputStreamsWithPrefix)(r,{prefix:h});return r.backgroundJobs.push(M7r(e,t,Fze(r,{stdout:y,stderr:T})).catch(w=>T.write(`${w.message} `)).finally(()=>{r.stdout.isTTY&&r.stdout.write(`Job ${h}, '${f((0,U7r.stringifyCommandChain)(e))}' has ended `)})),0}return await M7r(e,t,r)}async function yls(e,t,r,{background:s=!1}={}){let c,o=A=>{c=A,r.variables["?"]=String(A)},f=async A=>{try{return await Els(A.chain,t,r,{background:s&&typeof A.then>"u"})}catch(h){if(!(h instanceof cj.ShellError))throw h;return r.stderr.write(`${h.message} -`),1}};for(o(await f(e));e.then;){if(r.exitCode!==null)return r.exitCode;switch(e.then.type){case"&&":c===0&&o(await f(e.then.line));break;case"||":c!==0&&o(await f(e.then.line));break;default:throw new Error(`Assertion failed: Unsupported command type: "${e.then.type}"`)}e=e.then.line}return c}async function Lze(e,t,r){let s=r.backgroundJobs;r.backgroundJobs=[];let c=0;for(let{command:o,type:f}of e){if(c=await yls(o,t,r,{background:f==="&"}),r.exitCode!==null)return r.exitCode;r.variables["?"]=String(c)}return await Promise.all(r.backgroundJobs),r.backgroundJobs=s,c}function j7r(e){switch(e.type){case"variable":return e.name==="@"||e.name==="#"||e.name==="*"||Number.isFinite(parseInt(e.name,10))||"defaultValue"in e&&!!e.defaultValue&&e.defaultValue.some(t=>WNe(t))||"alternativeValue"in e&&!!e.alternativeValue&&e.alternativeValue.some(t=>WNe(t));case"arithmetic":return Kkt(e.arithmetic);case"shell":return $kt(e.shell);default:return!1}}function WNe(e){switch(e.type){case"redirection":return e.args.some(t=>WNe(t));case"argument":return e.segments.some(t=>j7r(t));default:throw new Error(`Assertion failed: Unsupported argument type: "${e.type}"`)}}function Kkt(e){switch(e.type){case"variable":return j7r(e);case"number":return!1;default:return Kkt(e.left)||Kkt(e.right)}}function $kt(e){return e.some(({command:t})=>{for(;t;){let r=t.chain;for(;r;){let s;switch(r.type){case"subshell":s=$kt(r.subshell);break;case"command":s=r.envs.some(c=>c.args.some(o=>WNe(o)))||r.args.some(c=>WNe(c));break}if(s)return!0;if(!r.then)break;r=r.then.chain}if(!t.then)break;t=t.then.line}return!1})}async function Cls(e,t=[],{baseFs:r=new aj.NodeFS,builtins:s={},cwd:c=aj.npath.toPortablePath(process.cwd()),env:o=process.env,stdin:f=process.stdin,stdout:A=process.stdout,stderr:h=process.stderr,variables:y={},glob:T=Zkt}={}){let w={};for(let[x,J]of Object.entries(o))typeof J<"u"&&(w[x]=J);let b=new Map(_ls);for(let[x,J]of Object.entries(s))b.set(x,J);f===null&&(f=new p5.PassThrough,f.end());let U=(0,U7r.parseShell)(e,T);if(!$kt(U)&&U.length>0&&t.length>0){let{command:x}=U[U.length-1];for(;x.then;)x=x.then.line;let J=x.chain;for(;J.then;)J=J.then.chain;J.type==="command"&&(J.args=J.args.concat(t.map(Z=>({type:"argument",segments:[{type:"text",text:Z}]}))))}return await Lze(U,{args:t,baseFs:r,builtins:b,initialStdin:f,initialStdout:A,initialStderr:h,glob:T},{cwd:c,environment:w,exitCode:null,procedures:{},stdin:f,stdout:A,stderr:h,variables:Object.assign({},y,{"?":0}),nextBackgroundJobIndex:1,backgroundJobs:[]})}});var ePt=fe((iDa,H7r)=>{function Ils(e,t){for(var r=-1,s=e==null?0:e.length,c=Array(s);++r{var q7r=Cae(),Tls=ePt(),Sls=i5(),vls=TNe(),Dls=1/0,J7r=q7r?q7r.prototype:void 0,V7r=J7r?J7r.toString:void 0;function W7r(e){if(typeof e=="string")return e;if(Sls(e))return Tls(e,W7r)+"";if(vls(e))return V7r?V7r.call(e):"";var t=e+"";return t=="0"&&1/e==-Dls?"-0":t}Y7r.exports=W7r});var Qze=fe((oDa,K7r)=>{var bls=z7r();function wls(e){return e==null?"":bls(e)}K7r.exports=wls});var tPt=fe((aDa,X7r)=>{function Bls(e,t,r){var s=-1,c=e.length;t<0&&(t=-t>c?0:c+t),r=r>c?c:r,r<0&&(r+=c),c=t>r?0:r-t>>>0,t>>>=0;for(var o=Array(c);++s{var xls=tPt();function Nls(e,t,r){var s=e.length;return r=r===void 0?s:r,!t&&r>=s?e:xls(e,t,r)}Z7r.exports=Nls});var rPt=fe((lDa,e9r)=>{var Rls="\\ud800-\\udfff",kls="\\u0300-\\u036f",Pls="\\ufe20-\\ufe2f",Ols="\\u20d0-\\u20ff",Fls=kls+Pls+Ols,Lls="\\ufe0e\\ufe0f",Qls="\\u200d",Mls=RegExp("["+Qls+Rls+Fls+Lls+"]");function Uls(e){return Mls.test(e)}e9r.exports=Uls});var r9r=fe((uDa,t9r)=>{function Gls(e){return e.split("")}t9r.exports=Gls});var u9r=fe((fDa,l9r)=>{var n9r="\\ud800-\\udfff",jls="\\u0300-\\u036f",Hls="\\ufe20-\\ufe2f",qls="\\u20d0-\\u20ff",Jls=jls+Hls+qls,Vls="\\ufe0e\\ufe0f",Wls="["+n9r+"]",nPt="["+Jls+"]",iPt="\\ud83c[\\udffb-\\udfff]",Yls="(?:"+nPt+"|"+iPt+")",i9r="[^"+n9r+"]",s9r="(?:\\ud83c[\\udde6-\\uddff]){2}",o9r="[\\ud800-\\udbff][\\udc00-\\udfff]",zls="\\u200d",a9r=Yls+"?",c9r="["+Vls+"]?",Kls="(?:"+zls+"(?:"+[i9r,s9r,o9r].join("|")+")"+c9r+a9r+")*",Xls=c9r+a9r+Kls,Zls="(?:"+[i9r+nPt+"?",nPt,s9r,o9r,Wls].join("|")+")",$ls=RegExp(iPt+"(?="+iPt+")|"+Zls+Xls,"g");function eus(e){return e.match($ls)||[]}l9r.exports=eus});var p9r=fe((pDa,f9r)=>{var tus=r9r(),rus=rPt(),nus=u9r();function ius(e){return rus(e)?nus(e):tus(e)}f9r.exports=ius});var _9r=fe((dDa,d9r)=>{var sus=$7r(),ous=rPt(),aus=p9r(),cus=Qze();function lus(e){return function(t){t=cus(t);var r=ous(t)?aus(t):void 0,s=r?r[0]:t.charAt(0),c=r?sus(r,1).join(""):t.slice(1);return s[e]()+c}}d9r.exports=lus});var h9r=fe((_Da,A9r)=>{var uus=_9r(),fus=uus("toUpperCase");A9r.exports=fus});var sPt=fe((ADa,m9r)=>{var pus=Qze(),dus=h9r();function _us(e){return dus(pus(e).toLowerCase())}m9r.exports=_us});var g9r=fe((hDa,Mze)=>{function Aus(){var e=0,t=1,r=2,s=3,c=4,o=5,f=6,A=7,h=8,y=9,T=10,w=11,b=12,U=13,x=14,J=15,Z=16,le=17,ce=0,_e=1,me=2,Ee=3,ge=4;function Ie(k,dt){return 55296<=k.charCodeAt(dt)&&k.charCodeAt(dt)<=56319&&56320<=k.charCodeAt(dt+1)&&k.charCodeAt(dt+1)<=57343}function De(k,dt){dt===void 0&&(dt=0);var _t=k.charCodeAt(dt);if(55296<=_t&&_t<=56319&&dt=1){var It=k.charCodeAt(dt-1),lt=_t;return 55296<=It&&It<=56319?(It-55296)*1024+(lt-56320)+65536:lt}return _t}function He(k,dt,_t){var It=[k].concat(dt).concat([_t]),lt=It[It.length-2],wt=_t,Vt=It.lastIndexOf(x);if(Vt>1&&It.slice(1,Vt).every(function(tr){return tr==s})&&[s,U,le].indexOf(k)==-1)return me;var Br=It.lastIndexOf(c);if(Br>0&&It.slice(1,Br).every(function(tr){return tr==c})&&[b,c].indexOf(lt)==-1)return It.filter(function(tr){return tr==c}).length%2==1?Ee:ge;if(lt==e&&wt==t)return ce;if(lt==r||lt==e||lt==t)return wt==x&&dt.every(function(tr){return tr==s})?me:_e;if(wt==r||wt==e||wt==t)return _e;if(lt==f&&(wt==f||wt==A||wt==y||wt==T))return ce;if((lt==y||lt==A)&&(wt==A||wt==h))return ce;if((lt==T||lt==h)&&wt==h)return ce;if(wt==s||wt==J)return ce;if(wt==o)return ce;if(lt==b)return ce;var En=It.indexOf(s)!=-1?It.lastIndexOf(s)-1:It.length-2;return[U,le].indexOf(It[En])!=-1&&It.slice(En+1,-1).every(function(tr){return tr==s})&&wt==x||lt==J&&[Z,le].indexOf(wt)!=-1?ce:dt.indexOf(c)!=-1?me:lt==c&&wt==c?ce:_e}this.nextBreak=function(k,dt){if(dt===void 0&&(dt=0),dt<0)return 0;if(dt>=k.length-1)return k.length;for(var _t=Xe(De(k,dt)),It=[],lt=dt+1;lt{var hus=/^(.*?)(\x1b\[[^m]+m|\x1b\]8;;.*?(\x1b\\|\u0007))/,Uze;function mus(){if(Uze)return Uze;if(typeof Intl.Segmenter<"u"){let e=new Intl.Segmenter("en",{granularity:"grapheme"});return Uze=t=>Array.from(e.segment(t),({segment:r})=>r)}else{let e=g9r(),t=new e;return Uze=r=>t.splitGraphemes(r)}}E9r.exports=(e,t=0,r=e.length)=>{if(t<0||r<0)throw new RangeError("Negative indices aren't supported by this implementation");let s=r-t,c="",o=0,f=0;for(;e.length>0;){let A=e.match(hus)||[e,e,void 0],h=mus()(A[1]),y=Math.min(t-o,h.length);h=h.slice(y);let T=Math.min(s-f,h.length);c+=h.slice(0,T).join(""),o+=y,f+=T,typeof A[2]<"u"&&(c+=A[2]),e=e.slice(A[0].length)}return c}});var YNe=fe(Gze=>{"use strict";Object.defineProperty(Gze,"__esModule",{value:!0});Gze.YarnVersion=void 0;Gze.YarnVersion=process.env.YARN_IS_TEST_ENV?"0.0.0":"1.0.0-git.20241118.hash-18af13f3"});var zNe=fe(x4=>{"use strict";Object.defineProperty(x4,"__esModule",{value:!0});x4.StreamReport=x4.SUPPORTS_GROUPS=x4.SINGLE_LINE_CHAR=void 0;x4.formatName=cPt;x4.formatNameWithHyperlink=S9r;x4.reportOptionDeprecations=Sus;var aPt=(Qa(),pi(La)),gus=aPt.__importDefault(y9r()),oPt=aPt.__importDefault(Aae()),lj=KO(),Eus=I4(),yus=YNe(),d5=aPt.__importStar(E4());x4.SINGLE_LINE_CHAR="\xB7";var C9r=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],I9r=80,Z$=oPt.default.GITHUB_ACTIONS?{start:e=>`::group::${e} +`),1}};for(o(await f(e));e.then;){if(r.exitCode!==null)return r.exitCode;switch(e.then.type){case"&&":c===0&&o(await f(e.then.line));break;case"||":c!==0&&o(await f(e.then.line));break;default:throw new Error(`Assertion failed: Unsupported command type: "${e.then.type}"`)}e=e.then.line}return c}async function Lze(e,t,r){let s=r.backgroundJobs;r.backgroundJobs=[];let c=0;for(let{command:o,type:f}of e){if(c=await yls(o,t,r,{background:f==="&"}),r.exitCode!==null)return r.exitCode;r.variables["?"]=String(c)}return await Promise.all(r.backgroundJobs),r.backgroundJobs=s,c}function j7r(e){switch(e.type){case"variable":return e.name==="@"||e.name==="#"||e.name==="*"||Number.isFinite(parseInt(e.name,10))||"defaultValue"in e&&!!e.defaultValue&&e.defaultValue.some(t=>WNe(t))||"alternativeValue"in e&&!!e.alternativeValue&&e.alternativeValue.some(t=>WNe(t));case"arithmetic":return Kkt(e.arithmetic);case"shell":return $kt(e.shell);default:return!1}}function WNe(e){switch(e.type){case"redirection":return e.args.some(t=>WNe(t));case"argument":return e.segments.some(t=>j7r(t));default:throw new Error(`Assertion failed: Unsupported argument type: "${e.type}"`)}}function Kkt(e){switch(e.type){case"variable":return j7r(e);case"number":return!1;default:return Kkt(e.left)||Kkt(e.right)}}function $kt(e){return e.some(({command:t})=>{for(;t;){let r=t.chain;for(;r;){let s;switch(r.type){case"subshell":s=$kt(r.subshell);break;case"command":s=r.envs.some(c=>c.args.some(o=>WNe(o)))||r.args.some(c=>WNe(c));break}if(s)return!0;if(!r.then)break;r=r.then.chain}if(!t.then)break;t=t.then.line}return!1})}async function Cls(e,t=[],{baseFs:r=new aj.NodeFS,builtins:s={},cwd:c=aj.npath.toPortablePath(process.cwd()),env:o=process.env,stdin:f=process.stdin,stdout:A=process.stdout,stderr:h=process.stderr,variables:y={},glob:T=Zkt}={}){let w={};for(let[x,J]of Object.entries(o))typeof J<"u"&&(w[x]=J);let b=new Map(_ls);for(let[x,J]of Object.entries(s))b.set(x,J);f===null&&(f=new p5.PassThrough,f.end());let U=(0,U7r.parseShell)(e,T);if(!$kt(U)&&U.length>0&&t.length>0){let{command:x}=U[U.length-1];for(;x.then;)x=x.then.line;let J=x.chain;for(;J.then;)J=J.then.chain;J.type==="command"&&(J.args=J.args.concat(t.map(Z=>({type:"argument",segments:[{type:"text",text:Z}]}))))}return await Lze(U,{args:t,baseFs:r,builtins:b,initialStdin:f,initialStdout:A,initialStderr:h,glob:T},{cwd:c,environment:w,exitCode:null,procedures:{},stdin:f,stdout:A,stderr:h,variables:Object.assign({},y,{"?":0}),nextBackgroundJobIndex:1,backgroundJobs:[]})}});var ePt=fe((iDa,H7r)=>{function Ils(e,t){for(var r=-1,s=e==null?0:e.length,c=Array(s);++r{var q7r=Cae(),Tls=ePt(),Sls=i5(),vls=TNe(),Dls=1/0,J7r=q7r?q7r.prototype:void 0,V7r=J7r?J7r.toString:void 0;function W7r(e){if(typeof e=="string")return e;if(Sls(e))return Tls(e,W7r)+"";if(vls(e))return V7r?V7r.call(e):"";var t=e+"";return t=="0"&&1/e==-Dls?"-0":t}Y7r.exports=W7r});var Qze=fe((oDa,K7r)=>{var bls=z7r();function wls(e){return e==null?"":bls(e)}K7r.exports=wls});var tPt=fe((aDa,X7r)=>{function Bls(e,t,r){var s=-1,c=e.length;t<0&&(t=-t>c?0:c+t),r=r>c?c:r,r<0&&(r+=c),c=t>r?0:r-t>>>0,t>>>=0;for(var o=Array(c);++s{var xls=tPt();function Nls(e,t,r){var s=e.length;return r=r===void 0?s:r,!t&&r>=s?e:xls(e,t,r)}Z7r.exports=Nls});var rPt=fe((lDa,e9r)=>{var Rls="\\ud800-\\udfff",kls="\\u0300-\\u036f",Pls="\\ufe20-\\ufe2f",Ols="\\u20d0-\\u20ff",Fls=kls+Pls+Ols,Lls="\\ufe0e\\ufe0f",Qls="\\u200d",Mls=RegExp("["+Qls+Rls+Fls+Lls+"]");function Uls(e){return Mls.test(e)}e9r.exports=Uls});var r9r=fe((uDa,t9r)=>{function Gls(e){return e.split("")}t9r.exports=Gls});var u9r=fe((fDa,l9r)=>{var n9r="\\ud800-\\udfff",jls="\\u0300-\\u036f",Hls="\\ufe20-\\ufe2f",qls="\\u20d0-\\u20ff",Jls=jls+Hls+qls,Vls="\\ufe0e\\ufe0f",Wls="["+n9r+"]",nPt="["+Jls+"]",iPt="\\ud83c[\\udffb-\\udfff]",Yls="(?:"+nPt+"|"+iPt+")",i9r="[^"+n9r+"]",s9r="(?:\\ud83c[\\udde6-\\uddff]){2}",o9r="[\\ud800-\\udbff][\\udc00-\\udfff]",zls="\\u200d",a9r=Yls+"?",c9r="["+Vls+"]?",Kls="(?:"+zls+"(?:"+[i9r,s9r,o9r].join("|")+")"+c9r+a9r+")*",Xls=c9r+a9r+Kls,Zls="(?:"+[i9r+nPt+"?",nPt,s9r,o9r,Wls].join("|")+")",$ls=RegExp(iPt+"(?="+iPt+")|"+Zls+Xls,"g");function eus(e){return e.match($ls)||[]}l9r.exports=eus});var p9r=fe((pDa,f9r)=>{var tus=r9r(),rus=rPt(),nus=u9r();function ius(e){return rus(e)?nus(e):tus(e)}f9r.exports=ius});var _9r=fe((dDa,d9r)=>{var sus=$7r(),ous=rPt(),aus=p9r(),cus=Qze();function lus(e){return function(t){t=cus(t);var r=ous(t)?aus(t):void 0,s=r?r[0]:t.charAt(0),c=r?sus(r,1).join(""):t.slice(1);return s[e]()+c}}d9r.exports=lus});var h9r=fe((_Da,A9r)=>{var uus=_9r(),fus=uus("toUpperCase");A9r.exports=fus});var sPt=fe((ADa,m9r)=>{var pus=Qze(),dus=h9r();function _us(e){return dus(pus(e).toLowerCase())}m9r.exports=_us});var g9r=fe((hDa,Mze)=>{function Aus(){var e=0,t=1,r=2,s=3,c=4,o=5,f=6,A=7,h=8,y=9,T=10,w=11,b=12,U=13,x=14,J=15,Z=16,le=17,ce=0,_e=1,me=2,Ee=3,ge=4;function Ie(k,dt){return 55296<=k.charCodeAt(dt)&&k.charCodeAt(dt)<=56319&&56320<=k.charCodeAt(dt+1)&&k.charCodeAt(dt+1)<=57343}function De(k,dt){dt===void 0&&(dt=0);var _t=k.charCodeAt(dt);if(55296<=_t&&_t<=56319&&dt=1){var It=k.charCodeAt(dt-1),lt=_t;return 55296<=It&&It<=56319?(It-55296)*1024+(lt-56320)+65536:lt}return _t}function He(k,dt,_t){var It=[k].concat(dt).concat([_t]),lt=It[It.length-2],wt=_t,Vt=It.lastIndexOf(x);if(Vt>1&&It.slice(1,Vt).every(function(tr){return tr==s})&&[s,U,le].indexOf(k)==-1)return me;var Br=It.lastIndexOf(c);if(Br>0&&It.slice(1,Br).every(function(tr){return tr==c})&&[b,c].indexOf(lt)==-1)return It.filter(function(tr){return tr==c}).length%2==1?Ee:ge;if(lt==e&&wt==t)return ce;if(lt==r||lt==e||lt==t)return wt==x&&dt.every(function(tr){return tr==s})?me:_e;if(wt==r||wt==e||wt==t)return _e;if(lt==f&&(wt==f||wt==A||wt==y||wt==T))return ce;if((lt==y||lt==A)&&(wt==A||wt==h))return ce;if((lt==T||lt==h)&&wt==h)return ce;if(wt==s||wt==J)return ce;if(wt==o)return ce;if(lt==b)return ce;var En=It.indexOf(s)!=-1?It.lastIndexOf(s)-1:It.length-2;return[U,le].indexOf(It[En])!=-1&&It.slice(En+1,-1).every(function(tr){return tr==s})&&wt==x||lt==J&&[Z,le].indexOf(wt)!=-1?ce:dt.indexOf(c)!=-1?me:lt==c&&wt==c?ce:_e}this.nextBreak=function(k,dt){if(dt===void 0&&(dt=0),dt<0)return 0;if(dt>=k.length-1)return k.length;for(var _t=Xe(De(k,dt)),It=[],lt=dt+1;lt{var hus=/^(.*?)(\x1b\[[^m]+m|\x1b\]8;;.*?(\x1b\\|\u0007))/,Uze;function mus(){if(Uze)return Uze;if(typeof Intl.Segmenter<"u"){let e=new Intl.Segmenter("en",{granularity:"grapheme"});return Uze=t=>Array.from(e.segment(t),({segment:r})=>r)}else{let e=g9r(),t=new e;return Uze=r=>t.splitGraphemes(r)}}E9r.exports=(e,t=0,r=e.length)=>{if(t<0||r<0)throw new RangeError("Negative indices aren't supported by this implementation");let s=r-t,c="",o=0,f=0;for(;e.length>0;){let A=e.match(hus)||[e,e,void 0],h=mus()(A[1]),y=Math.min(t-o,h.length);h=h.slice(y);let T=Math.min(s-f,h.length);c+=h.slice(0,T).join(""),o+=y,f+=T,typeof A[2]<"u"&&(c+=A[2]),e=e.slice(A[0].length)}return c}});var YNe=fe(Gze=>{"use strict";Object.defineProperty(Gze,"__esModule",{value:!0});Gze.YarnVersion=void 0;Gze.YarnVersion=process.env.YARN_IS_TEST_ENV?"0.0.0":"1.0.0-git.20241118.hash-dba888b6"});var zNe=fe(x4=>{"use strict";Object.defineProperty(x4,"__esModule",{value:!0});x4.StreamReport=x4.SUPPORTS_GROUPS=x4.SINGLE_LINE_CHAR=void 0;x4.formatName=cPt;x4.formatNameWithHyperlink=S9r;x4.reportOptionDeprecations=Sus;var aPt=(Qa(),pi(La)),gus=aPt.__importDefault(y9r()),oPt=aPt.__importDefault(Aae()),lj=KO(),Eus=I4(),yus=YNe(),d5=aPt.__importStar(E4());x4.SINGLE_LINE_CHAR="\xB7";var C9r=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],I9r=80,Z$=oPt.default.GITHUB_ACTIONS?{start:e=>`::group::${e} `,end:e=>`::endgroup:: `}:oPt.default.TRAVIS?{start:e=>`travis_fold:start:${e} `,end:e=>`travis_fold:end:${e} @@ -1573,7 +1573,7 @@ See https://github.com/okonet/lint-staged#configuration.`;var rjt=(e={},t)=>{if( ${f6} ${e} failed without output (${A}).`);r.quiet||r.output.push(h)}},OZs=async e=>{try{let t=await(0,KCn.default)(e.pid);for(let r of t)try{process.kill(r)}catch(s){gFe('Failed to kill process with pid "%d": %o',r,s)}}catch(t){gFe('Failed to kill process with pid "%d": %o',e.pid,t)}e.kill()},FZs=(e,t)=>{let r,s=async()=>{r=OZs(t),await r};return e.events.on(Ajt,s,{once:!0}),async()=>{e.events.off(Ajt,s),await r}},LZs=(e,t,r)=>{r.errors.add(Sle),r.events.emit(Ajt,Sle),ZCn(e,t,r,!0);let s=XCn(t);return new Error(`${s_.redBright(e)} ${s_.dim(`[${s}]`)}`)},$Cn=({command:e,cwd:t=process.cwd(),files:r,topLevelDir:s,isFn:c,shell:o=!1,verbose:f=!1})=>{let[A,...h]=fjt(e);gFe("cmd:",A),gFe("args:",h);let y={cwd:/^git(\.exe)?/i.test(A)?s:t,preferLocal:!0,reject:!1,shell:o,stdin:"ignore"};return gFe("execaOptions:",y),async(T=git())=>{let w=o?UAn(c?e:`${e} ${r.join(" ")}`,y):cY(A,c?h:h.concat(r),y),b=FZs(T,w),U=await w;if(await b(),U.failed||U.killed||U.signal!=null)throw LZs(e,U,T);f&&ZCn(e,U,T)}};var QZs=(0,eIn.default)("lint-staged:makeCmdTasks"),tIn=async({commands:e,cwd:t,files:r,topLevelDir:s,shell:c,verbose:o})=>{QZs("Creating listr tasks for commands %o",e);let f=Array.isArray(e)?e:[e],A=[];for(let h of f){let y=typeof h=="function",T=y?await h([...r]):h,w=Array.isArray(T)?T:[T];for(let b of w){if(y&&typeof b!="string")throw new Error(pFe("[Function]","Function task should return a string or an array of strings",T));let U=$Cn({command:b,cwd:t,files:r,topLevelDir:s,isFn:y,shell:c,verbose:o});A.push({title:b,command:b,task:U})}}return A};var rIn=Yt(lR(),1);import hjt from"node:path";var t1e=(0,rIn.default)("lint-staged:resolveGitRepo"),MZs=async(e=process.cwd())=>{let t=hP(["rev-parse","--show-toplevel"],{cwd:e}),r=hP(["rev-parse","--absolute-git-dir"],{cwd:e}),[s,c]=await Promise.all([t,r]);return hjt.relative(s,c)},nIn=async(e=process.cwd())=>{try{t1e("Resolving git repo from `%s`",e),t1e("Unset GIT_DIR (was `%s`)",process.env.GIT_DIR),delete process.env.GIT_DIR,t1e("Unset GIT_WORK_TREE (was `%s`)",process.env.GIT_WORK_TREE),delete process.env.GIT_WORK_TREE;let t=await hP(["rev-parse","--show-cdup"],{cwd:e}),r=fR(hjt.join(e,t));t1e("Resolved git repository top-level directory to be `%s`",r);let s=await MZs(e),c=fR(hjt.join(r,s));return t1e("Resolved git config directory to be `%s`",c),{topLevelDir:r,gitConfigDir:c}}catch(t){return t1e("Failed to resolve git repo with error:",t),{error:t,topLevelDir:null,gitConfigDir:null}}};var cvn=Yt(lR(),1);import avn from"node:path";var XSn=Yt(lR(),1),ZSn=Yt(jSn(),1);import pno from"node:fs/promises";import A1e from"node:path";import{pathToFileURL as cno}from"node:url";var pst=e=>import(cno(e)).then(t=>t.default);import{createRequire as lno}from"node:module";function HSn(e){try{return lno(import.meta.url).resolve(e)}catch{return e}}var dst="lint-staged",_st="package.json",XHt=["package.yaml","package.yml"],Ast=[_st,...XHt,".lintstagedrc",".lintstagedrc.json",".lintstagedrc.yaml",".lintstagedrc.yml",".lintstagedrc.mjs",".lintstagedrc.js",".lintstagedrc.cjs","lint-staged.config.mjs","lint-staged.config.js","lint-staged.config.cjs"];var _1e=(0,XSn.default)("lint-staged:loadConfig"),dno=(e,t)=>{let r=_st.includes(A1e.basename(e));try{let s=JSON.parse(t);return r?s[dst]:s}catch(s){if(A1e.basename(e)===_st){_1e("Ignoring invalid package file `%s` with content:\n%s",e,t);return}throw s}},eqt=(e,t)=>{let r=XHt.includes(A1e.basename(e));try{let s=ZSn.default.parse(t);return r?s[dst]:s}catch(s){if(r){_1e("Ignoring invalid package file `%s` with content:\n%s",e,t);return}throw s}},$Sn="noExt",evn={".js":pst,".json":dno,".mjs":pst,".cjs":pst,".yaml":eqt,".yml":eqt,[$Sn]:eqt},_no=async e=>{let t=A1e.resolve(e);return await(await pno.readFile(t)).toString()},Ano=async e=>{e=A1e.resolve(e);let t=A1e.extname(e)||$Sn,r=evn[t],s=r.length>1?await _no(e):void 0;return{config:await r(e,s),filepath:e}},yst=async({configPath:e,cwd:t},r)=>{try{let s;if(e)_1e("Loading configuration from `%s`...",e),s=await Ano(HSn(e));else{_1e("Searching for configuration from `%s`...",t);let{lilconfig:f}=await Promise.resolve().then(()=>Yt(KSn(),1));s=await f(dst,{searchPlaces:Ast,loaders:evn}).search(t)}if(!s)return{};let c=await s.config??null,o=s.filepath;return _1e("Successfully loaded config from `%s`:\n%O",o,c),{config:c,filepath:o}}catch(s){return _1e("Failed to load configuration from `%s` with error:\n",e,s),r.error(aCn(e)),{}}};var ivn=Yt(lR(),1);import{inspect as yno}from"node:util";var hno=/(?{let t=`${e}`,r=null;for(;r=hno.exec(e);){let s=r[0],c=s.replace(/{/,"").replace(/}/,"");t=t.replace(s,c)}return t},gno=/{{[^}{]*}}/,Eno=e=>{let t=`${e}`,r=gno.exec(e)?.[0];if(r){let s=r.replace("{{","{").replace("}}","}");t=t.replace(r,s)}return t},tvn=(e,t)=>{let r=Eno(mno(e));return r!==e&&t.warn(X1n(e,r)),r};var tqt=(0,ivn.default)("lint-staged:validateConfig"),rvn=e=>e&&typeof e=="object"&&!Array.isArray(e),nvn=new Map([["concurrent",e=>typeof e=="boolean"],["chunkSize",e=>typeof e=="number"],["globOptions",rvn],["linters",rvn],["ignore",e=>Array.isArray(e)],["subTaskConcurrency",e=>typeof e=="number"],["renderer",e=>typeof e=="string"],["relative",e=>typeof e=="boolean"]]),Cno=(e,t,r)=>{if(tqt("Validating config from `%s`...",t),!e||typeof e!="object"&&typeof e!="function")throw mCn;if(typeof e=="function")return{"*":e};if(Object.entries(e).length===0)throw gCn;let s=[],c=Object.entries(e).reduce((o,[f,A])=>{if(nvn.has(f))return nvn.get(f)(A)&&s.push(pFe(f,"Advanced configuration has been deprecated.",A)),o;(!Array.isArray(A)||A.some(y=>typeof y!="string"&&typeof y!="function"))&&typeof A!="string"&&typeof A!="function"&&s.push(pFe(f,"Should be a string, a function, or an array of strings and functions.",A));let h=tvn(f,r);return{...o,[h]:A}},{});if(s.length){let o=s.join(` `);throw r.error(tjt(t,o)),new Error(o)}return tqt("Validated config from `%s`:",t),tqt(yno(e,{compact:!1})),c},zFe=(e,t,r)=>{try{return Cno(e,t,r)}catch(s){throw r.error(tjt(t,s)),s}};var EY=(0,cvn.default)("lint-staged:searchConfigs"),svn=["ls-files","-z","--full-name","-t"],Ino=e=>Ast.includes(avn.basename(e)),ovn=e=>e.split("/").length,Tno=(e,t)=>ovn(e)>ovn(t)?-1:1,Sno=e=>t=>t.startsWith(fR(e)),lvn=async({configObject:e,configPath:t,cwd:r=process.cwd(),topLevelDir:s=r},c)=>{if(EY("Searching for configuration files..."),e)return EY("Using single direct configuration object..."),{"":zFe(e,"config object",c)};if(t){EY("Using single configuration path...");let{config:T,filepath:w}=await yst({configPath:t},c);return T?{[t]:zFe(T,w,c)}:{}}let[o,f]=await Promise.all([hP(svn,{cwd:s}).then(_Fe),hP([...svn,"--others","--exclude-standard"],{cwd:s}).then(_Fe)]),A=[...o,...f].flatMap(T=>T.startsWith("S ")?[]:[T.replace(/^[HSMRCK?U] /,"")]).filter(Ino).map(T=>fR(avn.join(s,T))).filter(Sno(r)).sort(Tno);EY("Found possible config files:",A);let h=A.reduce((T,w)=>Object.assign(T,{[w]:null}),{});await Promise.all(Object.keys(h).map(T=>yst({configPath:T},c).then(({config:w,filepath:b})=>{w&&(T!==b&&EY('Config file "%s" resolved to "%s"',T,b),h[T]=zFe(w,b,c))})));let y=Object.entries(h).filter(([,T])=>!!T).reduce((T,[w,b])=>({...T,[w]:b}),{});if(!Object.keys(y).length){EY('Could not find config files inside "%s"',r);let{config:T,filepath:w}=await yst({cwd:r},c);T?(EY('Found parent configuration file from "%s"',w),y[w]=zFe(T,w,c)):EY('Could not find parent configuration files from "%s"',r)}return EY("Found %d config files",Object.keys(y).length),y};var XFe=(0,uvn.default)("lint-staged:runAll"),Cst=e=>Object.assign(new Error("lint-staged failed"),{ctx:e}),fvn=async({allowEmpty:e=!1,concurrent:t=!0,configObject:r,configPath:s,cwd:c,debug:o=!1,diff:f,diffFilter:A,maxArgLength:h,quiet:y=!1,relative:T=!1,shell:w=!1,stash:b=f===void 0,hidePartiallyStaged:U=b,verbose:x=!1},J=console)=>{XFe("Running all linter scripts...");let Z=!!c;c=Z?KFe.resolve(c):process.cwd(),XFe("Using working directory `%s`",c);let le=git({quiet:y}),{topLevelDir:ce,gitConfigDir:_e}=await nIn(c);if(!ce)throw y||le.output.push(z1n),le.errors.add(ECn),Cst(le);let me=await hP(["log","-1"],{cwd:ce}).then(()=>!0).catch(()=>!1);le.shouldBackup=me&&b,!le.shouldBackup&&!y&&J.warn(tCn(me,f)),le.shouldHidePartiallyStaged=U,!le.shouldHidePartiallyStaged&&!y&&J.warn(rCn(me&&b,f));let Ee=await ACn({cwd:ce,diff:f,diffFilter:A});if(!Ee)throw y||le.output.push(K1n),le.errors.add(cjt),Cst(le,cjt);if(XFe(`Loaded list of staged files in git: -%O`,Ee),Ee.length===0)return y||le.output.push($1n),le;let ge=await lvn({configObject:r,configPath:s,cwd:c,topLevelDir:ce},J),Ie=Object.keys(ge).length;if(Ie===0)throw le.errors.add(hFe),Cst(le,hFe);let De=await wCn({configs:ge,files:Ee,singleConfigMode:r||s!==void 0}),He=Ie>1,Xe=!1,k={ctx:le,exitOnError:!1,registerSignalListeners:!1,..._Cn({debug:o,quiet:y},J)},dt=0,_t=[],It=new Set;for(let[Br,{config:En,files:tr}]of Object.entries(De)){let Fr=Br?fR(KFe.relative(c,Br)):"Config object",Tr=ijt({baseDir:ce,files:tr,maxArgLength:h,relative:T}),_r=He&&!Z?KFe.dirname(Br):c,Vr=Tr.length;Vr>1&&XFe("Chunked staged files from `%s` into %d part",Br,Vr);for(let[An,Sr]of Tr.entries()){let Tn=await Promise.all(pCn({config:En,cwd:_r,files:Sr,relative:T}).map(Dn=>tIn({commands:Dn.commands,cwd:_r,files:Dn.fileList,topLevelDir:ce,shell:w,verbose:x}).then(or=>{Dn.fileList.forEach(ui=>{let Be=KFe.isAbsolute(ui)?ui:fR(KFe.join(_r,ui));It.add(Be)}),Xe=Xe||or.some(ui=>ui.command==="git add");let gi=Dn.fileList.length;return{title:`${Dn.pattern}${s_.dim(` \u2014 ${gi} ${gi===1?"file":"files"}`)}`,task:async(ui,Be)=>Be.newListr(or,{concurrent:!1,exitOnError:!0}),skip:()=>gi===0?`${Dn.pattern}${s_.dim(" \u2014 no files")}`:!1}})));dt+=Tn.length,_t.push({title:`${Fr}${s_.dim(` \u2014 ${Sr.length} ${Sr.length>1?"files":"file"}`)}`+(Vr>1?s_.dim(` (chunk ${An+1}/${Vr})...`):""),task:(Dn,or)=>or.newListr(Tn,{concurrent:t,exitOnError:!0}),skip:()=>le.errors.has(J5)?iCn:Tn.every(Dn=>Dn.skip())?`${Fr}${s_.dim(" \u2014 no tasks to run")}`:!1})}}if(Xe&&!y&&J.warn(nCn),_t.every(Br=>Br.skip()))return y||le.output.push(eCn),le;let lt=ijt({baseDir:c,files:Array.from(It),maxArgLength:h,relative:!1}),wt=new hit({allowEmpty:e,gitConfigDir:_e,topLevelDir:ce,matchedFileChunks:lt,diff:f,diffFilter:A}),Vt=new uit([{title:"Preparing lint-staged...",task:Br=>wt.prepare(Br)},{title:"Hiding unstaged changes to partially staged files...",task:Br=>wt.hideUnstagedChanges(Br),enabled:_jt},{title:`Running tasks for ${f?"changed":"staged"} files...`,task:(Br,En)=>En.newListr(_t,{concurrent:t}),skip:()=>_t.every(Br=>Br.skip())},{title:"Applying modifications from tasks...",task:Br=>wt.applyModifications(Br),skip:HCn},{title:"Restoring unstaged changes to partially staged files...",task:Br=>wt.restoreUnstagedChanges(Br),enabled:_jt,skip:qCn},{title:"Reverting to original state because of errors...",task:Br=>wt.restoreOriginalState(Br),enabled:JCn,skip:VCn},{title:"Cleaning up temporary files...",task:Br=>wt.cleanup(Br),enabled:WCn,skip:YCn}],k);if(XFe("Set max event listeners to the number of tasks: %i",dt),le.events.setMaxListeners(dt),await Vt.run(),le.errors.size>0)throw Cst(le);return le};var _vn=Yt(lR(),1);import{constants as pvn}from"node:fs";import dvn from"node:fs/promises";import vno from"node:path";var Ist=(0,_vn.default)("lint-staged:validateOptions"),Avn=async(e={},t)=>{if(Ist("Validating options..."),typeof e.cwd=="string")try{let r=vno.resolve(e.cwd);await dvn.access(r,pvn.F_OK)}catch(r){throw Ist("Failed to validate options: %o",e),t.error(ejt("cwd",e.cwd,r.message)),ljt}if(typeof e.shell=="string")try{await dvn.access(e.shell,pvn.X_OK)}catch(r){throw Ist("Failed to validate options: %o",e),t.error(ejt("shell",e.shell,r.message)),ljt}Ist("Validated options: %o",e)};var rqt=(0,hvn.default)("lint-staged"),Dno=()=>{switch(process.platform){case"darwin":return 262144;case"win32":return 8191;default:return 131072}},bno=async({allowEmpty:e=!1,concurrent:t=!0,config:r,configPath:s,cwd:c,debug:o=!1,diff:f,diffFilter:A,maxArgLength:h=Dno()/2,quiet:y=!1,relative:T=!1,shell:w=!1,stash:b=f===void 0,hidePartiallyStaged:U=b,verbose:x=!1}={},J=console)=>{let Z=await hP(["version","--build-options"],{cwd:c});rqt("%s",Z);let le={allowEmpty:e,concurrent:t,configObject:r,configPath:s,cwd:c,debug:o,diff:f,diffFilter:A,maxArgLength:h,quiet:y,relative:T,shell:w,stash:b,hidePartiallyStaged:U,verbose:x};await Avn(le,J),rqt("Unset GIT_LITERAL_PATHSPECS (was `%s`)",process.env.GIT_LITERAL_PATHSPECS),delete process.env.GIT_LITERAL_PATHSPECS;try{let ce=await fvn(le,J);return rqt("Tasks were executed successfully!"),rjt(ce,J),!0}catch(ce){if(ce?.ctx?.errors){let{ctx:_e}=ce;return _e.errors.has(hFe)?J.error(Z1n):_e.errors.has(ute)?J.warn(sCn):_e.errors.has(J5)&&!_e.errors.has(_it)&&(J.error(lte),_e.shouldBackup&&J.error(oCn)),rjt(_e,J),!1}throw ce}},mvn=bno;var wno={"*.{yml,yaml,json,graphql,md}":"yarn format","*.{js,mjs,cjs,jsx,ts,tsx}":["yarn format","yarn lint"],"*.{ts,tsx}":["yarn typecheck"],"*.{tsx,ts}":["yarn test unit"]},Tst=class extends gvn.BaseCommand{static paths=[["commit","staged"]];args=Gd.Rest({required:0});async execute(){try{return await mvn({config:wno,debug:!1})?0:1}catch{return 1}}};var Evn={commands:[Hnt,Ant,Tst]};var iqt={};Tm(iqt,{SetVersionCommand:()=>ZFe,default:()=>Ivn});var yvn=Yt(Pl(),1),Cvn=Yt(On(),1);Fl();var ZFe=class extends yvn.BaseCommand{static paths=[["set","version","atlantis"]];static usage=lI.Usage({description:"lock the Yarn version used by the project",details:"\n This command will get latest Atlantis bundle from [Atlantis Raijin repo](https://github.com/atls/raijin) and bump `@atls/code-runtime` dependency\n "});async execute(){let t=["set","version"];t.push("https://raw.githubusercontent.com/atls/raijin/master/yarn/cli/dist/yarn.mjs");let r=await this.cli.run(t),s=["up","@atls/code-runtime"],c=await this.cli.run(s),o=await Cvn.Configuration.find(this.context.cwd,this.context.plugins);return await o.triggerHook(f=>f.afterYarnVersionSet,o,this.context),c&&r}};var Ivn={commands:[ZFe]};var bJt={};Tm(bJt,{WorkspaceExportCommand:()=>DLe,default:()=>Gbn});var Obn=Yt(Pl(),1),Fbn=Yt(Pl(),1),Lbn=Yt(On(),1),Qbn=Yt(On(),1),Mbn=Yt(On(),1),Ubn=Yt(On(),1);Fl();var O1e={};Tm(O1e,{pack:()=>wco});var DJt=Yt(On(),1),Bbn=Yt(On(),1),xbn=Yt(On(),1),Nbn=Yt(oa(),1),Rbn=Yt(On(),1),kbn=Yt(oa(),1),Pbn=Yt(Qle(),1);var lDn=Yt(On(),1),uDn=Yt(On(),1),fDn=Yt(oa(),1),pDn=Yt(oa(),1),dDn=Yt(oa(),1),qqt=Yt(On(),1),Jqt=Yt(oa(),1),_Dn=Yt(oa(),1),Wst=class e extends lDn.Cache{nodeLinker;parentCache;parentMirror=new Map;workspaceMutexes=new Map;static async find(t,r){let s=t.get("nodeLinker"),c=new e(t.get("cacheFolder"),{configuration:t,nodeLinker:s,parentCache:r});return await c.setup(),c}constructor(t,{configuration:r,nodeLinker:s,parentCache:c}){super(t,{configuration:r}),this.nodeLinker=s,this.parentCache=c}getLocatorMirrorPath(t){return this.parentMirror.get(qqt.structUtils.slugifyLocator(t))??null}async setup(){await super.setup();let t=await _Dn.xfs.readdirPromise(this.parentCache.cwd,{withFileTypes:!0});for(let r of t){let s;r.isDirectory()||!(s=r.name.match(/^(.*)-[a-f\d]+\.zip$/i))||this.parentMirror.set(s[1],Jqt.ppath.join(this.parentCache.cwd,r.name))}}async fetchPackageFromCache(t,r,{loader:s}){let c=new pDn.NodeFS,o=async()=>{let f=Jqt.ppath.resolve(this.cwd,"../workspaces",qqt.structUtils.stringifyIdent(t)),h=(async()=>{if(!await c.existsPromise(f)){let T=await s();await c.copyPromise(f,dDn.PortablePath.root,{baseFs:T}),T.discardAndClose()}return f})();this.workspaceMutexes.set(t.locatorHash,h);try{return await h}finally{this.workspaceMutexes.delete(t.locatorHash)}};if(t.reference.startsWith(uDn.WorkspaceResolver.protocol)){for(let A;A=this.workspaceMutexes.get(t.locatorHash);)await A;let f=await o();return[new fDn.JailFS(f,{baseFs:c}),()=>{},null]}else return await super.fetchPackageFromCache(t,r,{loader:s})}};var Tbn=Yt(On(),1),Sbn=Yt(On(),1);var vbn=Yt(On(),1),SJt=Yt(oa(),1),Vle=Yt(oa(),1),vJt=Yt(Qle(),1),bco=Yt(hbn(),1);var CJt=Yt(On(),1),sot=class{resolvers;constructor(t){this.resolvers=t.filter(r=>r)}supportsDescriptor(t,r){return!!this.tryResolverByDescriptor(t,r)}supportsLocator(t,r){return!!this.tryResolverByLocator(t,r)}shouldPersistResolution(t,r){return this.getResolverByLocator(t,r).shouldPersistResolution(t,r)}bindDescriptor(t,r,s){return this.getResolverByDescriptor(t,s).bindDescriptor(t,r,s)}getResolutionDependencies(t,r){return this.getResolverByDescriptor(t,r).getResolutionDependencies(t,r)}async getCandidates(t,r,s){return await this.getResolverByDescriptor(t,s).getCandidates(t,r,s)}async getSatisfying(t,r,s,c){return this.getResolverByDescriptor(t,c).getSatisfying(t,r,s,c)}async resolve(t,r){return await this.getResolverByLocator(t,r).resolve(t,r)}tryResolverByDescriptor(t,r){let s=this.resolvers.find(c=>c.supportsDescriptor(t,r));return s||null}getResolverByDescriptor(t,r){let s=this.resolvers.find(c=>c.supportsDescriptor(t,r));if(!s)throw new Error(`${CJt.structUtils.prettyDescriptor(r.project.configuration,t)} isn't supported by any available resolver`);return s}tryResolverByLocator(t,r){let s=this.resolvers.find(c=>c.supportsLocator(t,r));return s||null}getResolverByLocator(t,r){let s=this.resolvers.find(c=>c.supportsLocator(t,r));if(!s)throw new Error(`${CJt.structUtils.prettyLocator(r.project.configuration,t)} isn't supported by any available resolver`);return s}};var gbn=Yt(On(),1),oot=Yt(On(),1),Ebn=Yt(Py(),1),mbn=/^(?!v)[a-z0-9._-]+$/i,aot=class{supportsDescriptor(t,r){return!!(gbn.semverUtils.validRange(t.range)||mbn.test(t.range))}supportsLocator(t,r){return!!(Ebn.default.valid(t.reference)||mbn.test(t.reference))}shouldPersistResolution(t,r){return r.resolver.shouldPersistResolution(this.forwardLocator(t,r),r)}bindDescriptor(t,r,s){return s.resolver.bindDescriptor(this.forwardDescriptor(t,s),r,s)}getResolutionDependencies(t,r){return r.resolver.getResolutionDependencies(this.forwardDescriptor(t,r),r)}async getCandidates(t,r,s){return s.resolver.getCandidates(this.forwardDescriptor(t,s),r,s)}async getSatisfying(t,r,s,c){return c.resolver.getSatisfying(this.forwardDescriptor(t,c),r,s,c)}async resolve(t,r){let s=await r.resolver.resolve(this.forwardLocator(t,r),r);return oot.structUtils.renamePackage(s,t)}forwardDescriptor(t,r){return oot.structUtils.makeDescriptor(t,`${r.project.configuration.get("defaultProtocol")}${t.range}`)}forwardLocator(t,r){return oot.structUtils.makeLocator(t,`${r.project.configuration.get("defaultProtocol")}${t.reference}`)}};var cot=class e{static protocol="virtual:";static isVirtualDescriptor(t){return!!t.range.startsWith(e.protocol)}static isVirtualLocator(t){return!!t.reference.startsWith(e.protocol)}supportsDescriptor(t,r){return e.isVirtualDescriptor(t)}supportsLocator(t,r){return e.isVirtualLocator(t)}shouldPersistResolution(t,r){return!1}bindDescriptor(t,r,s){throw new Error('Assertion failed: calling "bindDescriptor" on a virtual descriptor is unsupported')}getResolutionDependencies(t,r){throw new Error('Assertion failed: calling "getResolutionDependencies" on a virtual descriptor is unsupported')}async getCandidates(t,r,s){throw new Error('Assertion failed: calling "getCandidates" on a virtual descriptor is unsupported')}async getSatisfying(t,r,s,c){throw new Error('Assertion failed: calling "getSatisfying" on a virtual descriptor is unsupported')}async resolve(t,r){throw new Error('Assertion failed: calling "resolve" on a virtual locator is unsupported')}};var IJt=Yt(On(),1),ybn=Yt(On(),1),Cbn=Yt(oa(),1);var lot=class extends ybn.WorkspaceFetcher{constructor(r){super();this.originalProject=r}getLocalPath(r,s){return super.getLocalPath(r,this.rewriteOpts(r,s))}async fetch(r,s){if(r.reference.slice(IJt.WorkspaceResolver.protocol.length)===".")return await super.fetch(r,s);let c=s.checksums.get(r.locatorHash)||null,[o,f]=await s.cache.fetchPackageFromCache(r,c,{loader:()=>this.packWorkspace(r)});return{packageFs:o,releaseFs:f,localPath:this.getLocalPath(r,s),prefixPath:Cbn.PortablePath.dot}}async packWorkspace(r){let s=this.originalProject.getWorkspaceByLocator(r);return await Ibn(s,{compressionLevel:this.originalProject.configuration.get("compressionLevel"),stripComponents:1})}rewriteOpts(r,s){return r.reference.slice(IJt.WorkspaceResolver.protocol.length)==="."?s:{...s,project:this.originalProject}}};var TJt=Yt(On(),1),uot=Yt(On(),1),fot=class extends uot.WorkspaceResolver{constructor(r){super();this.originalProject=r}supportsDescriptor(r,s){return super.supportsDescriptor(r,this.rewriteOpts(r,s))}supportsLocator(r,s){return super.supportsLocator(r,this.rewriteOpts(r,s))}shouldPersistResolution(r,s){return super.shouldPersistResolution(r,this.rewriteOpts(r,s))}bindDescriptor(r,s,c){return super.bindDescriptor(r,s,this.rewriteOpts(r,c))}getResolutionDependencies(r,s){return super.getResolutionDependencies(r,this.rewriteOpts(r,s))}async getCandidates(r,s,c){return await super.getCandidates(r,s,this.rewriteOpts(r,c))}async getSatisfying(r,s,c){return await super.getSatisfying(r,s,this.rewriteOpts(r,c))}async resolve(r,s){let c=r.reference.slice(uot.WorkspaceResolver.protocol.length),{project:o}=this.rewriteOpts(r,s),f=o.getWorkspaceByCwd(c);return{...r,version:f.manifest.version||"0.0.0",languageName:"unknown",linkType:c==="."?TJt.LinkType.SOFT:TJt.LinkType.HARD,dependencies:f.manifest.dependencies,peerDependencies:f.manifest.peerDependencies,dependenciesMeta:f.manifest.dependenciesMeta,peerDependenciesMeta:f.manifest.peerDependenciesMeta,bin:f.manifest.bin}}rewriteOpts(r,s){return("descriptorHash"in r?r.range:r.reference).slice(uot.WorkspaceResolver.protocol.length)==="."?s:{...s,project:this.originalProject}}};var Dbn=e=>{let t=[];for(let r of e.configuration.plugins.values())for(let s of r.fetchers||[])t.push(new s);return new Sbn.MultiFetcher([new Tbn.VirtualFetcher,new lot(e),...t])},bbn=e=>{let t=[];for(let r of e.configuration.plugins.values())for(let s of r.resolvers||[])t.push(new s);return new sot([new cot,new fot(e),new aot,...t])};var wbn=async e=>{let t=await Vle.xfs.mktempPromise(),r=await vJt.packUtils.genPackStream(e),s=SJt.ppath.join(t,"package.tgz"),c=Vle.xfs.createWriteStream(s);return r.pipe(c),await new Promise(o=>{c.on("finish",o)}),Vle.xfs.readFilePromise(s)},Ibn=async(e,t)=>await Vle.xfs.mktempPromise(async r=>{let s=await vJt.packUtils.genPackStream(e),c=SJt.ppath.join(r,"package.tgz"),o=Vle.xfs.createWriteStream(c);s.pipe(o),await new Promise(A=>{o.on("finish",A)});let f=await Vle.xfs.readFilePromise(c);return await vbn.tgzUtils.convertToZip(f,t)});var wco=async(e,t,r,s,c)=>{process.env.IMAGE_PACK=!0;let o=await xbn.Cache.find(e,{immutable:!0});await t.restoreInstallState(),await Pbn.packUtils.prepareForPack(r,{report:s},async()=>{r.manifest.devDependencies.clear();let f=new Nbn.CwdFS(c),A=await wbn(r);await Rbn.tgzUtils.extractArchiveTo(A,f,{stripComponents:1});let h=DJt.Configuration.create(c,c,e.plugins);h.values.set("compressionLevel",t.configuration.get("compressionLevel")),h.values.set("enableGlobalCache",!1),h.values.set("enableMirror",!1),h.values.set("globalFolder",e.get("globalFolder")),h.values.set("packageExtensions",e.get("packageExtensions")),h.values.set("pnpEnableEsmLoader",e.get("pnpEnableEsmLoader")),h.values.set("cacheFolder",kbn.ppath.join(c,".yarn/packages")),h.values.set("preferAggregateCacheInfo",!0),await DJt.Configuration.updateConfiguration(c,{cacheFolder:".yarn/packages",compressionLevel:h.get("compressionLevel"),enableGlobalCache:h.get("enableGlobalCache"),enableNetwork:h.get("enableNetwork"),enableMirror:h.get("enableMirror"),packageExtensions:h.get("packageExtensions"),nodeLinker:t.configuration.get("nodeLinker")}),await h.getPackageExtensions();let{project:y,workspace:T}=await Bbn.Project.find(h,c);if(!T)throw new Error("Workspace not found");T.manifest.dependencies=r.manifest.dependencies,T.manifest.resolutions=t.topLevelWorkspace.manifest.resolutions,T.manifest.devDependencies.clear(),await y.install({cache:await Wst.find(h,o),fetcher:Dbn(t),resolver:bbn(t),persistProject:!0,report:s})})};var Bco=Yt(Qle(),1);var DLe=class extends Obn.BaseCommand{static paths=[["export"]];destination=Gd.String("-d,--destination",{required:!0});async execute(){let t=await Lbn.Configuration.find(this.context.cwd,this.context.plugins),{project:r,workspace:s}=await Qbn.Project.find(t,this.context.cwd);if(!s)throw new Fbn.WorkspaceRequiredError(r.cwd,this.context.cwd);return(await Mbn.StreamReport.start({configuration:t,stdout:this.context.stdout},async o=>{await O1e.pack(t,r,s,o,this.destination),o.reportInfo(null,`Workspace ${s.manifest.name?Ubn.structUtils.prettyIdent(t,s.manifest.name):s.relativeCwd} exported to ${this.destination}`)})).exitCode()}};var Gbn={commands:[DLe]};var tKt={};Tm(tKt,{FormatCommand:()=>m3e,default:()=>$Mn});var zMn=Yt(Pl(),1),KMn=Yt(On(),1),XMn=Yt(On(),1);Fl();var ZMn=Yt(Rc(),1),eKt=Yt(Ls(),1);var Eot=Yt(Rc(),1),twn=Yt(Rc(),1),zle=Yt(Ls(),1);var pot=class{constructor(t){this.frames=t}get topFrame(){return this.frames.find(t=>t.file)}};var jbn=Yt(IZe(),1);var Hbn=e=>{let t=e.split(` +%O`,Ee),Ee.length===0)return y||le.output.push($1n),le;let ge=await lvn({configObject:r,configPath:s,cwd:c,topLevelDir:ce},J),Ie=Object.keys(ge).length;if(Ie===0)throw le.errors.add(hFe),Cst(le,hFe);let De=await wCn({configs:ge,files:Ee,singleConfigMode:r||s!==void 0}),He=Ie>1,Xe=!1,k={ctx:le,exitOnError:!1,registerSignalListeners:!1,..._Cn({debug:o,quiet:y},J)},dt=0,_t=[],It=new Set;for(let[Br,{config:En,files:tr}]of Object.entries(De)){let Fr=Br?fR(KFe.relative(c,Br)):"Config object",Tr=ijt({baseDir:ce,files:tr,maxArgLength:h,relative:T}),_r=He&&!Z?KFe.dirname(Br):c,Vr=Tr.length;Vr>1&&XFe("Chunked staged files from `%s` into %d part",Br,Vr);for(let[An,Sr]of Tr.entries()){let Tn=await Promise.all(pCn({config:En,cwd:_r,files:Sr,relative:T}).map(Dn=>tIn({commands:Dn.commands,cwd:_r,files:Dn.fileList,topLevelDir:ce,shell:w,verbose:x}).then(or=>{Dn.fileList.forEach(ui=>{let Be=KFe.isAbsolute(ui)?ui:fR(KFe.join(_r,ui));It.add(Be)}),Xe=Xe||or.some(ui=>ui.command==="git add");let gi=Dn.fileList.length;return{title:`${Dn.pattern}${s_.dim(` \u2014 ${gi} ${gi===1?"file":"files"}`)}`,task:async(ui,Be)=>Be.newListr(or,{concurrent:!1,exitOnError:!0}),skip:()=>gi===0?`${Dn.pattern}${s_.dim(" \u2014 no files")}`:!1}})));dt+=Tn.length,_t.push({title:`${Fr}${s_.dim(` \u2014 ${Sr.length} ${Sr.length>1?"files":"file"}`)}`+(Vr>1?s_.dim(` (chunk ${An+1}/${Vr})...`):""),task:(Dn,or)=>or.newListr(Tn,{concurrent:t,exitOnError:!0}),skip:()=>le.errors.has(J5)?iCn:Tn.every(Dn=>Dn.skip())?`${Fr}${s_.dim(" \u2014 no tasks to run")}`:!1})}}if(Xe&&!y&&J.warn(nCn),_t.every(Br=>Br.skip()))return y||le.output.push(eCn),le;let lt=ijt({baseDir:c,files:Array.from(It),maxArgLength:h,relative:!1}),wt=new hit({allowEmpty:e,gitConfigDir:_e,topLevelDir:ce,matchedFileChunks:lt,diff:f,diffFilter:A}),Vt=new uit([{title:"Preparing lint-staged...",task:Br=>wt.prepare(Br)},{title:"Hiding unstaged changes to partially staged files...",task:Br=>wt.hideUnstagedChanges(Br),enabled:_jt},{title:`Running tasks for ${f?"changed":"staged"} files...`,task:(Br,En)=>En.newListr(_t,{concurrent:t}),skip:()=>_t.every(Br=>Br.skip())},{title:"Applying modifications from tasks...",task:Br=>wt.applyModifications(Br),skip:HCn},{title:"Restoring unstaged changes to partially staged files...",task:Br=>wt.restoreUnstagedChanges(Br),enabled:_jt,skip:qCn},{title:"Reverting to original state because of errors...",task:Br=>wt.restoreOriginalState(Br),enabled:JCn,skip:VCn},{title:"Cleaning up temporary files...",task:Br=>wt.cleanup(Br),enabled:WCn,skip:YCn}],k);if(XFe("Set max event listeners to the number of tasks: %i",dt),le.events.setMaxListeners(dt),await Vt.run(),le.errors.size>0)throw Cst(le);return le};var _vn=Yt(lR(),1);import{constants as pvn}from"node:fs";import dvn from"node:fs/promises";import vno from"node:path";var Ist=(0,_vn.default)("lint-staged:validateOptions"),Avn=async(e={},t)=>{if(Ist("Validating options..."),typeof e.cwd=="string")try{let r=vno.resolve(e.cwd);await dvn.access(r,pvn.F_OK)}catch(r){throw Ist("Failed to validate options: %o",e),t.error(ejt("cwd",e.cwd,r.message)),ljt}if(typeof e.shell=="string")try{await dvn.access(e.shell,pvn.X_OK)}catch(r){throw Ist("Failed to validate options: %o",e),t.error(ejt("shell",e.shell,r.message)),ljt}Ist("Validated options: %o",e)};var rqt=(0,hvn.default)("lint-staged"),Dno=()=>{switch(process.platform){case"darwin":return 262144;case"win32":return 8191;default:return 131072}},bno=async({allowEmpty:e=!1,concurrent:t=!0,config:r,configPath:s,cwd:c,debug:o=!1,diff:f,diffFilter:A,maxArgLength:h=Dno()/2,quiet:y=!1,relative:T=!1,shell:w=!1,stash:b=f===void 0,hidePartiallyStaged:U=b,verbose:x=!1}={},J=console)=>{let Z=await hP(["version","--build-options"],{cwd:c});rqt("%s",Z);let le={allowEmpty:e,concurrent:t,configObject:r,configPath:s,cwd:c,debug:o,diff:f,diffFilter:A,maxArgLength:h,quiet:y,relative:T,shell:w,stash:b,hidePartiallyStaged:U,verbose:x};await Avn(le,J),rqt("Unset GIT_LITERAL_PATHSPECS (was `%s`)",process.env.GIT_LITERAL_PATHSPECS),delete process.env.GIT_LITERAL_PATHSPECS;try{let ce=await fvn(le,J);return rqt("Tasks were executed successfully!"),rjt(ce,J),!0}catch(ce){if(ce?.ctx?.errors){let{ctx:_e}=ce;return _e.errors.has(hFe)?J.error(Z1n):_e.errors.has(ute)?J.warn(sCn):_e.errors.has(J5)&&!_e.errors.has(_it)&&(J.error(lte),_e.shouldBackup&&J.error(oCn)),rjt(_e,J),!1}throw ce}},mvn=bno;var wno={"*.{yml,yaml,json,graphql,md}":"yarn format","*.{js,mjs,cjs,jsx,ts,tsx}":["yarn format","yarn lint"],"*.{ts,tsx}":["yarn typecheck"],"*.{tsx,ts}":["yarn test unit"]},Tst=class extends gvn.BaseCommand{static paths=[["commit","staged"]];args=Gd.Rest({required:0});async execute(){try{return await mvn({config:wno,debug:!1})?0:1}catch{return 1}}};var Evn={commands:[Hnt,Ant,Tst]};var iqt={};Tm(iqt,{SetVersionCommand:()=>ZFe,default:()=>Ivn});var yvn=Yt(Pl(),1),Cvn=Yt(On(),1);Fl();var ZFe=class extends yvn.BaseCommand{static paths=[["set","version","atls"]];static usage=lI.Usage({description:"lock the Yarn version used by the project",details:"\n This command will get latest Atlantis bundle from [Atlantis Raijin repo](https://github.com/atls/raijin) and bump `@atls/code-runtime` dependency\n "});async execute(){let t=["set","version"];t.push("https://raw.githubusercontent.com/atls/raijin/master/yarn/cli/dist/yarn.mjs");let r=await this.cli.run(t),s=["up","@atls/code-runtime"],c=await this.cli.run(s),o=await Cvn.Configuration.find(this.context.cwd,this.context.plugins);return await o.triggerHook(f=>f.afterYarnVersionSet,o,this.context),c&&r}};var Ivn={commands:[ZFe]};var bJt={};Tm(bJt,{WorkspaceExportCommand:()=>DLe,default:()=>Gbn});var Obn=Yt(Pl(),1),Fbn=Yt(Pl(),1),Lbn=Yt(On(),1),Qbn=Yt(On(),1),Mbn=Yt(On(),1),Ubn=Yt(On(),1);Fl();var O1e={};Tm(O1e,{pack:()=>wco});var DJt=Yt(On(),1),Bbn=Yt(On(),1),xbn=Yt(On(),1),Nbn=Yt(oa(),1),Rbn=Yt(On(),1),kbn=Yt(oa(),1),Pbn=Yt(Qle(),1);var lDn=Yt(On(),1),uDn=Yt(On(),1),fDn=Yt(oa(),1),pDn=Yt(oa(),1),dDn=Yt(oa(),1),qqt=Yt(On(),1),Jqt=Yt(oa(),1),_Dn=Yt(oa(),1),Wst=class e extends lDn.Cache{nodeLinker;parentCache;parentMirror=new Map;workspaceMutexes=new Map;static async find(t,r){let s=t.get("nodeLinker"),c=new e(t.get("cacheFolder"),{configuration:t,nodeLinker:s,parentCache:r});return await c.setup(),c}constructor(t,{configuration:r,nodeLinker:s,parentCache:c}){super(t,{configuration:r}),this.nodeLinker=s,this.parentCache=c}getLocatorMirrorPath(t){return this.parentMirror.get(qqt.structUtils.slugifyLocator(t))??null}async setup(){await super.setup();let t=await _Dn.xfs.readdirPromise(this.parentCache.cwd,{withFileTypes:!0});for(let r of t){let s;r.isDirectory()||!(s=r.name.match(/^(.*)-[a-f\d]+\.zip$/i))||this.parentMirror.set(s[1],Jqt.ppath.join(this.parentCache.cwd,r.name))}}async fetchPackageFromCache(t,r,{loader:s}){let c=new pDn.NodeFS,o=async()=>{let f=Jqt.ppath.resolve(this.cwd,"../workspaces",qqt.structUtils.stringifyIdent(t)),h=(async()=>{if(!await c.existsPromise(f)){let T=await s();await c.copyPromise(f,dDn.PortablePath.root,{baseFs:T}),T.discardAndClose()}return f})();this.workspaceMutexes.set(t.locatorHash,h);try{return await h}finally{this.workspaceMutexes.delete(t.locatorHash)}};if(t.reference.startsWith(uDn.WorkspaceResolver.protocol)){for(let A;A=this.workspaceMutexes.get(t.locatorHash);)await A;let f=await o();return[new fDn.JailFS(f,{baseFs:c}),()=>{},null]}else return await super.fetchPackageFromCache(t,r,{loader:s})}};var Tbn=Yt(On(),1),Sbn=Yt(On(),1);var vbn=Yt(On(),1),SJt=Yt(oa(),1),Vle=Yt(oa(),1),vJt=Yt(Qle(),1),bco=Yt(hbn(),1);var CJt=Yt(On(),1),sot=class{resolvers;constructor(t){this.resolvers=t.filter(r=>r)}supportsDescriptor(t,r){return!!this.tryResolverByDescriptor(t,r)}supportsLocator(t,r){return!!this.tryResolverByLocator(t,r)}shouldPersistResolution(t,r){return this.getResolverByLocator(t,r).shouldPersistResolution(t,r)}bindDescriptor(t,r,s){return this.getResolverByDescriptor(t,s).bindDescriptor(t,r,s)}getResolutionDependencies(t,r){return this.getResolverByDescriptor(t,r).getResolutionDependencies(t,r)}async getCandidates(t,r,s){return await this.getResolverByDescriptor(t,s).getCandidates(t,r,s)}async getSatisfying(t,r,s,c){return this.getResolverByDescriptor(t,c).getSatisfying(t,r,s,c)}async resolve(t,r){return await this.getResolverByLocator(t,r).resolve(t,r)}tryResolverByDescriptor(t,r){let s=this.resolvers.find(c=>c.supportsDescriptor(t,r));return s||null}getResolverByDescriptor(t,r){let s=this.resolvers.find(c=>c.supportsDescriptor(t,r));if(!s)throw new Error(`${CJt.structUtils.prettyDescriptor(r.project.configuration,t)} isn't supported by any available resolver`);return s}tryResolverByLocator(t,r){let s=this.resolvers.find(c=>c.supportsLocator(t,r));return s||null}getResolverByLocator(t,r){let s=this.resolvers.find(c=>c.supportsLocator(t,r));if(!s)throw new Error(`${CJt.structUtils.prettyLocator(r.project.configuration,t)} isn't supported by any available resolver`);return s}};var gbn=Yt(On(),1),oot=Yt(On(),1),Ebn=Yt(Py(),1),mbn=/^(?!v)[a-z0-9._-]+$/i,aot=class{supportsDescriptor(t,r){return!!(gbn.semverUtils.validRange(t.range)||mbn.test(t.range))}supportsLocator(t,r){return!!(Ebn.default.valid(t.reference)||mbn.test(t.reference))}shouldPersistResolution(t,r){return r.resolver.shouldPersistResolution(this.forwardLocator(t,r),r)}bindDescriptor(t,r,s){return s.resolver.bindDescriptor(this.forwardDescriptor(t,s),r,s)}getResolutionDependencies(t,r){return r.resolver.getResolutionDependencies(this.forwardDescriptor(t,r),r)}async getCandidates(t,r,s){return s.resolver.getCandidates(this.forwardDescriptor(t,s),r,s)}async getSatisfying(t,r,s,c){return c.resolver.getSatisfying(this.forwardDescriptor(t,c),r,s,c)}async resolve(t,r){let s=await r.resolver.resolve(this.forwardLocator(t,r),r);return oot.structUtils.renamePackage(s,t)}forwardDescriptor(t,r){return oot.structUtils.makeDescriptor(t,`${r.project.configuration.get("defaultProtocol")}${t.range}`)}forwardLocator(t,r){return oot.structUtils.makeLocator(t,`${r.project.configuration.get("defaultProtocol")}${t.reference}`)}};var cot=class e{static protocol="virtual:";static isVirtualDescriptor(t){return!!t.range.startsWith(e.protocol)}static isVirtualLocator(t){return!!t.reference.startsWith(e.protocol)}supportsDescriptor(t,r){return e.isVirtualDescriptor(t)}supportsLocator(t,r){return e.isVirtualLocator(t)}shouldPersistResolution(t,r){return!1}bindDescriptor(t,r,s){throw new Error('Assertion failed: calling "bindDescriptor" on a virtual descriptor is unsupported')}getResolutionDependencies(t,r){throw new Error('Assertion failed: calling "getResolutionDependencies" on a virtual descriptor is unsupported')}async getCandidates(t,r,s){throw new Error('Assertion failed: calling "getCandidates" on a virtual descriptor is unsupported')}async getSatisfying(t,r,s,c){throw new Error('Assertion failed: calling "getSatisfying" on a virtual descriptor is unsupported')}async resolve(t,r){throw new Error('Assertion failed: calling "resolve" on a virtual locator is unsupported')}};var IJt=Yt(On(),1),ybn=Yt(On(),1),Cbn=Yt(oa(),1);var lot=class extends ybn.WorkspaceFetcher{constructor(r){super();this.originalProject=r}getLocalPath(r,s){return super.getLocalPath(r,this.rewriteOpts(r,s))}async fetch(r,s){if(r.reference.slice(IJt.WorkspaceResolver.protocol.length)===".")return await super.fetch(r,s);let c=s.checksums.get(r.locatorHash)||null,[o,f]=await s.cache.fetchPackageFromCache(r,c,{loader:()=>this.packWorkspace(r)});return{packageFs:o,releaseFs:f,localPath:this.getLocalPath(r,s),prefixPath:Cbn.PortablePath.dot}}async packWorkspace(r){let s=this.originalProject.getWorkspaceByLocator(r);return await Ibn(s,{compressionLevel:this.originalProject.configuration.get("compressionLevel"),stripComponents:1})}rewriteOpts(r,s){return r.reference.slice(IJt.WorkspaceResolver.protocol.length)==="."?s:{...s,project:this.originalProject}}};var TJt=Yt(On(),1),uot=Yt(On(),1),fot=class extends uot.WorkspaceResolver{constructor(r){super();this.originalProject=r}supportsDescriptor(r,s){return super.supportsDescriptor(r,this.rewriteOpts(r,s))}supportsLocator(r,s){return super.supportsLocator(r,this.rewriteOpts(r,s))}shouldPersistResolution(r,s){return super.shouldPersistResolution(r,this.rewriteOpts(r,s))}bindDescriptor(r,s,c){return super.bindDescriptor(r,s,this.rewriteOpts(r,c))}getResolutionDependencies(r,s){return super.getResolutionDependencies(r,this.rewriteOpts(r,s))}async getCandidates(r,s,c){return await super.getCandidates(r,s,this.rewriteOpts(r,c))}async getSatisfying(r,s,c){return await super.getSatisfying(r,s,this.rewriteOpts(r,c))}async resolve(r,s){let c=r.reference.slice(uot.WorkspaceResolver.protocol.length),{project:o}=this.rewriteOpts(r,s),f=o.getWorkspaceByCwd(c);return{...r,version:f.manifest.version||"0.0.0",languageName:"unknown",linkType:c==="."?TJt.LinkType.SOFT:TJt.LinkType.HARD,dependencies:f.manifest.dependencies,peerDependencies:f.manifest.peerDependencies,dependenciesMeta:f.manifest.dependenciesMeta,peerDependenciesMeta:f.manifest.peerDependenciesMeta,bin:f.manifest.bin}}rewriteOpts(r,s){return("descriptorHash"in r?r.range:r.reference).slice(uot.WorkspaceResolver.protocol.length)==="."?s:{...s,project:this.originalProject}}};var Dbn=e=>{let t=[];for(let r of e.configuration.plugins.values())for(let s of r.fetchers||[])t.push(new s);return new Sbn.MultiFetcher([new Tbn.VirtualFetcher,new lot(e),...t])},bbn=e=>{let t=[];for(let r of e.configuration.plugins.values())for(let s of r.resolvers||[])t.push(new s);return new sot([new cot,new fot(e),new aot,...t])};var wbn=async e=>{let t=await Vle.xfs.mktempPromise(),r=await vJt.packUtils.genPackStream(e),s=SJt.ppath.join(t,"package.tgz"),c=Vle.xfs.createWriteStream(s);return r.pipe(c),await new Promise(o=>{c.on("finish",o)}),Vle.xfs.readFilePromise(s)},Ibn=async(e,t)=>await Vle.xfs.mktempPromise(async r=>{let s=await vJt.packUtils.genPackStream(e),c=SJt.ppath.join(r,"package.tgz"),o=Vle.xfs.createWriteStream(c);s.pipe(o),await new Promise(A=>{o.on("finish",A)});let f=await Vle.xfs.readFilePromise(c);return await vbn.tgzUtils.convertToZip(f,t)});var wco=async(e,t,r,s,c)=>{process.env.IMAGE_PACK=!0;let o=await xbn.Cache.find(e,{immutable:!0});await t.restoreInstallState(),await Pbn.packUtils.prepareForPack(r,{report:s},async()=>{r.manifest.devDependencies.clear();let f=new Nbn.CwdFS(c),A=await wbn(r);await Rbn.tgzUtils.extractArchiveTo(A,f,{stripComponents:1});let h=DJt.Configuration.create(c,c,e.plugins);h.values.set("compressionLevel",t.configuration.get("compressionLevel")),h.values.set("enableGlobalCache",!1),h.values.set("enableMirror",!1),h.values.set("globalFolder",e.get("globalFolder")),h.values.set("packageExtensions",e.get("packageExtensions")),h.values.set("pnpEnableEsmLoader",e.get("pnpEnableEsmLoader")),h.values.set("cacheFolder",kbn.ppath.join(c,".yarn/packages")),h.values.set("preferAggregateCacheInfo",!0),await DJt.Configuration.updateConfiguration(c,{cacheFolder:".yarn/packages",compressionLevel:h.get("compressionLevel"),enableGlobalCache:h.get("enableGlobalCache"),enableNetwork:h.get("enableNetwork"),enableMirror:h.get("enableMirror"),packageExtensions:h.get("packageExtensions"),nodeLinker:t.configuration.get("nodeLinker")}),await h.getPackageExtensions();let{project:y,workspace:T}=await Bbn.Project.find(h,c);if(!T)throw new Error("Workspace not found");T.manifest.dependencies=r.manifest.dependencies,T.manifest.resolutions=t.topLevelWorkspace.manifest.resolutions,T.manifest.devDependencies.clear(),await y.install({cache:await Wst.find(h,o),fetcher:Dbn(t),resolver:bbn(t),persistProject:!0,report:s})})};var Bco=Yt(Qle(),1);var DLe=class extends Obn.BaseCommand{static paths=[["export"]];destination=Gd.String("-d,--destination",{required:!0});async execute(){let t=await Lbn.Configuration.find(this.context.cwd,this.context.plugins),{project:r,workspace:s}=await Qbn.Project.find(t,this.context.cwd);if(!s)throw new Fbn.WorkspaceRequiredError(r.cwd,this.context.cwd);return(await Mbn.StreamReport.start({configuration:t,stdout:this.context.stdout},async o=>{await O1e.pack(t,r,s,o,this.destination),o.reportInfo(null,`Workspace ${s.manifest.name?Ubn.structUtils.prettyIdent(t,s.manifest.name):s.relativeCwd} exported to ${this.destination}`)})).exitCode()}};var Gbn={commands:[DLe]};var tKt={};Tm(tKt,{FormatCommand:()=>m3e,default:()=>$Mn});var zMn=Yt(Pl(),1),KMn=Yt(On(),1),XMn=Yt(On(),1);Fl();var ZMn=Yt(Rc(),1),eKt=Yt(Ls(),1);var Eot=Yt(Rc(),1),twn=Yt(Rc(),1),zle=Yt(Ls(),1);var pot=class{constructor(t){this.frames=t}get topFrame(){return this.frames.find(t=>t.file)}};var jbn=Yt(IZe(),1);var Hbn=e=>{let t=e.split(` `),r=process.cwd(),s=new jbn.default({cwd:r}),c=t.reduce((o,f)=>{let A=s.parseLine(f.trim());return A&&o.push(A),o},[]);return new pot(c)};var ewn=Yt(Rc(),1),Q1e=Yt(Rc(),1);var mot=Yt(Ls(),1),SY=Yt(Ls(),1);var Xbn=Yt(Rc(),1),hot=Yt(Ls(),1);import{basename as Rco}from"node:path";import{isAbsolute as kco}from"node:path";import{relative as Pco}from"node:path";var BJt=Yt(Ls(),1),Aot=Yt(Rc(),1),Yle=Yt(xye(),1);var Qy="\x1B[",bLe="\x1B]",F1e="\x07",dot=";",qbn=process.env.TERM_PROGRAM==="Apple_Terminal",Ug={};Ug.cursorTo=(e,t)=>{if(typeof e!="number")throw new TypeError("The `x` argument is required");return typeof t!="number"?Qy+(e+1)+"G":Qy+(t+1)+";"+(e+1)+"H"};Ug.cursorMove=(e,t)=>{if(typeof e!="number")throw new TypeError("The `x` argument is required");let r="";return e<0?r+=Qy+-e+"D":e>0&&(r+=Qy+e+"C"),t<0?r+=Qy+-t+"A":t>0&&(r+=Qy+t+"B"),r};Ug.cursorUp=(e=1)=>Qy+e+"A";Ug.cursorDown=(e=1)=>Qy+e+"B";Ug.cursorForward=(e=1)=>Qy+e+"C";Ug.cursorBackward=(e=1)=>Qy+e+"D";Ug.cursorLeft=Qy+"G";Ug.cursorSavePosition=qbn?"\x1B7":Qy+"s";Ug.cursorRestorePosition=qbn?"\x1B8":Qy+"u";Ug.cursorGetPosition=Qy+"6n";Ug.cursorNextLine=Qy+"E";Ug.cursorPrevLine=Qy+"F";Ug.cursorHide=Qy+"?25l";Ug.cursorShow=Qy+"?25h";Ug.eraseLines=e=>{let t="";for(let r=0;r[bLe,"8",dot,dot,t,F1e,e,bLe,"8",dot,dot,F1e].join("");Ug.image=(e,t={})=>{let r=`${bLe}1337;File=inline=1`;return t.width&&(r+=`;width=${t.width}`),t.height&&(r+=`;height=${t.height}`),t.preserveAspectRatio===!1&&(r+=";preserveAspectRatio=0"),r+":"+e.toString("base64")+F1e};Ug.iTerm={setCwd:(e=process.cwd())=>`${bLe}50;CurrentDir=${e}${F1e}`,annotation:(e,t={})=>{let r=`${bLe}1337;`,s=typeof t.x<"u",c=typeof t.y<"u";if((s||c)&&!(s&&c&&typeof t.length<"u"))throw new Error("`x`, `y` and `length` must be defined when `x` or `y` is defined");return e=e.replace(/\|/g,""),r+=t.isHidden?"AddHiddenAnnotation=":"AddAnnotation=",t.length>0?r+=(s?[e,t.length,t.x,t.y]:[t.length,e]).join("|"):r+=e,r+F1e}};var Jbn=Ug;var _ot=Yt(Ybn(),1);function Wle(e,t,{target:r="stdout",...s}={}){return _ot.default[r]?Jbn.link(e,t):s.fallback===!1?e:typeof s.fallback=="function"?s.fallback(e,t):`${e} (\u200B${t}\u200B)`}Wle.isSupported=_ot.default.stdout;Wle.stderr=(e,t,r={})=>Wle(e,t,{target:"stderr",...r});Wle.stderr.isSupported=_ot.default.stderr;var zbn=({children:e,url:t,fallback:r=!0})=>BJt.default.createElement(Aot.Transform,{transform:s=>Wle(s,t,{fallback:r})},BJt.default.createElement(Aot.Text,null,e));zbn.propTypes={children:Yle.default.oneOfType([Yle.default.arrayOf(Yle.default.node),Yle.default.node]).isRequired,url:Yle.default.string.isRequired,fallback:Yle.default.bool};var Kbn=zbn;var xJt=Yt(Ls(),1),Zbn=({url:e,cwd:t=process.cwd(),column:r=0,line:s=0})=>{let c=(0,hot.useMemo)(()=>{try{return new URL(e).pathname}catch{return e}},[e]),o=(0,hot.useMemo)(()=>kco(c)?Pco(t,c):c,[c]),f=(0,hot.useMemo)(()=>o.includes("/node_modules/")?Rco(o):o,[o]);return xJt.default.createElement(Kbn,{url:e},xJt.default.createElement(Xbn.Text,{color:"gray"},f,":",s,":",r))};import{readFileSync as Oco}from"node:fs";import{fileURLToPath as Fco}from"node:url";var $bn=e=>{if(e.sourceMap)return e.sourceMap.payload.sourcesContent[0];if(e.file)try{return Oco(e.file.startsWith("file:/")?Fco(new URL(e.file)):e.file,"utf-8")}catch{return null}return null};var got=({children:e,cwd:t})=>{let r=(0,mot.useMemo)(()=>Hbn(e),[e]),s=(0,mot.useMemo)(()=>r.topFrame||r.frames.at(0),[r]),c=(0,mot.useMemo)(()=>s?$bn(s):null,[s]);return r?SY.default.createElement(Q1e.Box,{flexDirection:"column",flexGrow:1},!!c&&!!r.topFrame?.line&&SY.default.createElement(Q1e.Box,{marginBottom:1},SY.default.createElement(H4,{line:r.topFrame.line,column:r.topFrame.column},c)),r.frames.map(o=>SY.default.createElement(Q1e.Box,{key:LQ(),flexDirection:"row"},SY.default.createElement(Q1e.Box,{flexBasis:"30%"},SY.default.createElement(ewn.Text,null,o.function)),SY.default.createElement(Q1e.Box,{flexBasis:"70%",justifyContent:"flex-end"},!!o.file&&SY.default.createElement(Zbn,{cwd:t,url:o.file,line:o.line,column:o.column}))))):null};var Lco=({children:e})=>e?zle.default.createElement(Eot.Box,{marginBottom:1},zle.default.createElement(twn.Text,{bold:!0,color:"red"},e)):null,jb=({error:e,cwd:t})=>zle.default.createElement(Eot.Box,{flexDirection:"column",borderStyle:"single",borderColor:"gray",paddingX:2,paddingY:1},zle.default.createElement(Lco,null,e.message),!!e.stack&&zle.default.createElement(Eot.Box,null,zle.default.createElement(got,{cwd:t},e.stack)));var OLe=Yt(Rc(),1),jwn=Yt(Ls(),1),Hwn=Yt(Ls(),1),Zle=Yt(Ls(),1);var NJt=Yt(Rc(),1),RJt=Yt(Ls(),1);var BLe=Yt(Ls(),1),plo=Yt(swn(),1);var own={info:"blue",success:"green",error:"red",warning:"yellow"},Xco={styles:{container:({variant:e})=>({flexGrow:1,borderStyle:"round",borderColor:own[e],gap:1,paddingX:1}),iconContainer:()=>({flexShrink:0}),icon:({variant:e})=>({color:own[e]}),content:()=>({flexShrink:1,flexGrow:1,minWidth:0,flexDirection:"column",gap:1}),title:()=>({bold:!0}),message:()=>({})},config({variant:e}){let t;return e==="info"&&(t=ah.info),e==="success"&&(t=ah.tick),e==="error"&&(t=ah.cross),e==="warning"&&(t=ah.warning),{icon:t}}},awn=Xco;var Zco={styles:{container:({color:e})=>({backgroundColor:e}),label:()=>({color:"black"})}},cwn=Zco;var $co={styles:{input:({isFocused:e})=>({dimColor:!e})}},lwn=$co;var elo={styles:{container:()=>({flexDirection:"column"}),option:({isFocused:e})=>({gap:1,paddingLeft:e?0:2}),selectedIndicator:()=>({color:"green"}),focusIndicator:()=>({color:"blue"}),label({isFocused:e,isSelected:t}){let r;return t&&(r="green"),e&&(r="blue"),{color:r}},highlightedText:()=>({bold:!0})}},uwn=elo;var tlo={styles:{list:()=>({flexDirection:"column"}),listItem:()=>({gap:1}),marker:()=>({dimColor:!0}),content:()=>({flexDirection:"column"})}},fwn=tlo;var rlo={styles:{container:()=>({flexGrow:1,minWidth:0}),completed:()=>({color:"magenta"}),remaining:()=>({dimColor:!0})},config:()=>({completedCharacter:ah.square,remainingCharacter:ah.squareLightShade})},pwn=rlo;var nlo={styles:{container:()=>({flexDirection:"column"}),option:({isFocused:e})=>({gap:1,paddingLeft:e?0:2}),selectedIndicator:()=>({color:"green"}),focusIndicator:()=>({color:"blue"}),label({isFocused:e,isSelected:t}){let r;return t&&(r="green"),e&&(r="blue"),{color:r}},highlightedText:()=>({bold:!0})}},dwn=nlo;var ilo={styles:{container:()=>({gap:1}),frame:()=>({color:"blue"}),label:()=>({})}},_wn=ilo;var slo={success:"green",error:"red",warning:"yellow",info:"blue"},olo={success:ah.tick,error:ah.cross,warning:ah.warning,info:ah.info},alo={styles:{container:()=>({gap:1}),iconContainer:()=>({flexShrink:0}),icon:({variant:e})=>({color:slo[e]}),message:()=>({})},config:({variant:e})=>({icon:olo[e]})},Awn=alo;var clo={styles:{list:()=>({flexDirection:"column"}),listItem:()=>({gap:1}),marker:()=>({dimColor:!0}),content:()=>({flexDirection:"column"})},config:()=>({marker:ah.line})},hwn=clo;var llo={styles:{value:()=>({})}},mwn=llo;var ulo={styles:{value:()=>({})}},gwn=ulo;var flo={styles:{value:()=>({})}},Ewn=flo;var dlo={components:{Alert:awn,Badge:cwn,ConfirmInput:lwn,MultiSelect:uwn,OrderedList:fwn,ProgressBar:pwn,Select:dwn,Spinner:_wn,StatusMessage:Awn,UnorderedList:hwn,TextInput:mwn,EmailInput:gwn,PasswordInput:Ewn}},_lo=(0,BLe.createContext)(dlo);var AS=e=>(0,BLe.useContext)(_lo).components[e];function dR({children:e,color:t="magenta"}){let{styles:r}=AS("Badge"),s=e;return typeof e=="string"&&(s=e.toUpperCase()),RJt.default.createElement(NJt.Text,{...r.container({color:t})}," ",RJt.default.createElement(NJt.Text,{...r.label()},s)," ")}var Alo=Yt(Ls(),1),ywn=Yt(Rc(),1);var Swn=Yt(Rc(),1),vY=Yt(Ls(),1);var NLe=Yt(Rc(),1),U1e=Yt(Ls(),1);var Cwn=Yt(Ls(),1);var xLe=ah.line;var yot=(0,Cwn.createContext)({marker:xLe});function Iwn({children:e}){let{marker:t}=(0,U1e.useContext)(yot),{styles:r}=AS("UnorderedList");return U1e.default.createElement(NLe.Box,{...r.listItem()},U1e.default.createElement(NLe.Text,{...r.marker()},t),U1e.default.createElement(NLe.Box,{...r.content()},e))}var Twn=Yt(Ls(),1),kJt=(0,Twn.createContext)({depth:0});function hlo({children:e}){let{depth:t}=(0,vY.useContext)(kJt),{styles:r,config:s}=AS("UnorderedList"),c=(0,vY.useMemo)(()=>({depth:t+1}),[t]),o=(0,vY.useMemo)(()=>{let{marker:f}=s();return typeof f=="string"?{marker:f}:Array.isArray(f)?{marker:f[t]??f.at(-1)??xLe}:{marker:xLe}},[s,t]);return vY.default.createElement(kJt.Provider,{value:c},vY.default.createElement(yot.Provider,{value:o},vY.default.createElement(Swn.Box,{...r.list()},e)))}hlo.Item=Iwn;var ylo=Yt(Ls(),1),Dwn=Yt(Rc(),1);var mlo=Yt(Ls(),1),vwn=Yt(Rc(),1);var RLe=Yt(Ls(),1);var Elo=Yt(Rc(),1);var Kle=Yt(Ls(),1),Xle=Yt(Rc(),1);function h6({value:e}){let[t,r]=(0,Kle.useState)(0),[s,c]=(0,Kle.useState)(null);if(s){let T=(0,Xle.measureElement)(s);T.width!==t&&r(T.width)}let o=Math.min(100,Math.max(0,e)),f=Math.round(o/100*t),A=t-f,{styles:h,config:y}=AS("ProgressBar");return Kle.default.createElement(Xle.Box,{ref:c,...h.container()},f>0&&Kle.default.createElement(Xle.Text,{...h.completed()},y().completedCharacter.repeat(f)),A>0&&Kle.default.createElement(Xle.Text,{...h.remaining()},y().remainingCharacter.repeat(A)))}var Tlo=Yt(Ls(),1),wwn=Yt(Rc(),1);var Clo=Yt(Ls(),1),bwn=Yt(Rc(),1);var kLe=Yt(Ls(),1);var Ilo=Yt(Rc(),1);var Slo=Yt(Ls(),1),xwn=Yt(Rc(),1);var Bwn=Yt(Ls(),1);var blo=Yt(Ls(),1),wlo=Yt(Rc(),1);var Cot=Yt(Ls(),1);var vlo=Yt(Ls(),1),Dlo=Yt(Rc(),1);var cKa=s_.inverse(" ");var kwn=Yt(Rc(),1),K5=Yt(Ls(),1);var PLe=Yt(Rc(),1),G1e=Yt(Ls(),1);var Nwn=Yt(Ls(),1);var Iot=(0,Nwn.createContext)({marker:ah.line});function Tot({children:e}){let{marker:t}=(0,G1e.useContext)(Iot),{styles:r}=AS("OrderedList");return G1e.default.createElement(PLe.Box,{...r.listItem()},G1e.default.createElement(PLe.Text,{...r.marker()},t),G1e.default.createElement(PLe.Box,{...r.content()},e))}var Rwn=Yt(Ls(),1),PJt=(0,Rwn.createContext)({marker:""});function Blo({children:e}){let{marker:t}=(0,K5.useContext)(PJt),{styles:r}=AS("OrderedList"),s=0;for(let o of K5.default.Children.toArray(e))!(0,K5.isValidElement)(o)||o.type!==Tot||s++;let c=String(s).length;return K5.default.createElement(kwn.Box,{...r.list()},K5.default.Children.map(e,(o,f)=>{if(!(0,K5.isValidElement)(o)||o.type!==Tot)return o;let A=`${String(f+1).padStart(c)}.`,h=`${t}${A}`;return K5.default.createElement(PJt.Provider,{value:{marker:h}},K5.default.createElement(Iot.Provider,{value:{marker:h}},o))}))}Blo.Item=Tot;var Rlo=Yt(Ls(),1),klo=Yt(Rc(),1);var OJt=Yt(Ls(),1);var xlo=Yt(Ls(),1),Nlo=Yt(Rc(),1);var kKa=s_.inverse(" ");var Plo=Yt(Ls(),1),Pwn=Yt(Rc(),1);var Olo=Yt(Ls(),1),Own=Yt(Rc(),1);var Qlo=Yt(Ls(),1),Mlo=Yt(Rc(),1);var Sot=Yt(Ls(),1);var Flo=Yt(Ls(),1),Llo=Yt(Rc(),1);var $Ka=s_.inverse(" ");var Fwn=Yt(Ls(),1),FJt=Yt(Ls(),1),Lwn=Yt(Ls(),1),Qwn=({formatter:e})=>{let[t,r]=(0,FJt.useState)(0),[s,c]=(0,FJt.useState)(0);return(0,Fwn.useEffect)(()=>{let o=({files:h})=>{r(h.length)},f=()=>{c(h=>h+1)},A=()=>{c(t)};return e.on("start",o),e.on("format:end",f),e.on("end",A),()=>{e.off("start",o),e.off("format:end",f),e.off("end",A)}},[e,t,r,c]),Lwn.default.createElement(h6,{value:t>0?s/t*100:0})};import{relative as Mwn}from"node:path";var j1e=Yt(Rc(),1),s3=Yt(Rc(),1),Uwn=Yt(Ls(),1),vot=Yt(Ls(),1),Av=Yt(Ls(),1);var Ulo=({changed:e})=>e?Av.default.createElement(s3.Text,{color:"green"},ah.tick):Av.default.createElement(s3.Text,{color:"white"},ah.circleDotted),Glo=({changed:e,children:t})=>e?Av.default.createElement(s3.Text,{color:"white"},t):Av.default.createElement(s3.Text,{color:"gray"},t),Gwn=({cwd:e,formatter:t})=>{let[r,s]=(0,vot.useState)(void 0),[c,o]=(0,vot.useState)(0),[f,A]=(0,vot.useState)(0);return(0,Uwn.useEffect)(()=>{let h=w=>{o(w.files.length)},y=w=>{s({changed:!1,file:Mwn(e,w.file)})},T=w=>{s({changed:w.changed,file:Mwn(e,w.file)}),w.changed&&A(b=>b+1)};return t.on("start",h),t.on("format:start",y),t.on("format:end",T),()=>{t.off("start",h),t.off("format:start",y),t.off("format:end",T)}},[t,s,o,A]),r?Av.default.createElement(j1e.Box,{flexDirection:"row",width:"100%"},Av.default.createElement(j1e.Box,{flexGrow:1},Av.default.createElement(dR,{color:"cyan"},"Format:"),Av.default.createElement(s3.Text,null," "),Av.default.createElement(Glo,{changed:r.changed},r.file)),Av.default.createElement(j1e.Box,{flexDirection:"row"},Av.default.createElement(j1e.Box,null,Av.default.createElement(Ulo,{changed:r.changed}),Av.default.createElement(s3.Text,null," "),Av.default.createElement(s3.Text,{color:"green"},f," Formatted"),Av.default.createElement(s3.Text,null," "),Av.default.createElement(s3.Text,{color:"white"},c," Files"),Av.default.createElement(s3.Text,null," ")))):Av.default.createElement(j1e.Box,{flexDirection:"row"},Av.default.createElement(dR,{color:"cyan"},"Format:"),Av.default.createElement(s3.Text,null," "),Av.default.createElement(s3.Text,{color:"white"},"Loading files..."))};var qwn=({cwd:e,formatter:t})=>{let[r,s]=(0,jwn.useState)(!1);return(0,Hwn.useEffect)(()=>{let c=()=>{setTimeout(()=>{s(!0)},1)};return t.on("end",c),()=>{t.off("end",c)}},[s]),r?null:Zle.default.createElement(OLe.Box,{position:"relative",height:7},Zle.default.createElement(OLe.Box,{flexDirection:"column",borderColor:"gray",padding:1,borderStyle:"round",position:"absolute",height:7,width:"100%"},Zle.default.createElement(OLe.Box,null,Zle.default.createElement(Gwn,{cwd:e,formatter:t})),Zle.default.createElement(OLe.Box,{marginTop:1,marginBottom:1},Zle.default.createElement(Qwn,{formatter:t}))))};import kOo from"node:events";import{writeFile as POo}from"node:fs/promises";import{readFile as WMn}from"node:fs/promises";import{relative as OOo}from"node:path";import{join as FOo}from"node:path";var V1e={};Tm(V1e,{default:()=>tfo,parsers:()=>J1e});var jlo=Object.create,jJt=Object.defineProperty,Hlo=Object.getOwnPropertyDescriptor,qlo=Object.getOwnPropertyNames,Jlo=Object.getPrototypeOf,Vlo=Object.prototype.hasOwnProperty,Wlo=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Ylo=(e,t)=>{for(var r in t)jJt(e,r,{get:t[r],enumerable:!0})},zlo=(e,t,r,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let c of qlo(t))!Vlo.call(e,c)&&c!==r&&jJt(e,c,{get:()=>t[c],enumerable:!(s=Hlo(t,c))||s.enumerable});return e},rBn=(e,t,r)=>(r=e!=null?jlo(Jlo(e)):{},zlo(t||!e||!e.__esModule?jJt(r,"default",{value:e,enumerable:!0}):r,e)),nBn=Wlo(e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});function t(te,M){if(te==null)return{};var oe={},ve=Object.keys(te),it,Xt;for(Xt=0;Xt=0)&&(oe[it]=te[it]);return oe}var r=class{constructor(te,M,oe){this.line=void 0,this.column=void 0,this.index=void 0,this.line=te,this.column=M,this.index=oe}},s=class{constructor(te,M){this.start=void 0,this.end=void 0,this.filename=void 0,this.identifierName=void 0,this.start=te,this.end=M}};function c(te,M){let{line:oe,column:ve,index:it}=te;return new r(oe,ve+M,it+M)}var o="BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED",f={ImportMetaOutsideModule:{message:`import.meta may appear only with 'sourceType: "module"'`,code:o},ImportOutsideModule:{message:`'import' and 'export' may appear only with 'sourceType: "module"'`,code:o}},A={ArrayPattern:"array destructuring pattern",AssignmentExpression:"assignment expression",AssignmentPattern:"assignment expression",ArrowFunctionExpression:"arrow function expression",ConditionalExpression:"conditional expression",CatchClause:"catch clause",ForOfStatement:"for-of statement",ForInStatement:"for-in statement",ForStatement:"for-loop",FormalParameters:"function parameter list",Identifier:"identifier",ImportSpecifier:"import specifier",ImportDefaultSpecifier:"import default specifier",ImportNamespaceSpecifier:"import namespace specifier",ObjectPattern:"object destructuring pattern",ParenthesizedExpression:"parenthesized expression",RestElement:"rest element",UpdateExpression:{true:"prefix operation",false:"postfix operation"},VariableDeclarator:"variable declaration",YieldExpression:"yield expression"},h=te=>te.type==="UpdateExpression"?A.UpdateExpression[`${te.prefix}`]:A[te.type],y={AccessorIsGenerator:({kind:te})=>`A ${te}ter cannot be a generator.`,ArgumentsInClass:"'arguments' is only allowed in functions and class methods.",AsyncFunctionInSingleStatementContext:"Async functions can only be declared at the top level or inside a block.",AwaitBindingIdentifier:"Can not use 'await' as identifier inside an async function.",AwaitBindingIdentifierInStaticBlock:"Can not use 'await' as identifier inside a static block.",AwaitExpressionFormalParameter:"'await' is not allowed in async function parameters.",AwaitUsingNotInAsyncContext:"'await using' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncContext:"'await' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncFunction:"'await' is only allowed within async functions.",BadGetterArity:"A 'get' accessor must not have any formal parameters.",BadSetterArity:"A 'set' accessor must have exactly one formal parameter.",BadSetterRestParameter:"A 'set' accessor function argument must not be a rest parameter.",ConstructorClassField:"Classes may not have a field named 'constructor'.",ConstructorClassPrivateField:"Classes may not have a private field named '#constructor'.",ConstructorIsAccessor:"Class constructor may not be an accessor.",ConstructorIsAsync:"Constructor can't be an async function.",ConstructorIsGenerator:"Constructor can't be a generator.",DeclarationMissingInitializer:({kind:te})=>`Missing initializer in ${te} declaration.`,DecoratorArgumentsOutsideParentheses:"Decorator arguments must be moved inside parentheses: use '@(decorator(args))' instead of '@(decorator)(args)'.",DecoratorBeforeExport:"Decorators must be placed *before* the 'export' keyword. Remove the 'decoratorsBeforeExport: true' option to use the 'export @decorator class {}' syntax.",DecoratorsBeforeAfterExport:"Decorators can be placed *either* before or after the 'export' keyword, but not in both locations at the same time.",DecoratorConstructor:"Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?",DecoratorExportClass:"Decorators must be placed *after* the 'export' keyword. Remove the 'decoratorsBeforeExport: false' option to use the '@decorator export class {}' syntax.",DecoratorSemicolon:"Decorators must not be followed by a semicolon.",DecoratorStaticBlock:"Decorators can't be used with a static block.",DeferImportRequiresNamespace:'Only `import defer * as x from "./module"` is valid.',DeletePrivateField:"Deleting a private field is not allowed.",DestructureNamedImport:"ES2015 named imports do not destructure. Use another statement for destructuring after the import.",DuplicateConstructor:"Duplicate constructor in the same class.",DuplicateDefaultExport:"Only one default export allowed per module.",DuplicateExport:({exportName:te})=>`\`${te}\` has already been exported. Exported identifiers must be unique.`,DuplicateProto:"Redefinition of __proto__ property.",DuplicateRegExpFlags:"Duplicate regular expression flag.",DynamicImportPhaseRequiresImportExpressions:({phase:te})=>`'import.${te}(...)' can only be parsed when using the 'createImportExpressions' option.`,ElementAfterRest:"Rest element must be last element.",EscapedCharNotAnIdentifier:"Invalid Unicode escape.",ExportBindingIsString:({localName:te,exportName:M})=>`A string literal cannot be used as an exported binding without \`from\`. - Did you mean \`export { '${te}' as '${M}' } from 'some-module'\`?`,ExportDefaultFromAsIdentifier:"'from' is not allowed as an identifier after 'export default'.",ForInOfLoopInitializer:({type:te})=>`'${te==="ForInStatement"?"for-in":"for-of"}' loop variable declaration may not have an initializer.`,ForInUsing:"For-in loop may not start with 'using' declaration.",ForOfAsync:"The left-hand side of a for-of loop may not be 'async'.",ForOfLet:"The left-hand side of a for-of loop may not start with 'let'.",GeneratorInSingleStatementContext:"Generators can only be declared at the top level or inside a block.",IllegalBreakContinue:({type:te})=>`Unsyntactic ${te==="BreakStatement"?"break":"continue"}.`,IllegalLanguageModeDirective:"Illegal 'use strict' directive in function with non-simple parameter list.",IllegalReturn:"'return' outside of function.",ImportAttributesUseAssert:"The `assert` keyword in import attributes is deprecated and it has been replaced by the `with` keyword. You can enable the `deprecatedAssertSyntax: true` option in the import attributes plugin to suppress this error.",ImportBindingIsString:({importName:te})=>`A string literal cannot be used as an imported binding. - Did you mean \`import { "${te}" as foo }\`?`,ImportCallArgumentTrailingComma:"Trailing comma is disallowed inside import(...) arguments.",ImportCallArity:({maxArgumentCount:te})=>`\`import()\` requires exactly ${te===1?"one argument":"one or two arguments"}.`,ImportCallNotNewExpression:"Cannot use new with import(...).",ImportCallSpreadArgument:"`...` is not allowed in `import()`.",ImportJSONBindingNotDefault:"A JSON module can only be imported with `default`.",ImportReflectionHasAssertion:"`import module x` cannot have assertions.",ImportReflectionNotBinding:'Only `import module x from "./module"` is valid.',IncompatibleRegExpUVFlags:"The 'u' and 'v' regular expression flags cannot be enabled at the same time.",InvalidBigIntLiteral:"Invalid BigIntLiteral.",InvalidCodePoint:"Code point out of bounds.",InvalidCoverInitializedName:"Invalid shorthand property initializer.",InvalidDecimal:"Invalid decimal.",InvalidDigit:({radix:te})=>`Expected number in radix ${te}.`,InvalidEscapeSequence:"Bad character escape sequence.",InvalidEscapeSequenceTemplate:"Invalid escape sequence in template.",InvalidEscapedReservedWord:({reservedWord:te})=>`Escape sequence in keyword ${te}.`,InvalidIdentifier:({identifierName:te})=>`Invalid identifier ${te}.`,InvalidLhs:({ancestor:te})=>`Invalid left-hand side in ${h(te)}.`,InvalidLhsBinding:({ancestor:te})=>`Binding invalid left-hand side in ${h(te)}.`,InvalidLhsOptionalChaining:({ancestor:te})=>`Invalid optional chaining in the left-hand side of ${h(te)}.`,InvalidNumber:"Invalid number.",InvalidOrMissingExponent:"Floating-point numbers require a valid exponent after the 'e'.",InvalidOrUnexpectedToken:({unexpected:te})=>`Unexpected character '${te}'.`,InvalidParenthesizedAssignment:"Invalid parenthesized assignment pattern.",InvalidPrivateFieldResolution:({identifierName:te})=>`Private name #${te} is not defined.`,InvalidPropertyBindingPattern:"Binding member expression.",InvalidRecordProperty:"Only properties and spread elements are allowed in record definitions.",InvalidRestAssignmentPattern:"Invalid rest operator's argument.",LabelRedeclaration:({labelName:te})=>`Label '${te}' is already declared.`,LetInLexicalBinding:"'let' is disallowed as a lexically bound name.",LineTerminatorBeforeArrow:"No line break is allowed before '=>'.",MalformedRegExpFlags:"Invalid regular expression flag.",MissingClassName:"A class name is required.",MissingEqInAssignment:"Only '=' operator can be used for specifying default value.",MissingSemicolon:"Missing semicolon.",MissingPlugin:({missingPlugin:te})=>`This experimental syntax requires enabling the parser plugin: ${te.map(M=>JSON.stringify(M)).join(", ")}.`,MissingOneOfPlugins:({missingPlugin:te})=>`This experimental syntax requires enabling one of the following parser plugin(s): ${te.map(M=>JSON.stringify(M)).join(", ")}.`,MissingUnicodeEscape:"Expecting Unicode escape sequence \\uXXXX.",MixingCoalesceWithLogical:"Nullish coalescing operator(??) requires parens when mixing with logical operators.",ModuleAttributeDifferentFromType:"The only accepted module attribute is `type`.",ModuleAttributeInvalidValue:"Only string literals are allowed as module attribute values.",ModuleAttributesWithDuplicateKeys:({key:te})=>`Duplicate key "${te}" is not allowed in module attributes.`,ModuleExportNameHasLoneSurrogate:({surrogateCharCode:te})=>`An export name cannot include a lone surrogate, found '\\u${te.toString(16)}'.`,ModuleExportUndefined:({localName:te})=>`Export '${te}' is not defined.`,MultipleDefaultsInSwitch:"Multiple default clauses.",NewlineAfterThrow:"Illegal newline after throw.",NoCatchOrFinally:"Missing catch or finally clause.",NumberIdentifier:"Identifier directly after number.",NumericSeparatorInEscapeSequence:"Numeric separators are not allowed inside unicode escape sequences or hex escape sequences.",ObsoleteAwaitStar:"'await*' has been removed from the async functions proposal. Use Promise.all() instead.",OptionalChainingNoNew:"Constructors in/after an Optional Chain are not allowed.",OptionalChainingNoTemplate:"Tagged Template Literals are not allowed in optionalChain.",OverrideOnConstructor:"'override' modifier cannot appear on a constructor declaration.",ParamDupe:"Argument name clash.",PatternHasAccessor:"Object pattern can't contain getter or setter.",PatternHasMethod:"Object pattern can't contain methods.",PrivateInExpectedIn:({identifierName:te})=>`Private names are only allowed in property accesses (\`obj.#${te}\`) or in \`in\` expressions (\`#${te} in obj\`).`,PrivateNameRedeclaration:({identifierName:te})=>`Duplicate private name #${te}.`,RecordExpressionBarIncorrectEndSyntaxType:"Record expressions ending with '|}' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",RecordExpressionBarIncorrectStartSyntaxType:"Record expressions starting with '{|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",RecordExpressionHashIncorrectStartSyntaxType:"Record expressions starting with '#{' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.",RecordNoProto:"'__proto__' is not allowed in Record expressions.",RestTrailingComma:"Unexpected trailing comma after rest element.",SloppyFunction:"In non-strict mode code, functions can only be declared at top level or inside a block.",SloppyFunctionAnnexB:"In non-strict mode code, functions can only be declared at top level, inside a block, or as the body of an if statement.",SourcePhaseImportRequiresDefault:'Only `import source x from "./module"` is valid.',StaticPrototype:"Classes may not have static property named prototype.",SuperNotAllowed:"`super()` is only valid inside a class constructor of a subclass. Maybe a typo in the method name ('constructor') or not extending another class?",SuperPrivateField:"Private fields can't be accessed on super.",TrailingDecorator:"Decorators must be attached to a class element.",TupleExpressionBarIncorrectEndSyntaxType:"Tuple expressions ending with '|]' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",TupleExpressionBarIncorrectStartSyntaxType:"Tuple expressions starting with '[|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",TupleExpressionHashIncorrectStartSyntaxType:"Tuple expressions starting with '#[' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.",UnexpectedArgumentPlaceholder:"Unexpected argument placeholder.",UnexpectedAwaitAfterPipelineBody:'Unexpected "await" after pipeline body; await must have parentheses in minimal proposal.',UnexpectedDigitAfterHash:"Unexpected digit after hash token.",UnexpectedImportExport:"'import' and 'export' may only appear at the top level.",UnexpectedKeyword:({keyword:te})=>`Unexpected keyword '${te}'.`,UnexpectedLeadingDecorator:"Leading decorators must be attached to a class declaration.",UnexpectedLexicalDeclaration:"Lexical declaration cannot appear in a single-statement context.",UnexpectedNewTarget:"`new.target` can only be used in functions or class properties.",UnexpectedNumericSeparator:"A numeric separator is only allowed between two digits.",UnexpectedPrivateField:"Unexpected private name.",UnexpectedReservedWord:({reservedWord:te})=>`Unexpected reserved word '${te}'.`,UnexpectedSuper:"'super' is only allowed in object methods and classes.",UnexpectedToken:({expected:te,unexpected:M})=>`Unexpected token${M?` '${M}'.`:""}${te?`, expected "${te}"`:""}`,UnexpectedTokenUnaryExponentiation:"Illegal expression. Wrap left hand side or entire exponentiation in parentheses.",UnexpectedUsingDeclaration:"Using declaration cannot appear in the top level when source type is `script`.",UnsupportedBind:"Binding should be performed on object property.",UnsupportedDecoratorExport:"A decorated export must export a class declaration.",UnsupportedDefaultExport:"Only expressions, functions or classes are allowed as the `default` export.",UnsupportedImport:"`import` can only be used in `import()` or `import.meta`.",UnsupportedMetaProperty:({target:te,onlyValidPropertyName:M})=>`The only valid meta property for ${te} is ${te}.${M}.`,UnsupportedParameterDecorator:"Decorators cannot be used to decorate parameters.",UnsupportedPropertyDecorator:"Decorators cannot be used to decorate object literal properties.",UnsupportedSuper:"'super' can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop]).",UnterminatedComment:"Unterminated comment.",UnterminatedRegExp:"Unterminated regular expression.",UnterminatedString:"Unterminated string constant.",UnterminatedTemplate:"Unterminated template.",UsingDeclarationExport:"Using declaration cannot be exported.",UsingDeclarationHasBindingPattern:"Using declaration cannot have destructuring patterns.",VarRedeclaration:({identifierName:te})=>`Identifier '${te}' has already been declared.`,YieldBindingIdentifier:"Can not use 'yield' as identifier inside a generator.",YieldInParameter:"Yield expression is not allowed in formal parameters.",ZeroDigitNumericSeparator:"Numeric separator can not be used after leading 0."},T={StrictDelete:"Deleting local variable in strict mode.",StrictEvalArguments:({referenceName:te})=>`Assigning to '${te}' in strict mode.`,StrictEvalArgumentsBinding:({bindingName:te})=>`Binding '${te}' in strict mode.`,StrictFunction:"In strict mode code, functions can only be declared at top level or inside a block.",StrictNumericEscape:"The only valid numeric escape in strict mode is '\\0'.",StrictOctalLiteral:"Legacy octal literals are not allowed in strict mode.",StrictWith:"'with' in strict mode."},w=new Set(["ArrowFunctionExpression","AssignmentExpression","ConditionalExpression","YieldExpression"]),b={PipeBodyIsTighter:"Unexpected yield after pipeline body; any yield expression acting as Hack-style pipe body must be parenthesized due to its loose operator precedence.",PipeTopicRequiresHackPipes:'Topic reference is used, but the pipelineOperator plugin was not passed a "proposal": "hack" or "smart" option.',PipeTopicUnbound:"Topic reference is unbound; it must be inside a pipe body.",PipeTopicUnconfiguredToken:({token:te})=>`Invalid topic token ${te}. In order to use ${te} as a topic reference, the pipelineOperator plugin must be configured with { "proposal": "hack", "topicToken": "${te}" }.`,PipeTopicUnused:"Hack-style pipe body does not contain a topic reference; Hack-style pipes must use topic at least once.",PipeUnparenthesizedBody:({type:te})=>`Hack-style pipe body cannot be an unparenthesized ${h({type:te})}; please wrap it in parentheses.`,PipelineBodyNoArrow:'Unexpected arrow "=>" after pipeline body; arrow function in pipeline body must be parenthesized.',PipelineBodySequenceExpression:"Pipeline body may not be a comma-separated sequence expression.",PipelineHeadSequenceExpression:"Pipeline head should not be a comma-separated sequence expression.",PipelineTopicUnused:"Pipeline is in topic style but does not use topic reference.",PrimaryTopicNotAllowed:"Topic reference was used in a lexical context without topic binding.",PrimaryTopicRequiresSmartPipeline:'Topic reference is used, but the pipelineOperator plugin was not passed a "proposal": "hack" or "smart" option.'},U=["toMessage"],x=["message"];function J(te,M,oe){Object.defineProperty(te,M,{enumerable:!1,configurable:!0,value:oe})}function Z(te){let{toMessage:M}=te,oe=t(te,U);return function ve(it,Xt){let Pr=new SyntaxError;return Object.assign(Pr,oe,{loc:it,pos:it.index}),"missingPlugin"in Xt&&Object.assign(Pr,{missingPlugin:Xt.missingPlugin}),J(Pr,"clone",function(Xr={}){var Qn;let{line:Mn,column:Qo,index:xc}=(Qn=Xr.loc)!=null?Qn:it;return ve(new r(Mn,Qo,xc),Object.assign({},Xt,Xr.details))}),J(Pr,"details",Xt),Object.defineProperty(Pr,"message",{configurable:!0,get(){let Xr=`${M(Xt)} (${it.line}:${it.column})`;return this.message=Xr,Xr},set(Xr){Object.defineProperty(this,"message",{value:Xr,writable:!0})}}),Pr}}function le(te,M){if(Array.isArray(te))return ve=>le(ve,te[0]);let oe={};for(let ve of Object.keys(te)){let it=te[ve],Xt=typeof it=="string"?{message:()=>it}:typeof it=="function"?{message:it}:it,{message:Pr}=Xt,Xr=t(Xt,x),Qn=typeof Pr=="string"?()=>Pr:Pr;oe[ve]=Z(Object.assign({code:"BABEL_PARSER_SYNTAX_ERROR",reasonCode:ve,toMessage:Qn},M?{syntaxPlugin:M}:{},Xr))}return oe}var ce=Object.assign({},le(f),le(y),le(T),le`pipelineOperator`(b)),{defineProperty:_e}=Object,me=(te,M)=>{te&&_e(te,M,{enumerable:!1,value:te[M]})};function Ee(te){return me(te.loc.start,"index"),me(te.loc.end,"index"),te}var ge=te=>class extends te{parse(){let M=Ee(super.parse());return this.options.tokens&&(M.tokens=M.tokens.map(Ee)),M}parseRegExpLiteral({pattern:M,flags:oe}){let ve=null;try{ve=new RegExp(M,oe)}catch{}let it=this.estreeParseLiteral(ve);return it.regex={pattern:M,flags:oe},it}parseBigIntLiteral(M){let oe;try{oe=BigInt(M)}catch{oe=null}let ve=this.estreeParseLiteral(oe);return ve.bigint=String(ve.value||M),ve}parseDecimalLiteral(M){let oe=this.estreeParseLiteral(null);return oe.decimal=String(oe.value||M),oe}estreeParseLiteral(M){return this.parseLiteral(M,"Literal")}parseStringLiteral(M){return this.estreeParseLiteral(M)}parseNumericLiteral(M){return this.estreeParseLiteral(M)}parseNullLiteral(){return this.estreeParseLiteral(null)}parseBooleanLiteral(M){return this.estreeParseLiteral(M)}directiveToStmt(M){let oe=M.value;delete M.value,oe.type="Literal",oe.raw=oe.extra.raw,oe.value=oe.extra.expressionValue;let ve=M;return ve.type="ExpressionStatement",ve.expression=oe,ve.directive=oe.extra.rawValue,delete oe.extra,ve}initFunction(M,oe){super.initFunction(M,oe),M.expression=!1}checkDeclaration(M){M!=null&&this.isObjectProperty(M)?this.checkDeclaration(M.value):super.checkDeclaration(M)}getObjectOrClassMethodParams(M){return M.value.params}isValidDirective(M){var oe;return M.type==="ExpressionStatement"&&M.expression.type==="Literal"&&typeof M.expression.value=="string"&&!((oe=M.expression.extra)!=null&&oe.parenthesized)}parseBlockBody(M,oe,ve,it,Xt){super.parseBlockBody(M,oe,ve,it,Xt);let Pr=M.directives.map(Xr=>this.directiveToStmt(Xr));M.body=Pr.concat(M.body),delete M.directives}pushClassMethod(M,oe,ve,it,Xt,Pr){this.parseMethod(oe,ve,it,Xt,Pr,"ClassMethod",!0),oe.typeParameters&&(oe.value.typeParameters=oe.typeParameters,delete oe.typeParameters),M.body.push(oe)}parsePrivateName(){let M=super.parsePrivateName();return this.getPluginOption("estree","classFeatures")?this.convertPrivateNameToPrivateIdentifier(M):M}convertPrivateNameToPrivateIdentifier(M){let oe=super.getPrivateNameSV(M);return M=M,delete M.id,M.name=oe,M.type="PrivateIdentifier",M}isPrivateName(M){return this.getPluginOption("estree","classFeatures")?M.type==="PrivateIdentifier":super.isPrivateName(M)}getPrivateNameSV(M){return this.getPluginOption("estree","classFeatures")?M.name:super.getPrivateNameSV(M)}parseLiteral(M,oe){let ve=super.parseLiteral(M,oe);return ve.raw=ve.extra.raw,delete ve.extra,ve}parseFunctionBody(M,oe,ve=!1){super.parseFunctionBody(M,oe,ve),M.expression=M.body.type!=="BlockStatement"}parseMethod(M,oe,ve,it,Xt,Pr,Xr=!1){let Qn=this.startNode();return Qn.kind=M.kind,Qn=super.parseMethod(Qn,oe,ve,it,Xt,Pr,Xr),Qn.type="FunctionExpression",delete Qn.kind,M.value=Qn,Pr==="ClassPrivateMethod"&&(M.computed=!1),this.finishNode(M,"MethodDefinition")}nameIsConstructor(M){return M.type==="Literal"?M.value==="constructor":super.nameIsConstructor(M)}parseClassProperty(...M){let oe=super.parseClassProperty(...M);return this.getPluginOption("estree","classFeatures")&&(oe.type="PropertyDefinition"),oe}parseClassPrivateProperty(...M){let oe=super.parseClassPrivateProperty(...M);return this.getPluginOption("estree","classFeatures")&&(oe.type="PropertyDefinition",oe.computed=!1),oe}parseObjectMethod(M,oe,ve,it,Xt){let Pr=super.parseObjectMethod(M,oe,ve,it,Xt);return Pr&&(Pr.type="Property",Pr.kind==="method"&&(Pr.kind="init"),Pr.shorthand=!1),Pr}parseObjectProperty(M,oe,ve,it){let Xt=super.parseObjectProperty(M,oe,ve,it);return Xt&&(Xt.kind="init",Xt.type="Property"),Xt}isValidLVal(M,oe,ve){return M==="Property"?"value":super.isValidLVal(M,oe,ve)}isAssignable(M,oe){return M!=null&&this.isObjectProperty(M)?this.isAssignable(M.value,oe):super.isAssignable(M,oe)}toAssignable(M,oe=!1){if(M!=null&&this.isObjectProperty(M)){let{key:ve,value:it}=M;this.isPrivateName(ve)&&this.classScope.usePrivateName(this.getPrivateNameSV(ve),ve.loc.start),this.toAssignable(it,oe)}else super.toAssignable(M,oe)}toAssignableObjectExpressionProp(M,oe,ve){M.type==="Property"&&(M.kind==="get"||M.kind==="set")?this.raise(ce.PatternHasAccessor,M.key):M.type==="Property"&&M.method?this.raise(ce.PatternHasMethod,M.key):super.toAssignableObjectExpressionProp(M,oe,ve)}finishCallExpression(M,oe){let ve=super.finishCallExpression(M,oe);if(ve.callee.type==="Import"){if(ve.type="ImportExpression",ve.source=ve.arguments[0],this.hasPlugin("importAttributes")||this.hasPlugin("importAssertions")){var it,Xt;ve.options=(it=ve.arguments[1])!=null?it:null,ve.attributes=(Xt=ve.arguments[1])!=null?Xt:null}delete ve.arguments,delete ve.callee}return ve}toReferencedArguments(M){M.type!=="ImportExpression"&&super.toReferencedArguments(M)}parseExport(M,oe){let ve=this.state.lastTokStartLoc,it=super.parseExport(M,oe);switch(it.type){case"ExportAllDeclaration":it.exported=null;break;case"ExportNamedDeclaration":it.specifiers.length===1&&it.specifiers[0].type==="ExportNamespaceSpecifier"&&(it.type="ExportAllDeclaration",it.exported=it.specifiers[0].exported,delete it.specifiers);case"ExportDefaultDeclaration":{var Xt;let{declaration:Pr}=it;Pr?.type==="ClassDeclaration"&&((Xt=Pr.decorators)==null?void 0:Xt.length)>0&&Pr.start===it.start&&this.resetStartLocation(it,ve)}break}return it}parseSubscript(M,oe,ve,it){let Xt=super.parseSubscript(M,oe,ve,it);if(it.optionalChainMember){if((Xt.type==="OptionalMemberExpression"||Xt.type==="OptionalCallExpression")&&(Xt.type=Xt.type.substring(8)),it.stop){let Pr=this.startNodeAtNode(Xt);return Pr.expression=Xt,this.finishNode(Pr,"ChainExpression")}}else(Xt.type==="MemberExpression"||Xt.type==="CallExpression")&&(Xt.optional=!1);return Xt}isOptionalMemberExpression(M){return M.type==="ChainExpression"?M.expression.type==="MemberExpression":super.isOptionalMemberExpression(M)}hasPropertyAsPrivateName(M){return M.type==="ChainExpression"&&(M=M.expression),super.hasPropertyAsPrivateName(M)}isObjectProperty(M){return M.type==="Property"&&M.kind==="init"&&!M.method}isObjectMethod(M){return M.type==="Property"&&(M.method||M.kind==="get"||M.kind==="set")}finishNodeAt(M,oe,ve){return Ee(super.finishNodeAt(M,oe,ve))}resetStartLocation(M,oe){super.resetStartLocation(M,oe),Ee(M)}resetEndLocation(M,oe=this.state.lastTokEndLoc){super.resetEndLocation(M,oe),Ee(M)}},Ie=class{constructor(te,M){this.token=void 0,this.preserveSpace=void 0,this.token=te,this.preserveSpace=!!M}},De={brace:new Ie("{"),j_oTag:new Ie("...",!0)};De.template=new Ie("`",!0);var He=!0,Xe=!0,k=!0,dt=!0,_t=!0,It=!0,lt=class{constructor(te,M={}){this.label=void 0,this.keyword=void 0,this.beforeExpr=void 0,this.startsExpr=void 0,this.rightAssociative=void 0,this.isLoop=void 0,this.isAssign=void 0,this.prefix=void 0,this.postfix=void 0,this.binop=void 0,this.label=te,this.keyword=M.keyword,this.beforeExpr=!!M.beforeExpr,this.startsExpr=!!M.startsExpr,this.rightAssociative=!!M.rightAssociative,this.isLoop=!!M.isLoop,this.isAssign=!!M.isAssign,this.prefix=!!M.prefix,this.postfix=!!M.postfix,this.binop=M.binop!=null?M.binop:null,this.updateContext=null}},wt=new Map;function Vt(te,M={}){M.keyword=te;let oe=Sr(te,M);return wt.set(te,oe),oe}function Br(te,M){return Sr(te,{beforeExpr:He,binop:M})}var En=-1,tr=[],Fr=[],Tr=[],_r=[],Vr=[],An=[];function Sr(te,M={}){var oe,ve,it,Xt;return++En,Fr.push(te),Tr.push((oe=M.binop)!=null?oe:-1),_r.push((ve=M.beforeExpr)!=null?ve:!1),Vr.push((it=M.startsExpr)!=null?it:!1),An.push((Xt=M.prefix)!=null?Xt:!1),tr.push(new lt(te,M)),En}function Tn(te,M={}){var oe,ve,it,Xt;return++En,wt.set(te,En),Fr.push(te),Tr.push((oe=M.binop)!=null?oe:-1),_r.push((ve=M.beforeExpr)!=null?ve:!1),Vr.push((it=M.startsExpr)!=null?it:!1),An.push((Xt=M.prefix)!=null?Xt:!1),tr.push(new lt("name",M)),En}var Dn={bracketL:Sr("[",{beforeExpr:He,startsExpr:Xe}),bracketHashL:Sr("#[",{beforeExpr:He,startsExpr:Xe}),bracketBarL:Sr("[|",{beforeExpr:He,startsExpr:Xe}),bracketR:Sr("]"),bracketBarR:Sr("|]"),braceL:Sr("{",{beforeExpr:He,startsExpr:Xe}),braceBarL:Sr("{|",{beforeExpr:He,startsExpr:Xe}),braceHashL:Sr("#{",{beforeExpr:He,startsExpr:Xe}),braceR:Sr("}"),braceBarR:Sr("|}"),parenL:Sr("(",{beforeExpr:He,startsExpr:Xe}),parenR:Sr(")"),comma:Sr(",",{beforeExpr:He}),semi:Sr(";",{beforeExpr:He}),colon:Sr(":",{beforeExpr:He}),doubleColon:Sr("::",{beforeExpr:He}),dot:Sr("."),question:Sr("?",{beforeExpr:He}),questionDot:Sr("?."),arrow:Sr("=>",{beforeExpr:He}),template:Sr("template"),ellipsis:Sr("...",{beforeExpr:He}),backQuote:Sr("`",{startsExpr:Xe}),dollarBraceL:Sr("${",{beforeExpr:He,startsExpr:Xe}),templateTail:Sr("...`",{startsExpr:Xe}),templateNonTail:Sr("...${",{beforeExpr:He,startsExpr:Xe}),at:Sr("@"),hash:Sr("#",{startsExpr:Xe}),interpreterDirective:Sr("#!..."),eq:Sr("=",{beforeExpr:He,isAssign:dt}),assign:Sr("_=",{beforeExpr:He,isAssign:dt}),slashAssign:Sr("_=",{beforeExpr:He,isAssign:dt}),xorAssign:Sr("_=",{beforeExpr:He,isAssign:dt}),moduloAssign:Sr("_=",{beforeExpr:He,isAssign:dt}),incDec:Sr("++/--",{prefix:_t,postfix:It,startsExpr:Xe}),bang:Sr("!",{beforeExpr:He,prefix:_t,startsExpr:Xe}),tilde:Sr("~",{beforeExpr:He,prefix:_t,startsExpr:Xe}),doubleCaret:Sr("^^",{startsExpr:Xe}),doubleAt:Sr("@@",{startsExpr:Xe}),pipeline:Br("|>",0),nullishCoalescing:Br("??",1),logicalOR:Br("||",1),logicalAND:Br("&&",2),bitwiseOR:Br("|",3),bitwiseXOR:Br("^",4),bitwiseAND:Br("&",5),equality:Br("==/!=/===/!==",6),lt:Br("/<=/>=",7),gt:Br("/<=/>=",7),relational:Br("/<=/>=",7),bitShift:Br("<>/>>>",8),bitShiftL:Br("<>/>>>",8),bitShiftR:Br("<>/>>>",8),plusMin:Sr("+/-",{beforeExpr:He,binop:9,prefix:_t,startsExpr:Xe}),modulo:Sr("%",{binop:10,startsExpr:Xe}),star:Sr("*",{binop:10}),slash:Br("/",10),exponent:Sr("**",{beforeExpr:He,binop:11,rightAssociative:!0}),_in:Vt("in",{beforeExpr:He,binop:7}),_instanceof:Vt("instanceof",{beforeExpr:He,binop:7}),_break:Vt("break"),_case:Vt("case",{beforeExpr:He}),_catch:Vt("catch"),_continue:Vt("continue"),_debugger:Vt("debugger"),_default:Vt("default",{beforeExpr:He}),_else:Vt("else",{beforeExpr:He}),_finally:Vt("finally"),_function:Vt("function",{startsExpr:Xe}),_if:Vt("if"),_return:Vt("return",{beforeExpr:He}),_switch:Vt("switch"),_throw:Vt("throw",{beforeExpr:He,prefix:_t,startsExpr:Xe}),_try:Vt("try"),_var:Vt("var"),_const:Vt("const"),_with:Vt("with"),_new:Vt("new",{beforeExpr:He,startsExpr:Xe}),_this:Vt("this",{startsExpr:Xe}),_super:Vt("super",{startsExpr:Xe}),_class:Vt("class",{startsExpr:Xe}),_extends:Vt("extends",{beforeExpr:He}),_export:Vt("export"),_import:Vt("import",{startsExpr:Xe}),_null:Vt("null",{startsExpr:Xe}),_true:Vt("true",{startsExpr:Xe}),_false:Vt("false",{startsExpr:Xe}),_typeof:Vt("typeof",{beforeExpr:He,prefix:_t,startsExpr:Xe}),_void:Vt("void",{beforeExpr:He,prefix:_t,startsExpr:Xe}),_delete:Vt("delete",{beforeExpr:He,prefix:_t,startsExpr:Xe}),_do:Vt("do",{isLoop:k,beforeExpr:He}),_for:Vt("for",{isLoop:k}),_while:Vt("while",{isLoop:k}),_as:Tn("as",{startsExpr:Xe}),_assert:Tn("assert",{startsExpr:Xe}),_async:Tn("async",{startsExpr:Xe}),_await:Tn("await",{startsExpr:Xe}),_defer:Tn("defer",{startsExpr:Xe}),_from:Tn("from",{startsExpr:Xe}),_get:Tn("get",{startsExpr:Xe}),_let:Tn("let",{startsExpr:Xe}),_meta:Tn("meta",{startsExpr:Xe}),_of:Tn("of",{startsExpr:Xe}),_sent:Tn("sent",{startsExpr:Xe}),_set:Tn("set",{startsExpr:Xe}),_source:Tn("source",{startsExpr:Xe}),_static:Tn("static",{startsExpr:Xe}),_using:Tn("using",{startsExpr:Xe}),_yield:Tn("yield",{startsExpr:Xe}),_asserts:Tn("asserts",{startsExpr:Xe}),_checks:Tn("checks",{startsExpr:Xe}),_exports:Tn("exports",{startsExpr:Xe}),_global:Tn("global",{startsExpr:Xe}),_implements:Tn("implements",{startsExpr:Xe}),_intrinsic:Tn("intrinsic",{startsExpr:Xe}),_infer:Tn("infer",{startsExpr:Xe}),_is:Tn("is",{startsExpr:Xe}),_mixins:Tn("mixins",{startsExpr:Xe}),_proto:Tn("proto",{startsExpr:Xe}),_require:Tn("require",{startsExpr:Xe}),_satisfies:Tn("satisfies",{startsExpr:Xe}),_keyof:Tn("keyof",{startsExpr:Xe}),_readonly:Tn("readonly",{startsExpr:Xe}),_unique:Tn("unique",{startsExpr:Xe}),_abstract:Tn("abstract",{startsExpr:Xe}),_declare:Tn("declare",{startsExpr:Xe}),_enum:Tn("enum",{startsExpr:Xe}),_module:Tn("module",{startsExpr:Xe}),_namespace:Tn("namespace",{startsExpr:Xe}),_interface:Tn("interface",{startsExpr:Xe}),_type:Tn("type",{startsExpr:Xe}),_opaque:Tn("opaque",{startsExpr:Xe}),name:Sr("name",{startsExpr:Xe}),string:Sr("string",{startsExpr:Xe}),num:Sr("num",{startsExpr:Xe}),bigint:Sr("bigint",{startsExpr:Xe}),decimal:Sr("decimal",{startsExpr:Xe}),regexp:Sr("regexp",{startsExpr:Xe}),privateName:Sr("#name",{startsExpr:Xe}),eof:Sr("eof"),jsxName:Sr("jsxName"),jsxText:Sr("jsxText",{beforeExpr:!0}),jsxTagStart:Sr("jsxTagStart",{startsExpr:!0}),jsxTagEnd:Sr("jsxTagEnd"),placeholder:Sr("%%",{startsExpr:!0})};function or(te){return te>=93&&te<=132}function gi(te){return te<=92}function ui(te){return te>=58&&te<=132}function Be(te){return te>=58&&te<=136}function us(te){return _r[te]}function kc(te){return Vr[te]}function za(te){return te>=29&&te<=33}function zs(te){return te>=129&&te<=131}function ur(te){return te>=90&&te<=92}function aa(te){return te>=58&&te<=92}function bi(te){return te>=39&&te<=59}function Hu(te){return te===34}function qu(te){return An[te]}function jp(te){return te>=121&&te<=123}function ld(te){return te>=124&&te<=130}function xf(te){return Fr[te]}function g_(te){return Tr[te]}function Kr(te){return te===57}function kr(te){return te>=24&&te<=25}function dr(te){return tr[te]}tr[8].updateContext=te=>{te.pop()},tr[5].updateContext=tr[7].updateContext=tr[23].updateContext=te=>{te.push(De.brace)},tr[22].updateContext=te=>{te[te.length-1]===De.template?te.pop():te.push(De.template)},tr[142].updateContext=te=>{te.push(De.j_expr,De.j_oTag)};var nn="\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC",dn="\u200C\u200D\xB7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0898-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0CF3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u180F-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1ABF-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u200C\u200D\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\u30FB\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA8FF-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F\uFF65",Ln=new RegExp("["+nn+"]"),Ji=new RegExp("["+nn+dn+"]");nn=dn=null;var qr=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,68,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,4026,582,8634,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,757,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],js=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,81,2,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,9,5351,0,7,14,13835,9,87,9,39,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,4706,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,983,6,110,6,6,9,4759,9,787719,239];function Go(te,M){let oe=65536;for(let ve=0,it=M.length;vete)return!1;if(oe+=M[ve+1],oe>=te)return!0}return!1}function $n(te){return te<65?te===36:te<=90?!0:te<97?te===95:te<=122?!0:te<=65535?te>=170&&Ln.test(String.fromCharCode(te)):Go(te,qr)}function Ca(te){return te<48?te===36:te<58?!0:te<65?!1:te<=90?!0:te<97?te===95:te<=122?!0:te<=65535?te>=170&&Ji.test(String.fromCharCode(te)):Go(te,qr)||Go(te,js)}var Af={keyword:["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete"],strict:["implements","interface","let","package","private","protected","public","static","yield"],strictBind:["eval","arguments"]},Zu=new Set(Af.keyword),hf=new Set(Af.strict),Pu=new Set(Af.strictBind);function pl(te,M){return M&&te==="await"||te==="enum"}function Qi(te,M){return pl(te,M)||hf.has(te)}function Vi(te){return Pu.has(te)}function $i(te,M){return Qi(te,M)||Vi(te)}function Ra(te){return Zu.has(te)}function Ks(te,M,oe){return te===64&&M===64&&$n(oe)}var Ll=new Set(["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete","implements","interface","let","package","private","protected","public","static","yield","eval","arguments","enum","await"]);function ca(te){return Ll.has(te)}var ka=class{constructor(te){this.flags=0,this.names=new Map,this.firstLexicalName="",this.flags=te}},yu=class{constructor(te,M){this.parser=void 0,this.scopeStack=[],this.inModule=void 0,this.undefinedExports=new Map,this.parser=te,this.inModule=M}get inTopLevel(){return(this.currentScope().flags&1)>0}get inFunction(){return(this.currentVarScopeFlags()&2)>0}get allowSuper(){return(this.currentThisScopeFlags()&16)>0}get allowDirectSuper(){return(this.currentThisScopeFlags()&32)>0}get inClass(){return(this.currentThisScopeFlags()&64)>0}get inClassAndNotInNonArrowFunction(){let te=this.currentThisScopeFlags();return(te&64)>0&&(te&2)===0}get inStaticBlock(){for(let te=this.scopeStack.length-1;;te--){let{flags:M}=this.scopeStack[te];if(M&128)return!0;if(M&451)return!1}}get inNonArrowFunction(){return(this.currentThisScopeFlags()&2)>0}get treatFunctionsAsVar(){return this.treatFunctionsAsVarInScope(this.currentScope())}createScope(te){return new ka(te)}enter(te){this.scopeStack.push(this.createScope(te))}exit(){return this.scopeStack.pop().flags}treatFunctionsAsVarInScope(te){return!!(te.flags&130||!this.parser.inModule&&te.flags&1)}declareName(te,M,oe){let ve=this.currentScope();if(M&8||M&16){this.checkRedeclarationInScope(ve,te,M,oe);let it=ve.names.get(te)||0;M&16?it=it|4:(ve.firstLexicalName||(ve.firstLexicalName=te),it=it|2),ve.names.set(te,it),M&8&&this.maybeExportDefined(ve,te)}else if(M&4)for(let it=this.scopeStack.length-1;it>=0&&(ve=this.scopeStack[it],this.checkRedeclarationInScope(ve,te,M,oe),ve.names.set(te,(ve.names.get(te)||0)|1),this.maybeExportDefined(ve,te),!(ve.flags&387));--it);this.parser.inModule&&ve.flags&1&&this.undefinedExports.delete(te)}maybeExportDefined(te,M){this.parser.inModule&&te.flags&1&&this.undefinedExports.delete(M)}checkRedeclarationInScope(te,M,oe,ve){this.isRedeclaredInScope(te,M,oe)&&this.parser.raise(ce.VarRedeclaration,ve,{identifierName:M})}isRedeclaredInScope(te,M,oe){if(!(oe&1))return!1;if(oe&8)return te.names.has(M);let ve=te.names.get(M);return oe&16?(ve&2)>0||!this.treatFunctionsAsVarInScope(te)&&(ve&1)>0:(ve&2)>0&&!(te.flags&8&&te.firstLexicalName===M)||!this.treatFunctionsAsVarInScope(te)&&(ve&4)>0}checkLocalExport(te){let{name:M}=te;this.scopeStack[0].names.has(M)||this.undefinedExports.set(M,te.loc.start)}currentScope(){return this.scopeStack[this.scopeStack.length-1]}currentVarScopeFlags(){for(let te=this.scopeStack.length-1;;te--){let{flags:M}=this.scopeStack[te];if(M&387)return M}}currentThisScopeFlags(){for(let te=this.scopeStack.length-1;;te--){let{flags:M}=this.scopeStack[te];if(M&451&&!(M&4))return M}}},Bp=class extends ka{constructor(...te){super(...te),this.declareFunctions=new Set}},al=class extends yu{createScope(te){return new Bp(te)}declareName(te,M,oe){let ve=this.currentScope();if(M&2048){this.checkRedeclarationInScope(ve,te,M,oe),this.maybeExportDefined(ve,te),ve.declareFunctions.add(te);return}super.declareName(te,M,oe)}isRedeclaredInScope(te,M,oe){if(super.isRedeclaredInScope(te,M,oe))return!0;if(oe&2048&&!te.declareFunctions.has(M)){let ve=te.names.get(M);return(ve&4)>0||(ve&2)>0}return!1}checkLocalExport(te){this.scopeStack[0].declareFunctions.has(te.name)||super.checkLocalExport(te)}},au=class{constructor(){this.sawUnambiguousESM=!1,this.ambiguousScriptDifferentAst=!1}hasPlugin(te){if(typeof te=="string")return this.plugins.has(te);{let[M,oe]=te;if(!this.hasPlugin(M))return!1;let ve=this.plugins.get(M);for(let it of Object.keys(oe))if(ve?.[it]!==oe[it])return!1;return!0}}getPluginOption(te,M){var oe;return(oe=this.plugins.get(te))==null?void 0:oe[M]}};function Ff(te,M){te.trailingComments===void 0?te.trailingComments=M:te.trailingComments.unshift(...M)}function fA(te,M){te.leadingComments===void 0?te.leadingComments=M:te.leadingComments.unshift(...M)}function Wp(te,M){te.innerComments===void 0?te.innerComments=M:te.innerComments.unshift(...M)}function ei(te,M,oe){let ve=null,it=M.length;for(;ve===null&&it>0;)ve=M[--it];ve===null||ve.start>oe.start?Wp(te,oe.comments):Ff(ve,oe.comments)}var nc=class extends au{addComment(te){this.filename&&(te.loc.filename=this.filename);let{commentsLen:M}=this.state;this.comments.length!==M&&(this.comments.length=M),this.comments.push(te),this.state.commentsLen++}processComment(te){let{commentStack:M}=this.state,oe=M.length;if(oe===0)return;let ve=oe-1,it=M[ve];it.start===te.end&&(it.leadingNode=te,ve--);let{start:Xt}=te;for(;ve>=0;ve--){let Pr=M[ve],Xr=Pr.end;if(Xr>Xt)Pr.containingNode=te,this.finalizeComment(Pr),M.splice(ve,1);else{Xr===Xt&&(Pr.trailingNode=te);break}}}finalizeComment(te){let{comments:M}=te;if(te.leadingNode!==null||te.trailingNode!==null)te.leadingNode!==null&&Ff(te.leadingNode,M),te.trailingNode!==null&&fA(te.trailingNode,M);else{let{containingNode:oe,start:ve}=te;if(this.input.charCodeAt(ve-1)===44)switch(oe.type){case"ObjectExpression":case"ObjectPattern":case"RecordExpression":ei(oe,oe.properties,te);break;case"CallExpression":case"OptionalCallExpression":ei(oe,oe.arguments,te);break;case"FunctionDeclaration":case"FunctionExpression":case"ArrowFunctionExpression":case"ObjectMethod":case"ClassMethod":case"ClassPrivateMethod":ei(oe,oe.params,te);break;case"ArrayExpression":case"ArrayPattern":case"TupleExpression":ei(oe,oe.elements,te);break;case"ExportNamedDeclaration":case"ImportDeclaration":ei(oe,oe.specifiers,te);break;default:Wp(oe,M)}else Wp(oe,M)}}finalizeRemainingComments(){let{commentStack:te}=this.state;for(let M=te.length-1;M>=0;M--)this.finalizeComment(te[M]);this.state.commentStack=[]}resetPreviousNodeTrailingComments(te){let{commentStack:M}=this.state,{length:oe}=M;if(oe===0)return;let ve=M[oe-1];ve.leadingNode===te&&(ve.leadingNode=null)}resetPreviousIdentifierLeadingComments(te){let{commentStack:M}=this.state,{length:oe}=M;oe!==0&&(M[oe-1].trailingNode===te?M[oe-1].trailingNode=null:oe>=2&&M[oe-2].trailingNode===te&&(M[oe-2].trailingNode=null))}takeSurroundingComments(te,M,oe){let{commentStack:ve}=this.state,it=ve.length;if(it===0)return;let Xt=it-1;for(;Xt>=0;Xt--){let Pr=ve[Xt],Xr=Pr.end;if(Pr.start===oe)Pr.leadingNode=te;else if(Xr===M)Pr.trailingNode=te;else if(Xr0}set strict(M){M?this.flags|=1:this.flags&=-2}init({strictMode:M,sourceType:oe,startLine:ve,startColumn:it}){this.strict=M===!1?!1:M===!0?!0:oe==="module",this.curLine=ve,this.lineStart=-it,this.startLoc=this.endLoc=new r(ve,it,0)}get maybeInArrowParameters(){return(this.flags&2)>0}set maybeInArrowParameters(M){M?this.flags|=2:this.flags&=-3}get inType(){return(this.flags&4)>0}set inType(M){M?this.flags|=4:this.flags&=-5}get noAnonFunctionType(){return(this.flags&8)>0}set noAnonFunctionType(M){M?this.flags|=8:this.flags&=-9}get hasFlowComment(){return(this.flags&16)>0}set hasFlowComment(M){M?this.flags|=16:this.flags&=-17}get isAmbientContext(){return(this.flags&32)>0}set isAmbientContext(M){M?this.flags|=32:this.flags&=-33}get inAbstractClass(){return(this.flags&64)>0}set inAbstractClass(M){M?this.flags|=64:this.flags&=-65}get inDisallowConditionalTypesContext(){return(this.flags&128)>0}set inDisallowConditionalTypesContext(M){M?this.flags|=128:this.flags&=-129}get soloAwait(){return(this.flags&256)>0}set soloAwait(M){M?this.flags|=256:this.flags&=-257}get inFSharpPipelineDirectBody(){return(this.flags&512)>0}set inFSharpPipelineDirectBody(M){M?this.flags|=512:this.flags&=-513}get canStartJSXElement(){return(this.flags&1024)>0}set canStartJSXElement(M){M?this.flags|=1024:this.flags&=-1025}get containsEsc(){return(this.flags&2048)>0}set containsEsc(M){M?this.flags|=2048:this.flags&=-2049}curPosition(){return new r(this.curLine,this.pos-this.lineStart,this.pos)}clone(){let M=new iBn;return M.flags=this.flags,M.curLine=this.curLine,M.lineStart=this.lineStart,M.startLoc=this.startLoc,M.endLoc=this.endLoc,M.errors=this.errors.slice(),M.potentialArrowAt=this.potentialArrowAt,M.noArrowAt=this.noArrowAt.slice(),M.noArrowParamsConversionAt=this.noArrowParamsConversionAt.slice(),M.topicContext=this.topicContext,M.labels=this.labels.slice(),M.commentsLen=this.commentsLen,M.commentStack=this.commentStack.slice(),M.pos=this.pos,M.type=this.type,M.value=this.value,M.start=this.start,M.end=this.end,M.lastTokEndLoc=this.lastTokEndLoc,M.lastTokStartLoc=this.lastTokStartLoc,M.context=this.context.slice(),M.firstInvalidTemplateEscapePos=this.firstInvalidTemplateEscapePos,M.strictErrors=this.strictErrors,M.tokensLength=this.tokensLength,M}},_p=function(te){return te>=48&&te<=57},Pp={decBinOct:new Set([46,66,69,79,95,98,101,111]),hex:new Set([46,88,95,120])},So={bin:te=>te===48||te===49,oct:te=>te>=48&&te<=55,dec:te=>te>=48&&te<=57,hex:te=>te>=48&&te<=57||te>=65&&te<=70||te>=97&&te<=102};function Zl(te,M,oe,ve,it,Xt){let Pr=oe,Xr=ve,Qn=it,Mn="",Qo=null,xc=oe,{length:yc}=M;for(;;){if(oe>=yc){Xt.unterminated(Pr,Xr,Qn),Mn+=M.slice(xc,oe);break}let Nl=M.charCodeAt(oe);if(xA(te,Nl,M,oe)){Mn+=M.slice(xc,oe);break}if(Nl===92){Mn+=M.slice(xc,oe);let Ao=kd(M,oe,ve,it,te==="template",Xt);Ao.ch===null&&!Qo?Qo={pos:oe,lineStart:ve,curLine:it}:Mn+=Ao.ch,{pos:oe,lineStart:ve,curLine:it}=Ao,xc=oe}else Nl===8232||Nl===8233?(++oe,++it,ve=oe):Nl===10||Nl===13?te==="template"?(Mn+=M.slice(xc,oe)+` diff --git a/yarn/plugin-essentials/sources/commands/set-version.command.ts b/yarn/plugin-essentials/sources/commands/set-version.command.ts index bf61e494..d9ff5bb7 100644 --- a/yarn/plugin-essentials/sources/commands/set-version.command.ts +++ b/yarn/plugin-essentials/sources/commands/set-version.command.ts @@ -3,7 +3,7 @@ import { Configuration } from '@yarnpkg/core' import { Command } from 'clipanion' export class SetVersionCommand extends BaseCommand { - static paths = [['set', 'version', 'atlantis']] + static paths = [['set', 'version', 'atls']] static usage = Command.Usage({ description: 'lock the Yarn version used by the project',