@github/copilot 0.0.338-5 → 0.0.338-6

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/index.js CHANGED
@@ -1316,7 +1316,7 @@ globstar while`,e,p,l,h,W),this.matchOne(e.slice(p),l.slice(h),n))return this.de
1316
1316
 
1317
1317
  # Repository-specific instructions
1318
1318
 
1319
- `,h+=" + .github/copilot-instructions.md"):h=".github/copilot-instructions.md",p+=gC(y)}return{content:p,source:"copilot",sourcePath:h,additionalInstructions:a,mergedFromHome:W}}let d=fUl(t);if(d.exists){let p=await nE.promises.readFile(d.path,"utf-8");return{content:gC(p),source:"claude",sourcePath:"CLAUDE.md",additionalInstructions:a}}let u=vUl(t);if(u.exists){let p=await nE.promises.readFile(u.path,"utf-8");return{content:gC(p),source:"codex",sourcePath:"AGENTS.md",additionalInstructions:a}}let G=HUl(t);if(G.exists){let p=await nE.promises.readFile(G.path,"utf-8");return{content:gC(p),source:"gemini",sourcePath:"GEMINI.md",additionalInstructions:a}}if(a)return I&&!r?I:r&&!I?r:I}function vUl(t){let e=oG.join(t,"AGENTS.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function fUl(t){let e=oG.join(t,"CLAUDE.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function HUl(t){let e=oG.join(t,"GEMINI.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function XUl(t){let e=oG.join(t,".github","copilot-instructions.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function kUl(){let t=oG.join(zRt(),"copilot-instructions.md");return S5(t)?{exists:!0,path:t}:{exists:!1,path:void 0}}function gNe(t,e){let l=oG.normalize(t),n=oG.normalize(e);return process.platform==="win32"||process.platform==="darwin"?l.toLowerCase()===n.toLowerCase():l===n}async function LUl(t){let e=(0,KRt.default)();e.add(["node_modules",".git","vendor","dist","build",".next",".nuxt","out","coverage"]);let l=oG.join(t,".gitignore");if(S5(l))try{let n=await nE.promises.readFile(l,"utf-8");e.add(n)}catch{}return n=>{let I=oG.relative(t,n);return!e.ignores(I)}}async function JUl(t,e,l=[]){let n=[t];e&&!gNe(e,t)&&n.push(e);for(let a of l)n.some(s=>gNe(s,a))||n.push(a);let I=[];for(let a of n){let s=oG.join(a,".github","instructions");if(S5(s))try{let o=TUl(oG.join(s,"**","*.instructions.md")),d=await cNe(o),u=await LUl(a),G=d.filter(u),p=await Promise.all(G.map(async h=>{try{if(!(await nE.promises.stat(h)).isFile())return null;let y=await nE.promises.readFile(h,"utf-8"),R=xUl(y);return{path:oG.relative(t,h),content:gC(y),metadata:R}}catch{return null}}));I.push(...p.filter(h=>h!==null))}catch{}}return I.length===0?void 0:{content:SUl(I),source:"vscode",sourcePath:".github/instructions"}}async function BUl(t,e,l=[]){let n=[t];e&&!gNe(e,t)&&n.push(e);for(let a of l)n.some(s=>gNe(s,a))||n.push(a);let I=[];for(let a of n){let s=oG.join(a,"AGENTS.md");if(S5(s))try{if(!(await nE.promises.stat(s)).isFile())continue;let d=await nE.promises.readFile(s,"utf-8"),u=oG.relative(t,s);if(u==="AGENTS.md")continue;I.push({path:u,content:gC(d)})}catch{}}return I.length===0?void 0:{content:OUl(I),source:"codex",sourcePath:"AGENTS.md (nested)"}}function xUl(t){let e=t.match(/^---\s*\n([\s\S]*?)\n---\s*\n([\s\S]*)/);if(e){let l=e[1],n=e[2].trim(),I=l.match(/applyTo:\s*(.+)/);return{applyTo:I?I[1].trim().replace(/['"]/g,""):void 0,description:n}}return{description:t.trim()}}function SUl(t){let e=[],l=[];for(let I of t){let{path:r,content:a,metadata:s}=I,o=s.applyTo,d=s.description??"";o&&o!=="**"&&o!=="**/*"&&o!=="*"?e.push(`| ${o} | '${r}' | ${d} |`):l.push(a)}let n="";return l.length>0&&(n+=l.join(`
1319
+ `,h+=" + .github/copilot-instructions.md"):h=".github/copilot-instructions.md",p+=gC(y)}return{content:p,source:"copilot",sourcePath:h,additionalInstructions:a,mergedFromHome:W}}let d=vUl(t);if(d.exists){let p=await nE.promises.readFile(d.path,"utf-8");return{content:gC(p),source:"codex",sourcePath:"AGENTS.md",additionalInstructions:a}}let u=fUl(t);if(u.exists){let p=await nE.promises.readFile(u.path,"utf-8");return{content:gC(p),source:"claude",sourcePath:"CLAUDE.md",additionalInstructions:a}}let G=HUl(t);if(G.exists){let p=await nE.promises.readFile(G.path,"utf-8");return{content:gC(p),source:"gemini",sourcePath:"GEMINI.md",additionalInstructions:a}}if(a)return I&&!r?I:r&&!I?r:I}function vUl(t){let e=oG.join(t,"AGENTS.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function fUl(t){let e=oG.join(t,"CLAUDE.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function HUl(t){let e=oG.join(t,"GEMINI.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function XUl(t){let e=oG.join(t,".github","copilot-instructions.md");return S5(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function kUl(){let t=oG.join(zRt(),"copilot-instructions.md");return S5(t)?{exists:!0,path:t}:{exists:!1,path:void 0}}function gNe(t,e){let l=oG.normalize(t),n=oG.normalize(e);return process.platform==="win32"||process.platform==="darwin"?l.toLowerCase()===n.toLowerCase():l===n}async function LUl(t){let e=(0,KRt.default)();e.add(["node_modules",".git","vendor","dist","build",".next",".nuxt","out","coverage"]);let l=oG.join(t,".gitignore");if(S5(l))try{let n=await nE.promises.readFile(l,"utf-8");e.add(n)}catch{}return n=>{let I=oG.relative(t,n);return!e.ignores(I)}}async function JUl(t,e,l=[]){let n=[t];e&&!gNe(e,t)&&n.push(e);for(let a of l)n.some(s=>gNe(s,a))||n.push(a);let I=[];for(let a of n){let s=oG.join(a,".github","instructions");if(S5(s))try{let o=TUl(oG.join(s,"**","*.instructions.md")),d=await cNe(o),u=await LUl(a),G=d.filter(u),p=await Promise.all(G.map(async h=>{try{if(!(await nE.promises.stat(h)).isFile())return null;let y=await nE.promises.readFile(h,"utf-8"),R=xUl(y);return{path:oG.relative(t,h),content:gC(y),metadata:R}}catch{return null}}));I.push(...p.filter(h=>h!==null))}catch{}}return I.length===0?void 0:{content:SUl(I),source:"vscode",sourcePath:".github/instructions"}}async function BUl(t,e,l=[]){let n=[t];e&&!gNe(e,t)&&n.push(e);for(let a of l)n.some(s=>gNe(s,a))||n.push(a);let I=[];for(let a of n){let s=oG.join(a,"AGENTS.md");if(S5(s))try{if(!(await nE.promises.stat(s)).isFile())continue;let d=await nE.promises.readFile(s,"utf-8"),u=oG.relative(t,s);if(u==="AGENTS.md")continue;I.push({path:u,content:gC(d)})}catch{}}return I.length===0?void 0:{content:OUl(I),source:"codex",sourcePath:"AGENTS.md (nested)"}}function xUl(t){let e=t.match(/^---\s*\n([\s\S]*?)\n---\s*\n([\s\S]*)/);if(e){let l=e[1],n=e[2].trim(),I=l.match(/applyTo:\s*(.+)/);return{applyTo:I?I[1].trim().replace(/['"]/g,""):void 0,description:n}}return{description:t.trim()}}function SUl(t){let e=[],l=[];for(let I of t){let{path:r,content:a,metadata:s}=I,o=s.applyTo,d=s.description??"";o&&o!=="**"&&o!=="**/*"&&o!=="*"?e.push(`| ${o} | '${r}' | ${d} |`):l.push(a)}let n="";return l.length>0&&(n+=l.join(`
1320
1320
 
1321
1321
  `)+`
1322
1322
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@github/copilot",
3
3
  "description": "GitHub Copilot CLI brings the power of Copilot coding agent directly to your terminal.",
4
- "version": "0.0.338-5",
4
+ "version": "0.0.338-6",
5
5
  "type": "module",
6
6
  "repository": {
7
7
  "type": "git",
@@ -33,7 +33,7 @@
33
33
  "sdk/**/*"
34
34
  ],
35
35
  "buildMetadata": {
36
- "gitCommit": "6be0c31"
36
+ "gitCommit": "a9e7480"
37
37
  },
38
38
  "dependencies": {
39
39
  "node-pty": "npm:@devm33/node-pty@^1.0.8",
package/sdk/index.js CHANGED
@@ -930,7 +930,7 @@ globstar while`,e,h,I,p,Z),this.matchOne(e.slice(h),I.slice(p),l))return this.de
930
930
 
931
931
  # Repository-specific instructions
932
932
 
933
- `,p+=" + .github/copilot-instructions.md"):p=".github/copilot-instructions.md",h+=Vu(u)}return{content:h,source:"copilot",sourcePath:p,additionalInstructions:a,mergedFromHome:Z}}let o=pkI(t);if(o.exists){let h=await ni.promises.readFile(o.path,"utf-8");return{content:Vu(h),source:"claude",sourcePath:"CLAUDE.md",additionalInstructions:a}}let d=hkI(t);if(d.exists){let h=await ni.promises.readFile(d.path,"utf-8");return{content:Vu(h),source:"codex",sourcePath:"AGENTS.md",additionalInstructions:a}}let i=ZkI(t);if(i.exists){let h=await ni.promises.readFile(i.path,"utf-8");return{content:Vu(h),source:"gemini",sourcePath:"GEMINI.md",additionalInstructions:a}}if(a)return n&&!c?n:c&&!n?c:n}function hkI(t){let e=ra.join(t,"AGENTS.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function pkI(t){let e=ra.join(t,"CLAUDE.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function ZkI(t){let e=ra.join(t,"GEMINI.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function ukI(t){let e=ra.join(t,".github","copilot-instructions.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function WkI(){let t=ra.join(UUe(),"copilot-instructions.md");return nV(t)?{exists:!0,path:t}:{exists:!1,path:void 0}}function OP(t,e){let I=ra.normalize(t),l=ra.normalize(e);return process.platform==="win32"||process.platform==="darwin"?I.toLowerCase()===l.toLowerCase():I===l}async function NkI(t){let e=(0,SUe.default)();e.add(["node_modules",".git","vendor","dist","build",".next",".nuxt","out","coverage"]);let I=ra.join(t,".gitignore");if(nV(I))try{let l=await ni.promises.readFile(I,"utf-8");e.add(l)}catch{}return l=>{let n=ra.relative(t,l);return!e.ignores(n)}}async function YkI(t,e,I=[]){let l=[t];e&&!OP(e,t)&&l.push(e);for(let a of I)l.some(s=>OP(s,a))||l.push(a);let n=[];for(let a of l){let s=ra.join(a,".github","instructions");if(nV(s))try{let r=gkI(ra.join(s,"**","*.instructions.md")),o=await fP(r),d=await NkI(a),i=o.filter(d),h=await Promise.all(i.map(async p=>{try{if(!(await ni.promises.stat(p)).isFile())return null;let u=await ni.promises.readFile(p,"utf-8"),N=RkI(u);return{path:ra.relative(t,p),content:Vu(u),metadata:N}}catch{return null}}));n.push(...h.filter(p=>p!==null))}catch{}}return n.length===0?void 0:{content:ykI(n),source:"vscode",sourcePath:".github/instructions"}}async function VkI(t,e,I=[]){let l=[t];e&&!OP(e,t)&&l.push(e);for(let a of I)l.some(s=>OP(s,a))||l.push(a);let n=[];for(let a of l){let s=ra.join(a,"AGENTS.md");if(nV(s))try{if(!(await ni.promises.stat(s)).isFile())continue;let o=await ni.promises.readFile(s,"utf-8"),d=ra.relative(t,s);if(d==="AGENTS.md")continue;n.push({path:d,content:Vu(o)})}catch{}}return n.length===0?void 0:{content:FkI(n),source:"codex",sourcePath:"AGENTS.md (nested)"}}function RkI(t){let e=t.match(/^---\s*\n([\s\S]*?)\n---\s*\n([\s\S]*)/);if(e){let I=e[1],l=e[2].trim(),n=I.match(/applyTo:\s*(.+)/);return{applyTo:n?n[1].trim().replace(/['"]/g,""):void 0,description:l}}return{description:t.trim()}}function ykI(t){let e=[],I=[];for(let n of t){let{path:c,content:a,metadata:s}=n,r=s.applyTo,o=s.description??"";r&&r!=="**"&&r!=="**/*"&&r!=="*"?e.push(`| ${r} | '${c}' | ${o} |`):I.push(a)}let l="";return I.length>0&&(l+=I.join(`
933
+ `,p+=" + .github/copilot-instructions.md"):p=".github/copilot-instructions.md",h+=Vu(u)}return{content:h,source:"copilot",sourcePath:p,additionalInstructions:a,mergedFromHome:Z}}let o=hkI(t);if(o.exists){let h=await ni.promises.readFile(o.path,"utf-8");return{content:Vu(h),source:"codex",sourcePath:"AGENTS.md",additionalInstructions:a}}let d=pkI(t);if(d.exists){let h=await ni.promises.readFile(d.path,"utf-8");return{content:Vu(h),source:"claude",sourcePath:"CLAUDE.md",additionalInstructions:a}}let i=ZkI(t);if(i.exists){let h=await ni.promises.readFile(i.path,"utf-8");return{content:Vu(h),source:"gemini",sourcePath:"GEMINI.md",additionalInstructions:a}}if(a)return n&&!c?n:c&&!n?c:n}function hkI(t){let e=ra.join(t,"AGENTS.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function pkI(t){let e=ra.join(t,"CLAUDE.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function ZkI(t){let e=ra.join(t,"GEMINI.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function ukI(t){let e=ra.join(t,".github","copilot-instructions.md");return nV(e)?{exists:!0,path:e}:{exists:!1,path:void 0}}function WkI(){let t=ra.join(UUe(),"copilot-instructions.md");return nV(t)?{exists:!0,path:t}:{exists:!1,path:void 0}}function OP(t,e){let I=ra.normalize(t),l=ra.normalize(e);return process.platform==="win32"||process.platform==="darwin"?I.toLowerCase()===l.toLowerCase():I===l}async function NkI(t){let e=(0,SUe.default)();e.add(["node_modules",".git","vendor","dist","build",".next",".nuxt","out","coverage"]);let I=ra.join(t,".gitignore");if(nV(I))try{let l=await ni.promises.readFile(I,"utf-8");e.add(l)}catch{}return l=>{let n=ra.relative(t,l);return!e.ignores(n)}}async function YkI(t,e,I=[]){let l=[t];e&&!OP(e,t)&&l.push(e);for(let a of I)l.some(s=>OP(s,a))||l.push(a);let n=[];for(let a of l){let s=ra.join(a,".github","instructions");if(nV(s))try{let r=gkI(ra.join(s,"**","*.instructions.md")),o=await fP(r),d=await NkI(a),i=o.filter(d),h=await Promise.all(i.map(async p=>{try{if(!(await ni.promises.stat(p)).isFile())return null;let u=await ni.promises.readFile(p,"utf-8"),N=RkI(u);return{path:ra.relative(t,p),content:Vu(u),metadata:N}}catch{return null}}));n.push(...h.filter(p=>p!==null))}catch{}}return n.length===0?void 0:{content:ykI(n),source:"vscode",sourcePath:".github/instructions"}}async function VkI(t,e,I=[]){let l=[t];e&&!OP(e,t)&&l.push(e);for(let a of I)l.some(s=>OP(s,a))||l.push(a);let n=[];for(let a of l){let s=ra.join(a,"AGENTS.md");if(nV(s))try{if(!(await ni.promises.stat(s)).isFile())continue;let o=await ni.promises.readFile(s,"utf-8"),d=ra.relative(t,s);if(d==="AGENTS.md")continue;n.push({path:d,content:Vu(o)})}catch{}}return n.length===0?void 0:{content:FkI(n),source:"codex",sourcePath:"AGENTS.md (nested)"}}function RkI(t){let e=t.match(/^---\s*\n([\s\S]*?)\n---\s*\n([\s\S]*)/);if(e){let I=e[1],l=e[2].trim(),n=I.match(/applyTo:\s*(.+)/);return{applyTo:n?n[1].trim().replace(/['"]/g,""):void 0,description:l}}return{description:t.trim()}}function ykI(t){let e=[],I=[];for(let n of t){let{path:c,content:a,metadata:s}=n,r=s.applyTo,o=s.description??"";r&&r!=="**"&&r!=="**/*"&&r!=="*"?e.push(`| ${r} | '${c}' | ${o} |`):I.push(a)}let l="";return I.length>0&&(l+=I.join(`
934
934
 
935
935
  `)+`
936
936