New:Socket for Asana Is Now Available.Learn more
Sign In

@github/copilot-linux-arm64

Package Overview
Dependencies
Maintainers
24
Versions
353
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@github/copilot-linux-arm64 - npm Package Compare versions

Comparing version
1.0.81-11
to
1.0.81-12
+7
-7
index.js

@@ -9,9 +9,9 @@ #!/usr/bin/env node

var at=Object.create;var K=Object.defineProperty;var ct=Object.getOwnPropertyDescriptor;var ut=Object.getOwnPropertyNames;var lt=Object.getPrototypeOf,ft=Object.prototype.hasOwnProperty;var z=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,n)=>(typeof require<"u"?require:t)[n]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var S=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(n){throw t=0,n}};var dt=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of ut(t))!ft.call(e,o)&&o!==n&&K(e,o,{get:()=>t[o],enumerable:!(r=ct(t,o))||r.enumerable});return e};var pt=(e,t,n)=>(n=e!=null?at(lt(e)):{},dt(t||!e||!e.__esModule?K(n,"default",{value:e,enumerable:!0}):n,e));var Z=S((wn,X)=>{"use strict";var Y=()=>process.platform==="linux",E=null,mt=()=>{if(!E)if(Y()&&process.report){let e=process.report.excludeNetwork;process.report.excludeNetwork=!0,E=process.report.getReport(),process.report.excludeNetwork=e}else E={};return E};X.exports={isLinux:Y,getReport:mt}});var te=S((_n,ee)=>{"use strict";var y=z("fs"),gt="/usr/bin/ldd",ht="/proc/self/exe",x=2048,bt=e=>{let t=y.openSync(e,"r"),n=Buffer.alloc(x),r=y.readSync(t,n,0,x,0);return y.close(t,()=>{}),n.subarray(0,r)},yt=e=>new Promise((t,n)=>{y.open(e,"r",(r,o)=>{if(r)n(r);else{let i=Buffer.alloc(x);y.read(o,i,0,x,0,(s,c)=>{t(i.subarray(0,c)),y.close(o,()=>{})})}})});ee.exports={LDD_PATH:gt,SELF_PATH:ht,readFileSync:bt,readFile:yt}});var re=S((Rn,ne)=>{"use strict";var vt=e=>{if(e.length<64||e.readUInt32BE(0)!==2135247942||e.readUInt8(4)!==2||e.readUInt8(5)!==1)return null;let t=e.readUInt32LE(32),n=e.readUInt16LE(54),r=e.readUInt16LE(56);for(let o=0;o<r;o++){let i=t+o*n;if(e.readUInt32LE(i)===3){let c=e.readUInt32LE(i+8),b=e.readUInt32LE(i+32);return e.subarray(c,c+b).toString().replace(/\0.*$/g,"")}}return null};ne.exports={interpreterPath:vt}});var Re=S((Sn,_e)=>{"use strict";var ie=z("child_process"),{isLinux:v,getReport:se}=Z(),{LDD_PATH:P,SELF_PATH:ae,readFile:B,readFileSync:U}=te(),{interpreterPath:ce}=re(),l,f,d,ue="getconf GNU_LIBC_VERSION 2>&1 || true; ldd --version 2>&1 || true",m="",le=()=>m||new Promise(e=>{ie.exec(ue,(t,n)=>{m=t?" ":n,e(m)})}),fe=()=>{if(!m)try{m=ie.execSync(ue,{encoding:"utf8"})}catch{m=" "}return m},p="glibc",de=/LIBC[a-z0-9 \-).]*?(\d+\.\d+)/i,h="musl",wt=e=>e.includes("libc.musl-")||e.includes("ld-musl-"),pe=()=>{let e=se();return e.header&&e.header.glibcVersionRuntime?p:Array.isArray(e.sharedObjects)&&e.sharedObjects.some(wt)?h:null},me=e=>{let[t,n]=e.split(/[\r\n]+/);return t&&t.includes(p)?p:n&&n.includes(h)?h:null},ge=e=>{if(e){if(e.includes("/ld-musl-"))return h;if(e.includes("/ld-linux-"))return p}return null},he=e=>(e=e.toString(),e.includes("musl")?h:e.includes("GNU C Library")?p:null),_t=async()=>{if(f!==void 0)return f;f=null;try{let e=await B(P);f=he(e)}catch{}return f},Rt=()=>{if(f!==void 0)return f;f=null;try{let e=U(P);f=he(e)}catch{}return f},St=async()=>{if(l!==void 0)return l;l=null;try{let e=await B(ae),t=ce(e);l=ge(t)}catch{}return l},Et=()=>{if(l!==void 0)return l;l=null;try{let e=U(ae),t=ce(e);l=ge(t)}catch{}return l},be=async()=>{let e=null;if(v()&&(e=await St(),!e&&(e=await _t(),e||(e=pe()),!e))){let t=await le();e=me(t)}return e},ye=()=>{let e=null;if(v()&&(e=Et(),!e&&(e=Rt(),e||(e=pe()),!e))){let t=fe();e=me(t)}return e},xt=async()=>v()&&await be()!==p,Pt=()=>v()&&ye()!==p,Tt=async()=>{if(d!==void 0)return d;d=null;try{let t=(await B(P)).match(de);t&&(d=t[1])}catch{}return d},Nt=()=>{if(d!==void 0)return d;d=null;try{let t=U(P).match(de);t&&(d=t[1])}catch{}return d},ve=()=>{let e=se();return e.header&&e.header.glibcVersionRuntime?e.header.glibcVersionRuntime:null},oe=e=>e.trim().split(/\s+/)[1],we=e=>{let[t,n,r]=e.split(/[\r\n]+/);return t&&t.includes(p)?oe(t):n&&r&&n.includes(h)?oe(r):null},Lt=async()=>{let e=null;if(v()&&(e=await Tt(),e||(e=ve()),!e)){let t=await le();e=we(t)}return e},Ct=()=>{let e=null;if(v()&&(e=Nt(),e||(e=ve()),!e)){let t=fe();e=we(t)}return e};_e.exports={GLIBC:p,MUSL:h,family:be,familySync:ye,isNonGlibcLinux:xt,isNonGlibcLinuxSync:Pt,version:Lt,versionSync:Ct}});import pn from"node:module";import{dirname as mn,join as gn}from"node:path";import*as st from"node:sea";import{fileURLToPath as hn,pathToFileURL as j}from"node:url";import R from"node:path";import{fileURLToPath as Ae}from"node:url";var H=class{initialQueue=[];initialQueueResolvers=Promise.withResolvers();logWriter=null;cachedOutputPath;writePromise=this.initialQueueResolvers.promise;setLogWriter(t){this.logWriter=t,this.cachedOutputPath=void 0;for(let n of this.initialQueue)this.writeTo(t,n.method,n.message);this.initialQueue=[],this.initialQueueResolvers.resolve()}async flush(){if(!this.logWriter)return;let t=this.logWriter,n=(async()=>{try{await this.writePromise,await t.flush?.()}catch{}})(),r,o=new Promise(i=>{r=setTimeout(i,5e3),r.unref?.()});try{await Promise.race([n,o])}finally{r&&clearTimeout(r)}}async dispose(){await this.flush()}outputPath(){return this.cachedOutputPath??=this.logWriter?.outputPath()}logToLevel(t,n){this.logWriter?this.writeTo(this.logWriter,t,n):this.initialQueue.push({method:t,message:n})}writeTo(t,n,r){if(t.write&&t.flush){t.write(n,r),this.writePromise=t.flush().catch(()=>{});return}this.writePromise=t.writeLog(n,r).catch(()=>{})}info(t){this.logToLevel("info",t)}debug(t){this.logToLevel("debug",t)}warning(t){this.logToLevel("warning",t)}error(t){this.logToLevel("error",t instanceof Error?t.message:t)}log(t){this.error(t)}isDebug(){return!1}shouldLog(t){return!0}notice(t){this.info(t instanceof Error?t.message:t)}startGroup(t,n){this.info(`--- Start of group: ${t} ---`)}endGroup(t){this.info("--- End of group ---")}},Q=new H;import{createRequire as kt}from"node:module";import{platform as Ot,type as It}from"node:os";import{join as Ee,resolve as At}from"node:path";import{fileURLToPath as Dt}from"node:url";var T=pt(Re(),1);function N(e={}){return(e.platform??process.platform)!=="linux"?"gnu":e.detectLibcFamily?e.detectLibcFamily()==="musl"?"musl":"gnu":(0,T.familySync)()===T.MUSL?"musl":"gnu"}function q(e=process.platform,t){let n=t??(e==="linux"?N():"gnu");return e==="linux"&&n==="musl"?"linuxmusl":e}function Se(e=process.platform,t,n=process.arch){return`${q(e,t)}-${n}`}function Ft(){let e=Pe(),t=e==="linux"?N({platform:e}):"gnu";return`${q(e,t)}-${process.arch}`}function Ht(){let e=Pe(),{arch:t}=process;switch(e){case"win32":return`win32-${t}-msvc`;case"darwin":return`darwin-${t}`;case"linux":return`linux-${t}-${N({platform:e})}`;default:throw new Error(`Unsupported platform: ${e}/${t}`)}}var u;function Pe(){if(u!==void 0)return u;switch(It()){case"Windows_NT":u="win32";break;case"Darwin":u="darwin";break;case"Linux":u="linux";break;case"AIX":u="aix";break;case"FreeBSD":case"DragonFly":u="freebsd";break;case"OpenBSD":u="openbsd";break;case"NetBSD":u="netbsd";break;case"SunOS":u="sunos";break;default:u=Ot();break}return u}function L(e,t){let n=Ft(),r=`${e}.node`,o=`${e}.${Ht()}.node`,i=[];for(let c of t){let b=At(c),J=Ee(b,"prebuilds",n,r),D=xe(J);if(D.ok)return D.value;i.push({path:J,err:D.err});let G=Ee(b,o),F=xe(G);if(F.ok)return F.value;i.push({path:G,err:F.err})}let s=i.map(c=>` ${c.path}: ${Bt(c.err)}`).join(`
var ut=Object.create;var z=Object.defineProperty;var ct=Object.getOwnPropertyDescriptor;var lt=Object.getOwnPropertyNames;var ft=Object.getPrototypeOf,dt=Object.prototype.hasOwnProperty;var K=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,n)=>(typeof require<"u"?require:t)[n]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var S=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(n){throw t=0,n}};var pt=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of lt(t))!dt.call(e,o)&&o!==n&&z(e,o,{get:()=>t[o],enumerable:!(r=ct(t,o))||r.enumerable});return e};var gt=(e,t,n)=>(n=e!=null?ut(ft(e)):{},pt(t||!e||!e.__esModule?z(n,"default",{value:e,enumerable:!0}):n,e));var X=S((Rn,Z)=>{"use strict";var Y=()=>process.platform==="linux",E=null,mt=()=>{if(!E)if(Y()&&process.report){let e=process.report.excludeNetwork;process.report.excludeNetwork=!0,E=process.report.getReport(),process.report.excludeNetwork=e}else E={};return E};Z.exports={isLinux:Y,getReport:mt}});var te=S((Sn,ee)=>{"use strict";var y=K("fs"),ht="/usr/bin/ldd",bt="/proc/self/exe",x=2048,yt=e=>{let t=y.openSync(e,"r"),n=Buffer.alloc(x),r=y.readSync(t,n,0,x,0);return y.close(t,()=>{}),n.subarray(0,r)},vt=e=>new Promise((t,n)=>{y.open(e,"r",(r,o)=>{if(r)n(r);else{let i=Buffer.alloc(x);y.read(o,i,0,x,0,(s,a)=>{t(i.subarray(0,a)),y.close(o,()=>{})})}})});ee.exports={LDD_PATH:ht,SELF_PATH:bt,readFileSync:yt,readFile:vt}});var re=S((En,ne)=>{"use strict";var wt=e=>{if(e.length<64||e.readUInt32BE(0)!==2135247942||e.readUInt8(4)!==2||e.readUInt8(5)!==1)return null;let t=e.readUInt32LE(32),n=e.readUInt16LE(54),r=e.readUInt16LE(56);for(let o=0;o<r;o++){let i=t+o*n;if(e.readUInt32LE(i)===3){let a=e.readUInt32LE(i+8),u=e.readUInt32LE(i+32);return e.subarray(a,a+u).toString().replace(/\0.*$/g,"")}}return null};ne.exports={interpreterPath:wt}});var Re=S((xn,_e)=>{"use strict";var ie=K("child_process"),{isLinux:v,getReport:se}=X(),{LDD_PATH:P,SELF_PATH:ae,readFile:B,readFileSync:U}=te(),{interpreterPath:ue}=re(),f,d,p,ce="getconf GNU_LIBC_VERSION 2>&1 || true; ldd --version 2>&1 || true",m="",le=()=>m||new Promise(e=>{ie.exec(ce,(t,n)=>{m=t?" ":n,e(m)})}),fe=()=>{if(!m)try{m=ie.execSync(ce,{encoding:"utf8"})}catch{m=" "}return m},g="glibc",de=/LIBC[a-z0-9 \-).]*?(\d+\.\d+)/i,b="musl",_t=e=>e.includes("libc.musl-")||e.includes("ld-musl-"),pe=()=>{let e=se();return e.header&&e.header.glibcVersionRuntime?g:Array.isArray(e.sharedObjects)&&e.sharedObjects.some(_t)?b:null},ge=e=>{let[t,n]=e.split(/[\r\n]+/);return t&&t.includes(g)?g:n&&n.includes(b)?b:null},me=e=>{if(e){if(e.includes("/ld-musl-"))return b;if(e.includes("/ld-linux-"))return g}return null},he=e=>(e=e.toString(),e.includes("musl")?b:e.includes("GNU C Library")?g:null),Rt=async()=>{if(d!==void 0)return d;d=null;try{let e=await B(P);d=he(e)}catch{}return d},St=()=>{if(d!==void 0)return d;d=null;try{let e=U(P);d=he(e)}catch{}return d},Et=async()=>{if(f!==void 0)return f;f=null;try{let e=await B(ae),t=ue(e);f=me(t)}catch{}return f},xt=()=>{if(f!==void 0)return f;f=null;try{let e=U(ae),t=ue(e);f=me(t)}catch{}return f},be=async()=>{let e=null;if(v()&&(e=await Et(),!e&&(e=await Rt(),e||(e=pe()),!e))){let t=await le();e=ge(t)}return e},ye=()=>{let e=null;if(v()&&(e=xt(),!e&&(e=St(),e||(e=pe()),!e))){let t=fe();e=ge(t)}return e},Pt=async()=>v()&&await be()!==g,Tt=()=>v()&&ye()!==g,Nt=async()=>{if(p!==void 0)return p;p=null;try{let t=(await B(P)).match(de);t&&(p=t[1])}catch{}return p},Lt=()=>{if(p!==void 0)return p;p=null;try{let t=U(P).match(de);t&&(p=t[1])}catch{}return p},ve=()=>{let e=se();return e.header&&e.header.glibcVersionRuntime?e.header.glibcVersionRuntime:null},oe=e=>e.trim().split(/\s+/)[1],we=e=>{let[t,n,r]=e.split(/[\r\n]+/);return t&&t.includes(g)?oe(t):n&&r&&n.includes(b)?oe(r):null},Ct=async()=>{let e=null;if(v()&&(e=await Nt(),e||(e=ve()),!e)){let t=await le();e=we(t)}return e},kt=()=>{let e=null;if(v()&&(e=Lt(),e||(e=ve()),!e)){let t=fe();e=we(t)}return e};_e.exports={GLIBC:g,MUSL:b,family:be,familySync:ye,isNonGlibcLinux:Pt,isNonGlibcLinuxSync:Tt,version:Ct,versionSync:kt}});import mn from"node:module";import{dirname as hn,join as bn}from"node:path";import*as at from"node:sea";import{fileURLToPath as yn,pathToFileURL as j}from"node:url";import R from"node:path";import{fileURLToPath as Ae}from"node:url";var H=class{initialQueue=[];initialQueueResolvers=Promise.withResolvers();logWriter=null;cachedOutputPath;writePromise=this.initialQueueResolvers.promise;setLogWriter(t){this.logWriter=t,this.cachedOutputPath=void 0;for(let n of this.initialQueue)this.writeTo(t,n.method,n.message);this.initialQueue=[],this.initialQueueResolvers.resolve()}async flush(){if(!this.logWriter)return;let t=this.logWriter,n=(async()=>{try{await this.writePromise,await t.flush?.()}catch{}})(),r,o=new Promise(i=>{r=setTimeout(i,5e3),r.unref?.()});try{await Promise.race([n,o])}finally{r&&clearTimeout(r)}}async dispose(){await this.flush()}outputPath(){return this.cachedOutputPath??=this.logWriter?.outputPath()}logToLevel(t,n){this.logWriter?this.writeTo(this.logWriter,t,n):this.initialQueue.push({method:t,message:n})}writeTo(t,n,r){if(t.write&&t.flush){t.write(n,r),this.writePromise=t.flush().catch(()=>{});return}this.writePromise=t.writeLog(n,r).catch(()=>{})}info(t){this.logToLevel("info",t)}debug(t){this.logToLevel("debug",t)}warning(t){this.logToLevel("warning",t)}error(t){this.logToLevel("error",t instanceof Error?t.message:t)}log(t){this.error(t)}isDebug(){return!1}shouldLog(t){return!0}notice(t){this.info(t instanceof Error?t.message:t)}startGroup(t,n){this.info(`--- Start of group: ${t} ---`)}endGroup(t){this.info("--- End of group ---")}},Q=new H;import{createRequire as It}from"node:module";import{platform as Ot,type as At}from"node:os";import{join as Ee,resolve as Dt}from"node:path";import{fileURLToPath as Ft}from"node:url";var T=gt(Re(),1);function N(e={}){return(e.platform??process.platform)!=="linux"?"gnu":e.detectLibcFamily?e.detectLibcFamily()==="musl"?"musl":"gnu":(0,T.familySync)()===T.MUSL?"musl":"gnu"}function q(e=process.platform,t){let n=t??(e==="linux"?N():"gnu");return e==="linux"&&n==="musl"?"linuxmusl":e}function Se(e=process.platform,t,n=process.arch){return`${q(e,t)}-${n}`}function Ht(){let e=Pe(),t=e==="linux"?N({platform:e}):"gnu";return`${q(e,t)}-${process.arch}`}function Bt(){let e=Pe(),{arch:t}=process;switch(e){case"win32":return`win32-${t}-msvc`;case"darwin":return`darwin-${t}`;case"linux":return`linux-${t}-${N({platform:e})}`;default:throw new Error(`Unsupported platform: ${e}/${t}`)}}var l;function Pe(){if(l!==void 0)return l;switch(At()){case"Windows_NT":l="win32";break;case"Darwin":l="darwin";break;case"Linux":l="linux";break;case"AIX":l="aix";break;case"FreeBSD":case"DragonFly":l="freebsd";break;case"OpenBSD":l="openbsd";break;case"NetBSD":l="netbsd";break;case"SunOS":l="sunos";break;default:l=Ot();break}return l}function L(e,t){let n=Ht(),r=`${e}.node`,o=`${e}.${Bt()}.node`,i=[];for(let a of t){let u=Dt(a),J=Ee(u,"prebuilds",n,r),D=xe(J);if(D.ok)return D.value;i.push({path:J,err:D.err});let G=Ee(u,o),F=xe(G);if(F.ok)return F.value;i.push({path:G,err:F.err})}let s=i.map(a=>` ${a.path}: ${Ut(a.err)}`).join(`
`);throw new Error(`Native addon "${e}" not found for ${n}. Tried:
${s}`)}function Bt(e){if(e instanceof Error)return e.message;if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return Object.prototype.toString.call(e)}}function xe(e){try{return{ok:!0,value:Ut(e)}}catch(t){return{ok:!1,err:t}}}function Ut(e){return kt(Dt(import.meta.url))(e)}function Te(e){if(!(e instanceof Error))return e;let t=C.sharedApiSqliteNativeErrorPayload(e.message);if(!t)return e;let n=new Error(t.message);return n.code="ERR_SQLITE_ERROR",n.errcode=t.errcode,n.errstr=t.errstr,n}var Ne="__copilotRuntimeAddon__";function De(){let e=globalThis,t=e[Ne];return t||(t={addon:null,processStateInitialized:!1},e[Ne]=t),t}function qt(){let e=De();if(e.addon)return e.addon;Q.debug("[nativeRuntime] in-process mode: loading the native runtime .node addon");let t=R.dirname(Ae(import.meta.url)),n=L("runtime",[t,R.resolve(t,".."),R.resolve(t,"..","..","native","runtime")]);return e.addon=n,n}var k;function Vt(e){let t=R.dirname(Ae(e));return e.endsWith(".ts")?R.resolve(t,"..","..","..","dist-cli"):t}function Mt(e,t,n,r=import.meta.url){e.toolsInitializeBundledBinaryRoot?.(Vt(r)),e.authInitializeProcessUserAgent?.(n);let o=t.COPILOT_DEBUG_ENTRA_BROKER_URL?.trim()||void 0;delete t.COPILOT_DEBUG_ENTRA_BROKER_URL,e.authInitializeDebugEntraBrokerUrl?.(o)}function w(){k||(k=qt());let e=De();return e.processStateInitialized||(e.processStateInitialized=!0,Mt(k,process.env,process.version)),k}var Le="\0__copilot_git_structured_error__\0",Ce="__copilot_session_fs_error:";function $t(e){if(!(e instanceof Error)||!e.message.startsWith(Le))return e;let t;try{t=JSON.parse(e.message.slice(Le.length))}catch{return e}let n=new Error(typeof t.message=="string"?t.message:"");typeof t.name=="string"&&(n.name=t.name);for(let[r,o]of Object.entries(t))r!=="message"&&r!=="name"&&(n[r]=o);return n}function Fe(e){if(!(e instanceof Error)||!e.message.startsWith(Ce))return e;let t;try{t=JSON.parse(e.message.slice(Ce.length))}catch{return e}let n=typeof t.code=="string"?t.code:"UNKNOWN",r=typeof t.path=="string"?t.path:"sqliteQuery",o=typeof t.message=="string"&&t.message?`: ${t.message}`:"",i=new Error(`${n}: ${r}${o}`);return i.code=n,i.path=r,i}function g(e){let t=Te(e);return t!==e?t:Fe(e)}function ke(e){return e??void 0}function jt(e){class t{inner;constructor(...r){this.inner=new e(...r)}async execute(r,o,i){try{return ke(await this.inner.execute(r,o,i))}catch(s){throw g(s)}}async batch(r){try{return(await this.inner.batch(r)).map(ke)}catch(o){throw g(o)}}async transaction(r){try{return await this.inner.transaction(r)}catch(o){throw g(o)}}async getTableNames(){try{return await this.inner.getTableNames()}catch(r){throw g(r)}}async getTableNamesIfExists(){try{return await this.inner.getTableNamesIfExists()}catch(r){throw g(r)}}async getTodoStatus(){try{return await this.inner.getTodoStatus()}catch(r){throw g(r)}}async getCurrentIntent(){try{return await this.inner.getCurrentIntent()}catch(r){throw g(r)}}async closeAll(){try{await this.inner.closeAll()}catch(r){throw g(r)}}}return Object.defineProperty(t,"name",{value:"SessionDatabaseHandle"}),t}function Oe(e){return JSON.stringify(e,(t,n)=>typeof n=="number"&&!Number.isFinite(n)?{__copilot_forge_number:String(n)}:n)??"null"}var Wt=new Set(["runnerCreateNoopLogger","runnerCreateNoopExec"]),Ie=new WeakMap;function Jt(e,t,n){let r=Ie.get(e);return r||(r=new Map,Ie.set(e,r)),r.has(t)||r.set(t,n()),r.get(t)}function Gt(e,t){let n=Reflect.get(e,t);if(typeof n=="function"&&t==="SessionDatabaseHandle")return jt(n);if(typeof n=="function"&&typeof t=="string"&&Wt.has(t)){let r=n;return()=>Jt(e,t,()=>r.call(e))}if(typeof n=="function"&&t==="sessionStoreTrackingPostToolUsePlan"){let r=n;return(o,i,s)=>r.call(e,Oe(o),Oe(i),s)}if(typeof n=="function"&&typeof t=="string"&&/^git[A-Z]/.test(t)){let r=n;return(...o)=>{let i=r.apply(e,o);return i instanceof Promise?i.catch(s=>{throw $t(s)}):i}}if(typeof n=="function"&&typeof t=="string"&&/^sessionFs[A-Z]/.test(t)){let r=n;return(...o)=>{let i=r.apply(e,o);return i instanceof Promise?i.catch(s=>{throw Fe(s)}):i}}return n}var C=new Proxy({},{get:(e,t)=>Gt(w(),t),has:(e,t)=>Reflect.has(w(),t),set:(e,t,n)=>Reflect.set(w(),t,n),ownKeys:()=>Reflect.ownKeys(w()),getOwnPropertyDescriptor:(e,t)=>Reflect.getOwnPropertyDescriptor(w(),t),defineProperty:(e,t,n)=>Reflect.defineProperty(w(),t,n)});function O(e){return C.errorFormattingFormatUnknown(e)}import{basename as Zt,join as V}from"node:path";var He="0.0.1";function Be(e){return e===He||e.startsWith(`${He}-`)}import{readdir as Kt,access as zt,constants as Qt}from"node:fs/promises";import{join as a,basename as Ue}from"node:path";import{homedir as I}from"node:os";function Ve(){return process.env.XDG_CACHE_HOME||a(I(),".cache")}function Me(){if(process.argv.includes("--no-auto-update")||process.argv.includes("--prefer-version"))return!1;let e=process.env.COPILOT_AUTO_UPDATE;return!(e&&e.toLowerCase()==="false")}function $e(){let e=process.argv.indexOf("--prefer-version");if(!(e===-1||e+1>=process.argv.length))return process.argv[e+1]}function Yt(){if(process.platform==="darwin")return a(I(),"Library","Caches","copilot");if(process.platform==="win32"){let e=process.env.LOCALAPPDATA||a(I(),".cache");return a(e,"copilot")}return a(Ve(),"copilot")}function je(){let e=[];return process.env.COPILOT_PKG_CACHE_HOME&&e.push(a(process.env.COPILOT_PKG_CACHE_HOME,"pkg")),process.env.COPILOT_CACHE_HOME&&e.push(a(process.env.COPILOT_CACHE_HOME,"pkg")),e.push(a(Yt(),"pkg")),e.push(a(Ve(),"copilot","pkg")),process.env.COPILOT_HOME&&e.push(a(process.env.COPILOT_HOME,"pkg")),e.push(a(I(),".copilot","pkg")),[...new Set(e)]}function qe(e){let t=e.match(/^(\d+)\.(\d+)\.(\d+)/);if(t)return[Number(t[1]),Number(t[2]),Number(t[3])]}function Xt(e,t){let n=qe(e),r=qe(t);if(!n&&!r)return 0;if(!n)return-1;if(!r)return 1;for(let s=0;s<3;s++)if(n[s]!==r[s])return n[s]-r[s];let o=e.includes("-"),i=t.includes("-");return o!==i?o?-1:1:e.localeCompare(t)}async function We(e,...t){let n=[];for(let r of t){let o;try{o=await Kt(r)}catch{continue}for(let i of o){let s=a(r,i);try{await zt(a(s,e),Qt.R_OK),n.push(s)}catch{continue}}}return n.sort((r,o)=>{let i=Xt(Ue(o),Ue(r));return i!==0?i:r.localeCompare(o)}),n}import{join as Je}from"node:path";function Ge(){let e=Se();return je().flatMap(t=>[Je(t,"universal"),Je(t,e)])}function en(){return process.env.COPILOT_CLI_VERSION?process.env.COPILOT_CLI_VERSION:"1.0.81-11"}async function Ke(e,t){let n=V(e,"app.js"),r=!process.env.COPILOT_CLI_VERSION&&Be(en()),o=$e();if(o||t&&Me()&&!r){let i=Ge(),s=await We("app.js",...i);if(o){let c=s.find(b=>Zt(b)===o);c?n=V(c,"app.js"):process.stderr.write(`Warning: preferred version ${o} not found in package cache, using built-in version
`)}else s.length>0&&(n=V(s[0],"app.js"))}return n}import Qe from"node:path";import{fileURLToPath as tn}from"node:url";var _,ze=Qe.dirname(tn(import.meta.url));function Ye(){if(_){if(_.kind==="ok")return _.addon;throw _.error}try{let e=L("cli-native",[ze,Qe.resolve(ze,"..","native","cli")]);return _={kind:"ok",addon:e},e}catch(e){let t=e instanceof Error?e:new Error(`Failed to load cli-native addon: ${O(e)}`);throw _={kind:"error",error:t},t}}function A(){if(process.platform==="win32")return Ye()}var Xe=Symbol.for("github.copilot.cli.cleanExit");function nn(){let e=Reflect.get(process,"exit");if(typeof e!="function")return;let t=Reflect.get(e,Xe);return typeof t=="function"?t:void 0}function rn(){let e;if(process.platform==="win32")try{e=A()}catch{e=void 0}let t=!1;return()=>{if(!t){t=!0;try{process.report.reportOnFatalError=!1}catch{}if(e){try{e.uninstallExceptionFilter()}catch{}try{e.disableCrashReporting()}catch{}}}}}function Ze(){let e=nn();if(e)return e;let t=process.exit.bind(process),n=rn(),r=(...s)=>(n(),t(...s));process.once("exit",n);let o=!0,i=()=>{o&&(o=!1,process.exit===r&&(process.exit=t),process.removeListener("exit",n))};return Reflect.defineProperty(r,Xe,{value:i}),process.exit=r,i}import{existsSync as on}from"node:fs";import{basename as sn,resolve as an}from"node:path";var et="extension_bootstrap.mjs";function tt(e,t,n=on){let r=e.find(s=>sn(s)===et);if(!r)return;process.stderr.write(`[extension-fork] resolveBootstrapPath: __dir=${t}, argv-bootstrap=${r}
`);let o=an(t,"preloads",et),i=n(o);if(process.stderr.write(`[extension-fork] resolveBootstrapPath: localBootstrap=${o}, localExists=${i}
`),i)return o}var cn=new Set(["--server","--headless","--acp"]),un=new Set(["app","completion","help","init","login","mcp","plugin","update","version"]);function ln(e){return e==="--prompt"||e.startsWith("--prompt=")||e==="-p"||e.startsWith("-p")&&e.length>2}function fn(e){if(e.some(n=>cn.has(n)||ln(n)))return!0;let t=e.find(n=>!n.startsWith("-"));return t!==void 0&&un.has(t)}function nt(e){return!fn(e)}var dn="github.copilot.cli.typeahead.capture",rt=Symbol.for(dn);function M(){let e=globalThis,t=e[rt];return t||(t={buffer:[],capturing:!1,listener:null,exitHandler:null},e[rt]=t),t}var $=class{detachListener(t){t.listener&&(process.stdin.removeListener("data",t.listener),t.listener=null)}clearExitHandler(t){t.exitHandler&&(process.removeListener("exit",t.exitHandler),t.exitHandler=null)}start(){let t=M();if(!process.stdin.isTTY||typeof process.stdin.setRawMode!="function"||t.capturing)return;try{process.stdin.setRawMode(!0)}catch{return}if(!t.exitHandler){let r=()=>{if(t.capturing)try{process.stdin.setRawMode(!1)}catch{}};t.exitHandler=r,process.once("exit",r)}let n=r=>{if(r.length===1&&r[0]===3){this.dispose(),process.kill(process.pid,"SIGINT");return}t.buffer.push(Buffer.from(r))};t.listener=n,process.stdin.on("data",n),process.stdin.unref(),t.capturing=!0}drain(){let t=M();if(this.detachListener(t),this.clearExitHandler(t),t.capturing=!1,t.buffer.length===0)return null;let n=Buffer.concat(t.buffer);return t.buffer=[],n}dispose(){let t=M();if(this.detachListener(t),this.clearExitHandler(t),t.buffer=[],!!t.capturing){try{process.stdin.setRawMode(!1)}catch{}process.stdin.pause(),t.capturing=!1}}},ot=new $;try{pn.enableCompileCache?.()}catch{}var W=mn(hn(import.meta.url)),bn=st.isSea();process.report.reportOnFatalError=!0;process.report.excludeEnv=!0;if(process.platform==="win32"){try{let e=A();if(!e)throw new Error("loadWin32NativeAddon returned undefined on win32");e.enableCrashReporting(),e.installExceptionFilter()}catch{}Ze()}var it=tt(process.argv,W);if(it)await import(j(it).href);else if(process.env.COPILOT_VOICE_SERVER_MODE==="1"){let e=gn(W,"voice-server.js");try{let{runVoiceServer:t}=await import(j(e).href);await t()}catch(t){process.stderr.write(`voice server: fatal at ${e}: ${t.stack??String(t)}
`),process.exit(1)}}else if(process.env.COPILOT_SHUTDOWN_FLUSH){try{let{url:e,headers:t,body:n}=JSON.parse(process.env.COPILOT_SHUTDOWN_FLUSH),r=await fetch(e,{method:"POST",headers:t,body:n,signal:AbortSignal.timeout(3e4)});if(!r.ok)throw new Error(`Mission Control returned HTTP ${r.status}`)}catch(e){process.stderr.write(`shutdown flush: ${O(e)}
`)}process.exit(0)}else{nt(process.argv.slice(2))&&ot.start();let e=await Ke(W,bn);await import(j(e).href)}
${s}`)}function Ut(e){if(e instanceof Error)return e.message;if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return Object.prototype.toString.call(e)}}function xe(e){try{return{ok:!0,value:qt(e)}}catch(t){return{ok:!1,err:t}}}function qt(e){return It(Ft(import.meta.url))(e)}function Te(e){if(!(e instanceof Error))return e;let t=C.sharedApiSqliteNativeErrorPayload(e.message);if(!t)return e;let n=new Error(t.message);return n.code="ERR_SQLITE_ERROR",n.errcode=t.errcode,n.errstr=t.errstr,n}var Ne="__copilotRuntimeAddon__";function De(){let e=globalThis,t=e[Ne];return t||(t={addon:null,processStateInitialized:!1},e[Ne]=t),t}function Vt(){let e=De();if(e.addon)return e.addon;Q.debug("[nativeRuntime] in-process mode: loading the native runtime .node addon");let t=R.dirname(Ae(import.meta.url)),n=L("runtime",[t,R.resolve(t,".."),R.resolve(t,"..","..","native","runtime")]);return e.addon=n,n}var k;function Mt(e){let t=R.dirname(Ae(e));return e.endsWith(".ts")?R.resolve(t,"..","..","..","dist-cli"):t}function $t(e,t,n,r=import.meta.url){e.toolsInitializeBundledBinaryRoot?.(Mt(r)),e.authInitializeProcessUserAgent?.(n);let o=t.COPILOT_DEBUG_ENTRA_BROKER_URL?.trim()||void 0;delete t.COPILOT_DEBUG_ENTRA_BROKER_URL,e.authInitializeDebugEntraBrokerUrl?.(o)}function w(){k||(k=Vt());let e=De();return e.processStateInitialized||(e.processStateInitialized=!0,$t(k,process.env,process.version)),k}var Le="\0__copilot_git_structured_error__\0",Ce="__copilot_session_fs_error:";function jt(e){if(!(e instanceof Error)||!e.message.startsWith(Le))return e;let t;try{t=JSON.parse(e.message.slice(Le.length))}catch{return e}let n=new Error(typeof t.message=="string"?t.message:"");typeof t.name=="string"&&(n.name=t.name);for(let[r,o]of Object.entries(t))r!=="message"&&r!=="name"&&(n[r]=o);return n}function Fe(e){if(!(e instanceof Error)||!e.message.startsWith(Ce))return e;let t;try{t=JSON.parse(e.message.slice(Ce.length))}catch{return e}let n=typeof t.code=="string"?t.code:"UNKNOWN",r=typeof t.path=="string"?t.path:"sqliteQuery",o=typeof t.message=="string"&&t.message?`: ${t.message}`:"",i=new Error(`${n}: ${r}${o}`);return i.code=n,i.path=r,i}function h(e){let t=Te(e);return t!==e?t:Fe(e)}function ke(e){return e??void 0}function Wt(e){class t{inner;constructor(...r){this.inner=new e(...r)}async execute(r,o,i){try{return ke(await this.inner.execute(r,o,i))}catch(s){throw h(s)}}async batch(r){try{return(await this.inner.batch(r)).map(ke)}catch(o){throw h(o)}}async transaction(r){try{return await this.inner.transaction(r)}catch(o){throw h(o)}}async getTableNames(){try{return await this.inner.getTableNames()}catch(r){throw h(r)}}async getTableNamesIfExists(){try{return await this.inner.getTableNamesIfExists()}catch(r){throw h(r)}}async getTodoStatus(){try{return await this.inner.getTodoStatus()}catch(r){throw h(r)}}async getCurrentIntent(){try{return await this.inner.getCurrentIntent()}catch(r){throw h(r)}}async closeAll(){try{await this.inner.closeAll()}catch(r){throw h(r)}}}return Object.defineProperty(t,"name",{value:"SessionDatabaseHandle"}),t}function Ie(e){return JSON.stringify(e,(t,n)=>typeof n=="number"&&!Number.isFinite(n)?{__copilot_forge_number:String(n)}:n)??"null"}var Jt=new Set(["runnerCreateNoopLogger","runnerCreateNoopExec"]),Oe=new WeakMap;function Gt(e,t,n){let r=Oe.get(e);return r||(r=new Map,Oe.set(e,r)),r.has(t)||r.set(t,n()),r.get(t)}function zt(e,t){let n=Reflect.get(e,t);if(typeof n=="function"&&t==="SessionDatabaseHandle")return Wt(n);if(typeof n=="function"&&typeof t=="string"&&Jt.has(t)){let r=n;return()=>Gt(e,t,()=>r.call(e))}if(typeof n=="function"&&t==="sessionStoreTrackingPostToolUsePlan"){let r=n;return(o,i,s)=>r.call(e,Ie(o),Ie(i),s)}if(typeof n=="function"&&typeof t=="string"&&/^git[A-Z]/.test(t)){let r=n;return(...o)=>{let i=r.apply(e,o);return i instanceof Promise?i.catch(s=>{throw jt(s)}):i}}if(typeof n=="function"&&typeof t=="string"&&/^sessionFs[A-Z]/.test(t)){let r=n;return(...o)=>{let i=r.apply(e,o);return i instanceof Promise?i.catch(s=>{throw Fe(s)}):i}}return n}var C=new Proxy({},{get:(e,t)=>zt(w(),t),has:(e,t)=>Reflect.has(w(),t),set:(e,t,n)=>Reflect.set(w(),t,n),ownKeys:()=>Reflect.ownKeys(w()),getOwnPropertyDescriptor:(e,t)=>Reflect.getOwnPropertyDescriptor(w(),t),defineProperty:(e,t,n)=>Reflect.defineProperty(w(),t,n)});function I(e){return C.errorFormattingFormatUnknown(e)}import{basename as tn,join as V}from"node:path";var He="0.0.1";function Be(e){return e===He||e.startsWith(`${He}-`)}import{readdir as Kt,access as Qt,constants as Yt}from"node:fs/promises";import{join as c,basename as Ue}from"node:path";import{homedir as O}from"node:os";function Me(){return process.env.XDG_CACHE_HOME||c(O(),".cache")}function $e(){if(process.argv.includes("--no-auto-update")||process.argv.includes("--prefer-version"))return!1;let e=process.env.COPILOT_AUTO_UPDATE;return!(e&&e.toLowerCase()==="false")}function je(){let e=process.argv.indexOf("--prefer-version");if(!(e===-1||e+1>=process.argv.length))return process.argv[e+1]}function Zt(){if(process.platform==="darwin")return c(O(),"Library","Caches","copilot");if(process.platform==="win32"){let e=process.env.LOCALAPPDATA||c(O(),".cache");return c(e,"copilot")}return c(Me(),"copilot")}function We(){let e=[];return process.env.COPILOT_PKG_CACHE_HOME&&e.push(c(process.env.COPILOT_PKG_CACHE_HOME,"pkg")),process.env.COPILOT_CACHE_HOME&&e.push(c(process.env.COPILOT_CACHE_HOME,"pkg")),e.push(c(Zt(),"pkg")),e.push(c(Me(),"copilot","pkg")),process.env.COPILOT_HOME&&e.push(c(process.env.COPILOT_HOME,"pkg")),e.push(c(O(),".copilot","pkg")),[...new Set(e)]}function qe(e){let t=e.match(/^(\d+)\.(\d+)\.(\d+)/);if(t)return[Number(t[1]),Number(t[2]),Number(t[3])]}function Ve(e){let t=e.match(/^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-([^+]+))?(?:\+([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?$/);if(!t)return;let n=t[4];if(n===void 0)return[];let r=n.split(".");for(let o of r)if(!/^[0-9A-Za-z-]+$/.test(o)||/^\d+$/.test(o)&&o.length>1&&o.startsWith("0"))return;return r}function Xt(e,t){for(let n=0;n<Math.min(e.length,t.length);n++){let r=e[n],o=t[n];if(r===o)continue;let i=/^\d+$/.test(r),s=/^\d+$/.test(o);return i!==s?i?-1:1:i&&r.length!==o.length?r.length-o.length:r<o?-1:1}return e.length-t.length}function en(e,t){let n=qe(e),r=qe(t);if(!n&&!r)return 0;if(!n)return-1;if(!r)return 1;for(let u=0;u<3;u++)if(n[u]!==r[u])return n[u]-r[u];let o=Ve(e),i=Ve(t);if(o!==void 0&&i!==void 0)return o.length===0||i.length===0?o.length!==i.length?o.length===0?1:-1:0:Xt(o,i);let s=e.includes("-"),a=t.includes("-");return s!==a?s?-1:1:e.localeCompare(t)}async function Je(e,...t){let n=[];for(let r of t){let o;try{o=await Kt(r)}catch{continue}for(let i of o){let s=c(r,i);try{await Qt(c(s,e),Yt.R_OK),n.push(s)}catch{continue}}}return n.sort((r,o)=>{let i=en(Ue(o),Ue(r));return i!==0?i:r.localeCompare(o)}),n}import{join as Ge}from"node:path";function ze(){let e=Se();return We().flatMap(t=>[Ge(t,"universal"),Ge(t,e)])}function nn(){return process.env.COPILOT_CLI_VERSION?process.env.COPILOT_CLI_VERSION:"1.0.81-12"}async function Ke(e,t){let n=V(e,"app.js"),r=!process.env.COPILOT_CLI_VERSION&&Be(nn()),o=je();if(o||t&&$e()&&!r){let i=ze(),s=await Je("app.js",...i);if(o){let a=s.find(u=>tn(u)===o);a?n=V(a,"app.js"):process.stderr.write(`Warning: preferred version ${o} not found in package cache, using built-in version
`)}else s.length>0&&(n=V(s[0],"app.js"))}return n}import Ye from"node:path";import{fileURLToPath as rn}from"node:url";var _,Qe=Ye.dirname(rn(import.meta.url));function Ze(){if(_){if(_.kind==="ok")return _.addon;throw _.error}try{let e=L("cli-native",[Qe,Ye.resolve(Qe,"..","native","cli")]);return _={kind:"ok",addon:e},e}catch(e){let t=e instanceof Error?e:new Error(`Failed to load cli-native addon: ${I(e)}`);throw _={kind:"error",error:t},t}}function A(){if(process.platform==="win32")return Ze()}var Xe=Symbol.for("github.copilot.cli.cleanExit");function on(){let e=Reflect.get(process,"exit");if(typeof e!="function")return;let t=Reflect.get(e,Xe);return typeof t=="function"?t:void 0}function sn(){let e;if(process.platform==="win32")try{e=A()}catch{e=void 0}let t=!1;return()=>{if(!t){t=!0;try{process.report.reportOnFatalError=!1}catch{}if(e){try{e.uninstallExceptionFilter()}catch{}try{e.disableCrashReporting()}catch{}}}}}function et(){let e=on();if(e)return e;let t=process.exit.bind(process),n=sn(),r=(...s)=>(n(),t(...s));process.once("exit",n);let o=!0,i=()=>{o&&(o=!1,process.exit===r&&(process.exit=t),process.removeListener("exit",n))};return Reflect.defineProperty(r,Xe,{value:i}),process.exit=r,i}import{existsSync as an}from"node:fs";import{basename as un,resolve as cn}from"node:path";var tt="extension_bootstrap.mjs";function nt(e,t,n=an){let r=e.find(s=>un(s)===tt);if(!r)return;process.stderr.write(`[extension-fork] resolveBootstrapPath: __dir=${t}, argv-bootstrap=${r}
`);let o=cn(t,"preloads",tt),i=n(o);if(process.stderr.write(`[extension-fork] resolveBootstrapPath: localBootstrap=${o}, localExists=${i}
`),i)return o}var ln=new Set(["--server","--headless","--acp"]),fn=new Set(["app","completion","help","init","login","mcp","plugin","update","version"]);function dn(e){return e==="--prompt"||e.startsWith("--prompt=")||e==="-p"||e.startsWith("-p")&&e.length>2}function pn(e){if(e.some(n=>ln.has(n)||dn(n)))return!0;let t=e.find(n=>!n.startsWith("-"));return t!==void 0&&fn.has(t)}function rt(e){return!pn(e)}var gn="github.copilot.cli.typeahead.capture",ot=Symbol.for(gn);function M(){let e=globalThis,t=e[ot];return t||(t={buffer:[],capturing:!1,listener:null,exitHandler:null},e[ot]=t),t}var $=class{detachListener(t){t.listener&&(process.stdin.removeListener("data",t.listener),t.listener=null)}clearExitHandler(t){t.exitHandler&&(process.removeListener("exit",t.exitHandler),t.exitHandler=null)}start(){let t=M();if(!process.stdin.isTTY||typeof process.stdin.setRawMode!="function"||t.capturing)return;try{process.stdin.setRawMode(!0)}catch{return}if(!t.exitHandler){let r=()=>{if(t.capturing)try{process.stdin.setRawMode(!1)}catch{}};t.exitHandler=r,process.once("exit",r)}let n=r=>{if(r.length===1&&r[0]===3){this.dispose(),process.kill(process.pid,"SIGINT");return}t.buffer.push(Buffer.from(r))};t.listener=n,process.stdin.on("data",n),process.stdin.unref(),t.capturing=!0}drain(){let t=M();if(this.detachListener(t),this.clearExitHandler(t),t.capturing=!1,t.buffer.length===0)return null;let n=Buffer.concat(t.buffer);return t.buffer=[],n}dispose(){let t=M();if(this.detachListener(t),this.clearExitHandler(t),t.buffer=[],!!t.capturing){try{process.stdin.setRawMode(!1)}catch{}process.stdin.pause(),t.capturing=!1}}},it=new $;try{mn.enableCompileCache?.()}catch{}var W=hn(yn(import.meta.url)),vn=at.isSea();process.report.reportOnFatalError=!0;process.report.excludeEnv=!0;if(process.platform==="win32"){try{let e=A();if(!e)throw new Error("loadWin32NativeAddon returned undefined on win32");e.enableCrashReporting(),e.installExceptionFilter()}catch{}et()}var st=nt(process.argv,W);if(st)await import(j(st).href);else if(process.env.COPILOT_VOICE_SERVER_MODE==="1"){let e=bn(W,"voice-server.js");try{let{runVoiceServer:t}=await import(j(e).href);await t()}catch(t){process.stderr.write(`voice server: fatal at ${e}: ${t.stack??String(t)}
`),process.exit(1)}}else if(process.env.COPILOT_SHUTDOWN_FLUSH){try{let{url:e,headers:t,body:n}=JSON.parse(process.env.COPILOT_SHUTDOWN_FLUSH),r=await fetch(e,{method:"POST",headers:t,body:n,signal:AbortSignal.timeout(3e4)});if(!r.ok)throw new Error(`Mission Control returned HTTP ${r.status}`)}catch(e){process.stderr.write(`shutdown flush: ${I(e)}
`)}process.exit(0)}else{rt(process.argv.slice(2))&&it.start();let e=await Ke(W,vn);await import(j(e).href)}
{
"name": "@github/copilot-linux-arm64",
"version": "1.0.81-11",
"version": "1.0.81-12",
"description": "GitHub Copilot CLI for linux-arm64",

@@ -5,0 +5,0 @@ "license": "SEE LICENSE IN LICENSE.md",

@@ -1,2 +0,2 @@

(()=>{const stack=new Error().stack;stack&&(globalThis._sentryDebugIds=globalThis._sentryDebugIds||{},globalThis._sentryDebugIds[stack]="7b1d2690-81dc-5cfd-881d-2400d980f916",globalThis._sentryDebugIdIdentifier="sentry-dbid-7b1d2690-81dc-5cfd-881d-2400d980f916");})();
(()=>{const stack=new Error().stack;stack&&(globalThis._sentryDebugIds=globalThis._sentryDebugIds||{},globalThis._sentryDebugIds[stack]="0059522b-e2f5-51b0-956a-69e077dbc97e",globalThis._sentryDebugIdIdentifier="sentry-dbid-0059522b-e2f5-51b0-956a-69e077dbc97e");})();

@@ -53,6 +53,6 @@ /*---------------------------------------------------------------------------------------------

const __esmShimDirname = __path.dirname(__esmShimFilename);
var Ye=Object.create;var X=Object.defineProperty;var Ze=Object.getOwnPropertyDescriptor;var et=Object.getOwnPropertyNames;var tt=Object.getPrototypeOf,rt=Object.prototype.hasOwnProperty;var Y=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var x=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(r){throw t=0,r}};var nt=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of et(t))!rt.call(e,o)&&o!==r&&X(e,o,{get:()=>t[o],enumerable:!(n=Ze(t,o))||n.enumerable});return e};var ot=(e,t,r)=>(r=e!=null?Ye(tt(e)):{},nt(t||!e||!e.__esModule?X(r,"default",{value:e,enumerable:!0}):r,e));var re=x((lr,te)=>{"use strict";var ee=()=>process.platform==="linux",P=null,it=()=>{if(!P)if(ee()&&process.report){let e=process.report.excludeNetwork;process.report.excludeNetwork=!0,P=process.report.getReport(),process.report.excludeNetwork=e}else P={};return P};te.exports={isLinux:ee,getReport:it}});var oe=x((fr,ne)=>{"use strict";var v=Y("fs"),at="/usr/bin/ldd",ct="/proc/self/exe",L=2048,ut=e=>{let t=v.openSync(e,"r"),r=Buffer.alloc(L),n=v.readSync(t,r,0,L,0);return v.close(t,()=>{}),r.subarray(0,n)},lt=e=>new Promise((t,r)=>{v.open(e,"r",(n,o)=>{if(n)r(n);else{let s=Buffer.alloc(L);v.read(o,s,0,L,0,(i,c)=>{t(s.subarray(0,c)),v.close(o,()=>{})})}})});ne.exports={LDD_PATH:at,SELF_PATH:ct,readFileSync:ut,readFile:lt}});var ie=x((dr,se)=>{"use strict";var ft=e=>{if(e.length<64||e.readUInt32BE(0)!==2135247942||e.readUInt8(4)!==2||e.readUInt8(5)!==1)return null;let t=e.readUInt32LE(32),r=e.readUInt16LE(54),n=e.readUInt16LE(56);for(let o=0;o<n;o++){let s=t+o*r;if(e.readUInt32LE(s)===3){let c=e.readUInt32LE(s+8),w=e.readUInt32LE(s+32);return e.subarray(c,c+w).toString().replace(/\0.*$/g,"")}}return null};se.exports={interpreterPath:ft}});var xe=x((pr,ke)=>{"use strict";var ce=Y("child_process"),{isLinux:S,getReport:ue}=re(),{LDD_PATH:N,SELF_PATH:le,readFile:U,readFileSync:M}=oe(),{interpreterPath:fe}=ie(),f,d,p,de="getconf GNU_LIBC_VERSION 2>&1 || true; ldd --version 2>&1 || true",y="",pe=()=>y||new Promise(e=>{ce.exec(de,(t,r)=>{y=t?" ":r,e(y)})}),ge=()=>{if(!y)try{y=ce.execSync(de,{encoding:"utf8"})}catch{y=" "}return y},g="glibc",me=/LIBC[a-z0-9 \-).]*?(\d+\.\d+)/i,b="musl",dt=e=>e.includes("libc.musl-")||e.includes("ld-musl-"),ye=()=>{let e=ue();return e.header&&e.header.glibcVersionRuntime?g:Array.isArray(e.sharedObjects)&&e.sharedObjects.some(dt)?b:null},he=e=>{let[t,r]=e.split(/[\r\n]+/);return t&&t.includes(g)?g:r&&r.includes(b)?b:null},we=e=>{if(e){if(e.includes("/ld-musl-"))return b;if(e.includes("/ld-linux-"))return g}return null},be=e=>(e=e.toString(),e.includes("musl")?b:e.includes("GNU C Library")?g:null),pt=async()=>{if(d!==void 0)return d;d=null;try{let e=await U(N);d=be(e)}catch{}return d},gt=()=>{if(d!==void 0)return d;d=null;try{let e=M(N);d=be(e)}catch{}return d},mt=async()=>{if(f!==void 0)return f;f=null;try{let e=await U(le),t=fe(e);f=we(t)}catch{}return f},yt=()=>{if(f!==void 0)return f;f=null;try{let e=M(le),t=fe(e);f=we(t)}catch{}return f},ve=async()=>{let e=null;if(S()&&(e=await mt(),!e&&(e=await pt(),e||(e=ye()),!e))){let t=await pe();e=he(t)}return e},Se=()=>{let e=null;if(S()&&(e=yt(),!e&&(e=gt(),e||(e=ye()),!e))){let t=ge();e=he(t)}return e},ht=async()=>S()&&await ve()!==g,wt=()=>S()&&Se()!==g,bt=async()=>{if(p!==void 0)return p;p=null;try{let t=(await U(N)).match(me);t&&(p=t[1])}catch{}return p},vt=()=>{if(p!==void 0)return p;p=null;try{let t=M(N).match(me);t&&(p=t[1])}catch{}return p},Re=()=>{let e=ue();return e.header&&e.header.glibcVersionRuntime?e.header.glibcVersionRuntime:null},ae=e=>e.trim().split(/\s+/)[1],Ee=e=>{let[t,r,n]=e.split(/[\r\n]+/);return t&&t.includes(g)?ae(t):r&&n&&r.includes(b)?ae(n):null},St=async()=>{let e=null;if(S()&&(e=await bt(),e||(e=Re()),!e)){let t=await pe();e=Ee(t)}return e},Rt=()=>{let e=null;if(S()&&(e=vt(),e||(e=Re()),!e)){let t=ge();e=Ee(t)}return e};ke.exports={GLIBC:g,MUSL:b,family:ve,familySync:Se,isNonGlibcLinux:ht,isNonGlibcLinuxSync:wt,version:St,versionSync:Rt}});import{parentPort as Xe,workerData as Zt}from"node:worker_threads";var _=class{initialQueue=[];initialQueueResolvers=Promise.withResolvers();logWriter=null;cachedOutputPath;writePromise=this.initialQueueResolvers.promise;setLogWriter(t){this.logWriter=t,this.cachedOutputPath=void 0;for(let r of this.initialQueue)this.writeTo(t,r.method,r.message);this.initialQueue=[],this.initialQueueResolvers.resolve()}async flush(){if(!this.logWriter)return;let t=this.logWriter,r=(async()=>{try{await this.writePromise,await t.flush?.()}catch{}})(),n,o=new Promise(s=>{n=setTimeout(s,5e3),n.unref?.()});try{await Promise.race([r,o])}finally{n&&clearTimeout(n)}}async dispose(){await this.flush()}outputPath(){return this.cachedOutputPath??=this.logWriter?.outputPath()}logToLevel(t,r){this.logWriter?this.writeTo(this.logWriter,t,r):this.initialQueue.push({method:t,message:r})}writeTo(t,r,n){if(t.write&&t.flush){t.write(r,n),this.writePromise=t.flush().catch(()=>{});return}this.writePromise=t.writeLog(r,n).catch(()=>{})}info(t){this.logToLevel("info",t)}debug(t){this.logToLevel("debug",t)}warning(t){this.logToLevel("warning",t)}error(t){this.logToLevel("error",t instanceof Error?t.message:t)}log(t){this.error(t)}isDebug(){return!1}shouldLog(t){return!0}notice(t){this.info(t instanceof Error?t.message:t)}startGroup(t,r){this.info(`--- Start of group: ${t} ---`)}endGroup(t){this.info("--- End of group ---")}},m=new _;import{createRequire as Ut}from"node:module";import*as a from"node:fs/promises";import*as l from"node:path";import{createHash as Mt}from"node:crypto";import{join as E,basename as ar}from"node:path";import{homedir as q}from"node:os";function st(){return process.env.XDG_CACHE_HOME||E(q(),".cache")}function Z(){if(process.platform==="darwin")return E(q(),"Library","Caches","copilot");if(process.platform==="win32"){let e=process.env.LOCALAPPDATA||E(q(),".cache");return E(e,"copilot")}return E(st(),"copilot")}import k from"node:path";import{fileURLToPath as $e}from"node:url";import{createRequire as Et}from"node:module";import{platform as kt,type as xt}from"node:os";import{join as Pe,resolve as _t}from"node:path";import{fileURLToPath as Pt}from"node:url";var I=ot(xe(),1);function T(e={}){return(e.platform??process.platform)!=="linux"?"gnu":e.detectLibcFamily?e.detectLibcFamily()==="musl"?"musl":"gnu":(0,I.familySync)()===I.MUSL?"musl":"gnu"}function _e(e=process.platform,t){let r=t??(e==="linux"?T():"gnu");return e==="linux"&&r==="musl"?"linuxmusl":e}function Lt(){let e=Ne(),t=e==="linux"?T({platform:e}):"gnu";return`${_e(e,t)}-${process.arch}`}function Nt(){let e=Ne(),{arch:t}=process;switch(e){case"win32":return`win32-${t}-msvc`;case"darwin":return`darwin-${t}`;case"linux":return`linux-${t}-${T({platform:e})}`;default:throw new Error(`Unsupported platform: ${e}/${t}`)}}var u;function Ne(){if(u!==void 0)return u;switch(xt()){case"Windows_NT":u="win32";break;case"Darwin":u="darwin";break;case"Linux":u="linux";break;case"AIX":u="aix";break;case"FreeBSD":case"DragonFly":u="freebsd";break;case"OpenBSD":u="openbsd";break;case"NetBSD":u="netbsd";break;case"SunOS":u="sunos";break;default:u=kt();break}return u}function Ie(e,t){let r=Lt(),n=`${e}.node`,o=`${e}.${Nt()}.node`,s=[];for(let c of t){let w=_t(c),K=Pe(w,"prebuilds",r,n),H=Le(K);if(H.ok)return H.value;s.push({path:K,err:H.err});let Q=Pe(w,o),$=Le(Q);if($.ok)return $.value;s.push({path:Q,err:$.err})}let i=s.map(c=>` ${c.path}: ${It(c.err)}`).join(`
var Ye=Object.create;var X=Object.defineProperty;var Ze=Object.getOwnPropertyDescriptor;var et=Object.getOwnPropertyNames;var tt=Object.getPrototypeOf,rt=Object.prototype.hasOwnProperty;var Y=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var x=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(r){throw t=0,r}};var nt=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of et(t))!rt.call(e,o)&&o!==r&&X(e,o,{get:()=>t[o],enumerable:!(n=Ze(t,o))||n.enumerable});return e};var ot=(e,t,r)=>(r=e!=null?Ye(tt(e)):{},nt(t||!e||!e.__esModule?X(r,"default",{value:e,enumerable:!0}):r,e));var re=x((lr,te)=>{"use strict";var ee=()=>process.platform==="linux",P=null,st=()=>{if(!P)if(ee()&&process.report){let e=process.report.excludeNetwork;process.report.excludeNetwork=!0,P=process.report.getReport(),process.report.excludeNetwork=e}else P={};return P};te.exports={isLinux:ee,getReport:st}});var oe=x((fr,ne)=>{"use strict";var v=Y("fs"),at="/usr/bin/ldd",ct="/proc/self/exe",L=2048,ut=e=>{let t=v.openSync(e,"r"),r=Buffer.alloc(L),n=v.readSync(t,r,0,L,0);return v.close(t,()=>{}),r.subarray(0,n)},lt=e=>new Promise((t,r)=>{v.open(e,"r",(n,o)=>{if(n)r(n);else{let i=Buffer.alloc(L);v.read(o,i,0,L,0,(s,c)=>{t(i.subarray(0,c)),v.close(o,()=>{})})}})});ne.exports={LDD_PATH:at,SELF_PATH:ct,readFileSync:ut,readFile:lt}});var se=x((dr,ie)=>{"use strict";var ft=e=>{if(e.length<64||e.readUInt32BE(0)!==2135247942||e.readUInt8(4)!==2||e.readUInt8(5)!==1)return null;let t=e.readUInt32LE(32),r=e.readUInt16LE(54),n=e.readUInt16LE(56);for(let o=0;o<n;o++){let i=t+o*r;if(e.readUInt32LE(i)===3){let c=e.readUInt32LE(i+8),w=e.readUInt32LE(i+32);return e.subarray(c,c+w).toString().replace(/\0.*$/g,"")}}return null};ie.exports={interpreterPath:ft}});var xe=x((gr,ke)=>{"use strict";var ce=Y("child_process"),{isLinux:S,getReport:ue}=re(),{LDD_PATH:N,SELF_PATH:le,readFile:U,readFileSync:M}=oe(),{interpreterPath:fe}=se(),f,d,g,de="getconf GNU_LIBC_VERSION 2>&1 || true; ldd --version 2>&1 || true",y="",ge=()=>y||new Promise(e=>{ce.exec(de,(t,r)=>{y=t?" ":r,e(y)})}),pe=()=>{if(!y)try{y=ce.execSync(de,{encoding:"utf8"})}catch{y=" "}return y},p="glibc",me=/LIBC[a-z0-9 \-).]*?(\d+\.\d+)/i,b="musl",dt=e=>e.includes("libc.musl-")||e.includes("ld-musl-"),ye=()=>{let e=ue();return e.header&&e.header.glibcVersionRuntime?p:Array.isArray(e.sharedObjects)&&e.sharedObjects.some(dt)?b:null},he=e=>{let[t,r]=e.split(/[\r\n]+/);return t&&t.includes(p)?p:r&&r.includes(b)?b:null},we=e=>{if(e){if(e.includes("/ld-musl-"))return b;if(e.includes("/ld-linux-"))return p}return null},be=e=>(e=e.toString(),e.includes("musl")?b:e.includes("GNU C Library")?p:null),gt=async()=>{if(d!==void 0)return d;d=null;try{let e=await U(N);d=be(e)}catch{}return d},pt=()=>{if(d!==void 0)return d;d=null;try{let e=M(N);d=be(e)}catch{}return d},mt=async()=>{if(f!==void 0)return f;f=null;try{let e=await U(le),t=fe(e);f=we(t)}catch{}return f},yt=()=>{if(f!==void 0)return f;f=null;try{let e=M(le),t=fe(e);f=we(t)}catch{}return f},ve=async()=>{let e=null;if(S()&&(e=await mt(),!e&&(e=await gt(),e||(e=ye()),!e))){let t=await ge();e=he(t)}return e},Se=()=>{let e=null;if(S()&&(e=yt(),!e&&(e=pt(),e||(e=ye()),!e))){let t=pe();e=he(t)}return e},ht=async()=>S()&&await ve()!==p,wt=()=>S()&&Se()!==p,bt=async()=>{if(g!==void 0)return g;g=null;try{let t=(await U(N)).match(me);t&&(g=t[1])}catch{}return g},vt=()=>{if(g!==void 0)return g;g=null;try{let t=M(N).match(me);t&&(g=t[1])}catch{}return g},Re=()=>{let e=ue();return e.header&&e.header.glibcVersionRuntime?e.header.glibcVersionRuntime:null},ae=e=>e.trim().split(/\s+/)[1],Ee=e=>{let[t,r,n]=e.split(/[\r\n]+/);return t&&t.includes(p)?ae(t):r&&n&&r.includes(b)?ae(n):null},St=async()=>{let e=null;if(S()&&(e=await bt(),e||(e=Re()),!e)){let t=await ge();e=Ee(t)}return e},Rt=()=>{let e=null;if(S()&&(e=vt(),e||(e=Re()),!e)){let t=pe();e=Ee(t)}return e};ke.exports={GLIBC:p,MUSL:b,family:ve,familySync:Se,isNonGlibcLinux:ht,isNonGlibcLinuxSync:wt,version:St,versionSync:Rt}});import{parentPort as Xe,workerData as Zt}from"node:worker_threads";var _=class{initialQueue=[];initialQueueResolvers=Promise.withResolvers();logWriter=null;cachedOutputPath;writePromise=this.initialQueueResolvers.promise;setLogWriter(t){this.logWriter=t,this.cachedOutputPath=void 0;for(let r of this.initialQueue)this.writeTo(t,r.method,r.message);this.initialQueue=[],this.initialQueueResolvers.resolve()}async flush(){if(!this.logWriter)return;let t=this.logWriter,r=(async()=>{try{await this.writePromise,await t.flush?.()}catch{}})(),n,o=new Promise(i=>{n=setTimeout(i,5e3),n.unref?.()});try{await Promise.race([r,o])}finally{n&&clearTimeout(n)}}async dispose(){await this.flush()}outputPath(){return this.cachedOutputPath??=this.logWriter?.outputPath()}logToLevel(t,r){this.logWriter?this.writeTo(this.logWriter,t,r):this.initialQueue.push({method:t,message:r})}writeTo(t,r,n){if(t.write&&t.flush){t.write(r,n),this.writePromise=t.flush().catch(()=>{});return}this.writePromise=t.writeLog(r,n).catch(()=>{})}info(t){this.logToLevel("info",t)}debug(t){this.logToLevel("debug",t)}warning(t){this.logToLevel("warning",t)}error(t){this.logToLevel("error",t instanceof Error?t.message:t)}log(t){this.error(t)}isDebug(){return!1}shouldLog(t){return!0}notice(t){this.info(t instanceof Error?t.message:t)}startGroup(t,r){this.info(`--- Start of group: ${t} ---`)}endGroup(t){this.info("--- End of group ---")}},m=new _;import{createRequire as Ut}from"node:module";import*as a from"node:fs/promises";import*as l from"node:path";import{createHash as Mt}from"node:crypto";import{join as E,basename as ar}from"node:path";import{homedir as q}from"node:os";function it(){return process.env.XDG_CACHE_HOME||E(q(),".cache")}function Z(){if(process.platform==="darwin")return E(q(),"Library","Caches","copilot");if(process.platform==="win32"){let e=process.env.LOCALAPPDATA||E(q(),".cache");return E(e,"copilot")}return E(it(),"copilot")}import k from"node:path";import{fileURLToPath as $e}from"node:url";import{createRequire as Et}from"node:module";import{platform as kt,type as xt}from"node:os";import{join as Pe,resolve as _t}from"node:path";import{fileURLToPath as Pt}from"node:url";var I=ot(xe(),1);function T(e={}){return(e.platform??process.platform)!=="linux"?"gnu":e.detectLibcFamily?e.detectLibcFamily()==="musl"?"musl":"gnu":(0,I.familySync)()===I.MUSL?"musl":"gnu"}function _e(e=process.platform,t){let r=t??(e==="linux"?T():"gnu");return e==="linux"&&r==="musl"?"linuxmusl":e}function Lt(){let e=Ne(),t=e==="linux"?T({platform:e}):"gnu";return`${_e(e,t)}-${process.arch}`}function Nt(){let e=Ne(),{arch:t}=process;switch(e){case"win32":return`win32-${t}-msvc`;case"darwin":return`darwin-${t}`;case"linux":return`linux-${t}-${T({platform:e})}`;default:throw new Error(`Unsupported platform: ${e}/${t}`)}}var u;function Ne(){if(u!==void 0)return u;switch(xt()){case"Windows_NT":u="win32";break;case"Darwin":u="darwin";break;case"Linux":u="linux";break;case"AIX":u="aix";break;case"FreeBSD":case"DragonFly":u="freebsd";break;case"OpenBSD":u="openbsd";break;case"NetBSD":u="netbsd";break;case"SunOS":u="sunos";break;default:u=kt();break}return u}function Ie(e,t){let r=Lt(),n=`${e}.node`,o=`${e}.${Nt()}.node`,i=[];for(let c of t){let w=_t(c),K=Pe(w,"prebuilds",r,n),H=Le(K);if(H.ok)return H.value;i.push({path:K,err:H.err});let Q=Pe(w,o),$=Le(Q);if($.ok)return $.value;i.push({path:Q,err:$.err})}let s=i.map(c=>` ${c.path}: ${It(c.err)}`).join(`
`);throw new Error(`Native addon "${e}" not found for ${r}. Tried:
${i}`)}function It(e){if(e instanceof Error)return e.message;if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return Object.prototype.toString.call(e)}}function Le(e){try{return{ok:!0,value:Tt(e)}}catch(t){return{ok:!1,err:t}}}function Tt(e){return Et(Pt(import.meta.url))(e)}function Te(e){if(!(e instanceof Error))return e;let t=O.sharedApiSqliteNativeErrorPayload(e.message);if(!t)return e;let r=new Error(t.message);return r.code="ERR_SQLITE_ERROR",r.errcode=t.errcode,r.errstr=t.errstr,r}var Oe="__copilotRuntimeAddon__";function qe(){let e=globalThis,t=e[Oe];return t||(t={addon:null,processStateInitialized:!1},e[Oe]=t),t}function Ot(){let e=qe();if(e.addon)return e.addon;m.debug("[nativeRuntime] in-process mode: loading the native runtime .node addon");let t=k.dirname($e(import.meta.url)),r=Ie("runtime",[t,k.resolve(t,".."),k.resolve(t,"..","..","native","runtime")]);return e.addon=r,r}var C;function Ct(e){let t=k.dirname($e(e));return e.endsWith(".ts")?k.resolve(t,"..","..","..","dist-cli"):t}function At(e,t,r,n=import.meta.url){e.toolsInitializeBundledBinaryRoot?.(Ct(n)),e.authInitializeProcessUserAgent?.(r);let o=t.COPILOT_DEBUG_ENTRA_BROKER_URL?.trim()||void 0;delete t.COPILOT_DEBUG_ENTRA_BROKER_URL,e.authInitializeDebugEntraBrokerUrl?.(o)}function R(){C||(C=Ot());let e=qe();return e.processStateInitialized||(e.processStateInitialized=!0,At(C,process.env,process.version)),C}var Ce="\0__copilot_git_structured_error__\0",Ae="__copilot_session_fs_error:";function Ft(e){if(!(e instanceof Error)||!e.message.startsWith(Ce))return e;let t;try{t=JSON.parse(e.message.slice(Ce.length))}catch{return e}let r=new Error(typeof t.message=="string"?t.message:"");typeof t.name=="string"&&(r.name=t.name);for(let[n,o]of Object.entries(t))n!=="message"&&n!=="name"&&(r[n]=o);return r}function Ue(e){if(!(e instanceof Error)||!e.message.startsWith(Ae))return e;let t;try{t=JSON.parse(e.message.slice(Ae.length))}catch{return e}let r=typeof t.code=="string"?t.code:"UNKNOWN",n=typeof t.path=="string"?t.path:"sqliteQuery",o=typeof t.message=="string"&&t.message?`: ${t.message}`:"",s=new Error(`${r}: ${n}${o}`);return s.code=r,s.path=n,s}function h(e){let t=Te(e);return t!==e?t:Ue(e)}function Fe(e){return e??void 0}function Dt(e){class t{inner;constructor(...n){this.inner=new e(...n)}async execute(n,o,s){try{return Fe(await this.inner.execute(n,o,s))}catch(i){throw h(i)}}async batch(n){try{return(await this.inner.batch(n)).map(Fe)}catch(o){throw h(o)}}async transaction(n){try{return await this.inner.transaction(n)}catch(o){throw h(o)}}async getTableNames(){try{return await this.inner.getTableNames()}catch(n){throw h(n)}}async getTableNamesIfExists(){try{return await this.inner.getTableNamesIfExists()}catch(n){throw h(n)}}async getTodoStatus(){try{return await this.inner.getTodoStatus()}catch(n){throw h(n)}}async getCurrentIntent(){try{return await this.inner.getCurrentIntent()}catch(n){throw h(n)}}async closeAll(){try{await this.inner.closeAll()}catch(n){throw h(n)}}}return Object.defineProperty(t,"name",{value:"SessionDatabaseHandle"}),t}function De(e){return JSON.stringify(e,(t,r)=>typeof r=="number"&&!Number.isFinite(r)?{__copilot_forge_number:String(r)}:r)??"null"}var Ht=new Set(["runnerCreateNoopLogger","runnerCreateNoopExec"]),He=new WeakMap;function $t(e,t,r){let n=He.get(e);return n||(n=new Map,He.set(e,n)),n.has(t)||n.set(t,r()),n.get(t)}function qt(e,t){let r=Reflect.get(e,t);if(typeof r=="function"&&t==="SessionDatabaseHandle")return Dt(r);if(typeof r=="function"&&typeof t=="string"&&Ht.has(t)){let n=r;return()=>$t(e,t,()=>n.call(e))}if(typeof r=="function"&&t==="sessionStoreTrackingPostToolUsePlan"){let n=r;return(o,s,i)=>n.call(e,De(o),De(s),i)}if(typeof r=="function"&&typeof t=="string"&&/^git[A-Z]/.test(t)){let n=r;return(...o)=>{let s=n.apply(e,o);return s instanceof Promise?s.catch(i=>{throw Ft(i)}):s}}if(typeof r=="function"&&typeof t=="string"&&/^sessionFs[A-Z]/.test(t)){let n=r;return(...o)=>{let s=n.apply(e,o);return s instanceof Promise?s.catch(i=>{throw Ue(i)}):s}}return r}var O=new Proxy({},{get:(e,t)=>qt(R(),t),has:(e,t)=>Reflect.has(R(),t),set:(e,t,r)=>Reflect.set(R(),t,r),ownKeys:()=>Reflect.ownKeys(R()),getOwnPropertyDescriptor:(e,t)=>Reflect.getOwnPropertyDescriptor(R(),t),defineProperty:(e,t,r)=>Reflect.defineProperty(R(),t,r)});function B(e){return O.errorFormattingFormatUnknown(e)}var Bt=1,Me=".complete";var j={"win32-x64":"win-x64","win32-arm64":"win-arm64","linux-x64":"linux-x64","darwin-arm64":"osx-arm64"};function Be(){return typeof __foundryRequire<"u"&&__foundryRequire||Ut(import.meta.url)}var A;function jt(){if(A)return A;try{let e=Be()("foundry-local-sdk/script/install-utils.cjs");if(typeof e.runInstall!="function")throw new Error(`Expected exports {runInstall: function}, got: ${JSON.stringify(Object.fromEntries(Object.entries(e).map(([t,r])=>[t,typeof r])))}`);return A=e,A}catch(e){throw new Error(`Failed to load foundry-local-sdk/script/install-utils.cjs: ${B(e)}. The upstream foundry-local-sdk installer may have changed shape \u2014 re-run the audit checklist in src/cli/voice/foundry/installer/nativeLoader.ts and update accordingly.`)}}var F;function Jt(){if(F)return F;try{let e=Be()("foundry-local-sdk/deps_versions.json");if(typeof e["foundry-local-core"]?.nuget!="string"||typeof e.onnxruntime?.version!="string"||typeof e["onnxruntime-genai"]?.version!="string")throw new Error('deps_versions.json is missing one of the expected version keys: ["foundry-local-core"].nuget, .onnxruntime.version, ["onnxruntime-genai"].version');return F=e,F}catch(e){throw new Error(`Failed to load foundry-local-sdk/deps_versions.json: ${B(e)}. The upstream foundry-local-sdk installer may have changed shape \u2014 re-run the audit checklist in src/cli/voice/foundry/installer/nativeLoader.ts and update accordingly.`)}}function je(e=process.platform){let t=Jt();return[{name:"Microsoft.AI.Foundry.Local.Core",version:t["foundry-local-core"].nuget},{name:e==="linux"?"Microsoft.ML.OnnxRuntime.Gpu.Linux":"Microsoft.ML.OnnxRuntime.Foundry",version:t.onnxruntime.version},{name:"Microsoft.ML.OnnxRuntimeGenAI.Foundry",version:t["onnxruntime-genai"].version}]}function Je(e){return e==="win32"?".dll":e==="darwin"?".dylib":".so"}function Vt(e,t){return l.join(e,`Microsoft.AI.Foundry.Local.Core${Je(t)}`)}function Wt(e){let t=Je(e),r=e==="win32"?"":"lib";return[`Microsoft.AI.Foundry.Local.Core${t}`,`${r}onnxruntime${t}`,`${r}onnxruntime-genai${t}`]}function Gt(e,t=process.platform,r=process.arch){let n=j[`${t}-${r}`];if(!n)throw new Error(`Voice mode not supported on ${t}-${r}`);let o=e??process.env.COPILOT_CACHE_HOME??Z(),s=je(t),i=Mt("sha256").update(JSON.stringify({schema:Bt,artifacts:s})).digest("hex").slice(0,12);return l.join(o,"foundry",i,n)}async function Ve(e={}){let t=e.platform??process.platform,r=e.arch??process.arch,n=`${t}-${r}`;if(!j[n])throw new Error(`Voice mode is not supported on ${n}. Supported platforms: ${Object.keys(j).join(", ")}.`);let s=Gt(e.cacheRoot,t,r),i=Vt(s,t),c=Wt(t);return await We(s,c)?{corePath:i}:(e.onDownloadStart?.(),await zt(s,t,c,e.runInstall),{corePath:i})}async function We(e,t){return await J(l.join(e,Me))?(await Promise.all(t.map(n=>J(l.join(e,n))))).every(Boolean):!1}async function J(e){try{return await a.access(e),!0}catch{return!1}}async function zt(e,t,r,n){let o=l.dirname(e);await a.mkdir(o,{recursive:!0});let s=l.join(o,`.tmp-${l.basename(e)}-${process.pid}-${Date.now()}`);await a.mkdir(s,{recursive:!0});try{let i=n??jt().runInstall,c=je(t);await Qt(()=>i(c,{binDir:s}));for(let w of r)if(!await J(l.join(s,w)))throw new Error(`Foundry runtime download finished but required file is missing: ${w}. RID for ${t} may not be supported by the published packages.`);await a.writeFile(l.join(s,Me),""),await Kt(s,e,r)}catch(i){throw await a.rm(s,{recursive:!0,force:!0}).catch(()=>{}),i}}async function Kt(e,t,r){try{await a.rename(e,t)}catch(n){let o=n.code;if(o==="ENOTEMPTY"||o==="EEXIST"||o==="EPERM"){if(await We(t,r)){await a.rm(e,{recursive:!0,force:!0}).catch(()=>{});return}await a.rm(t,{recursive:!0,force:!0}),await a.rename(e,t);return}throw n}}async function Qt(e){let t=process.stdout.write.bind(process.stdout),r=process.stderr.write.bind(process.stderr);process.stdout.write=(()=>!0),process.stderr.write=(()=>!0);try{return await e()}finally{process.stdout.write=t,process.stderr.write=r}}var V=class extends Error{constructor(r,n,o){super(r,o);this.code=n;this.name="VoiceBackendError"}code};function Ge(e){return e instanceof V?{message:e.message,code:e.code}:e instanceof Error?{message:e.message}:{message:String(e)}}function ze(e){return e instanceof Error?e:new Error(String(e))}var Xt=16;function W(e){return Ke(e,new WeakSet,0)}function Ke(e,t,r){if(r>=Xt)return"<cause chain truncated>";if(typeof e=="object"&&e!==null){if(t.has(e))return"<cyclic cause>";t.add(e)}if(!(e instanceof Error))return String(e);let n=e.stack??`${e.name}: ${e.message}`;if(e.cause===void 0)return n;let o=Ke(e.cause,t,r+1);return`${n}
Caused by: ${o}`}var G=16*1024,z=class{constructor(t){this.port=t}port;writeLog(t,r){let n={kind:"log",level:t,message:Yt(r)};try{this.port.postMessage(n)}catch{}return Promise.resolve()}outputPath(){return"<voice-worker>"}};function Qe(e,t=m){t.setLogWriter(new z(e))}function Yt(e){return e.length<=G?e:`${e.slice(0,G)}\u2026 [truncated, ${e.length-G} more chars]`}if(!Xe)throw new Error("voice-installer.worker.js must be loaded as a worker thread.");var D=Xe;Qe(D);var er=Zt??{};async function tr(){try{let t={kind:"ok",location:await Ve({cacheRoot:er.cacheRoot,onDownloadStart:()=>{let r={kind:"download-started"};D.postMessage(r)}})};D.postMessage(t)}catch(e){let t=ze(e);m.error(`[voice-installer worker] install failed: ${W(t)}`);let r={kind:"error",error:Ge(t)};D.postMessage(r)}finally{setImmediate(()=>process.exit(0))}}tr().catch(e=>{m.error(`[voice-installer worker] fatal: ${W(e)}`),process.exit(1)});
${s}`)}function It(e){if(e instanceof Error)return e.message;if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return Object.prototype.toString.call(e)}}function Le(e){try{return{ok:!0,value:Tt(e)}}catch(t){return{ok:!1,err:t}}}function Tt(e){return Et(Pt(import.meta.url))(e)}function Te(e){if(!(e instanceof Error))return e;let t=O.sharedApiSqliteNativeErrorPayload(e.message);if(!t)return e;let r=new Error(t.message);return r.code="ERR_SQLITE_ERROR",r.errcode=t.errcode,r.errstr=t.errstr,r}var Oe="__copilotRuntimeAddon__";function qe(){let e=globalThis,t=e[Oe];return t||(t={addon:null,processStateInitialized:!1},e[Oe]=t),t}function Ot(){let e=qe();if(e.addon)return e.addon;m.debug("[nativeRuntime] in-process mode: loading the native runtime .node addon");let t=k.dirname($e(import.meta.url)),r=Ie("runtime",[t,k.resolve(t,".."),k.resolve(t,"..","..","native","runtime")]);return e.addon=r,r}var C;function Ct(e){let t=k.dirname($e(e));return e.endsWith(".ts")?k.resolve(t,"..","..","..","dist-cli"):t}function At(e,t,r,n=import.meta.url){e.toolsInitializeBundledBinaryRoot?.(Ct(n)),e.authInitializeProcessUserAgent?.(r);let o=t.COPILOT_DEBUG_ENTRA_BROKER_URL?.trim()||void 0;delete t.COPILOT_DEBUG_ENTRA_BROKER_URL,e.authInitializeDebugEntraBrokerUrl?.(o)}function R(){C||(C=Ot());let e=qe();return e.processStateInitialized||(e.processStateInitialized=!0,At(C,process.env,process.version)),C}var Ce="\0__copilot_git_structured_error__\0",Ae="__copilot_session_fs_error:";function Ft(e){if(!(e instanceof Error)||!e.message.startsWith(Ce))return e;let t;try{t=JSON.parse(e.message.slice(Ce.length))}catch{return e}let r=new Error(typeof t.message=="string"?t.message:"");typeof t.name=="string"&&(r.name=t.name);for(let[n,o]of Object.entries(t))n!=="message"&&n!=="name"&&(r[n]=o);return r}function Ue(e){if(!(e instanceof Error)||!e.message.startsWith(Ae))return e;let t;try{t=JSON.parse(e.message.slice(Ae.length))}catch{return e}let r=typeof t.code=="string"?t.code:"UNKNOWN",n=typeof t.path=="string"?t.path:"sqliteQuery",o=typeof t.message=="string"&&t.message?`: ${t.message}`:"",i=new Error(`${r}: ${n}${o}`);return i.code=r,i.path=n,i}function h(e){let t=Te(e);return t!==e?t:Ue(e)}function Fe(e){return e??void 0}function Dt(e){class t{inner;constructor(...n){this.inner=new e(...n)}async execute(n,o,i){try{return Fe(await this.inner.execute(n,o,i))}catch(s){throw h(s)}}async batch(n){try{return(await this.inner.batch(n)).map(Fe)}catch(o){throw h(o)}}async transaction(n){try{return await this.inner.transaction(n)}catch(o){throw h(o)}}async getTableNames(){try{return await this.inner.getTableNames()}catch(n){throw h(n)}}async getTableNamesIfExists(){try{return await this.inner.getTableNamesIfExists()}catch(n){throw h(n)}}async getTodoStatus(){try{return await this.inner.getTodoStatus()}catch(n){throw h(n)}}async getCurrentIntent(){try{return await this.inner.getCurrentIntent()}catch(n){throw h(n)}}async closeAll(){try{await this.inner.closeAll()}catch(n){throw h(n)}}}return Object.defineProperty(t,"name",{value:"SessionDatabaseHandle"}),t}function De(e){return JSON.stringify(e,(t,r)=>typeof r=="number"&&!Number.isFinite(r)?{__copilot_forge_number:String(r)}:r)??"null"}var Ht=new Set(["runnerCreateNoopLogger","runnerCreateNoopExec"]),He=new WeakMap;function $t(e,t,r){let n=He.get(e);return n||(n=new Map,He.set(e,n)),n.has(t)||n.set(t,r()),n.get(t)}function qt(e,t){let r=Reflect.get(e,t);if(typeof r=="function"&&t==="SessionDatabaseHandle")return Dt(r);if(typeof r=="function"&&typeof t=="string"&&Ht.has(t)){let n=r;return()=>$t(e,t,()=>n.call(e))}if(typeof r=="function"&&t==="sessionStoreTrackingPostToolUsePlan"){let n=r;return(o,i,s)=>n.call(e,De(o),De(i),s)}if(typeof r=="function"&&typeof t=="string"&&/^git[A-Z]/.test(t)){let n=r;return(...o)=>{let i=n.apply(e,o);return i instanceof Promise?i.catch(s=>{throw Ft(s)}):i}}if(typeof r=="function"&&typeof t=="string"&&/^sessionFs[A-Z]/.test(t)){let n=r;return(...o)=>{let i=n.apply(e,o);return i instanceof Promise?i.catch(s=>{throw Ue(s)}):i}}return r}var O=new Proxy({},{get:(e,t)=>qt(R(),t),has:(e,t)=>Reflect.has(R(),t),set:(e,t,r)=>Reflect.set(R(),t,r),ownKeys:()=>Reflect.ownKeys(R()),getOwnPropertyDescriptor:(e,t)=>Reflect.getOwnPropertyDescriptor(R(),t),defineProperty:(e,t,r)=>Reflect.defineProperty(R(),t,r)});function B(e){return O.errorFormattingFormatUnknown(e)}var Bt=1,Me=".complete";var j={"win32-x64":"win-x64","win32-arm64":"win-arm64","linux-x64":"linux-x64","darwin-arm64":"osx-arm64"};function Be(){return typeof __foundryRequire<"u"&&__foundryRequire||Ut(import.meta.url)}var A;function jt(){if(A)return A;try{let e=Be()("foundry-local-sdk/script/install-utils.cjs");if(typeof e.runInstall!="function")throw new Error(`Expected exports {runInstall: function}, got: ${JSON.stringify(Object.fromEntries(Object.entries(e).map(([t,r])=>[t,typeof r])))}`);return A=e,A}catch(e){throw new Error(`Failed to load foundry-local-sdk/script/install-utils.cjs: ${B(e)}. The upstream foundry-local-sdk installer may have changed shape \u2014 re-run the audit checklist in src/cli/voice/foundry/installer/nativeLoader.ts and update accordingly.`)}}var F;function Jt(){if(F)return F;try{let e=Be()("foundry-local-sdk/deps_versions.json");if(typeof e["foundry-local-core"]?.nuget!="string"||typeof e.onnxruntime?.version!="string"||typeof e["onnxruntime-genai"]?.version!="string")throw new Error('deps_versions.json is missing one of the expected version keys: ["foundry-local-core"].nuget, .onnxruntime.version, ["onnxruntime-genai"].version');return F=e,F}catch(e){throw new Error(`Failed to load foundry-local-sdk/deps_versions.json: ${B(e)}. The upstream foundry-local-sdk installer may have changed shape \u2014 re-run the audit checklist in src/cli/voice/foundry/installer/nativeLoader.ts and update accordingly.`)}}function je(e=process.platform){let t=Jt();return[{name:"Microsoft.AI.Foundry.Local.Core",version:t["foundry-local-core"].nuget},{name:e==="linux"?"Microsoft.ML.OnnxRuntime.Gpu.Linux":"Microsoft.ML.OnnxRuntime.Foundry",version:t.onnxruntime.version},{name:"Microsoft.ML.OnnxRuntimeGenAI.Foundry",version:t["onnxruntime-genai"].version}]}function Je(e){return e==="win32"?".dll":e==="darwin"?".dylib":".so"}function Wt(e,t){return l.join(e,`Microsoft.AI.Foundry.Local.Core${Je(t)}`)}function Vt(e){let t=Je(e),r=e==="win32"?"":"lib";return[`Microsoft.AI.Foundry.Local.Core${t}`,`${r}onnxruntime${t}`,`${r}onnxruntime-genai${t}`]}function Gt(e,t=process.platform,r=process.arch){let n=j[`${t}-${r}`];if(!n)throw new Error(`Voice mode not supported on ${t}-${r}`);let o=e??process.env.COPILOT_CACHE_HOME??Z(),i=je(t),s=Mt("sha256").update(JSON.stringify({schema:Bt,artifacts:i})).digest("hex").slice(0,12);return l.join(o,"foundry",s,n)}async function We(e={}){let t=e.platform??process.platform,r=e.arch??process.arch,n=`${t}-${r}`;if(!j[n])throw new Error(`Voice mode is not supported on ${n}. Supported platforms: ${Object.keys(j).join(", ")}.`);let i=Gt(e.cacheRoot,t,r),s=Wt(i,t),c=Vt(t);return await Ve(i,c)?{corePath:s}:(e.onDownloadStart?.(),await zt(i,t,c,e.runInstall),{corePath:s})}async function Ve(e,t){return await J(l.join(e,Me))?(await Promise.all(t.map(n=>J(l.join(e,n))))).every(Boolean):!1}async function J(e){try{return await a.access(e),!0}catch{return!1}}async function zt(e,t,r,n){let o=l.dirname(e);await a.mkdir(o,{recursive:!0});let i=l.join(o,`.tmp-${l.basename(e)}-${process.pid}-${Date.now()}`);await a.mkdir(i,{recursive:!0});try{let s=n??jt().runInstall,c=je(t);await Qt(()=>s(c,{binDir:i}));for(let w of r)if(!await J(l.join(i,w)))throw new Error(`Foundry runtime download finished but required file is missing: ${w}. RID for ${t} may not be supported by the published packages.`);await a.writeFile(l.join(i,Me),""),await Kt(i,e,r)}catch(s){throw await a.rm(i,{recursive:!0,force:!0}).catch(()=>{}),s}}async function Kt(e,t,r){try{await a.rename(e,t)}catch(n){let o=n.code;if(o==="ENOTEMPTY"||o==="EEXIST"||o==="EPERM"){if(await Ve(t,r)){await a.rm(e,{recursive:!0,force:!0}).catch(()=>{});return}await a.rm(t,{recursive:!0,force:!0}),await a.rename(e,t);return}throw n}}async function Qt(e){let t=process.stdout.write.bind(process.stdout),r=process.stderr.write.bind(process.stderr);process.stdout.write=(()=>!0),process.stderr.write=(()=>!0);try{return await e()}finally{process.stdout.write=t,process.stderr.write=r}}var W=class extends Error{constructor(r,n,o){super(r,o);this.code=n;this.name="VoiceBackendError"}code};function Ge(e){return e instanceof W?{message:e.message,code:e.code}:e instanceof Error?{message:e.message}:{message:String(e)}}function ze(e){return e instanceof Error?e:new Error(String(e))}var Xt=16;function V(e){return Ke(e,new WeakSet,0)}function Ke(e,t,r){if(r>=Xt)return"<cause chain truncated>";if(typeof e=="object"&&e!==null){if(t.has(e))return"<cyclic cause>";t.add(e)}if(!(e instanceof Error))return String(e);let n=e.stack??`${e.name}: ${e.message}`;if(e.cause===void 0)return n;let o=Ke(e.cause,t,r+1);return`${n}
Caused by: ${o}`}var G=16*1024,z=class{constructor(t){this.port=t}port;writeLog(t,r){let n={kind:"log",level:t,message:Yt(r)};try{this.port.postMessage(n)}catch{}return Promise.resolve()}outputPath(){return"<voice-worker>"}};function Qe(e,t=m){t.setLogWriter(new z(e))}function Yt(e){return e.length<=G?e:`${e.slice(0,G)}\u2026 [truncated, ${e.length-G} more chars]`}if(!Xe)throw new Error("voice-installer.worker.js must be loaded as a worker thread.");var D=Xe;Qe(D);var er=Zt??{};async function tr(){try{let t={kind:"ok",location:await We({cacheRoot:er.cacheRoot,onDownloadStart:()=>{let r={kind:"download-started"};D.postMessage(r)}})};D.postMessage(t)}catch(e){let t=ze(e);m.error(`[voice-installer worker] install failed: ${V(t)}`);let r={kind:"error",error:Ge(t)};D.postMessage(r)}finally{setImmediate(()=>process.exit(0))}}tr().catch(e=>{m.error(`[voice-installer worker] fatal: ${V(e)}`),process.exit(1)});
//# sourceMappingURL=voice-installer.worker.js.map

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display