create-turbo 2.8.2-canary.1 → 2.8.2-canary.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +1 -1
- package/package.json +5 -5
package/dist/cli.js
CHANGED
|
@@ -70,7 +70,7 @@ Please report this to https://github.com/szmarczak/http2-wrapper/`);E(d)}return}
|
|
|
70
70
|
`).reverse(),a=r.stack.slice(r.stack.indexOf(r.message)+r.message.length).split(`
|
|
71
71
|
`).reverse();for(;a.length!==0&&a[0]===o[0];)o.shift();this.stack=`${this.stack.slice(0,i)}${o.reverse().join(`
|
|
72
72
|
`)}${a.reverse().join(`
|
|
73
|
-
`)}`}}};_t.RequestError=Br;var oI=class extends Br{constructor(e){super(`Redirected ${e.options.maxRedirects} times. Aborting.`,{},e),this.name="MaxRedirectsError",this.code="ERR_TOO_MANY_REDIRECTS"}};_t.MaxRedirectsError=oI;var aI=class extends Br{constructor(e){super(`Response code ${e.statusCode} (${e.statusMessage})`,{},e.request),this.name="HTTPError",this.code="ERR_NON_2XX_3XX_RESPONSE"}};_t.HTTPError=aI;var cI=class extends Br{constructor(e,r){super(e.message,e,r),this.name="CacheError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_CACHE_ACCESS":this.code}};_t.CacheError=cI;var lI=class extends Br{constructor(e,r){super(e.message,e,r),this.name="UploadError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_UPLOAD":this.code}};_t.UploadError=lI;var uI=class extends Br{constructor(e,r,A){super(e.message,e,A),this.name="TimeoutError",this.event=e.event,this.timings=r}};_t.TimeoutError=uI;var df=class extends Br{constructor(e,r){super(e.message,e,r),this.name="ReadError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_READING_RESPONSE_STREAM":this.code}};_t.ReadError=df;var hI=class extends Br{constructor(e){super(`Unsupported protocol "${e.url.protocol}"`,{},e),this.name="UnsupportedProtocolError",this.code="ERR_UNSUPPORTED_PROTOCOL"}};_t.UnsupportedProtocolError=hI;var w0e=["socket","connect","continue","information","upgrade","timeout"],gI=class extends _3.Duplex{constructor(e,r={},A){super({autoDestroy:!1,highWaterMark:0}),this[Ju]=0,this[Vu]=0,this.requestInitialized=!1,this[nI]=new Set,this.redirects=[],this[qu]=!1,this[sI]=!1,this[Ef]=[],this.retryCount=0,this._progressCallbacks=[];let n=()=>this._unlockWrite(),s=()=>this._lockWrite();this.on("pipe",c=>{c.prependListener("data",n),c.on("data",s),c.prependListener("end",n),c.on("end",s)}),this.on("unpipe",c=>{c.off("data",n),c.off("data",s),c.off("end",n),c.off("end",s)}),this.on("pipe",c=>{c instanceof MS.IncomingMessage&&(this.options.headers={...c.headers,...this.options.headers})});let{json:i,body:o,form:a}=r;if((i||o||a)&&this._lockWrite(),_t.kIsNormalizedAlready in r)this.options=r;else try{this.options=this.constructor.normalizeArguments(e,r,A)}catch(c){Ie.default.nodeStream(r.body)&&r.body.destroy(),this.destroy(c);return}(async()=>{var c;try{this.options.body instanceof A0e.ReadStream&&await p0e(this.options.body);let{url:l}=this.options;if(!l)throw new TypeError("Missing `url` property");if(this.requestUrl=l.toString(),decodeURI(this.requestUrl),await this._finalizeBody(),await this._makeRequest(),this.destroyed){(c=this[qr])===null||c===void 0||c.destroy();return}for(let u of this[Ef])u();this[Ef].length=0,this.requestInitialized=!0}catch(l){if(l instanceof Br){this._beforeError(l);return}this.destroyed||this.destroy(l)}})()}static normalizeArguments(e,r,A){var n,s,i,o,a;let c=r;if(Ie.default.object(e)&&!Ie.default.urlInstance(e))r={...A,...e,...r};else{if(e&&r&&r.url!==void 0)throw new TypeError("The `url` option is mutually exclusive with the `input` argument");r={...A,...r},e!==void 0&&(r.url=e),Ie.default.urlInstance(r.url)&&(r.url=new mo.URL(r.url.toString()))}if(r.cache===!1&&(r.cache=void 0),r.dnsCache===!1&&(r.dnsCache=void 0),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.method),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.headers),Ie.assert.any([Ie.default.string,Ie.default.urlInstance,Ie.default.undefined],r.prefixUrl),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.cookieJar),Ie.assert.any([Ie.default.object,Ie.default.string,Ie.default.undefined],r.searchParams),Ie.assert.any([Ie.default.object,Ie.default.string,Ie.default.undefined],r.cache),Ie.assert.any([Ie.default.object,Ie.default.number,Ie.default.undefined],r.timeout),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.context),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.hooks),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.decompress),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.ignoreInvalidCookies),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.followRedirect),Ie.assert.any([Ie.default.number,Ie.default.undefined],r.maxRedirects),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.throwHttpErrors),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.http2),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.allowGetBody),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.localAddress),Ie.assert.any([P3.isDnsLookupIpVersion,Ie.default.undefined],r.dnsLookupIpVersion),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.https),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.rejectUnauthorized),r.https&&(Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.https.rejectUnauthorized),Ie.assert.any([Ie.default.function_,Ie.default.undefined],r.https.checkServerIdentity),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.certificateAuthority),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.key),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.certificate),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.https.passphrase),Ie.assert.any([Ie.default.string,Ie.default.buffer,Ie.default.array,Ie.default.undefined],r.https.pfx)),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.cacheOptions),Ie.default.string(r.method)?r.method=r.method.toUpperCase():r.method="GET",r.headers===(A==null?void 0:A.headers)?r.headers={...r.headers}:r.headers=c0e({...A==null?void 0:A.headers,...r.headers}),"slashes"in r)throw new TypeError("The legacy `url.Url` has been deprecated. Use `URL` instead.");if("auth"in r)throw new TypeError("Parameter `auth` is deprecated. Use `username` / `password` instead.");if("searchParams"in r&&r.searchParams&&r.searchParams!==(A==null?void 0:A.searchParams)){let g;if(Ie.default.string(r.searchParams)||r.searchParams instanceof mo.URLSearchParams)g=new mo.URLSearchParams(r.searchParams);else{Q0e(r.searchParams),g=new mo.URLSearchParams;for(let E in r.searchParams){let d=r.searchParams[E];d===null?g.append(E,""):d!==void 0&&g.append(E,d)}}(n=A==null?void 0:A.searchParams)===null||n===void 0||n.forEach((E,d)=>{g.has(d)||g.append(d,E)}),r.searchParams=g}if(r.username=(s=r.username)!==null&&s!==void 0?s:"",r.password=(i=r.password)!==null&&i!==void 0?i:"",Ie.default.undefined(r.prefixUrl)?r.prefixUrl=(o=A==null?void 0:A.prefixUrl)!==null&&o!==void 0?o:"":(r.prefixUrl=r.prefixUrl.toString(),r.prefixUrl!==""&&!r.prefixUrl.endsWith("/")&&(r.prefixUrl+="/")),Ie.default.string(r.url)){if(r.url.startsWith("/"))throw new Error("`input` must not start with a slash when using `prefixUrl`");r.url=J3.default(r.prefixUrl+r.url,r)}else(Ie.default.undefined(r.url)&&r.prefixUrl!==""||r.protocol)&&(r.url=J3.default(r.prefixUrl,r));if(r.url){"port"in r&&delete r.port;let{prefixUrl:g}=r;Object.defineProperty(r,"prefixUrl",{set:d=>{let f=r.url;if(!f.href.startsWith(d))throw new Error(`Cannot change \`prefixUrl\` from ${g} to ${d}: ${f.href}`);r.url=new mo.URL(d+f.href.slice(g.length)),g=d},get:()=>g});let{protocol:E}=r.url;if(E==="unix:"&&(E="http:",r.url=new mo.URL(`http://unix${r.url.pathname}${r.url.search}`)),r.searchParams&&(r.url.search=r.searchParams.toString()),E!=="http:"&&E!=="https:")throw new hI(r);r.username===""?r.username=r.url.username:r.url.username=r.username,r.password===""?r.password=r.url.password:r.url.password=r.password}let{cookieJar:l}=r;if(l){let{setCookie:g,getCookieString:E}=l;Ie.assert.function_(g),Ie.assert.function_(E),g.length===4&&E.length===0&&(g=U3.promisify(g.bind(r.cookieJar)),E=U3.promisify(E.bind(r.cookieJar)),r.cookieJar={setCookie:g,getCookieString:E})}let{cache:u}=r;if(u&&(xS.has(u)||xS.set(u,new Y3(((g,E)=>{let d=g[qr](g,E);return Ie.default.promise(d)&&(d.once=(f,C)=>{if(f==="error")d.catch(C);else if(f==="abort")(async()=>{try{(await d).once("abort",C)}catch{}})();else throw new Error(`Unknown HTTP2 promise event: ${f}`);return d}),d}),u))),r.cacheOptions={...r.cacheOptions},r.dnsCache===!0)TS||(TS=new i0e.default),r.dnsCache=TS;else if(!Ie.default.undefined(r.dnsCache)&&!r.dnsCache.lookup)throw new TypeError(`Parameter \`dnsCache\` must be a CacheableLookup instance or a boolean, got ${Ie.default(r.dnsCache)}`);Ie.default.number(r.timeout)?r.timeout={request:r.timeout}:A&&r.timeout!==A.timeout?r.timeout={...A.timeout,...r.timeout}:r.timeout={...r.timeout},r.context||(r.context={});let h=r.hooks===(A==null?void 0:A.hooks);r.hooks={...r.hooks};for(let g of _t.knownHookEvents)if(g in r.hooks)if(Ie.default.array(r.hooks[g]))r.hooks[g]=[...r.hooks[g]];else throw new TypeError(`Parameter \`${g}\` must be an Array, got ${Ie.default(r.hooks[g])}`);else r.hooks[g]=[];if(A&&!h)for(let g of _t.knownHookEvents)A.hooks[g].length>0&&(r.hooks[g]=[...A.hooks[g],...r.hooks[g]]);if("family"in r&&yo.default('"options.family" was never documented, please use "options.dnsLookupIpVersion"'),A!=null&&A.https&&(r.https={...A.https,...r.https}),"rejectUnauthorized"in r&&yo.default('"options.rejectUnauthorized" is now deprecated, please use "options.https.rejectUnauthorized"'),"checkServerIdentity"in r&&yo.default('"options.checkServerIdentity" was never documented, please use "options.https.checkServerIdentity"'),"ca"in r&&yo.default('"options.ca" was never documented, please use "options.https.certificateAuthority"'),"key"in r&&yo.default('"options.key" was never documented, please use "options.https.key"'),"cert"in r&&yo.default('"options.cert" was never documented, please use "options.https.certificate"'),"passphrase"in r&&yo.default('"options.passphrase" was never documented, please use "options.https.passphrase"'),"pfx"in r&&yo.default('"options.pfx" was never documented, please use "options.https.pfx"'),"followRedirects"in r)throw new TypeError("The `followRedirects` option does not exist. Use `followRedirect` instead.");if(r.agent){for(let g in r.agent)if(g!=="http"&&g!=="https"&&g!=="http2")throw new TypeError(`Expected the \`options.agent\` properties to be \`http\`, \`https\` or \`http2\`, got \`${g}\``)}return r.maxRedirects=(a=r.maxRedirects)!==null&&a!==void 0?a:0,_t.setNonEnumerableProperties([A,c],r),d0e.default(r,A)}_lockWrite(){let e=()=>{throw new TypeError("The payload has been already provided")};this.write=e,this.end=e}_unlockWrite(){this.write=super.write,this.end=super.end}async _finalizeBody(){let{options:e}=this,{headers:r}=e,A=!Ie.default.undefined(e.form),n=!Ie.default.undefined(e.json),s=!Ie.default.undefined(e.body),i=A||n||s,o=_t.withoutBody.has(e.method)&&!(e.method==="GET"&&e.allowGetBody);if(this._cannotHaveBody=o,i){if(o)throw new TypeError(`The \`${e.method}\` method cannot be used with a body`);if([s,A,n].filter(a=>a).length>1)throw new TypeError("The `body`, `json` and `form` options are mutually exclusive");if(s&&!(e.body instanceof _3.Readable)&&!Ie.default.string(e.body)&&!Ie.default.buffer(e.body)&&!O3.default(e.body))throw new TypeError("The `body` option must be a stream.Readable, string or Buffer");if(A&&!Ie.default.object(e.form))throw new TypeError("The `form` option must be an Object");{let a=!Ie.default.string(r["content-type"]);s?(O3.default(e.body)&&a&&(r["content-type"]=`multipart/form-data; boundary=${e.body.getBoundary()}`),this[wo]=e.body):A?(a&&(r["content-type"]="application/x-www-form-urlencoded"),this[wo]=new mo.URLSearchParams(e.form).toString()):(a&&(r["content-type"]="application/json"),this[wo]=e.stringifyJson(e.json));let c=await l0e.default(this[wo],e.headers);Ie.default.undefined(r["content-length"])&&Ie.default.undefined(r["transfer-encoding"])&&!o&&!Ie.default.undefined(c)&&(r["content-length"]=String(c))}}else o?this._lockWrite():this._unlockWrite();this[Pu]=Number(r["content-length"])||void 0}async _onResponseBase(e){let{options:r}=this,{url:A}=r;this[j3]=e,r.decompress&&(e=o0e(e));let n=e.statusCode,s=e;s.statusMessage=s.statusMessage?s.statusMessage:G3.STATUS_CODES[n],s.url=r.url.toString(),s.requestUrl=this.requestUrl,s.redirectUrls=this.redirects,s.request=this,s.isFromCache=e.fromCache||!1,s.ip=this.ip,s.retryCount=this.retryCount,this[q3]=s.isFromCache,this[Hu]=Number(e.headers["content-length"])||void 0,this[iI]=e,e.once("end",()=>{this[Hu]=this[Ju],this.emit("downloadProgress",this.downloadProgress)}),e.once("error",o=>{e.destroy(),this._beforeError(new df(o,this))}),e.once("aborted",()=>{this._beforeError(new df({name:"Error",message:"The server aborted pending request",code:"ECONNRESET"},this))}),this.emit("downloadProgress",this.downloadProgress);let i=e.headers["set-cookie"];if(Ie.default.object(r.cookieJar)&&i){let o=i.map(async a=>r.cookieJar.setCookie(a,A.toString()));r.ignoreInvalidCookies&&(o=o.map(async a=>a.catch(()=>{})));try{await Promise.all(o)}catch(a){this._beforeError(a);return}}if(r.followRedirect&&e.headers.location&&m0e.has(n)){if(e.resume(),this[qr]&&(this[LS](),delete this[qr],this[V3]()),(n===303&&r.method!=="GET"&&r.method!=="HEAD"||!r.methodRewriting)&&(r.method="GET","body"in r&&delete r.body,"json"in r&&delete r.json,"form"in r&&delete r.form,this[wo]=void 0,delete r.headers["content-length"]),this.redirects.length>=r.maxRedirects){this._beforeError(new oI(this));return}try{let u=function(h){return h.protocol==="unix:"||h.hostname==="unix"},a=Buffer.from(e.headers.location,"binary").toString(),c=new mo.URL(a,A),l=c.toString();if(decodeURI(l),!u(A)&&u(c)){this._beforeError(new Br("Cannot redirect to UNIX socket",{},this));return}c.hostname!==A.hostname||c.port!==A.port?("host"in r.headers&&delete r.headers.host,"cookie"in r.headers&&delete r.headers.cookie,"authorization"in r.headers&&delete r.headers.authorization,(r.username||r.password)&&(r.username="",r.password="")):(c.username=r.username,c.password=r.password),this.redirects.push(l),r.url=c;for(let h of r.hooks.beforeRedirect)await h(r,s);this.emit("redirect",s,r),await this._makeRequest()}catch(a){this._beforeError(a);return}return}if(r.isStream&&r.throwHttpErrors&&!E0e.isResponseOk(s)){this._beforeError(new aI(s));return}e.on("readable",()=>{this[sI]&&this._read()}),this.on("resume",()=>{e.resume()}),this.on("pause",()=>{e.pause()}),e.once("end",()=>{this.push(null)}),this.emit("response",e);for(let o of this[nI])if(!o.headersSent){for(let a in e.headers){let c=r.decompress?a!=="content-encoding":!0,l=e.headers[a];c&&o.setHeader(a,l)}o.statusCode=n}}async _onResponse(e){try{await this._onResponseBase(e)}catch(r){this._beforeError(r)}}_onRequest(e){let{options:r}=this,{timeout:A,url:n}=r;s0e.default(e),this[LS]=H3.default(e,A,n);let s=r.cache?"cacheableResponse":"response";e.once(s,a=>{this._onResponse(a)}),e.once("error",a=>{var c;e.destroy(),(c=e.res)===null||c===void 0||c.removeAllListeners("end"),a=a instanceof H3.TimeoutError?new uI(a,this.timings,this):new Br(a.message,a,this),this._beforeError(a)}),this[V3]=u0e.default(e,this,w0e),this[qr]=e,this.emit("uploadProgress",this.uploadProgress);let i=this[wo],o=this.redirects.length===0?this:e;Ie.default.nodeStream(i)?(i.pipe(o),i.once("error",a=>{this._beforeError(new lI(a,this))})):(this._unlockWrite(),Ie.default.undefined(i)?(this._cannotHaveBody||this._noPipe)&&(o.end(),this._lockWrite()):(this._writeRequest(i,void 0,()=>{}),o.end(),this._lockWrite())),this.emit("request",e)}async _createCacheableRequest(e,r){return new Promise((A,n)=>{Object.assign(r,h0e.default(e)),delete r.url;let s,i=xS.get(r.cache)(r,async o=>{o._readableState.autoDestroy=!1,s&&(await s).emit("cacheableResponse",o),A(o)});r.url=e,i.once("error",n),i.once("request",async o=>{s=o,A(s)})})}async _makeRequest(){var e,r,A,n,s;let{options:i}=this,{headers:o}=i;for(let C in o)if(Ie.default.undefined(o[C]))delete o[C];else if(Ie.default.null_(o[C]))throw new TypeError(`Use \`undefined\` instead of \`null\` to delete the \`${C}\` header`);if(i.decompress&&Ie.default.undefined(o["accept-encoding"])&&(o["accept-encoding"]=B0e?"gzip, deflate, br":"gzip, deflate"),i.cookieJar){let C=await i.cookieJar.getCookieString(i.url.toString());Ie.default.nonEmptyString(C)&&(i.headers.cookie=C)}for(let C of i.hooks.beforeRequest){let Q=await C(i);if(!Ie.default.undefined(Q)){i.request=()=>Q;break}}i.body&&this[wo]!==i.body&&(this[wo]=i.body);let{agent:a,request:c,timeout:l,url:u}=i;if(i.dnsCache&&!("lookup"in i)&&(i.lookup=i.dnsCache.lookup),u.hostname==="unix"){let C=/(?<socketPath>.+?):(?<path>.+)/.exec(`${u.pathname}${u.search}`);if(C!=null&&C.groups){let{socketPath:Q,path:w}=C.groups;Object.assign(i,{socketPath:Q,path:w,host:""})}}let h=u.protocol==="https:",g;i.http2?g=a0e.auto:g=h?n0e.request:G3.request;let E=(e=i.request)!==null&&e!==void 0?e:g,d=i.cache?this._createCacheableRequest:E;a&&!i.http2&&(i.agent=a[h?"https":"http"]),i[qr]=E,delete i.request,delete i.timeout;let f=i;if(f.shared=(r=i.cacheOptions)===null||r===void 0?void 0:r.shared,f.cacheHeuristic=(A=i.cacheOptions)===null||A===void 0?void 0:A.cacheHeuristic,f.immutableMinTimeToLive=(n=i.cacheOptions)===null||n===void 0?void 0:n.immutableMinTimeToLive,f.ignoreCargoCult=(s=i.cacheOptions)===null||s===void 0?void 0:s.ignoreCargoCult,i.dnsLookupIpVersion!==void 0)try{f.family=P3.dnsLookupIpVersionToFamily(i.dnsLookupIpVersion)}catch{throw new Error("Invalid `dnsLookupIpVersion` option value")}i.https&&("rejectUnauthorized"in i.https&&(f.rejectUnauthorized=i.https.rejectUnauthorized),i.https.checkServerIdentity&&(f.checkServerIdentity=i.https.checkServerIdentity),i.https.certificateAuthority&&(f.ca=i.https.certificateAuthority),i.https.certificate&&(f.cert=i.https.certificate),i.https.key&&(f.key=i.https.key),i.https.passphrase&&(f.passphrase=i.https.passphrase),i.https.pfx&&(f.pfx=i.https.pfx));try{let C=await d(u,f);Ie.default.undefined(C)&&(C=g(u,f)),i.request=c,i.timeout=l,i.agent=a,i.https&&("rejectUnauthorized"in i.https&&delete f.rejectUnauthorized,i.https.checkServerIdentity&&delete f.checkServerIdentity,i.https.certificateAuthority&&delete f.ca,i.https.certificate&&delete f.cert,i.https.key&&delete f.key,i.https.passphrase&&delete f.passphrase,i.https.pfx&&delete f.pfx),I0e(C)?this._onRequest(C):this.writable?(this.once("finish",()=>{this._onResponse(C)}),this._unlockWrite(),this.end(),this._lockWrite()):this._onResponse(C)}catch(C){throw C instanceof Y3.CacheError?new cI(C,this):new Br(C.message,C,this)}}async _error(e){try{for(let r of this.options.hooks.beforeError)e=await r(e)}catch(r){e=new Br(r.message,r,this)}this.destroy(e)}_beforeError(e){if(this[qu])return;let{options:r}=this,A=this.retryCount+1;this[qu]=!0,e instanceof Br||(e=new Br(e.message,e,this));let n=e,{response:s}=n;(async()=>{if(s&&!s.body){s.setEncoding(this._readableState.encoding);try{s.rawBody=await f0e.default(s),s.body=s.rawBody.toString()}catch{}}if(this.listenerCount("retry")!==0){let i;try{let o;s&&"retry-after"in s.headers&&(o=Number(s.headers["retry-after"]),Number.isNaN(o)?(o=Date.parse(s.headers["retry-after"])-Date.now(),o<=0&&(o=1)):o*=1e3),i=await r.retry.calculateDelay({attemptCount:A,retryOptions:r.retry,error:n,retryAfter:o,computedValue:C0e.default({attemptCount:A,retryOptions:r.retry,error:n,retryAfter:o,computedValue:0})})}catch(o){this._error(new Br(o.message,o,this));return}if(i){let o=async()=>{try{for(let a of this.options.hooks.beforeRetry)await a(this.options,n,A)}catch(a){this._error(new Br(a.message,e,this));return}this.destroyed||(this.destroy(),this.emit("retry",A,e))};this[z3]=setTimeout(o,i);return}}this._error(n)})()}_read(){this[sI]=!0;let e=this[iI];if(e&&!this[qu]){e.readableLength&&(this[sI]=!1);let r;for(;(r=e.read())!==null;){this[Ju]+=r.length,this[W3]=!0;let A=this.downloadProgress;A.percent<1&&this.emit("downloadProgress",A),this.push(r)}}}_write(e,r,A){let n=()=>{this._writeRequest(e,r,A)};this.requestInitialized?n():this[Ef].push(n)}_writeRequest(e,r,A){this[qr].destroyed||(this._progressCallbacks.push(()=>{this[Vu]+=Buffer.byteLength(e,r);let n=this.uploadProgress;n.percent<1&&this.emit("uploadProgress",n)}),this[qr].write(e,r,n=>{!n&&this._progressCallbacks.length>0&&this._progressCallbacks.shift()(),A(n)}))}_final(e){let r=()=>{for(;this._progressCallbacks.length!==0;)this._progressCallbacks.shift()();if(!(qr in this)){e();return}if(this[qr].destroyed){e();return}this[qr].end(A=>{A||(this[Pu]=this[Vu],this.emit("uploadProgress",this.uploadProgress),this[qr].emit("upload-complete")),e(A)})};this.requestInitialized?r():this[Ef].push(r)}_destroy(e,r){var A;this[qu]=!0,clearTimeout(this[z3]),qr in this&&(this[LS](),!((A=this[iI])===null||A===void 0)&&A.complete||this[qr].destroy()),e!==null&&!Ie.default.undefined(e)&&!(e instanceof Br)&&(e=new Br(e.message,e,this)),r(e)}get _isAboutToError(){return this[qu]}get ip(){var e;return(e=this.socket)===null||e===void 0?void 0:e.remoteAddress}get aborted(){var e,r,A;return((r=(e=this[qr])===null||e===void 0?void 0:e.destroyed)!==null&&r!==void 0?r:this.destroyed)&&!(!((A=this[j3])===null||A===void 0)&&A.complete)}get socket(){var e,r;return(r=(e=this[qr])===null||e===void 0?void 0:e.socket)!==null&&r!==void 0?r:void 0}get downloadProgress(){let e;return this[Hu]?e=this[Ju]/this[Hu]:this[Hu]===this[Ju]?e=1:e=0,{percent:e,transferred:this[Ju],total:this[Hu]}}get uploadProgress(){let e;return this[Pu]?e=this[Vu]/this[Pu]:this[Pu]===this[Vu]?e=1:e=0,{percent:e,transferred:this[Vu],total:this[Pu]}}get timings(){var e;return(e=this[qr])===null||e===void 0?void 0:e.timings}get isFromCache(){return this[q3]}pipe(e,r){if(this[W3])throw new Error("Failed to pipe. The response has been emitted already.");return e instanceof MS.ServerResponse&&this[nI].add(e),super.pipe(e,r)}unpipe(e){return e instanceof MS.ServerResponse&&this[nI].delete(e),super.unpipe(e),this}};_t.default=gI});var Bf=J(jn=>{"use strict";var D0e=jn&&jn.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),b0e=jn&&jn.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&D0e(e,t,r)};Object.defineProperty(jn,"__esModule",{value:!0});jn.CancelError=jn.ParseError=void 0;var Z3=Cf(),US=class extends Z3.RequestError{constructor(e,r){let{options:A}=r.request;super(`${e.message} in "${A.url.toString()}"`,e,r.request),this.name="ParseError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_BODY_PARSE_FAILURE":this.code}};jn.ParseError=US;var _S=class extends Z3.RequestError{constructor(e){super("Promise was canceled",{},e),this.name="CancelError",this.code="ERR_CANCELED"}get isCanceled(){return!0}};jn.CancelError=_S;b0e(Cf(),jn)});var X3=J(GS=>{"use strict";Object.defineProperty(GS,"__esModule",{value:!0});var K3=Bf(),k0e=(t,e,r,A)=>{let{rawBody:n}=t;try{if(e==="text")return n.toString(A);if(e==="json")return n.length===0?"":r(n.toString());if(e==="buffer")return n;throw new K3.ParseError({message:`Unknown body type '${e}'`,name:"Error"},t)}catch(s){throw new K3.ParseError(s,t)}};GS.default=k0e});var YS=J(Do=>{"use strict";var R0e=Do&&Do.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),S0e=Do&&Do.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&R0e(e,t,r)};Object.defineProperty(Do,"__esModule",{value:!0});var F0e=require("events"),v0e=Ei(),N0e=Z8(),fI=Bf(),$3=X3(),e4=Cf(),M0e=mS(),T0e=SS(),t4=FS(),L0e=["request","response","redirect","uploadProgress","downloadProgress"];function r4(t){let e,r,A=new F0e.EventEmitter,n=new N0e((i,o,a)=>{let c=l=>{let u=new e4.default(void 0,t);u.retryCount=l,u._noPipe=!0,a(()=>u.destroy()),a.shouldReject=!1,a(()=>o(new fI.CancelError(u))),e=u,u.once("response",async E=>{var d;if(E.retryCount=l,E.request.aborted)return;let f;try{f=await T0e.default(u),E.rawBody=f}catch{return}if(u._isAboutToError)return;let C=((d=E.headers["content-encoding"])!==null&&d!==void 0?d:"").toLowerCase(),Q=["gzip","deflate","br"].includes(C),{options:w}=u;if(Q&&!w.decompress)E.body=f;else try{E.body=$3.default(E,w.responseType,w.parseJson,w.encoding)}catch(k){if(E.body=f.toString(),t4.isResponseOk(E)){u._beforeError(k);return}}try{for(let[k,R]of w.hooks.afterResponse.entries())E=await R(E,async L=>{let I=e4.default.normalizeArguments(void 0,{...L,retry:{calculateDelay:()=>0},throwHttpErrors:!1,resolveBodyOnly:!1},w);I.hooks.afterResponse=I.hooks.afterResponse.slice(0,k);for(let b of I.hooks.beforeRetry)await b(I);let S=r4(I);return a(()=>{S.catch(()=>{}),S.cancel()}),S})}catch(k){u._beforeError(new fI.RequestError(k.message,k,u));return}if(r=E,!t4.isResponseOk(E)){u._beforeError(new fI.HTTPError(E));return}u.destroy(),i(u.options.resolveBodyOnly?E.body:E)});let h=E=>{if(n.isCanceled)return;let{options:d}=u;if(E instanceof fI.HTTPError&&!d.throwHttpErrors){let{response:f}=E;i(u.options.resolveBodyOnly?f.body:f);return}o(E)};u.once("error",h);let g=u.options.body;u.once("retry",(E,d)=>{var f,C;if(g===((f=d.request)===null||f===void 0?void 0:f.options.body)&&v0e.default.nodeStream((C=d.request)===null||C===void 0?void 0:C.options.body)){h(d);return}c(E)}),M0e.default(u,A,L0e)};c(0)});n.on=(i,o)=>(A.on(i,o),n);let s=i=>{let o=(async()=>{await n;let{options:a}=r.request;return $3.default(r,i,a.parseJson,a.encoding)})();return Object.defineProperties(o,Object.getOwnPropertyDescriptors(n)),o};return n.json=()=>{let{headers:i}=e.options;return!e.writableFinished&&i.accept===void 0&&(i.accept="application/json"),s("json")},n.buffer=()=>s("buffer"),n.text=()=>s("text"),n}Do.default=r4;S0e(Bf(),Do)});var A4=J(OS=>{"use strict";Object.defineProperty(OS,"__esModule",{value:!0});var x0e=Bf();function U0e(t,...e){let r=(async()=>{if(t instanceof x0e.RequestError)try{for(let n of e)if(n)for(let s of n)t=await s(t)}catch(n){t=n}throw t})(),A=()=>r;return r.json=A,r.text=A,r.buffer=A,r.on=A,r}OS.default=U0e});var i4=J(HS=>{"use strict";Object.defineProperty(HS,"__esModule",{value:!0});var n4=Ei();function s4(t){for(let e of Object.values(t))(n4.default.plainObject(e)||n4.default.array(e))&&s4(e);return Object.freeze(t)}HS.default=s4});var a4=J(o4=>{"use strict";Object.defineProperty(o4,"__esModule",{value:!0})});var JS=J(kn=>{"use strict";var _0e=kn&&kn.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),G0e=kn&&kn.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&_0e(e,t,r)};Object.defineProperty(kn,"__esModule",{value:!0});kn.defaultHandler=void 0;var c4=Ei(),bn=YS(),Y0e=A4(),dI=Cf(),O0e=i4(),H0e={RequestError:bn.RequestError,CacheError:bn.CacheError,ReadError:bn.ReadError,HTTPError:bn.HTTPError,MaxRedirectsError:bn.MaxRedirectsError,TimeoutError:bn.TimeoutError,ParseError:bn.ParseError,CancelError:bn.CancelError,UnsupportedProtocolError:bn.UnsupportedProtocolError,UploadError:bn.UploadError},J0e=async t=>new Promise(e=>{setTimeout(e,t)}),{normalizeArguments:EI}=dI.default,l4=(...t)=>{let e;for(let r of t)e=EI(void 0,r,e);return e},P0e=t=>t.isStream?new dI.default(void 0,t):bn.default(t),V0e=t=>"defaults"in t&&"options"in t.defaults,q0e=["get","post","put","patch","head","delete"];kn.defaultHandler=(t,e)=>e(t);var u4=(t,e)=>{if(t)for(let r of t)r(e)},h4=t=>{t._rawHandlers=t.handlers,t.handlers=t.handlers.map(A=>((n,s)=>{let i,o=A(n,a=>(i=s(a),i));if(o!==i&&!n.isStream&&i){let a=o,{then:c,catch:l,finally:u}=a;Object.setPrototypeOf(a,Object.getPrototypeOf(i)),Object.defineProperties(a,Object.getOwnPropertyDescriptors(i)),a.then=c,a.catch=l,a.finally=u}return o}));let e=((A,n={},s)=>{var i,o;let a=0,c=l=>t.handlers[a++](l,a===t.handlers.length?P0e:c);if(c4.default.plainObject(A)){let l={...A,...n};dI.setNonEnumerableProperties([A,n],l),n=l,A=void 0}try{let l;try{u4(t.options.hooks.init,n),u4((i=n.hooks)===null||i===void 0?void 0:i.init,n)}catch(h){l=h}let u=EI(A,n,s!=null?s:t.options);if(u[dI.kIsNormalizedAlready]=!0,l)throw new bn.RequestError(l.message,l,u);return c(u)}catch(l){if(n.isStream)throw l;return Y0e.default(l,t.options.hooks.beforeError,(o=n.hooks)===null||o===void 0?void 0:o.beforeError)}});e.extend=(...A)=>{let n=[t.options],s=[...t._rawHandlers],i;for(let o of A)V0e(o)?(n.push(o.defaults.options),s.push(...o.defaults._rawHandlers),i=o.defaults.mutableDefaults):(n.push(o),"handlers"in o&&s.push(...o.handlers),i=o.mutableDefaults);return s=s.filter(o=>o!==kn.defaultHandler),s.length===0&&s.push(kn.defaultHandler),h4({options:l4(...n),handlers:s,mutableDefaults:!!i})};let r=(async function*(A,n){let s=EI(A,n,t.options);s.resolveBodyOnly=!1;let i=s.pagination;if(!c4.default.object(i))throw new TypeError("`options.pagination` must be implemented");let o=[],{countLimit:a}=i,c=0;for(;c<i.requestLimit;){c!==0&&await J0e(i.backoff);let l=await e(void 0,void 0,s),u=await i.transform(l),h=[];for(let E of u)if(i.filter(E,o,h)&&(!i.shouldContinue(E,o,h)||(yield E,i.stackAllItems&&o.push(E),h.push(E),--a<=0)))return;let g=i.paginate(l,o,h);if(g===!1)return;g===l.request.options?s=l.request.options:g!==void 0&&(s=EI(void 0,g,s)),c++}});e.paginate=r,e.paginate.all=(async(A,n)=>{let s=[];for await(let i of r(A,n))s.push(i);return s}),e.paginate.each=r,e.stream=((A,n)=>e(A,{...n,isStream:!0}));for(let A of q0e)e[A]=((n,s)=>e(n,{...s,method:A})),e.stream[A]=((n,s)=>e(n,{...s,method:A,isStream:!0}));return Object.assign(e,H0e),Object.defineProperty(e,"defaults",{value:t.mutableDefaults?t:O0e.default(t),writable:t.mutableDefaults,configurable:t.mutableDefaults,enumerable:!0}),e.mergeOptions=l4,e};kn.default=h4;G0e(a4(),kn)});var E4=J((di,CI)=>{"use strict";var W0e=di&&di.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),g4=di&&di.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&W0e(e,t,r)};Object.defineProperty(di,"__esModule",{value:!0});var j0e=require("url"),f4=JS(),z0e={options:{method:"GET",retry:{limit:2,methods:["GET","PUT","HEAD","DELETE","OPTIONS","TRACE"],statusCodes:[408,413,429,500,502,503,504,521,522,524],errorCodes:["ETIMEDOUT","ECONNRESET","EADDRINUSE","ECONNREFUSED","EPIPE","ENOTFOUND","ENETUNREACH","EAI_AGAIN"],maxRetryAfter:void 0,calculateDelay:({computedValue:t})=>t},timeout:{},headers:{"user-agent":"got (https://github.com/sindresorhus/got)"},hooks:{init:[],beforeRequest:[],beforeRedirect:[],beforeRetry:[],beforeError:[],afterResponse:[]},cache:void 0,dnsCache:void 0,decompress:!0,throwHttpErrors:!0,followRedirect:!0,isStream:!1,responseType:"text",resolveBodyOnly:!1,maxRedirects:10,prefixUrl:"",methodRewriting:!0,ignoreInvalidCookies:!1,context:{},http2:!1,allowGetBody:!1,https:void 0,pagination:{transform:t=>t.request.options.responseType==="json"?t.body:JSON.parse(t.body),paginate:t=>{if(!Reflect.has(t.headers,"link"))return!1;let e=t.headers.link.split(","),r;for(let A of e){let n=A.split(";");if(n[1].includes("next")){r=n[0].trimStart().trim(),r=r.slice(1,-1);break}}return r?{url:new j0e.URL(r)}:!1},filter:()=>!0,shouldContinue:()=>!0,countLimit:1/0,backoff:0,requestLimit:1e4,stackAllItems:!0},parseJson:t=>JSON.parse(t),stringifyJson:t=>JSON.stringify(t),cacheOptions:{}},handlers:[f4.defaultHandler],mutableDefaults:!1},PS=f4.default(z0e);di.default=PS;CI.exports=PS;CI.exports.default=PS;CI.exports.__esModule=!0;g4(JS(),di);g4(YS(),di)});var C4=J((_1e,X0e)=>{X0e.exports=[{name:"Agola CI",constant:"AGOLA",env:"AGOLA_GIT_REF",pr:"AGOLA_PULL_REQUEST_ID"},{name:"Appcircle",constant:"APPCIRCLE",env:"AC_APPCIRCLE"},{name:"AppVeyor",constant:"APPVEYOR",env:"APPVEYOR",pr:"APPVEYOR_PULL_REQUEST_NUMBER"},{name:"AWS CodeBuild",constant:"CODEBUILD",env:"CODEBUILD_BUILD_ARN"},{name:"Azure Pipelines",constant:"AZURE_PIPELINES",env:"TF_BUILD",pr:{BUILD_REASON:"PullRequest"}},{name:"Bamboo",constant:"BAMBOO",env:"bamboo_planKey"},{name:"Bitbucket Pipelines",constant:"BITBUCKET",env:"BITBUCKET_COMMIT",pr:"BITBUCKET_PR_ID"},{name:"Bitrise",constant:"BITRISE",env:"BITRISE_IO",pr:"BITRISE_PULL_REQUEST"},{name:"Buddy",constant:"BUDDY",env:"BUDDY_WORKSPACE_ID",pr:"BUDDY_EXECUTION_PULL_REQUEST_ID"},{name:"Buildkite",constant:"BUILDKITE",env:"BUILDKITE",pr:{env:"BUILDKITE_PULL_REQUEST",ne:"false"}},{name:"CircleCI",constant:"CIRCLE",env:"CIRCLECI",pr:"CIRCLE_PULL_REQUEST"},{name:"Cirrus CI",constant:"CIRRUS",env:"CIRRUS_CI",pr:"CIRRUS_PR"},{name:"Codefresh",constant:"CODEFRESH",env:"CF_BUILD_ID",pr:{any:["CF_PULL_REQUEST_NUMBER","CF_PULL_REQUEST_ID"]}},{name:"Codemagic",constant:"CODEMAGIC",env:"CM_BUILD_ID",pr:"CM_PULL_REQUEST"},{name:"Codeship",constant:"CODESHIP",env:{CI_NAME:"codeship"}},{name:"Drone",constant:"DRONE",env:"DRONE",pr:{DRONE_BUILD_EVENT:"pull_request"}},{name:"dsari",constant:"DSARI",env:"DSARI"},{name:"Earthly",constant:"EARTHLY",env:"EARTHLY_CI"},{name:"Expo Application Services",constant:"EAS",env:"EAS_BUILD"},{name:"Gerrit",constant:"GERRIT",env:"GERRIT_PROJECT"},{name:"Gitea Actions",constant:"GITEA_ACTIONS",env:"GITEA_ACTIONS"},{name:"GitHub Actions",constant:"GITHUB_ACTIONS",env:"GITHUB_ACTIONS",pr:{GITHUB_EVENT_NAME:"pull_request"}},{name:"GitLab CI",constant:"GITLAB",env:"GITLAB_CI",pr:"CI_MERGE_REQUEST_ID"},{name:"GoCD",constant:"GOCD",env:"GO_PIPELINE_LABEL"},{name:"Google Cloud Build",constant:"GOOGLE_CLOUD_BUILD",env:"BUILDER_OUTPUT"},{name:"Harness CI",constant:"HARNESS",env:"HARNESS_BUILD_ID"},{name:"Heroku",constant:"HEROKU",env:{env:"NODE",includes:"/app/.heroku/node/bin/node"}},{name:"Hudson",constant:"HUDSON",env:"HUDSON_URL"},{name:"Jenkins",constant:"JENKINS",env:["JENKINS_URL","BUILD_ID"],pr:{any:["ghprbPullId","CHANGE_ID"]}},{name:"LayerCI",constant:"LAYERCI",env:"LAYERCI",pr:"LAYERCI_PULL_REQUEST"},{name:"Magnum CI",constant:"MAGNUM",env:"MAGNUM"},{name:"Netlify CI",constant:"NETLIFY",env:"NETLIFY",pr:{env:"PULL_REQUEST",ne:"false"}},{name:"Nevercode",constant:"NEVERCODE",env:"NEVERCODE",pr:{env:"NEVERCODE_PULL_REQUEST",ne:"false"}},{name:"Prow",constant:"PROW",env:"PROW_JOB_ID"},{name:"ReleaseHub",constant:"RELEASEHUB",env:"RELEASE_BUILD_ID"},{name:"Render",constant:"RENDER",env:"RENDER",pr:{IS_PULL_REQUEST:"true"}},{name:"Sail CI",constant:"SAIL",env:"SAILCI",pr:"SAIL_PULL_REQUEST_NUMBER"},{name:"Screwdriver",constant:"SCREWDRIVER",env:"SCREWDRIVER",pr:{env:"SD_PULL_REQUEST",ne:"false"}},{name:"Semaphore",constant:"SEMAPHORE",env:"SEMAPHORE",pr:"PULL_REQUEST_NUMBER"},{name:"Sourcehut",constant:"SOURCEHUT",env:{CI_NAME:"sourcehut"}},{name:"Strider CD",constant:"STRIDER",env:"STRIDER"},{name:"TaskCluster",constant:"TASKCLUSTER",env:["TASK_ID","RUN_ID"]},{name:"TeamCity",constant:"TEAMCITY",env:"TEAMCITY_VERSION"},{name:"Travis CI",constant:"TRAVIS",env:"TRAVIS",pr:{env:"TRAVIS_PULL_REQUEST",ne:"false"}},{name:"Vela",constant:"VELA",env:"VELA",pr:{VELA_PULL_REQUEST:"1"}},{name:"Vercel",constant:"VERCEL",env:{any:["NOW_BUILDER","VERCEL"]},pr:"VERCEL_GIT_PULL_REQUEST_ID"},{name:"Visual Studio App Center",constant:"APPCENTER",env:"APPCENTER_BUILD_ID"},{name:"Woodpecker",constant:"WOODPECKER",env:{CI:"woodpecker"},pr:{CI_BUILD_EVENT:"pull_request"}},{name:"Xcode Cloud",constant:"XCODE_CLOUD",env:"CI_XCODE_PROJECT",pr:"CI_PULL_REQUEST_NUMBER"},{name:"Xcode Server",constant:"XCODE_SERVER",env:"XCS"}]});var I4=J(KA=>{"use strict";var Q4=C4(),vr=process.env;Object.defineProperty(KA,"_vendors",{value:Q4.map(function(t){return t.constant})});KA.name=null;KA.isPR=null;Q4.forEach(function(t){let r=(Array.isArray(t.env)?t.env:[t.env]).every(function(A){return B4(A)});if(KA[t.constant]=r,!!r)switch(KA.name=t.name,typeof t.pr){case"string":KA.isPR=!!vr[t.pr];break;case"object":"env"in t.pr?KA.isPR=t.pr.env in vr&&vr[t.pr.env]!==t.pr.ne:"any"in t.pr?KA.isPR=t.pr.any.some(function(A){return!!vr[A]}):KA.isPR=B4(t.pr);break;default:KA.isPR=null}});KA.isCI=!!(vr.CI!=="false"&&(vr.BUILD_ID||vr.BUILD_NUMBER||vr.CI||vr.CI_APP_ID||vr.CI_BUILD_ID||vr.CI_BUILD_NUMBER||vr.CI_NAME||vr.CONTINUOUS_INTEGRATION||vr.RUN_ID||KA.name));function B4(t){return typeof t=="string"?!!vr[t]:"env"in t?vr[t.env]&&vr[t.env].includes(t.includes):"any"in t?t.any.some(function(e){return!!vr[e]}):Object.keys(t).every(function(e){return vr[e]===t[e]})}});var jS=J((tTe,sye)=>{sye.exports={name:"create-turbo",version:"2.8.2-canary.1",description:"Create a new Turborepo",homepage:"https://turborepo.dev",license:"MIT",repository:{type:"git",url:"https://github.com/vercel/turborepo",directory:"packages/create-turbo"},bugs:{url:"https://github.com/vercel/turborepo/issues"},bin:{"create-turbo":"dist/cli.js"},scripts:{build:"tsup",test:"jest","check-types":"tsc --noEmit","lint:prettier":"prettier -c . --cache --ignore-path=../../.prettierignore"},dependencies:{commander:"11.0.0","fs-extra":"11.1.1",inquirer:"8.2.4",picocolors:"1.0.1","proxy-agent":"6.5.0",semver:"7.5.0","update-check":"1.5.4"},devDependencies:{"@jest/globals":"29.7.0","@turbo/telemetry":"workspace:*","@turbo/test-utils":"workspace:*","@turbo/tsconfig":"workspace:*","@turbo/utils":"workspace:*","@turbo/workspaces":"workspace:*","@types/fs-extra":"9.0.13","@types/inquirer":"7.3.3","@types/node":"18.17.4","@types/semver":"7.3.12",jest:"29.7.0","ts-jest":"29.2.5",tsup:"8.5.1",typescript:"5.5.4"},files:["dist"]}});var Kj=qe(require("http")),Xj=qe(require("https")),bF=qe(require("picocolors")),Jf=require("commander");var Bz=qe(xF());function jI(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function rh(t){"@babel/helpers - typeof";return rh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},rh(t)}function zI(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ZI(t,e){if(e&&(rh(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zI(t)}function Fo(t){return Fo=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Fo(t)}function Fs(t,e){return Fs=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(A,n){return A.__proto__=n,A},Fs(t,e)}function KI(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Fs(t,e)}function XI(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function $I(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ac(t,e,r){return $I()?ac=Reflect.construct.bind():ac=function(n,s,i){var o=[null];o.push.apply(o,s);var a=Function.bind.apply(n,o),c=new a;return i&&Fs(c,i.prototype),c},ac.apply(null,arguments)}function Ah(t){var e=typeof Map=="function"?new Map:void 0;return Ah=function(A){if(A===null||!XI(A))return A;if(typeof A!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e!="undefined"){if(e.has(A))return e.get(A);e.set(A,n)}function n(){return ac(A,arguments,Fo(this).constructor)}return n.prototype=Object.create(A.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),Fs(n,A)},Ah(t)}var ev=qe($F());var Qz=qe(require("fs-extra")),kbe=(function(t){KI(e,t);function e(r){var A;return jI(this,e),A=ZI(this,Fo(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),A.directory=r,A}return e})(Ah(Error));var Iz=qe(require("fs")),pz=qe(require("path"));var _te=qe(require("fs")),Gte=qe(require("path"));function dv(t){return typeof t=="undefined"||t===null}function wz(t){return typeof t=="object"&&t!==null}function Dz(t){return Array.isArray(t)?t:dv(t)?[]:[t]}function bz(t,e){var r,A,n,s;if(e)for(s=Object.keys(e),r=0,A=s.length;r<A;r+=1)n=s[r],t[n]=e[n];return t}function kz(t,e){var r="",A;for(A=0;A<e;A+=1)r+=t;return r}function Rz(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var Sz=dv,Fz=wz,vz=Dz,Nz=kz,Mz=Rz,Tz=bz,br={isNothing:Sz,isObject:Fz,toArray:vz,repeat:Nz,isNegativeZero:Mz,extend:Tz};function Cv(t,e){var r="",A=t.reason||"(unknown reason)";return t.mark?(t.mark.name&&(r+='in "'+t.mark.name+'" '),r+="("+(t.mark.line+1)+":"+(t.mark.column+1)+")",!e&&t.mark.snippet&&(r+=`
|
|
73
|
+
`)}`}}};_t.RequestError=Br;var oI=class extends Br{constructor(e){super(`Redirected ${e.options.maxRedirects} times. Aborting.`,{},e),this.name="MaxRedirectsError",this.code="ERR_TOO_MANY_REDIRECTS"}};_t.MaxRedirectsError=oI;var aI=class extends Br{constructor(e){super(`Response code ${e.statusCode} (${e.statusMessage})`,{},e.request),this.name="HTTPError",this.code="ERR_NON_2XX_3XX_RESPONSE"}};_t.HTTPError=aI;var cI=class extends Br{constructor(e,r){super(e.message,e,r),this.name="CacheError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_CACHE_ACCESS":this.code}};_t.CacheError=cI;var lI=class extends Br{constructor(e,r){super(e.message,e,r),this.name="UploadError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_UPLOAD":this.code}};_t.UploadError=lI;var uI=class extends Br{constructor(e,r,A){super(e.message,e,A),this.name="TimeoutError",this.event=e.event,this.timings=r}};_t.TimeoutError=uI;var df=class extends Br{constructor(e,r){super(e.message,e,r),this.name="ReadError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_READING_RESPONSE_STREAM":this.code}};_t.ReadError=df;var hI=class extends Br{constructor(e){super(`Unsupported protocol "${e.url.protocol}"`,{},e),this.name="UnsupportedProtocolError",this.code="ERR_UNSUPPORTED_PROTOCOL"}};_t.UnsupportedProtocolError=hI;var w0e=["socket","connect","continue","information","upgrade","timeout"],gI=class extends _3.Duplex{constructor(e,r={},A){super({autoDestroy:!1,highWaterMark:0}),this[Ju]=0,this[Vu]=0,this.requestInitialized=!1,this[nI]=new Set,this.redirects=[],this[qu]=!1,this[sI]=!1,this[Ef]=[],this.retryCount=0,this._progressCallbacks=[];let n=()=>this._unlockWrite(),s=()=>this._lockWrite();this.on("pipe",c=>{c.prependListener("data",n),c.on("data",s),c.prependListener("end",n),c.on("end",s)}),this.on("unpipe",c=>{c.off("data",n),c.off("data",s),c.off("end",n),c.off("end",s)}),this.on("pipe",c=>{c instanceof MS.IncomingMessage&&(this.options.headers={...c.headers,...this.options.headers})});let{json:i,body:o,form:a}=r;if((i||o||a)&&this._lockWrite(),_t.kIsNormalizedAlready in r)this.options=r;else try{this.options=this.constructor.normalizeArguments(e,r,A)}catch(c){Ie.default.nodeStream(r.body)&&r.body.destroy(),this.destroy(c);return}(async()=>{var c;try{this.options.body instanceof A0e.ReadStream&&await p0e(this.options.body);let{url:l}=this.options;if(!l)throw new TypeError("Missing `url` property");if(this.requestUrl=l.toString(),decodeURI(this.requestUrl),await this._finalizeBody(),await this._makeRequest(),this.destroyed){(c=this[qr])===null||c===void 0||c.destroy();return}for(let u of this[Ef])u();this[Ef].length=0,this.requestInitialized=!0}catch(l){if(l instanceof Br){this._beforeError(l);return}this.destroyed||this.destroy(l)}})()}static normalizeArguments(e,r,A){var n,s,i,o,a;let c=r;if(Ie.default.object(e)&&!Ie.default.urlInstance(e))r={...A,...e,...r};else{if(e&&r&&r.url!==void 0)throw new TypeError("The `url` option is mutually exclusive with the `input` argument");r={...A,...r},e!==void 0&&(r.url=e),Ie.default.urlInstance(r.url)&&(r.url=new mo.URL(r.url.toString()))}if(r.cache===!1&&(r.cache=void 0),r.dnsCache===!1&&(r.dnsCache=void 0),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.method),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.headers),Ie.assert.any([Ie.default.string,Ie.default.urlInstance,Ie.default.undefined],r.prefixUrl),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.cookieJar),Ie.assert.any([Ie.default.object,Ie.default.string,Ie.default.undefined],r.searchParams),Ie.assert.any([Ie.default.object,Ie.default.string,Ie.default.undefined],r.cache),Ie.assert.any([Ie.default.object,Ie.default.number,Ie.default.undefined],r.timeout),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.context),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.hooks),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.decompress),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.ignoreInvalidCookies),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.followRedirect),Ie.assert.any([Ie.default.number,Ie.default.undefined],r.maxRedirects),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.throwHttpErrors),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.http2),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.allowGetBody),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.localAddress),Ie.assert.any([P3.isDnsLookupIpVersion,Ie.default.undefined],r.dnsLookupIpVersion),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.https),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.rejectUnauthorized),r.https&&(Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.https.rejectUnauthorized),Ie.assert.any([Ie.default.function_,Ie.default.undefined],r.https.checkServerIdentity),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.certificateAuthority),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.key),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.certificate),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.https.passphrase),Ie.assert.any([Ie.default.string,Ie.default.buffer,Ie.default.array,Ie.default.undefined],r.https.pfx)),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.cacheOptions),Ie.default.string(r.method)?r.method=r.method.toUpperCase():r.method="GET",r.headers===(A==null?void 0:A.headers)?r.headers={...r.headers}:r.headers=c0e({...A==null?void 0:A.headers,...r.headers}),"slashes"in r)throw new TypeError("The legacy `url.Url` has been deprecated. Use `URL` instead.");if("auth"in r)throw new TypeError("Parameter `auth` is deprecated. Use `username` / `password` instead.");if("searchParams"in r&&r.searchParams&&r.searchParams!==(A==null?void 0:A.searchParams)){let g;if(Ie.default.string(r.searchParams)||r.searchParams instanceof mo.URLSearchParams)g=new mo.URLSearchParams(r.searchParams);else{Q0e(r.searchParams),g=new mo.URLSearchParams;for(let E in r.searchParams){let d=r.searchParams[E];d===null?g.append(E,""):d!==void 0&&g.append(E,d)}}(n=A==null?void 0:A.searchParams)===null||n===void 0||n.forEach((E,d)=>{g.has(d)||g.append(d,E)}),r.searchParams=g}if(r.username=(s=r.username)!==null&&s!==void 0?s:"",r.password=(i=r.password)!==null&&i!==void 0?i:"",Ie.default.undefined(r.prefixUrl)?r.prefixUrl=(o=A==null?void 0:A.prefixUrl)!==null&&o!==void 0?o:"":(r.prefixUrl=r.prefixUrl.toString(),r.prefixUrl!==""&&!r.prefixUrl.endsWith("/")&&(r.prefixUrl+="/")),Ie.default.string(r.url)){if(r.url.startsWith("/"))throw new Error("`input` must not start with a slash when using `prefixUrl`");r.url=J3.default(r.prefixUrl+r.url,r)}else(Ie.default.undefined(r.url)&&r.prefixUrl!==""||r.protocol)&&(r.url=J3.default(r.prefixUrl,r));if(r.url){"port"in r&&delete r.port;let{prefixUrl:g}=r;Object.defineProperty(r,"prefixUrl",{set:d=>{let f=r.url;if(!f.href.startsWith(d))throw new Error(`Cannot change \`prefixUrl\` from ${g} to ${d}: ${f.href}`);r.url=new mo.URL(d+f.href.slice(g.length)),g=d},get:()=>g});let{protocol:E}=r.url;if(E==="unix:"&&(E="http:",r.url=new mo.URL(`http://unix${r.url.pathname}${r.url.search}`)),r.searchParams&&(r.url.search=r.searchParams.toString()),E!=="http:"&&E!=="https:")throw new hI(r);r.username===""?r.username=r.url.username:r.url.username=r.username,r.password===""?r.password=r.url.password:r.url.password=r.password}let{cookieJar:l}=r;if(l){let{setCookie:g,getCookieString:E}=l;Ie.assert.function_(g),Ie.assert.function_(E),g.length===4&&E.length===0&&(g=U3.promisify(g.bind(r.cookieJar)),E=U3.promisify(E.bind(r.cookieJar)),r.cookieJar={setCookie:g,getCookieString:E})}let{cache:u}=r;if(u&&(xS.has(u)||xS.set(u,new Y3(((g,E)=>{let d=g[qr](g,E);return Ie.default.promise(d)&&(d.once=(f,C)=>{if(f==="error")d.catch(C);else if(f==="abort")(async()=>{try{(await d).once("abort",C)}catch{}})();else throw new Error(`Unknown HTTP2 promise event: ${f}`);return d}),d}),u))),r.cacheOptions={...r.cacheOptions},r.dnsCache===!0)TS||(TS=new i0e.default),r.dnsCache=TS;else if(!Ie.default.undefined(r.dnsCache)&&!r.dnsCache.lookup)throw new TypeError(`Parameter \`dnsCache\` must be a CacheableLookup instance or a boolean, got ${Ie.default(r.dnsCache)}`);Ie.default.number(r.timeout)?r.timeout={request:r.timeout}:A&&r.timeout!==A.timeout?r.timeout={...A.timeout,...r.timeout}:r.timeout={...r.timeout},r.context||(r.context={});let h=r.hooks===(A==null?void 0:A.hooks);r.hooks={...r.hooks};for(let g of _t.knownHookEvents)if(g in r.hooks)if(Ie.default.array(r.hooks[g]))r.hooks[g]=[...r.hooks[g]];else throw new TypeError(`Parameter \`${g}\` must be an Array, got ${Ie.default(r.hooks[g])}`);else r.hooks[g]=[];if(A&&!h)for(let g of _t.knownHookEvents)A.hooks[g].length>0&&(r.hooks[g]=[...A.hooks[g],...r.hooks[g]]);if("family"in r&&yo.default('"options.family" was never documented, please use "options.dnsLookupIpVersion"'),A!=null&&A.https&&(r.https={...A.https,...r.https}),"rejectUnauthorized"in r&&yo.default('"options.rejectUnauthorized" is now deprecated, please use "options.https.rejectUnauthorized"'),"checkServerIdentity"in r&&yo.default('"options.checkServerIdentity" was never documented, please use "options.https.checkServerIdentity"'),"ca"in r&&yo.default('"options.ca" was never documented, please use "options.https.certificateAuthority"'),"key"in r&&yo.default('"options.key" was never documented, please use "options.https.key"'),"cert"in r&&yo.default('"options.cert" was never documented, please use "options.https.certificate"'),"passphrase"in r&&yo.default('"options.passphrase" was never documented, please use "options.https.passphrase"'),"pfx"in r&&yo.default('"options.pfx" was never documented, please use "options.https.pfx"'),"followRedirects"in r)throw new TypeError("The `followRedirects` option does not exist. Use `followRedirect` instead.");if(r.agent){for(let g in r.agent)if(g!=="http"&&g!=="https"&&g!=="http2")throw new TypeError(`Expected the \`options.agent\` properties to be \`http\`, \`https\` or \`http2\`, got \`${g}\``)}return r.maxRedirects=(a=r.maxRedirects)!==null&&a!==void 0?a:0,_t.setNonEnumerableProperties([A,c],r),d0e.default(r,A)}_lockWrite(){let e=()=>{throw new TypeError("The payload has been already provided")};this.write=e,this.end=e}_unlockWrite(){this.write=super.write,this.end=super.end}async _finalizeBody(){let{options:e}=this,{headers:r}=e,A=!Ie.default.undefined(e.form),n=!Ie.default.undefined(e.json),s=!Ie.default.undefined(e.body),i=A||n||s,o=_t.withoutBody.has(e.method)&&!(e.method==="GET"&&e.allowGetBody);if(this._cannotHaveBody=o,i){if(o)throw new TypeError(`The \`${e.method}\` method cannot be used with a body`);if([s,A,n].filter(a=>a).length>1)throw new TypeError("The `body`, `json` and `form` options are mutually exclusive");if(s&&!(e.body instanceof _3.Readable)&&!Ie.default.string(e.body)&&!Ie.default.buffer(e.body)&&!O3.default(e.body))throw new TypeError("The `body` option must be a stream.Readable, string or Buffer");if(A&&!Ie.default.object(e.form))throw new TypeError("The `form` option must be an Object");{let a=!Ie.default.string(r["content-type"]);s?(O3.default(e.body)&&a&&(r["content-type"]=`multipart/form-data; boundary=${e.body.getBoundary()}`),this[wo]=e.body):A?(a&&(r["content-type"]="application/x-www-form-urlencoded"),this[wo]=new mo.URLSearchParams(e.form).toString()):(a&&(r["content-type"]="application/json"),this[wo]=e.stringifyJson(e.json));let c=await l0e.default(this[wo],e.headers);Ie.default.undefined(r["content-length"])&&Ie.default.undefined(r["transfer-encoding"])&&!o&&!Ie.default.undefined(c)&&(r["content-length"]=String(c))}}else o?this._lockWrite():this._unlockWrite();this[Pu]=Number(r["content-length"])||void 0}async _onResponseBase(e){let{options:r}=this,{url:A}=r;this[j3]=e,r.decompress&&(e=o0e(e));let n=e.statusCode,s=e;s.statusMessage=s.statusMessage?s.statusMessage:G3.STATUS_CODES[n],s.url=r.url.toString(),s.requestUrl=this.requestUrl,s.redirectUrls=this.redirects,s.request=this,s.isFromCache=e.fromCache||!1,s.ip=this.ip,s.retryCount=this.retryCount,this[q3]=s.isFromCache,this[Hu]=Number(e.headers["content-length"])||void 0,this[iI]=e,e.once("end",()=>{this[Hu]=this[Ju],this.emit("downloadProgress",this.downloadProgress)}),e.once("error",o=>{e.destroy(),this._beforeError(new df(o,this))}),e.once("aborted",()=>{this._beforeError(new df({name:"Error",message:"The server aborted pending request",code:"ECONNRESET"},this))}),this.emit("downloadProgress",this.downloadProgress);let i=e.headers["set-cookie"];if(Ie.default.object(r.cookieJar)&&i){let o=i.map(async a=>r.cookieJar.setCookie(a,A.toString()));r.ignoreInvalidCookies&&(o=o.map(async a=>a.catch(()=>{})));try{await Promise.all(o)}catch(a){this._beforeError(a);return}}if(r.followRedirect&&e.headers.location&&m0e.has(n)){if(e.resume(),this[qr]&&(this[LS](),delete this[qr],this[V3]()),(n===303&&r.method!=="GET"&&r.method!=="HEAD"||!r.methodRewriting)&&(r.method="GET","body"in r&&delete r.body,"json"in r&&delete r.json,"form"in r&&delete r.form,this[wo]=void 0,delete r.headers["content-length"]),this.redirects.length>=r.maxRedirects){this._beforeError(new oI(this));return}try{let u=function(h){return h.protocol==="unix:"||h.hostname==="unix"},a=Buffer.from(e.headers.location,"binary").toString(),c=new mo.URL(a,A),l=c.toString();if(decodeURI(l),!u(A)&&u(c)){this._beforeError(new Br("Cannot redirect to UNIX socket",{},this));return}c.hostname!==A.hostname||c.port!==A.port?("host"in r.headers&&delete r.headers.host,"cookie"in r.headers&&delete r.headers.cookie,"authorization"in r.headers&&delete r.headers.authorization,(r.username||r.password)&&(r.username="",r.password="")):(c.username=r.username,c.password=r.password),this.redirects.push(l),r.url=c;for(let h of r.hooks.beforeRedirect)await h(r,s);this.emit("redirect",s,r),await this._makeRequest()}catch(a){this._beforeError(a);return}return}if(r.isStream&&r.throwHttpErrors&&!E0e.isResponseOk(s)){this._beforeError(new aI(s));return}e.on("readable",()=>{this[sI]&&this._read()}),this.on("resume",()=>{e.resume()}),this.on("pause",()=>{e.pause()}),e.once("end",()=>{this.push(null)}),this.emit("response",e);for(let o of this[nI])if(!o.headersSent){for(let a in e.headers){let c=r.decompress?a!=="content-encoding":!0,l=e.headers[a];c&&o.setHeader(a,l)}o.statusCode=n}}async _onResponse(e){try{await this._onResponseBase(e)}catch(r){this._beforeError(r)}}_onRequest(e){let{options:r}=this,{timeout:A,url:n}=r;s0e.default(e),this[LS]=H3.default(e,A,n);let s=r.cache?"cacheableResponse":"response";e.once(s,a=>{this._onResponse(a)}),e.once("error",a=>{var c;e.destroy(),(c=e.res)===null||c===void 0||c.removeAllListeners("end"),a=a instanceof H3.TimeoutError?new uI(a,this.timings,this):new Br(a.message,a,this),this._beforeError(a)}),this[V3]=u0e.default(e,this,w0e),this[qr]=e,this.emit("uploadProgress",this.uploadProgress);let i=this[wo],o=this.redirects.length===0?this:e;Ie.default.nodeStream(i)?(i.pipe(o),i.once("error",a=>{this._beforeError(new lI(a,this))})):(this._unlockWrite(),Ie.default.undefined(i)?(this._cannotHaveBody||this._noPipe)&&(o.end(),this._lockWrite()):(this._writeRequest(i,void 0,()=>{}),o.end(),this._lockWrite())),this.emit("request",e)}async _createCacheableRequest(e,r){return new Promise((A,n)=>{Object.assign(r,h0e.default(e)),delete r.url;let s,i=xS.get(r.cache)(r,async o=>{o._readableState.autoDestroy=!1,s&&(await s).emit("cacheableResponse",o),A(o)});r.url=e,i.once("error",n),i.once("request",async o=>{s=o,A(s)})})}async _makeRequest(){var e,r,A,n,s;let{options:i}=this,{headers:o}=i;for(let C in o)if(Ie.default.undefined(o[C]))delete o[C];else if(Ie.default.null_(o[C]))throw new TypeError(`Use \`undefined\` instead of \`null\` to delete the \`${C}\` header`);if(i.decompress&&Ie.default.undefined(o["accept-encoding"])&&(o["accept-encoding"]=B0e?"gzip, deflate, br":"gzip, deflate"),i.cookieJar){let C=await i.cookieJar.getCookieString(i.url.toString());Ie.default.nonEmptyString(C)&&(i.headers.cookie=C)}for(let C of i.hooks.beforeRequest){let Q=await C(i);if(!Ie.default.undefined(Q)){i.request=()=>Q;break}}i.body&&this[wo]!==i.body&&(this[wo]=i.body);let{agent:a,request:c,timeout:l,url:u}=i;if(i.dnsCache&&!("lookup"in i)&&(i.lookup=i.dnsCache.lookup),u.hostname==="unix"){let C=/(?<socketPath>.+?):(?<path>.+)/.exec(`${u.pathname}${u.search}`);if(C!=null&&C.groups){let{socketPath:Q,path:w}=C.groups;Object.assign(i,{socketPath:Q,path:w,host:""})}}let h=u.protocol==="https:",g;i.http2?g=a0e.auto:g=h?n0e.request:G3.request;let E=(e=i.request)!==null&&e!==void 0?e:g,d=i.cache?this._createCacheableRequest:E;a&&!i.http2&&(i.agent=a[h?"https":"http"]),i[qr]=E,delete i.request,delete i.timeout;let f=i;if(f.shared=(r=i.cacheOptions)===null||r===void 0?void 0:r.shared,f.cacheHeuristic=(A=i.cacheOptions)===null||A===void 0?void 0:A.cacheHeuristic,f.immutableMinTimeToLive=(n=i.cacheOptions)===null||n===void 0?void 0:n.immutableMinTimeToLive,f.ignoreCargoCult=(s=i.cacheOptions)===null||s===void 0?void 0:s.ignoreCargoCult,i.dnsLookupIpVersion!==void 0)try{f.family=P3.dnsLookupIpVersionToFamily(i.dnsLookupIpVersion)}catch{throw new Error("Invalid `dnsLookupIpVersion` option value")}i.https&&("rejectUnauthorized"in i.https&&(f.rejectUnauthorized=i.https.rejectUnauthorized),i.https.checkServerIdentity&&(f.checkServerIdentity=i.https.checkServerIdentity),i.https.certificateAuthority&&(f.ca=i.https.certificateAuthority),i.https.certificate&&(f.cert=i.https.certificate),i.https.key&&(f.key=i.https.key),i.https.passphrase&&(f.passphrase=i.https.passphrase),i.https.pfx&&(f.pfx=i.https.pfx));try{let C=await d(u,f);Ie.default.undefined(C)&&(C=g(u,f)),i.request=c,i.timeout=l,i.agent=a,i.https&&("rejectUnauthorized"in i.https&&delete f.rejectUnauthorized,i.https.checkServerIdentity&&delete f.checkServerIdentity,i.https.certificateAuthority&&delete f.ca,i.https.certificate&&delete f.cert,i.https.key&&delete f.key,i.https.passphrase&&delete f.passphrase,i.https.pfx&&delete f.pfx),I0e(C)?this._onRequest(C):this.writable?(this.once("finish",()=>{this._onResponse(C)}),this._unlockWrite(),this.end(),this._lockWrite()):this._onResponse(C)}catch(C){throw C instanceof Y3.CacheError?new cI(C,this):new Br(C.message,C,this)}}async _error(e){try{for(let r of this.options.hooks.beforeError)e=await r(e)}catch(r){e=new Br(r.message,r,this)}this.destroy(e)}_beforeError(e){if(this[qu])return;let{options:r}=this,A=this.retryCount+1;this[qu]=!0,e instanceof Br||(e=new Br(e.message,e,this));let n=e,{response:s}=n;(async()=>{if(s&&!s.body){s.setEncoding(this._readableState.encoding);try{s.rawBody=await f0e.default(s),s.body=s.rawBody.toString()}catch{}}if(this.listenerCount("retry")!==0){let i;try{let o;s&&"retry-after"in s.headers&&(o=Number(s.headers["retry-after"]),Number.isNaN(o)?(o=Date.parse(s.headers["retry-after"])-Date.now(),o<=0&&(o=1)):o*=1e3),i=await r.retry.calculateDelay({attemptCount:A,retryOptions:r.retry,error:n,retryAfter:o,computedValue:C0e.default({attemptCount:A,retryOptions:r.retry,error:n,retryAfter:o,computedValue:0})})}catch(o){this._error(new Br(o.message,o,this));return}if(i){let o=async()=>{try{for(let a of this.options.hooks.beforeRetry)await a(this.options,n,A)}catch(a){this._error(new Br(a.message,e,this));return}this.destroyed||(this.destroy(),this.emit("retry",A,e))};this[z3]=setTimeout(o,i);return}}this._error(n)})()}_read(){this[sI]=!0;let e=this[iI];if(e&&!this[qu]){e.readableLength&&(this[sI]=!1);let r;for(;(r=e.read())!==null;){this[Ju]+=r.length,this[W3]=!0;let A=this.downloadProgress;A.percent<1&&this.emit("downloadProgress",A),this.push(r)}}}_write(e,r,A){let n=()=>{this._writeRequest(e,r,A)};this.requestInitialized?n():this[Ef].push(n)}_writeRequest(e,r,A){this[qr].destroyed||(this._progressCallbacks.push(()=>{this[Vu]+=Buffer.byteLength(e,r);let n=this.uploadProgress;n.percent<1&&this.emit("uploadProgress",n)}),this[qr].write(e,r,n=>{!n&&this._progressCallbacks.length>0&&this._progressCallbacks.shift()(),A(n)}))}_final(e){let r=()=>{for(;this._progressCallbacks.length!==0;)this._progressCallbacks.shift()();if(!(qr in this)){e();return}if(this[qr].destroyed){e();return}this[qr].end(A=>{A||(this[Pu]=this[Vu],this.emit("uploadProgress",this.uploadProgress),this[qr].emit("upload-complete")),e(A)})};this.requestInitialized?r():this[Ef].push(r)}_destroy(e,r){var A;this[qu]=!0,clearTimeout(this[z3]),qr in this&&(this[LS](),!((A=this[iI])===null||A===void 0)&&A.complete||this[qr].destroy()),e!==null&&!Ie.default.undefined(e)&&!(e instanceof Br)&&(e=new Br(e.message,e,this)),r(e)}get _isAboutToError(){return this[qu]}get ip(){var e;return(e=this.socket)===null||e===void 0?void 0:e.remoteAddress}get aborted(){var e,r,A;return((r=(e=this[qr])===null||e===void 0?void 0:e.destroyed)!==null&&r!==void 0?r:this.destroyed)&&!(!((A=this[j3])===null||A===void 0)&&A.complete)}get socket(){var e,r;return(r=(e=this[qr])===null||e===void 0?void 0:e.socket)!==null&&r!==void 0?r:void 0}get downloadProgress(){let e;return this[Hu]?e=this[Ju]/this[Hu]:this[Hu]===this[Ju]?e=1:e=0,{percent:e,transferred:this[Ju],total:this[Hu]}}get uploadProgress(){let e;return this[Pu]?e=this[Vu]/this[Pu]:this[Pu]===this[Vu]?e=1:e=0,{percent:e,transferred:this[Vu],total:this[Pu]}}get timings(){var e;return(e=this[qr])===null||e===void 0?void 0:e.timings}get isFromCache(){return this[q3]}pipe(e,r){if(this[W3])throw new Error("Failed to pipe. The response has been emitted already.");return e instanceof MS.ServerResponse&&this[nI].add(e),super.pipe(e,r)}unpipe(e){return e instanceof MS.ServerResponse&&this[nI].delete(e),super.unpipe(e),this}};_t.default=gI});var Bf=J(jn=>{"use strict";var D0e=jn&&jn.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),b0e=jn&&jn.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&D0e(e,t,r)};Object.defineProperty(jn,"__esModule",{value:!0});jn.CancelError=jn.ParseError=void 0;var Z3=Cf(),US=class extends Z3.RequestError{constructor(e,r){let{options:A}=r.request;super(`${e.message} in "${A.url.toString()}"`,e,r.request),this.name="ParseError",this.code=this.code==="ERR_GOT_REQUEST_ERROR"?"ERR_BODY_PARSE_FAILURE":this.code}};jn.ParseError=US;var _S=class extends Z3.RequestError{constructor(e){super("Promise was canceled",{},e),this.name="CancelError",this.code="ERR_CANCELED"}get isCanceled(){return!0}};jn.CancelError=_S;b0e(Cf(),jn)});var X3=J(GS=>{"use strict";Object.defineProperty(GS,"__esModule",{value:!0});var K3=Bf(),k0e=(t,e,r,A)=>{let{rawBody:n}=t;try{if(e==="text")return n.toString(A);if(e==="json")return n.length===0?"":r(n.toString());if(e==="buffer")return n;throw new K3.ParseError({message:`Unknown body type '${e}'`,name:"Error"},t)}catch(s){throw new K3.ParseError(s,t)}};GS.default=k0e});var YS=J(Do=>{"use strict";var R0e=Do&&Do.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),S0e=Do&&Do.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&R0e(e,t,r)};Object.defineProperty(Do,"__esModule",{value:!0});var F0e=require("events"),v0e=Ei(),N0e=Z8(),fI=Bf(),$3=X3(),e4=Cf(),M0e=mS(),T0e=SS(),t4=FS(),L0e=["request","response","redirect","uploadProgress","downloadProgress"];function r4(t){let e,r,A=new F0e.EventEmitter,n=new N0e((i,o,a)=>{let c=l=>{let u=new e4.default(void 0,t);u.retryCount=l,u._noPipe=!0,a(()=>u.destroy()),a.shouldReject=!1,a(()=>o(new fI.CancelError(u))),e=u,u.once("response",async E=>{var d;if(E.retryCount=l,E.request.aborted)return;let f;try{f=await T0e.default(u),E.rawBody=f}catch{return}if(u._isAboutToError)return;let C=((d=E.headers["content-encoding"])!==null&&d!==void 0?d:"").toLowerCase(),Q=["gzip","deflate","br"].includes(C),{options:w}=u;if(Q&&!w.decompress)E.body=f;else try{E.body=$3.default(E,w.responseType,w.parseJson,w.encoding)}catch(k){if(E.body=f.toString(),t4.isResponseOk(E)){u._beforeError(k);return}}try{for(let[k,R]of w.hooks.afterResponse.entries())E=await R(E,async L=>{let I=e4.default.normalizeArguments(void 0,{...L,retry:{calculateDelay:()=>0},throwHttpErrors:!1,resolveBodyOnly:!1},w);I.hooks.afterResponse=I.hooks.afterResponse.slice(0,k);for(let b of I.hooks.beforeRetry)await b(I);let S=r4(I);return a(()=>{S.catch(()=>{}),S.cancel()}),S})}catch(k){u._beforeError(new fI.RequestError(k.message,k,u));return}if(r=E,!t4.isResponseOk(E)){u._beforeError(new fI.HTTPError(E));return}u.destroy(),i(u.options.resolveBodyOnly?E.body:E)});let h=E=>{if(n.isCanceled)return;let{options:d}=u;if(E instanceof fI.HTTPError&&!d.throwHttpErrors){let{response:f}=E;i(u.options.resolveBodyOnly?f.body:f);return}o(E)};u.once("error",h);let g=u.options.body;u.once("retry",(E,d)=>{var f,C;if(g===((f=d.request)===null||f===void 0?void 0:f.options.body)&&v0e.default.nodeStream((C=d.request)===null||C===void 0?void 0:C.options.body)){h(d);return}c(E)}),M0e.default(u,A,L0e)};c(0)});n.on=(i,o)=>(A.on(i,o),n);let s=i=>{let o=(async()=>{await n;let{options:a}=r.request;return $3.default(r,i,a.parseJson,a.encoding)})();return Object.defineProperties(o,Object.getOwnPropertyDescriptors(n)),o};return n.json=()=>{let{headers:i}=e.options;return!e.writableFinished&&i.accept===void 0&&(i.accept="application/json"),s("json")},n.buffer=()=>s("buffer"),n.text=()=>s("text"),n}Do.default=r4;S0e(Bf(),Do)});var A4=J(OS=>{"use strict";Object.defineProperty(OS,"__esModule",{value:!0});var x0e=Bf();function U0e(t,...e){let r=(async()=>{if(t instanceof x0e.RequestError)try{for(let n of e)if(n)for(let s of n)t=await s(t)}catch(n){t=n}throw t})(),A=()=>r;return r.json=A,r.text=A,r.buffer=A,r.on=A,r}OS.default=U0e});var i4=J(HS=>{"use strict";Object.defineProperty(HS,"__esModule",{value:!0});var n4=Ei();function s4(t){for(let e of Object.values(t))(n4.default.plainObject(e)||n4.default.array(e))&&s4(e);return Object.freeze(t)}HS.default=s4});var a4=J(o4=>{"use strict";Object.defineProperty(o4,"__esModule",{value:!0})});var JS=J(kn=>{"use strict";var _0e=kn&&kn.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),G0e=kn&&kn.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&_0e(e,t,r)};Object.defineProperty(kn,"__esModule",{value:!0});kn.defaultHandler=void 0;var c4=Ei(),bn=YS(),Y0e=A4(),dI=Cf(),O0e=i4(),H0e={RequestError:bn.RequestError,CacheError:bn.CacheError,ReadError:bn.ReadError,HTTPError:bn.HTTPError,MaxRedirectsError:bn.MaxRedirectsError,TimeoutError:bn.TimeoutError,ParseError:bn.ParseError,CancelError:bn.CancelError,UnsupportedProtocolError:bn.UnsupportedProtocolError,UploadError:bn.UploadError},J0e=async t=>new Promise(e=>{setTimeout(e,t)}),{normalizeArguments:EI}=dI.default,l4=(...t)=>{let e;for(let r of t)e=EI(void 0,r,e);return e},P0e=t=>t.isStream?new dI.default(void 0,t):bn.default(t),V0e=t=>"defaults"in t&&"options"in t.defaults,q0e=["get","post","put","patch","head","delete"];kn.defaultHandler=(t,e)=>e(t);var u4=(t,e)=>{if(t)for(let r of t)r(e)},h4=t=>{t._rawHandlers=t.handlers,t.handlers=t.handlers.map(A=>((n,s)=>{let i,o=A(n,a=>(i=s(a),i));if(o!==i&&!n.isStream&&i){let a=o,{then:c,catch:l,finally:u}=a;Object.setPrototypeOf(a,Object.getPrototypeOf(i)),Object.defineProperties(a,Object.getOwnPropertyDescriptors(i)),a.then=c,a.catch=l,a.finally=u}return o}));let e=((A,n={},s)=>{var i,o;let a=0,c=l=>t.handlers[a++](l,a===t.handlers.length?P0e:c);if(c4.default.plainObject(A)){let l={...A,...n};dI.setNonEnumerableProperties([A,n],l),n=l,A=void 0}try{let l;try{u4(t.options.hooks.init,n),u4((i=n.hooks)===null||i===void 0?void 0:i.init,n)}catch(h){l=h}let u=EI(A,n,s!=null?s:t.options);if(u[dI.kIsNormalizedAlready]=!0,l)throw new bn.RequestError(l.message,l,u);return c(u)}catch(l){if(n.isStream)throw l;return Y0e.default(l,t.options.hooks.beforeError,(o=n.hooks)===null||o===void 0?void 0:o.beforeError)}});e.extend=(...A)=>{let n=[t.options],s=[...t._rawHandlers],i;for(let o of A)V0e(o)?(n.push(o.defaults.options),s.push(...o.defaults._rawHandlers),i=o.defaults.mutableDefaults):(n.push(o),"handlers"in o&&s.push(...o.handlers),i=o.mutableDefaults);return s=s.filter(o=>o!==kn.defaultHandler),s.length===0&&s.push(kn.defaultHandler),h4({options:l4(...n),handlers:s,mutableDefaults:!!i})};let r=(async function*(A,n){let s=EI(A,n,t.options);s.resolveBodyOnly=!1;let i=s.pagination;if(!c4.default.object(i))throw new TypeError("`options.pagination` must be implemented");let o=[],{countLimit:a}=i,c=0;for(;c<i.requestLimit;){c!==0&&await J0e(i.backoff);let l=await e(void 0,void 0,s),u=await i.transform(l),h=[];for(let E of u)if(i.filter(E,o,h)&&(!i.shouldContinue(E,o,h)||(yield E,i.stackAllItems&&o.push(E),h.push(E),--a<=0)))return;let g=i.paginate(l,o,h);if(g===!1)return;g===l.request.options?s=l.request.options:g!==void 0&&(s=EI(void 0,g,s)),c++}});e.paginate=r,e.paginate.all=(async(A,n)=>{let s=[];for await(let i of r(A,n))s.push(i);return s}),e.paginate.each=r,e.stream=((A,n)=>e(A,{...n,isStream:!0}));for(let A of q0e)e[A]=((n,s)=>e(n,{...s,method:A})),e.stream[A]=((n,s)=>e(n,{...s,method:A,isStream:!0}));return Object.assign(e,H0e),Object.defineProperty(e,"defaults",{value:t.mutableDefaults?t:O0e.default(t),writable:t.mutableDefaults,configurable:t.mutableDefaults,enumerable:!0}),e.mergeOptions=l4,e};kn.default=h4;G0e(a4(),kn)});var E4=J((di,CI)=>{"use strict";var W0e=di&&di.__createBinding||(Object.create?(function(t,e,r,A){A===void 0&&(A=r),Object.defineProperty(t,A,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,A){A===void 0&&(A=r),t[A]=e[r]})),g4=di&&di.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&W0e(e,t,r)};Object.defineProperty(di,"__esModule",{value:!0});var j0e=require("url"),f4=JS(),z0e={options:{method:"GET",retry:{limit:2,methods:["GET","PUT","HEAD","DELETE","OPTIONS","TRACE"],statusCodes:[408,413,429,500,502,503,504,521,522,524],errorCodes:["ETIMEDOUT","ECONNRESET","EADDRINUSE","ECONNREFUSED","EPIPE","ENOTFOUND","ENETUNREACH","EAI_AGAIN"],maxRetryAfter:void 0,calculateDelay:({computedValue:t})=>t},timeout:{},headers:{"user-agent":"got (https://github.com/sindresorhus/got)"},hooks:{init:[],beforeRequest:[],beforeRedirect:[],beforeRetry:[],beforeError:[],afterResponse:[]},cache:void 0,dnsCache:void 0,decompress:!0,throwHttpErrors:!0,followRedirect:!0,isStream:!1,responseType:"text",resolveBodyOnly:!1,maxRedirects:10,prefixUrl:"",methodRewriting:!0,ignoreInvalidCookies:!1,context:{},http2:!1,allowGetBody:!1,https:void 0,pagination:{transform:t=>t.request.options.responseType==="json"?t.body:JSON.parse(t.body),paginate:t=>{if(!Reflect.has(t.headers,"link"))return!1;let e=t.headers.link.split(","),r;for(let A of e){let n=A.split(";");if(n[1].includes("next")){r=n[0].trimStart().trim(),r=r.slice(1,-1);break}}return r?{url:new j0e.URL(r)}:!1},filter:()=>!0,shouldContinue:()=>!0,countLimit:1/0,backoff:0,requestLimit:1e4,stackAllItems:!0},parseJson:t=>JSON.parse(t),stringifyJson:t=>JSON.stringify(t),cacheOptions:{}},handlers:[f4.defaultHandler],mutableDefaults:!1},PS=f4.default(z0e);di.default=PS;CI.exports=PS;CI.exports.default=PS;CI.exports.__esModule=!0;g4(JS(),di);g4(YS(),di)});var C4=J((_1e,X0e)=>{X0e.exports=[{name:"Agola CI",constant:"AGOLA",env:"AGOLA_GIT_REF",pr:"AGOLA_PULL_REQUEST_ID"},{name:"Appcircle",constant:"APPCIRCLE",env:"AC_APPCIRCLE"},{name:"AppVeyor",constant:"APPVEYOR",env:"APPVEYOR",pr:"APPVEYOR_PULL_REQUEST_NUMBER"},{name:"AWS CodeBuild",constant:"CODEBUILD",env:"CODEBUILD_BUILD_ARN"},{name:"Azure Pipelines",constant:"AZURE_PIPELINES",env:"TF_BUILD",pr:{BUILD_REASON:"PullRequest"}},{name:"Bamboo",constant:"BAMBOO",env:"bamboo_planKey"},{name:"Bitbucket Pipelines",constant:"BITBUCKET",env:"BITBUCKET_COMMIT",pr:"BITBUCKET_PR_ID"},{name:"Bitrise",constant:"BITRISE",env:"BITRISE_IO",pr:"BITRISE_PULL_REQUEST"},{name:"Buddy",constant:"BUDDY",env:"BUDDY_WORKSPACE_ID",pr:"BUDDY_EXECUTION_PULL_REQUEST_ID"},{name:"Buildkite",constant:"BUILDKITE",env:"BUILDKITE",pr:{env:"BUILDKITE_PULL_REQUEST",ne:"false"}},{name:"CircleCI",constant:"CIRCLE",env:"CIRCLECI",pr:"CIRCLE_PULL_REQUEST"},{name:"Cirrus CI",constant:"CIRRUS",env:"CIRRUS_CI",pr:"CIRRUS_PR"},{name:"Codefresh",constant:"CODEFRESH",env:"CF_BUILD_ID",pr:{any:["CF_PULL_REQUEST_NUMBER","CF_PULL_REQUEST_ID"]}},{name:"Codemagic",constant:"CODEMAGIC",env:"CM_BUILD_ID",pr:"CM_PULL_REQUEST"},{name:"Codeship",constant:"CODESHIP",env:{CI_NAME:"codeship"}},{name:"Drone",constant:"DRONE",env:"DRONE",pr:{DRONE_BUILD_EVENT:"pull_request"}},{name:"dsari",constant:"DSARI",env:"DSARI"},{name:"Earthly",constant:"EARTHLY",env:"EARTHLY_CI"},{name:"Expo Application Services",constant:"EAS",env:"EAS_BUILD"},{name:"Gerrit",constant:"GERRIT",env:"GERRIT_PROJECT"},{name:"Gitea Actions",constant:"GITEA_ACTIONS",env:"GITEA_ACTIONS"},{name:"GitHub Actions",constant:"GITHUB_ACTIONS",env:"GITHUB_ACTIONS",pr:{GITHUB_EVENT_NAME:"pull_request"}},{name:"GitLab CI",constant:"GITLAB",env:"GITLAB_CI",pr:"CI_MERGE_REQUEST_ID"},{name:"GoCD",constant:"GOCD",env:"GO_PIPELINE_LABEL"},{name:"Google Cloud Build",constant:"GOOGLE_CLOUD_BUILD",env:"BUILDER_OUTPUT"},{name:"Harness CI",constant:"HARNESS",env:"HARNESS_BUILD_ID"},{name:"Heroku",constant:"HEROKU",env:{env:"NODE",includes:"/app/.heroku/node/bin/node"}},{name:"Hudson",constant:"HUDSON",env:"HUDSON_URL"},{name:"Jenkins",constant:"JENKINS",env:["JENKINS_URL","BUILD_ID"],pr:{any:["ghprbPullId","CHANGE_ID"]}},{name:"LayerCI",constant:"LAYERCI",env:"LAYERCI",pr:"LAYERCI_PULL_REQUEST"},{name:"Magnum CI",constant:"MAGNUM",env:"MAGNUM"},{name:"Netlify CI",constant:"NETLIFY",env:"NETLIFY",pr:{env:"PULL_REQUEST",ne:"false"}},{name:"Nevercode",constant:"NEVERCODE",env:"NEVERCODE",pr:{env:"NEVERCODE_PULL_REQUEST",ne:"false"}},{name:"Prow",constant:"PROW",env:"PROW_JOB_ID"},{name:"ReleaseHub",constant:"RELEASEHUB",env:"RELEASE_BUILD_ID"},{name:"Render",constant:"RENDER",env:"RENDER",pr:{IS_PULL_REQUEST:"true"}},{name:"Sail CI",constant:"SAIL",env:"SAILCI",pr:"SAIL_PULL_REQUEST_NUMBER"},{name:"Screwdriver",constant:"SCREWDRIVER",env:"SCREWDRIVER",pr:{env:"SD_PULL_REQUEST",ne:"false"}},{name:"Semaphore",constant:"SEMAPHORE",env:"SEMAPHORE",pr:"PULL_REQUEST_NUMBER"},{name:"Sourcehut",constant:"SOURCEHUT",env:{CI_NAME:"sourcehut"}},{name:"Strider CD",constant:"STRIDER",env:"STRIDER"},{name:"TaskCluster",constant:"TASKCLUSTER",env:["TASK_ID","RUN_ID"]},{name:"TeamCity",constant:"TEAMCITY",env:"TEAMCITY_VERSION"},{name:"Travis CI",constant:"TRAVIS",env:"TRAVIS",pr:{env:"TRAVIS_PULL_REQUEST",ne:"false"}},{name:"Vela",constant:"VELA",env:"VELA",pr:{VELA_PULL_REQUEST:"1"}},{name:"Vercel",constant:"VERCEL",env:{any:["NOW_BUILDER","VERCEL"]},pr:"VERCEL_GIT_PULL_REQUEST_ID"},{name:"Visual Studio App Center",constant:"APPCENTER",env:"APPCENTER_BUILD_ID"},{name:"Woodpecker",constant:"WOODPECKER",env:{CI:"woodpecker"},pr:{CI_BUILD_EVENT:"pull_request"}},{name:"Xcode Cloud",constant:"XCODE_CLOUD",env:"CI_XCODE_PROJECT",pr:"CI_PULL_REQUEST_NUMBER"},{name:"Xcode Server",constant:"XCODE_SERVER",env:"XCS"}]});var I4=J(KA=>{"use strict";var Q4=C4(),vr=process.env;Object.defineProperty(KA,"_vendors",{value:Q4.map(function(t){return t.constant})});KA.name=null;KA.isPR=null;Q4.forEach(function(t){let r=(Array.isArray(t.env)?t.env:[t.env]).every(function(A){return B4(A)});if(KA[t.constant]=r,!!r)switch(KA.name=t.name,typeof t.pr){case"string":KA.isPR=!!vr[t.pr];break;case"object":"env"in t.pr?KA.isPR=t.pr.env in vr&&vr[t.pr.env]!==t.pr.ne:"any"in t.pr?KA.isPR=t.pr.any.some(function(A){return!!vr[A]}):KA.isPR=B4(t.pr);break;default:KA.isPR=null}});KA.isCI=!!(vr.CI!=="false"&&(vr.BUILD_ID||vr.BUILD_NUMBER||vr.CI||vr.CI_APP_ID||vr.CI_BUILD_ID||vr.CI_BUILD_NUMBER||vr.CI_NAME||vr.CONTINUOUS_INTEGRATION||vr.RUN_ID||KA.name));function B4(t){return typeof t=="string"?!!vr[t]:"env"in t?vr[t.env]&&vr[t.env].includes(t.includes):"any"in t?t.any.some(function(e){return!!vr[e]}):Object.keys(t).every(function(e){return vr[e]===t[e]})}});var jS=J((tTe,sye)=>{sye.exports={name:"create-turbo",version:"2.8.2-canary.3",description:"Create a new Turborepo",homepage:"https://turborepo.dev",license:"MIT",repository:{type:"git",url:"https://github.com/vercel/turborepo",directory:"packages/create-turbo"},bugs:{url:"https://github.com/vercel/turborepo/issues"},bin:{"create-turbo":"dist/cli.js"},scripts:{build:"tsup",test:"jest","check-types":"tsc --noEmit","lint:prettier":"prettier -c . --cache --ignore-path=../../.prettierignore"},dependencies:{commander:"11.0.0","fs-extra":"11.1.1",inquirer:"8.2.7",picocolors:"1.0.1","proxy-agent":"6.5.0",semver:"7.5.0","update-check":"1.5.4"},devDependencies:{"@jest/globals":"29.7.0","@turbo/telemetry":"workspace:*","@turbo/test-utils":"workspace:*","@turbo/tsconfig":"workspace:*","@turbo/utils":"workspace:*","@turbo/workspaces":"workspace:*","@types/fs-extra":"9.0.13","@types/inquirer":"7.3.3","@types/node":"18.17.4","@types/semver":"7.3.12",jest:"29.7.0","ts-jest":"29.4.6",tsup:"8.5.1",typescript:"5.5.4"},files:["dist"]}});var Kj=qe(require("http")),Xj=qe(require("https")),bF=qe(require("picocolors")),Jf=require("commander");var Bz=qe(xF());function jI(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function rh(t){"@babel/helpers - typeof";return rh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},rh(t)}function zI(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ZI(t,e){if(e&&(rh(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zI(t)}function Fo(t){return Fo=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Fo(t)}function Fs(t,e){return Fs=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(A,n){return A.__proto__=n,A},Fs(t,e)}function KI(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Fs(t,e)}function XI(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function $I(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ac(t,e,r){return $I()?ac=Reflect.construct.bind():ac=function(n,s,i){var o=[null];o.push.apply(o,s);var a=Function.bind.apply(n,o),c=new a;return i&&Fs(c,i.prototype),c},ac.apply(null,arguments)}function Ah(t){var e=typeof Map=="function"?new Map:void 0;return Ah=function(A){if(A===null||!XI(A))return A;if(typeof A!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e!="undefined"){if(e.has(A))return e.get(A);e.set(A,n)}function n(){return ac(A,arguments,Fo(this).constructor)}return n.prototype=Object.create(A.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),Fs(n,A)},Ah(t)}var ev=qe($F());var Qz=qe(require("fs-extra")),kbe=(function(t){KI(e,t);function e(r){var A;return jI(this,e),A=ZI(this,Fo(e).call(this,"No package.json could be found upwards from the directory ".concat(r))),A.directory=r,A}return e})(Ah(Error));var Iz=qe(require("fs")),pz=qe(require("path"));var _te=qe(require("fs")),Gte=qe(require("path"));function dv(t){return typeof t=="undefined"||t===null}function wz(t){return typeof t=="object"&&t!==null}function Dz(t){return Array.isArray(t)?t:dv(t)?[]:[t]}function bz(t,e){var r,A,n,s;if(e)for(s=Object.keys(e),r=0,A=s.length;r<A;r+=1)n=s[r],t[n]=e[n];return t}function kz(t,e){var r="",A;for(A=0;A<e;A+=1)r+=t;return r}function Rz(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var Sz=dv,Fz=wz,vz=Dz,Nz=kz,Mz=Rz,Tz=bz,br={isNothing:Sz,isObject:Fz,toArray:vz,repeat:Nz,isNegativeZero:Mz,extend:Tz};function Cv(t,e){var r="",A=t.reason||"(unknown reason)";return t.mark?(t.mark.name&&(r+='in "'+t.mark.name+'" '),r+="("+(t.mark.line+1)+":"+(t.mark.column+1)+")",!e&&t.mark.snippet&&(r+=`
|
|
74
74
|
|
|
75
75
|
`+t.mark.snippet),A+" "+r):A}function sh(t,e){Error.call(this),this.name="YAMLException",this.reason=t,this.mark=e,this.message=Cv(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}sh.prototype=Object.create(Error.prototype);sh.prototype.constructor=sh;sh.prototype.toString=function(e){return this.name+": "+Cv(this,e)};var lA=sh;function ip(t,e,r,A,n){var s="",i="",o=Math.floor(n/2)-1;return A-e>o&&(s=" ... ",e=A-o+s.length),r-A>o&&(i=" ...",r=A+o-i.length),{str:s+t.slice(e,r).replace(/\t/g,"\u2192")+i,pos:A-e+s.length}}function op(t,e){return br.repeat(" ",e-t.length)+t}function Lz(t,e){if(e=Object.create(e||null),!t.buffer)return null;e.maxLength||(e.maxLength=79),typeof e.indent!="number"&&(e.indent=1),typeof e.linesBefore!="number"&&(e.linesBefore=3),typeof e.linesAfter!="number"&&(e.linesAfter=2);for(var r=/\r?\n|\r|\0/g,A=[0],n=[],s,i=-1;s=r.exec(t.buffer);)n.push(s.index),A.push(s.index+s[0].length),t.position<=s.index&&i<0&&(i=A.length-2);i<0&&(i=A.length-1);var o="",a,c,l=Math.min(t.line+e.linesAfter,n.length).toString().length,u=e.maxLength-(e.indent+l+3);for(a=1;a<=e.linesBefore&&!(i-a<0);a++)c=ip(t.buffer,A[i-a],n[i-a],t.position-(A[i]-A[i-a]),u),o=br.repeat(" ",e.indent)+op((t.line-a+1).toString(),l)+" | "+c.str+`
|
|
76
76
|
`+o;for(c=ip(t.buffer,A[i],n[i],t.position,u),o+=br.repeat(" ",e.indent)+op((t.line+1).toString(),l)+" | "+c.str+`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-turbo",
|
|
3
|
-
"version": "2.8.2-canary.
|
|
3
|
+
"version": "2.8.2-canary.3",
|
|
4
4
|
"description": "Create a new Turborepo",
|
|
5
5
|
"homepage": "https://turborepo.dev",
|
|
6
6
|
"license": "MIT",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"commander": "11.0.0",
|
|
20
20
|
"fs-extra": "11.1.1",
|
|
21
|
-
"inquirer": "8.2.
|
|
21
|
+
"inquirer": "8.2.7",
|
|
22
22
|
"picocolors": "1.0.1",
|
|
23
23
|
"proxy-agent": "6.5.0",
|
|
24
24
|
"semver": "7.5.0",
|
|
@@ -31,14 +31,14 @@
|
|
|
31
31
|
"@types/node": "18.17.4",
|
|
32
32
|
"@types/semver": "7.3.12",
|
|
33
33
|
"jest": "29.7.0",
|
|
34
|
-
"ts-jest": "29.
|
|
34
|
+
"ts-jest": "29.4.6",
|
|
35
35
|
"tsup": "8.5.1",
|
|
36
36
|
"typescript": "5.5.4",
|
|
37
37
|
"@turbo/telemetry": "0.0.0",
|
|
38
|
-
"@turbo/test-utils": "0.0.0",
|
|
39
38
|
"@turbo/tsconfig": "0.0.0",
|
|
39
|
+
"@turbo/test-utils": "0.0.0",
|
|
40
40
|
"@turbo/utils": "0.0.0",
|
|
41
|
-
"@turbo/workspaces": "2.8.2-canary.
|
|
41
|
+
"@turbo/workspaces": "2.8.2-canary.3"
|
|
42
42
|
},
|
|
43
43
|
"files": [
|
|
44
44
|
"dist"
|