@github/copilot-language-server 1.383.0 → 1.384.0
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/main.js +1 -1
- package/package.json +7 -7
package/dist/main.js
CHANGED
|
@@ -1110,7 +1110,7 @@ ${r}+- `:"";return e+this.description+o}}},ru=class{constructor(e,r,n,o){this.la
|
|
|
1110
1110
|
(using_declaration)
|
|
1111
1111
|
(alias_declaration)
|
|
1112
1112
|
(static_assert_declaration)
|
|
1113
|
-
] @statement`}};var hC=class{constructor(e,r,n){this.languageId=e;this.prefix=r;this.completion=n}static{a(this,"BlockTrimmer")}static isSupported(e){return ru.isSupported(e)}static isTrimmedByDefault(e){return ru.isTrimmedByDefault(e)}async withParsedStatementTree(e){var n=[];try{let r=Qwe(n,ru.create(this.languageId,this.prefix+this.completion,this.prefix.length,this.prefix.length+this.completion.length));await r.build();return await e(r)}catch(o){var s=o,c=!0}finally{qwe(n,s,c)}}trimmedCompletion(e){return e===void 0?this.completion:this.completion.substring(0,e)}getStatementAtCursor(e){return e.statementAt(Math.max(this.prefix.length-1,0))??e.statements[0]}getContainingBlockOffset(e){let r;if(e&&this.isCompoundStatement(e))r=e;else if(e){let n=e.parent;for(;n&&!this.isCompoundStatement(n);)n=n.parent;r=n}if(r){let n=this.asCompletionOffset(r.node.endIndex);if(n&&this.completion.substring(n).trim()!=="")return n}}hasNonStatementContentAfter(e){if(!e||!e.nextSibling)return!1;let r=this.asCompletionOffset(e.node.endIndex),n=this.asCompletionOffset(e.nextSibling.node.startIndex);return this.completion.substring(Math.max(0,r??0),Math.max(0,n??0)).trim()!==""}asCompletionOffset(e){return e===void 0?void 0:e-this.prefix.length}isCompoundStatement(e){return e.isCompoundStatementType||e.children.length>0}};var use=class extends hC{constructor(r,n,o,s=3,c=7){super(r,n,o);this.lineLimit=s;this.lookAhead=c;let l=[...this.completion.matchAll(/\n/g)],u=this.lineLimit+this.lookAhead;l.length>=this.lineLimit&&this.lineLimit>0&&(this.limitOffset=l[this.lineLimit-1].index),l.length>=u&&u>0&&(this.lookAheadOffset=l[u-1].index)}static{a(this,"TerseBlockTrimmer")}async getCompletionTrimOffset(){return await this.withParsedStatementTree(r=>{let n=r.statementAt(this.stmtStartPos()),o=this.getContainingBlockOffset(n);return o=this.trimAtFirstBlankLine(o),n&&(o=this.trimAtStatementChange(n,o)),this.limitOffset&&this.lookAheadOffset&&(o===void 0||o>this.lookAheadOffset)?this.limitOffset:o})}stmtStartPos(){let r=this.completion.match(/\S/);return r&&r.index!==void 0?this.prefix.length+r.index:Math.max(this.prefix.length-1,0)}trimAtFirstBlankLine(r){let n=[...this.trimmedCompletion(r).matchAll(/\r?\n\s*\r?\n/g)];for(;n.length>0&&(r===void 0||r>n[0].index);){let o=n.shift();if(this.completion.substring(0,o.index).trim()!=="")return o.index}return r}trimAtStatementChange(r,n){let o=this.prefix.length,s=this.prefix.length+(n??this.completion.length);if(r.node.endIndex>o&&this.isCompoundStatement(r))return r.nextSibling&&r.node.endIndex<s?this.asCompletionOffset(r.node.endIndex):n;let c=r,l=r.nextSibling;for(;l&&l.node.endIndex<=s&&!this.hasNonStatementContentAfter(c)&&!this.isCompoundStatement(l);)c=l,l=l.nextSibling;return l&&c.node.endIndex>o&&c.node.endIndex<s?this.asCompletionOffset(c.node.endIndex):n}};async function kxt(t,e){var l=[];try{let r=t.getText();let n=t.offsetAt(e);let o=Qwe(l,ru.create(t.detectedLanguageId,r,0,r.length));await o.build();let s=o.statementAt(n);if(!s)return"non-block";if(!s.isCompoundStatementType&&s.children.length===0)return s.parent&&!s.nextSibling&&s.node.endPosition.row<=e.line?"block-end":s.parent?"mid-block":"non-block";if(s.children.length===0)return"empty-block";let c=s.children[s.children.length-1];if(n<c.node.startIndex)return"mid-block";return"block-end"}catch(u){var d=u,p=!0}finally{qwe(l,d,p)}}a(kxt,"getBlockPositionType");f();function k6r(t){return t.HTTPS_PROXY||t.https_proxy||t.HTTP_PROXY||t.http_proxy}a(k6r,"getProxyFromEnvironment");function P6r(t){return t.NODE_TLS_REJECT_UNAUTHORIZED!=="0"}a(P6r,"getRejectUnauthorizedFromEnvironment");var Pxt=E.Object({proxy:E.Optional(E.String()),proxyStrictSSL:E.Optional(E.Boolean()),proxyAuthorization:E.Optional(E.String()),proxyKerberosServicePrincipal:E.Optional(E.String()),noProxy:E.Optional(E.Array(E.String()))});function Dxt(t){let e=k6r(t),r=xG({proxy:e,proxyStrictSSL:P6r(t)}),n=t.GH_COPILOT_KERBEROS_SERVICE_PRINCIPAL??t.GITHUB_COPILOT_KERBEROS_SERVICE_PRINCIPAL??t.AGENT_KERBEROS_SERVICE_PRINCIPAL;return n&&(r.proxyKerberosServicePrincipal=n),r}a(Dxt,"getHttpSettingsFromEnvironment");function xG(t){if(!t.proxy)return{...t,proxy:""};try{let{protocol:e,host:r,username:n,password:o,pathname:s,search:c,hash:l}=new URL(t.proxy);return{...t,proxy:`${e}//${r}${s}${c}${l}`,proxyAuthorization:t.proxyAuthorization||D6r(n,o),noProxy:t.noProxy||[]}}catch{return{...t,proxy:""}}}a(xG,"normalizeHttpSettings");function D6r(t,e){return!t||!e?"":`${decodeURIComponent(t)}:${decodeURIComponent(e)}`}a(D6r,"getAuth");var dDe={};bo(dDe,{activationEvents:()=>X6r,badges:()=>J6r,browser:()=>Z6r,bugs:()=>$6r,build:()=>O6r,buildType:()=>F6r,categories:()=>K6r,contributes:()=>fDe,default:()=>s9r,dependencies:()=>i9r,description:()=>M6r,devDependencies:()=>n9r,displayName:()=>L6r,enabledApiProposals:()=>t9r,engines:()=>z6r,extensionPack:()=>V6r,homepage:()=>q6r,icon:()=>H6r,keywords:()=>Y6r,license:()=>j6r,main:()=>e9r,name:()=>N6r,overrides:()=>o9r,preview:()=>Q6r,pricing:()=>W6r,publisher:()=>U6r,qna:()=>G6r,scripts:()=>r9r,version:()=>B6r});var N6r="copilot",L6r="GitHub Copilot",M6r="Your AI pair programmer",B6r="1.383.0",O6r="1809",F6r="prod",U6r="GitHub",Q6r=!1,q6r="https://github.com/features/copilot?editor=vscode",j6r="https://docs.github.com/en/site-policy/github-terms/github-terms-for-additional-products-and-features",$6r={url:"https://github.com/microsoft/vscode/issues"},G6r="https://github.com/github-community/community/discussions/categories/copilot",H6r="assets/Copilot-App-Icon.png",W6r="Trial",V6r=["GitHub.copilot-chat","GitHub.copilot"],z6r={vscode:"^1.103.0",node:">=22.0.0",npm:">=9.0.0"},K6r=["AI","Chat","Programming Languages","Machine Learning"],Y6r=["ai","openai","codex","pilot","snippets","documentation","autocomplete","intellisense","refactor","javascript","python","typescript","php","go","golang","ruby","c++","c#","java","kotlin","co-pilot"],J6r=[{url:"https://img.shields.io/badge/GitHub%20Copilot-Subscription%20Required-orange",href:"https://github.com/github-copilot/signup?editor=vscode",description:"Sign up for GitHub Copilot"},{url:"https://img.shields.io/github/stars/github/copilot-docs?style=social",href:"https://github.com/github/copilot-docs",description:"Star Copilot on GitHub"},{url:"https://img.shields.io/youtube/channel/views/UC7c3Kb6jYCRj4JOHHZTxKsQ?style=social",href:"https://www.youtube.com/@GitHub/search?query=copilot",description:"Check out GitHub on Youtube"},{url:"https://img.shields.io/twitter/follow/github?style=social",href:"https://twitter.com/github",description:"Follow GitHub on Twitter"}],X6r=["onStartupFinished"],Z6r="./dist/web",e9r="./dist/extension",t9r=["inlineCompletionsAdditions"],fDe={commands:[{command:"github.copilot.toggleStatusMenu",title:"Open Status Menu",category:"GitHub Copilot"},{command:"github.copilot.signIn",title:"Sign In",category:"GitHub Copilot",enablement:"!github.copilot.activated"},{command:"github.copilot.acceptCursorPanelSolution",title:"Accept Panel Suggestion at the Cursor",enablement:"github.copilot.panelVisible",category:"GitHub Copilot"},{command:"github.copilot.previousPanelSolution",title:"Navigate to the Previous Panel Suggestion",enablement:"github.copilot.panelVisible",category:"GitHub Copilot"},{command:"github.copilot.nextPanelSolution",title:"Navigate to the Next Panel Suggestion",enablement:"github.copilot.panelVisible",category:"GitHub Copilot"},{command:"github.copilot.generate",title:"Open Completions Panel",enablement:"github.copilot.activated && !isWeb",category:"GitHub Copilot"},{command:"github.copilot.generateComparison",title:"Open Comparison Panel",enablement:"github.copilot.activated && !isWeb && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.acceptCursorComparisonPanelSolution",title:"Accept Comparison Panel Suggestion at the Cursor",enablement:"github.copilot.comparisonPanelVisible && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.previousComparisonPanelSolution",title:"Navigate to the Previous Comparison Panel Suggestion",enablement:"github.copilot.comparisonPanelVisible && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.nextComparisonPanelSolution",title:"Navigate to the Next Comparison Panel Suggestion",enablement:"github.copilot.comparisonPanelVisible && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.completions.disable",title:"Disable Completions",enablement:"github.copilot.activated && config.editor.inlineSuggest.enabled && github.copilot.completions.enabled",category:"GitHub Copilot"},{command:"github.copilot.completions.enable",title:"Enable Completions",enablement:"github.copilot.activated && !(config.editor.inlineSuggest.enabled && github.copilot.completions.enabled)",category:"GitHub Copilot"},{command:"github.copilot.completions.toggle",title:"Toggle (Enable/Disable) Completions",enablement:"github.copilot.activated",category:"GitHub Copilot"},{command:"github.copilot.sendFeedback",title:"Send Feedback",category:"GitHub Copilot"},{command:"github.copilot.collectDiagnostics",title:"Collect Diagnostics",category:"GitHub Copilot",enablement:"!isWeb"},{command:"github.copilot.openLogs",title:"Open Logs",category:"GitHub Copilot"},{command:"github.copilot.openModelPicker",title:"Change Completions Model",category:"GitHub Copilot",enablement:"!isWeb"},{command:"github.copilot.sendCompletionFeedback",title:"Send Copilot Completion Feedback",category:"GitHub Copilot",enablement:"!isWeb"},{command:"github-copilot-completions-debugger-view.refresh",title:"Refresh",icon:"$(refresh)"}],keybindings:[{command:"github.copilot.acceptCursorPanelSolution",key:"ctrl+/",mac:"ctrl+/",when:"activeWebviewPanelId == 'GitHub Copilot Suggestions'"},{command:"github.copilot.previousPanelSolution",key:"alt+[",mac:"alt+[",when:"activeWebviewPanelId == 'GitHub Copilot Suggestions'"},{command:"github.copilot.nextPanelSolution",key:"alt+]",mac:"alt+]",when:"activeWebviewPanelId == 'GitHub Copilot Suggestions'"},{command:"github.copilot.acceptCursorComparisonPanelSolution",key:"ctrl+shift+/",mac:"ctrl+shift+/",when:"activeWebviewPanelId == 'GitHub Copilot Comparison' && github.copilot.comparisonPanelEnabled"},{command:"github.copilot.previousComparisonPanelSolution",key:"alt+shift+[",mac:"alt+shift+[",when:"activeWebviewPanelId == 'GitHub Copilot Comparison' && github.copilot.comparisonPanelEnabled"},{command:"github.copilot.nextComparisonPanelSolution",key:"alt+shift+]",mac:"alt+shift+]",when:"activeWebviewPanelId == 'GitHub Copilot Comparison' && github.copilot.comparisonPanelEnabled"},{command:"editor.action.inlineSuggest.trigger",key:"alt+\\",when:"editorTextFocus && !editorHasSelection && !inlineSuggestionsVisible"}],configuration:[{title:"GitHub Copilot",properties:{"github.copilot.selectedCompletionModel":{type:"string",default:"",markdownDescription:'The currently selected completion model ID. To select from a list of available models, use the __"Change Completions Model"__ command or open the model picker (from the Copilot menu in the VS Code title bar, select __"Configure Code Completions"__ then __"Change Completions Model"__. The value must be a valid model ID. An empty value indicates that the default model will be used.'},"github.copilot.advanced":{type:"object",title:"Advanced Settings",properties:{authProvider:{type:"string",enum:["github","github-enterprise"],enumDescriptions:["GitHub.com","GitHub Enterprise"],default:"github",description:"The GitHub identity to use for Copilot"},authPermissions:{type:"string",enum:["default","minimal"],markdownEnumDescriptions:["Default (recommended) - The default permissions enable the best that Copilot has to offer including, but not limited to, faster repo indexing and the power of the `@github` agent.","Minimal - The minimal permissions required for Copilot functionality."],default:"default",markdownDescription:"Controls what kind of permissions are asked for when signing in to Copilot. The options are\n* `default` - (strongly recommended) The default permissions enable the best that Copilot has to offer including, but not limited to, faster repo indexing and the power of the `@github` agent.\n* `minimal` - The minimal permissions are the least that Copilot needs to function. Some features may behave slower or not at all."},useLanguageServer:{type:"boolean",default:!1,description:"Experimental: Use language server"},"debug.overrideEngine":{type:"string",default:"",description:"Override engine name"},"debug.overrideProxyUrl":{type:"string",default:"",description:"Override GitHub authentication proxy full URL"},"debug.testOverrideProxyUrl":{type:"string",default:"",description:"Override GitHub authentication proxy URL when running tests"},"debug.overrideCapiUrl":{type:"string",default:"",description:"Override GitHub Copilot API full URL"},"debug.testOverrideCapiUrl":{type:"string",default:"",description:"Override GitHub Copilot API URL when running tests"},"debug.filterLogCategories":{type:"array",default:[],deprecationMessage:"Set overrideLogLevels.* to ERROR to filter out unwanted categories.",description:"Show only log categories listed in this setting. If an array is empty, show all loggers"}}},"github.copilot.enable":{type:"object",scope:"window",default:{"*":!0,plaintext:!1,markdown:!1,scminput:!1},additionalProperties:{type:"boolean"},markdownDescription:"Enable or disable auto triggering of Copilot completions for specified [languages](https://code.visualstudio.com/docs/languages/identifiers). You can still trigger suggestions manually using `Alt + \\`"}}}],configurationDefaults:{"editor.tokenColorCustomizations":{"[*Light*]":{textMateRules:[{scope:"ref.matchtext",settings:{foreground:"#000"}}]},"[*Dark*]":{textMateRules:[{scope:"ref.matchtext",settings:{foreground:"#fff"}}]}}},languages:[{id:"code-referencing"}],grammars:[{language:"code-referencing",scopeName:"text.ref",path:"./syntaxes/ref.tmGrammar.json"}],iconFonts:[{id:"copilot-font",src:[{path:"assets/copilot.woff",format:"woff"}]}],viewsContainers:{activitybar:[{id:"github-copilot-completions-debugger-panel",title:"Debugger",icon:"$(bug)",when:"config.github.copilot.internal.showWorkspaceContextDebugger && config.github.copilot.internal.useWorkspaceContextCoordinator"}]},views:{"github-copilot-completions-debugger-panel":[{id:"github-copilot-completions-debugger-view",name:"Debugger",when:"config.github.copilot.internal.showWorkspaceContextDebugger && config.github.copilot.internal.useWorkspaceContextCoordinator",icon:"$(bug)"}]},menus:{"view/title":[{command:"github-copilot-completions-debugger-view.refresh",when:"view == github-copilot-completions-debugger-view",group:"navigation"}]}},r9r={build:"tsx esbuild.ts",clean:"./script/build/clean.sh",compress:"tsx ./script/compressTokenizer.ts","forbid-sources-content:extension":"node script/forbid-sources-content.js --extension",generate_languages:"tsx script/generateLanguages.ts && prettier --write lib/src/language/generatedLanguages.ts",get_token:"tsx script/deviceFlow.ts --save-as-test-token",lint:'run-p --aggregate-output "lint:*"',"lint:deps":"depcruise -c .dependency-cruiser.js .","lint:eslint":"eslint -f visualstudio --quiet --cache .","lint:prettier":"prettier --check . 2>&1","lint:types":"tsc --noEmit && tsc --noEmit -p extension/src/copilotPanel/webview",prebuild:"npm install",pretest:"npm run build","pretest:headless":"npm run build","pretest:extension":"npm run build","pretest:lsp-client":"npm run build","pretest:lib-e2e":"npm run build",prewatch:"npm run build","prewatch:esbuild":"npm run build",start:"npm run watch",test:'npm-run-all "test:extension --ignore-scripts" "test:headless --ignore-scripts" lint',"test:headless":'npm-run-all test:lib test:agent "test:lib-e2e --ignore-scripts" test:prompt "test:lsp-client --ignore-scripts" lint',"test:agent":'mocha "agent/src/**/*.test.{ts,tsx}"',"test:extension":"tsx extension/test/runTest.ts","test:lib":'mocha "lib/src/**/*.test.{ts,tsx}"',"test:lib-e2e":'mocha "lib/e2e/src/**/*.test.{ts,tsx}" --exclude "lib/e2e/src/prompt/**/*.test.ts"',"test:lib-e2e-no-ci":'mocha "lib/e2e/no-ci/**/*.test.{ts,tsx}"',"test:lib-prompt-e2e":'mocha "lib/e2e/src/prompt/prompt.test.ts"',"test:lib-prompt-e2e-perf":"INCLUDE_PERFORMANCE=true npm run test:lib-prompt-e2e","test:lsp-client":'mocha "lsp-client/test/*.test.{ts,tsx}"',"test:prompt":'mocha "prompt/test/**/*.test.{ts,tsx}"',"test:prepare-msbench":"tsx script/setupMsbench.ts","test:run-msbench":"tsx lsp-client/test/msbench/agent/index.ts","vscode-dts":"vscode-dts dev && mv vscode.proposed.*.ts extension/src","vscode:prepublish":'run-s "build --ignore-scripts" forbid-sources-content:extension',"vscode:uninstall":"node dist/extensionUninstalled.js",vsix:"vsce package --allow-missing-repository",watch:'run-p "watch:esbuild --ignore-scripts" "watch:types -- --preserveWatchOutput"',"watch:esbuild":"tsx esbuild.ts --watch","watch:types":"tsc --noEmit --watch"},n9r={"@azure/identity":"^4.11.0","@azure/keyvault-secrets":"^4.10.0","@datadog/datadog-ci":"^3.17.0","@github/prettier-config":"0.0.6","@limegrass/eslint-plugin-import-alias":"^1.5.1","@parcel/watcher":"^2.5.1","@types/benchmark":"^2.1.5","@types/crypto-js":"^4.2.2","@types/diff":"^8.0.0","@types/git-url-parse":"^16.0.0","@types/js-yaml":"^4.0.6","@types/kerberos":"^1.1.2","@types/markdown-it":"^14.1.2","@types/mocha":"^10.0.10","@types/node":"~22.7.0","@types/semver":"^7.7.0","@types/sinon":"^17.0.4","@types/uuid":"^10.0.0","@types/vscode":"1.103.0","@types/yargs":"^17.0.24","@vscode/test-electron":"^2.5.2","@vscode/tree-sitter-wasm":"0.0.5-php.2","@vscode/vsce":"^3.6.0","@yao-pkg/pkg":"^6.8.0",benchmark:"^2.1.4",boxen:"^8.0.1",chalk:"^5.4.1","dependency-cruiser":"^17.0.1",electron:"^37.5.1",esbuild:"^0.25.8","esbuild-plugin-copy":"^2.1.1",eslint:"^9.32.0","eslint-formatter-visualstudio":"^8.40.0","eslint-plugin-mocha":"^10.5.0",glob:"^11.0.3",globals:"^16.3.0","js-yaml":"^4.1.0",mocha:"^11.2.2","mocha-junit-reporter":"^2.2.1","mocha-multi-reporters":"^1.5.1","npm-run-all":"^4.1.5",prettier:"^3.5.3","prettier-plugin-organize-imports":"^4.2.0",proxy:"^2.1.1","simple-git":"^3.28.0",sinon:"^20.0.0","ts-dedent":"^2.2.0",tsx:"^4.19.4",typescript:"^5.9.2","typescript-eslint":"^8.39.1","vscode-dts":"^0.3.3"},i9r={"@adobe/helix-fetch":"github:devm33/helix-fetch#2a08fa939591a0e14f34f611adcc3ed767579e9a","@anthropic-ai/sdk":"^0.56.0","@github/memoize":"1.1.5","@microsoft/1ds-post-js":"^4.3.9","@microsoft/applicationinsights-web-basic":"^3.3.6","@microsoft/tiktokenizer":"^1.0.10","@modelcontextprotocol/sdk":"^1.17.0","@octokit/graphql":"^8.0.1","@octokit/rest":"^22.0.0","@sinclair/typebox":"^0.34.33","@types/vscode-webview":"^1.57.4","@vscode/chat-lib":"^0.0.4","@vscode/codicons":"^0.0.39","@vscode/policy-watcher":"^1.3.2","@vscode/prompt-tsx":"0.4.0-alpha.1","@vscode/webview-ui-toolkit":"^1.3.1","await-lock":"^2.2.2","crypto-js":"^4.2.0",diff:"^8.0.2",dldr:"^0.0.10",events:"^3.3.0","get-stream":"^6.0.1","git-url-parse":"^16.0.3",kerberos:"^2.2.0","mac-ca":"^3.1.3","markdown-it":"^14.1.0",microjob:"^0.7.0",minimatch:"^9.0.3",open:"^10.2.0","os-browserify":"^0.3.0","path-browserify":"^1.0.1",semver:"^7.7.1",shiki:"~1.15.0","source-map-support":"^0.5.21",sqlite3:"^5.1.7",undici:"^7.16.0",uuid:"^11.1.0","vscode-languageclient":"^9.0.0","vscode-languageserver":"^9.0.0","vscode-languageserver-protocol":"^3.17","vscode-languageserver-textdocument":"~1.0.11","vscode-uri":"^3.1.0","web-tree-sitter":"^0.23.0","windows-ca-certs":"^0.2.2",yargs:"^17.7.2"},o9r={fsevents:"<0",bindings:"npm:bundled-bindings@^1.5.0"},s9r={name:N6r,displayName:L6r,description:M6r,version:B6r,build:O6r,buildType:F6r,publisher:U6r,preview:Q6r,homepage:q6r,license:j6r,bugs:$6r,qna:G6r,icon:H6r,pricing:W6r,extensionPack:V6r,engines:z6r,categories:K6r,keywords:Y6r,badges:J6r,activationEvents:X6r,browser:Z6r,main:e9r,enabledApiProposals:t9r,contributes:fDe,scripts:r9r,devDependencies:n9r,dependencies:i9r,overrides:o9r};var xt={Enable:"enable",UserSelectedCompletionModel:"selectedCompletionModel",ShowEditorCompletions:"editor.showEditorCompletions",EnableAutoCompletions:"editor.enableAutoCompletions",DelayCompletions:"editor.delayCompletions",FilterCompletions:"editor.filterCompletions",FetchStrategy:"fetchStrategy",ToolConfirmAutoApprove:"agent.toolConfirmAutoApprove",TrustToolAnnotations:"agent.trustToolAnnotations",MaxToolCallingLoop:"agent.maxToolCallingLoop",CompletionsDelay:"completionsDelay",CompletionsDebounce:"completionsDebounce",RelatedFilesVSCodeCSharp:"advanced.relatedFilesVSCodeCSharp",RelatedFilesVSCodeTypeScript:"advanced.relatedFilesVSCodeTypeScript",RelatedFilesVSCode:"advanced.relatedFilesVSCode",ContextProviders:"advanced.contextProviders",DebugOverrideLogLevels:"advanced.debug.overrideLogLevels",DebugFilterLogCategories:"advanced.debug.filterLogCategories",DebugSnippyOverrideUrl:"advanced.debug.codeRefOverrideUrl",DebugUseElectronFetcher:"advanced.debug.useElectronFetcher",DebugUseEditorFetcher:"advanced.debug.useEditorFetcher",UseSubsetMatching:"advanced.useSubsetMatching",ContextProviderTimeBudget:"advanced.contextProviderTimeBudget",DebugOverrideCapiUrl:"internal.capiUrl",DebugOverrideCapiUrlLegacy:"advanced.debug.overrideCapiUrl",DebugTestOverrideCapiUrl:"internal.capiTestUrl",DebugTestOverrideCapiUrlLegacy:"advanced.debug.testOverrideCapiUrl",DebugOverrideProxyUrl:"internal.completionsUrl",DebugOverrideProxyUrlLegacy:"advanced.debug.overrideProxyUrl",DebugTestOverrideProxyUrl:"internal.completionsTestUrl",DebugTestOverrideProxyUrlLegacy:"advanced.debug.testOverrideProxyUrl",DebugOverrideEngine:"internal.completionModel",DebugOverrideEngineLegacy:"advanced.debug.overrideEngine",AlwaysRequestMultiline:"internal.alwaysRequestMultiline",ModelAlwaysTerminatesSingleline:"internal.modelAlwaysTerminatesSingleline",TrimCompletionsAggressively:"internal.trimCompletionsAggressively",UseWorkspaceContextCoordinator:"internal.useWorkspaceContextCoordinator",ShowWorkspaceContextDebugger:"internal.showWorkspaceContextDebugger",IncludeNeighboringFiles:"internal.includeNeighboringFiles",ExcludeRelatedFiles:"internal.excludeRelatedFiles",DebugOverrideCppHeadersEnableSwitch:"internal.cppHeadersEnableSwitch",NESXTab:"internal.useXTab",UseSplitContextPrompt:"internal.useSplitContextPrompt",UseCompletionsComparisonPanel:"internal.useCompletionsComparisonPanel",ComparisonPanelModelIds:"internal.comparisonPanelModelIds",ComparisonPanelRandomizedMode:"internal.comparisonPanelRandomizedMode",UseFetchFetcher:"internal.useFetchFetcher"};function Nxt(t){return["server","parsingandserver"].includes(t)}a(Nxt,"shouldDoServerTrimming");var j1=class{static{a(this,"BlockModeConfig")}},GL=class extends j1{static{a(this,"ConfigBlockModeConfig")}forLanguage(e,r,n){let o=e.get(vt).overrideBlockMode(n);if(o)return pDe(o,r);let s=e.get(vt).enableProgressiveReveal(n);return(Ai(e,xt.AlwaysRequestMultiline)??s)||hC.isTrimmedByDefault(r)?pDe("moremultiline",r):r=="ruby"?"parsing":Wm(r)?"parsingandserver":"server"}};function a9r(t){return["parsing","parsingandserver","moremultiline"].includes(t)}a(a9r,"blockModeRequiresTreeSitter");function pDe(t,e){return t==="moremultiline"&&ru.isSupported(e)?t:a9r(t)&&!Wm(e)?"server":t}a(pDe,"toApplicableBlockMode");var Ma=class{static{a(this,"ConfigProvider")}requireReady(){return Promise.resolve()}},HL=class extends Ma{constructor(){super(...arguments);this.onDidChangeCopilotSettings=a(()=>({dispose:a(()=>{},"dispose")}),"onDidChangeCopilotSettings");this.onDidChangeHttpSettings=this.onDidChangeCopilotSettings}static{a(this,"DefaultsOnlyConfigProvider")}getConfig(r){return l9r(r)}getOptionalConfig(r){return u9r(r)}dumpForTelemetry(){return{}}getHttpSettings(){return{proxy:""}}},aP=class extends Ma{constructor(r,n){super();this.baseConfigProvider=r;this.overrides=n;this.copilotEmitter=new Yn;this.onDidChangeCopilotSettings=this.copilotEmitter.event;this.didChangeHttpSettingsEmitter=new Yn;this.onDidChangeHttpSettings=this.didChangeHttpSettingsEmitter.event;this.httpSettings=this.baseConfigProvider.getHttpSettings()}static{a(this,"InMemoryConfigProvider")}getOptionalOverride(r){return this.overrides.get(r)}getConfig(r){return this.getOptionalOverride(r)??this.baseConfigProvider.getConfig(r)}getOptionalConfig(r){return this.getOptionalOverride(r)??this.baseConfigProvider.getOptionalConfig(r)}setConfig(r,n){this.setCopilotSettings({[r]:n})}setCopilotSettings(r){for(let[n,o]of Object.entries(r))o!==void 0?this.overrides.set(n,o):this.overrides.delete(n);this.copilotEmitter.fire(this)}getHttpSettings(){return this.httpSettings}setHttpSettings(r){let n=xG(r);this.httpSettings=n,this.didChangeHttpSettingsEmitter.fire(this.getHttpSettings())}dumpForTelemetry(){let r=this.baseConfigProvider.dumpForTelemetry();for(let n of[xt.ShowEditorCompletions,xt.EnableAutoCompletions,xt.DelayCompletions,xt.FilterCompletions]){let o=this.overrides.get(n);o!==void 0&&(r[n]=JSON.stringify(o))}return r}};function c9r(t){return t?.type==="object"&&"properties"in t}a(c9r,"isContributesObject");function Lxt(t,e){let r=t,n=[];for(let o of e.split(".")){let s=[...n,o].join(".");r&&typeof r=="object"&&s in r?(r=r[s],n.length=0):n.push(o)}if(!(r===void 0||n.length>0))return r}a(Lxt,"getConfigKeyRecursively");function l9r(t){if($L.has(t))return $L.get(t);throw new Error(`Missing config default value: ${TQ}.${t}`)}a(l9r,"getConfigDefaultForKey");function u9r(t){return $L.get(t)}a(u9r,"getOptionalConfigDefaultForKey");var $L=new Map([[xt.DebugOverrideCppHeadersEnableSwitch,!1],[xt.RelatedFilesVSCodeCSharp,!1],[xt.RelatedFilesVSCodeTypeScript,!1],[xt.RelatedFilesVSCode,!1],[xt.IncludeNeighboringFiles,!1],[xt.ExcludeRelatedFiles,!1],[xt.ContextProviders,[]],[xt.DebugUseEditorFetcher,null],[xt.DebugUseElectronFetcher,null],[xt.DebugOverrideLogLevels,{}],[xt.DebugSnippyOverrideUrl,""],[xt.FetchStrategy,"auto"],[xt.ToolConfirmAutoApprove,!1],[xt.TrustToolAnnotations,!1],[xt.MaxToolCallingLoop,25],[xt.UseSubsetMatching,null],[xt.ContextProviderTimeBudget,void 0],[xt.DebugOverrideCapiUrl,""],[xt.DebugTestOverrideCapiUrl,""],[xt.DebugOverrideProxyUrl,""],[xt.DebugTestOverrideProxyUrl,""],[xt.DebugOverrideEngine,""],[xt.AlwaysRequestMultiline,void 0],[xt.ModelAlwaysTerminatesSingleline,void 0],[xt.TrimCompletionsAggressively,void 0],[xt.CompletionsDebounce,void 0],[xt.NESXTab,void 0],[xt.UseWorkspaceContextCoordinator,void 0],[xt.ShowWorkspaceContextDebugger,!1],[xt.CompletionsDelay,void 0],[xt.UseSplitContextPrompt,void 0],[xt.UseCompletionsComparisonPanel,void 0],[xt.ComparisonPanelModelIds,void 0],[xt.ComparisonPanelRandomizedMode,void 0],[xt.UseFetchFetcher,void 0],[xt.ShowEditorCompletions,void 0],[xt.EnableAutoCompletions,void 0],[xt.DelayCompletions,void 0],[xt.FilterCompletions,void 0]]);for(let t of Object.values(xt)){let e=fDe.configuration[0],r=[],n=`${TQ}.${t}`.split(".");for(;n.length>0;){r.push(n.shift());let o=e.properties[r.join(".")];if(c9r(o))r.length=0,e=o;else if(n.length==0&&o?.default!==void 0){if($L.has(t))throw new Error(`Duplicate config default value ${TQ}.${t}`);$L.set(t,o.default)}}if(!$L.has(t))throw new Error(`Missing config default value ${TQ}.${t}`)}function Ai(t,e){return t.get(Ma).getConfig(e)}a(Ai,"getConfig");function Tft(t){return t.get(Ma).dumpForTelemetry()}a(Tft,"dumpForTelemetry");var yi=class{constructor(){this.packageJson=dDe}static{a(this,"BuildInfo")}isPreRelease(){return this.getBuildType()==="nightly"}isProduction(){return this.getBuildType()!=="dev"}getBuildType(){return this.packageJson.buildType}getVersion(){return this.packageJson.version}getDisplayVersion(){return this.getBuildType()==="dev"?`${this.getVersion()}-dev`:this.getVersion()}getBuild(){return this.packageJson.build}getName(){return this.packageJson.name}};function ATe(t){return t.get(yi).isProduction()}a(ATe,"isProduction");function M9(t){return t.get(yi).getBuildType()==="dev"}a(M9,"isDevBuild");function wb(t){return t.get(yi).getBuildType()}a(wb,"getBuildType");function Ift(t){return t.get(yi).getBuild()}a(Ift,"getBuild");function m5(t){return t.get(yi).getVersion()}a(m5,"getVersion");var ls=class{constructor(e,r,n="none",o="desktop"){this.sessionId=e;this.machineId=r;this.remoteName=n;this.uiKind=o}static{a(this,"EditorSession")}};function sm({name:t,version:e}){return`${t}/${e}`}a(sm,"formatNameAndVersion");var Cr=class{static{a(this,"EditorAndPluginInfo")}getCopilotIntegrationId(){}getEditorPluginSpecificFilters(){return[]}},BL="2025-05-01";function om(t){let e=t.get(Cr);return{"Editor-Version":sm(e.getEditorInfo()),"Editor-Plugin-Version":sm(e.getEditorPluginInfo()),"Copilot-Language-Server-Version":m5(t)}}a(om,"editorVersionHeaders");var ag="Iv1.b507a08c87ecfe98",Mxt="350ee525b5da0e4a54c6e8e043edc1b99cc02f19",zl=class{static{a(this,"GitHubAppInfo")}findAppIdToAuthenticate(){return this.githubAppId??ag}};var Kt=class{static{a(this,"Fetcher")}getImplementation(){return this}};function GE(t,e,r,n,o,s,c,l,u,d){let p={...l,Authorization:`Bearer ${r}`,...om(t)};d===void 0&&(p["Openai-Organization"]="github-copilot",p["X-Request-Id"]=o,p["VScode-SessionId"]=t.get(ls).sessionId,p["VScode-MachineId"]=t.get(ls).machineId,p["X-GitHub-Api-Version"]=BL),n&&(p["OpenAI-Intent"]=n);let h={method:"POST",headers:p,json:s,timeout:u},m=t.get(Kt);if(c){let A=new AbortController;c.onCancellationRequested(()=>{tt(t,"networking.cancelRequest",sr.createAndMarkAsIssued({headerRequestId:o})),A.abort()}),h.signal=A.signal}return m.fetch(e,h).catch(A=>{if(d9r(A))return tt(t,"networking.disconnectAll"),m.disconnectAll().then(()=>m.fetch(e,h));throw A})}a(GE,"postRequest");function d9r(t){return t instanceof Error?t.message=="ERR_HTTP2_GOAWAY_SESSION"?!0:"code"in t?t.code=="ECONNRESET"||t.code=="ETIMEDOUT"||t.code=="ERR_HTTP2_INVALID_SESSION":!1:!1}a(d9r,"isInterruptedNetworkError");var f9r=new Set(["ERR_WORKER_OUT_OF_MEMORY","ENOMEM"]);function p9r(t){return f9r.has(t.code??"")||t.name==="RangeError"&&t.message==="WebAssembly.Memory(): could not allocate memory"}a(p9r,"isOomError");function YI(t,e,r,n=hr){if(!wd(e)){if(e instanceof Error){let o=e;p9r(o)?t.get(ro).setWarning("Out of memory"):o.code==="EMFILE"||o.code==="ENFILE"?t.get(ro).setWarning("Too many open files"):o.code==="CopilotPromptLoadFailure"?t.get(ro).setWarning("Corrupted Copilot installation"):`${o.code}`.startsWith("CopilotPromptWorkerExit")?t.get(ro).setWarning("Worker unexpectedly exited"):o.syscall==="uv_cwd"&&o.code==="ENOENT"&&t.get(ro).setWarning("Current working directory does not exist")}n.exception(t,e,r)}}a(YI,"handleException");function Bxt(t){process.addListener("uncaughtException",r=>{YI(t,r,"uncaughtException")});let e=!1;process.addListener("unhandledRejection",r=>{if(!e)try{e=!0,YI(t,r,"unhandledRejection")}finally{e=!1}})}a(Bxt,"registerDefaultHandlers");async function Oxt(t){try{await lG}catch(e){YI(t,e,"initializeTokenizers")}}a(Oxt,"waitForTokenizers");f();var JI=require("fs"),Fxt=require("os"),Uxt=ye(require("path")),WL=require("process");var In=class{static{a(this,"PersistenceManager")}},hDe=class extends In{constructor(r){super();this.directory=r}static{a(this,"FilePersistenceManager")}async read(r,n){try{return(await this.readJsonObject(r))[n]}catch{return}}async update(r,n,o){await JI.promises.mkdir(this.directory,{recursive:!0,mode:448});let s=`${this.directory}/${r}.json`,c;try{c=await EG.acquire(s);let l=await this.readJsonObject(r);l[n]=o,await JI.promises.writeFile(s,JSON.stringify(l)+`
|
|
1113
|
+
] @statement`}};var hC=class{constructor(e,r,n){this.languageId=e;this.prefix=r;this.completion=n}static{a(this,"BlockTrimmer")}static isSupported(e){return ru.isSupported(e)}static isTrimmedByDefault(e){return ru.isTrimmedByDefault(e)}async withParsedStatementTree(e){var n=[];try{let r=Qwe(n,ru.create(this.languageId,this.prefix+this.completion,this.prefix.length,this.prefix.length+this.completion.length));await r.build();return await e(r)}catch(o){var s=o,c=!0}finally{qwe(n,s,c)}}trimmedCompletion(e){return e===void 0?this.completion:this.completion.substring(0,e)}getStatementAtCursor(e){return e.statementAt(Math.max(this.prefix.length-1,0))??e.statements[0]}getContainingBlockOffset(e){let r;if(e&&this.isCompoundStatement(e))r=e;else if(e){let n=e.parent;for(;n&&!this.isCompoundStatement(n);)n=n.parent;r=n}if(r){let n=this.asCompletionOffset(r.node.endIndex);if(n&&this.completion.substring(n).trim()!=="")return n}}hasNonStatementContentAfter(e){if(!e||!e.nextSibling)return!1;let r=this.asCompletionOffset(e.node.endIndex),n=this.asCompletionOffset(e.nextSibling.node.startIndex);return this.completion.substring(Math.max(0,r??0),Math.max(0,n??0)).trim()!==""}asCompletionOffset(e){return e===void 0?void 0:e-this.prefix.length}isCompoundStatement(e){return e.isCompoundStatementType||e.children.length>0}};var use=class extends hC{constructor(r,n,o,s=3,c=7){super(r,n,o);this.lineLimit=s;this.lookAhead=c;let l=[...this.completion.matchAll(/\n/g)],u=this.lineLimit+this.lookAhead;l.length>=this.lineLimit&&this.lineLimit>0&&(this.limitOffset=l[this.lineLimit-1].index),l.length>=u&&u>0&&(this.lookAheadOffset=l[u-1].index)}static{a(this,"TerseBlockTrimmer")}async getCompletionTrimOffset(){return await this.withParsedStatementTree(r=>{let n=r.statementAt(this.stmtStartPos()),o=this.getContainingBlockOffset(n);return o=this.trimAtFirstBlankLine(o),n&&(o=this.trimAtStatementChange(n,o)),this.limitOffset&&this.lookAheadOffset&&(o===void 0||o>this.lookAheadOffset)?this.limitOffset:o})}stmtStartPos(){let r=this.completion.match(/\S/);return r&&r.index!==void 0?this.prefix.length+r.index:Math.max(this.prefix.length-1,0)}trimAtFirstBlankLine(r){let n=[...this.trimmedCompletion(r).matchAll(/\r?\n\s*\r?\n/g)];for(;n.length>0&&(r===void 0||r>n[0].index);){let o=n.shift();if(this.completion.substring(0,o.index).trim()!=="")return o.index}return r}trimAtStatementChange(r,n){let o=this.prefix.length,s=this.prefix.length+(n??this.completion.length);if(r.node.endIndex>o&&this.isCompoundStatement(r))return r.nextSibling&&r.node.endIndex<s?this.asCompletionOffset(r.node.endIndex):n;let c=r,l=r.nextSibling;for(;l&&l.node.endIndex<=s&&!this.hasNonStatementContentAfter(c)&&!this.isCompoundStatement(l);)c=l,l=l.nextSibling;return l&&c.node.endIndex>o&&c.node.endIndex<s?this.asCompletionOffset(c.node.endIndex):n}};async function kxt(t,e){var l=[];try{let r=t.getText();let n=t.offsetAt(e);let o=Qwe(l,ru.create(t.detectedLanguageId,r,0,r.length));await o.build();let s=o.statementAt(n);if(!s)return"non-block";if(!s.isCompoundStatementType&&s.children.length===0)return s.parent&&!s.nextSibling&&s.node.endPosition.row<=e.line?"block-end":s.parent?"mid-block":"non-block";if(s.children.length===0)return"empty-block";let c=s.children[s.children.length-1];if(n<c.node.startIndex)return"mid-block";return"block-end"}catch(u){var d=u,p=!0}finally{qwe(l,d,p)}}a(kxt,"getBlockPositionType");f();function k6r(t){return t.HTTPS_PROXY||t.https_proxy||t.HTTP_PROXY||t.http_proxy}a(k6r,"getProxyFromEnvironment");function P6r(t){return t.NODE_TLS_REJECT_UNAUTHORIZED!=="0"}a(P6r,"getRejectUnauthorizedFromEnvironment");var Pxt=E.Object({proxy:E.Optional(E.String()),proxyStrictSSL:E.Optional(E.Boolean()),proxyAuthorization:E.Optional(E.String()),proxyKerberosServicePrincipal:E.Optional(E.String()),noProxy:E.Optional(E.Array(E.String()))});function Dxt(t){let e=k6r(t),r=xG({proxy:e,proxyStrictSSL:P6r(t)}),n=t.GH_COPILOT_KERBEROS_SERVICE_PRINCIPAL??t.GITHUB_COPILOT_KERBEROS_SERVICE_PRINCIPAL??t.AGENT_KERBEROS_SERVICE_PRINCIPAL;return n&&(r.proxyKerberosServicePrincipal=n),r}a(Dxt,"getHttpSettingsFromEnvironment");function xG(t){if(!t.proxy)return{...t,proxy:""};try{let{protocol:e,host:r,username:n,password:o,pathname:s,search:c,hash:l}=new URL(t.proxy);return{...t,proxy:`${e}//${r}${s}${c}${l}`,proxyAuthorization:t.proxyAuthorization||D6r(n,o),noProxy:t.noProxy||[]}}catch{return{...t,proxy:""}}}a(xG,"normalizeHttpSettings");function D6r(t,e){return!t||!e?"":`${decodeURIComponent(t)}:${decodeURIComponent(e)}`}a(D6r,"getAuth");var dDe={};bo(dDe,{activationEvents:()=>X6r,badges:()=>J6r,browser:()=>Z6r,bugs:()=>$6r,build:()=>O6r,buildType:()=>F6r,categories:()=>K6r,contributes:()=>fDe,default:()=>s9r,dependencies:()=>i9r,description:()=>M6r,devDependencies:()=>n9r,displayName:()=>L6r,enabledApiProposals:()=>t9r,engines:()=>z6r,extensionPack:()=>V6r,homepage:()=>q6r,icon:()=>H6r,keywords:()=>Y6r,license:()=>j6r,main:()=>e9r,name:()=>N6r,overrides:()=>o9r,preview:()=>Q6r,pricing:()=>W6r,publisher:()=>U6r,qna:()=>G6r,scripts:()=>r9r,version:()=>B6r});var N6r="copilot",L6r="GitHub Copilot",M6r="Your AI pair programmer",B6r="1.384.0",O6r="1812",F6r="prod",U6r="GitHub",Q6r=!1,q6r="https://github.com/features/copilot?editor=vscode",j6r="https://docs.github.com/en/site-policy/github-terms/github-terms-for-additional-products-and-features",$6r={url:"https://github.com/microsoft/vscode/issues"},G6r="https://github.com/github-community/community/discussions/categories/copilot",H6r="assets/Copilot-App-Icon.png",W6r="Trial",V6r=["GitHub.copilot-chat","GitHub.copilot"],z6r={vscode:"^1.103.0",node:">=22.0.0",npm:">=9.0.0"},K6r=["AI","Chat","Programming Languages","Machine Learning"],Y6r=["ai","openai","codex","pilot","snippets","documentation","autocomplete","intellisense","refactor","javascript","python","typescript","php","go","golang","ruby","c++","c#","java","kotlin","co-pilot"],J6r=[{url:"https://img.shields.io/badge/GitHub%20Copilot-Subscription%20Required-orange",href:"https://github.com/github-copilot/signup?editor=vscode",description:"Sign up for GitHub Copilot"},{url:"https://img.shields.io/github/stars/github/copilot-docs?style=social",href:"https://github.com/github/copilot-docs",description:"Star Copilot on GitHub"},{url:"https://img.shields.io/youtube/channel/views/UC7c3Kb6jYCRj4JOHHZTxKsQ?style=social",href:"https://www.youtube.com/@GitHub/search?query=copilot",description:"Check out GitHub on Youtube"},{url:"https://img.shields.io/twitter/follow/github?style=social",href:"https://twitter.com/github",description:"Follow GitHub on Twitter"}],X6r=["onStartupFinished"],Z6r="./dist/web",e9r="./dist/extension",t9r=["inlineCompletionsAdditions"],fDe={commands:[{command:"github.copilot.toggleStatusMenu",title:"Open Status Menu",category:"GitHub Copilot"},{command:"github.copilot.signIn",title:"Sign In",category:"GitHub Copilot",enablement:"!github.copilot.activated"},{command:"github.copilot.acceptCursorPanelSolution",title:"Accept Panel Suggestion at the Cursor",enablement:"github.copilot.panelVisible",category:"GitHub Copilot"},{command:"github.copilot.previousPanelSolution",title:"Navigate to the Previous Panel Suggestion",enablement:"github.copilot.panelVisible",category:"GitHub Copilot"},{command:"github.copilot.nextPanelSolution",title:"Navigate to the Next Panel Suggestion",enablement:"github.copilot.panelVisible",category:"GitHub Copilot"},{command:"github.copilot.generate",title:"Open Completions Panel",enablement:"github.copilot.activated && !isWeb",category:"GitHub Copilot"},{command:"github.copilot.generateComparison",title:"Open Comparison Panel",enablement:"github.copilot.activated && !isWeb && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.acceptCursorComparisonPanelSolution",title:"Accept Comparison Panel Suggestion at the Cursor",enablement:"github.copilot.comparisonPanelVisible && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.previousComparisonPanelSolution",title:"Navigate to the Previous Comparison Panel Suggestion",enablement:"github.copilot.comparisonPanelVisible && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.nextComparisonPanelSolution",title:"Navigate to the Next Comparison Panel Suggestion",enablement:"github.copilot.comparisonPanelVisible && github.copilot.comparisonPanelEnabled",category:"GitHub Copilot"},{command:"github.copilot.completions.disable",title:"Disable Completions",enablement:"github.copilot.activated && config.editor.inlineSuggest.enabled && github.copilot.completions.enabled",category:"GitHub Copilot"},{command:"github.copilot.completions.enable",title:"Enable Completions",enablement:"github.copilot.activated && !(config.editor.inlineSuggest.enabled && github.copilot.completions.enabled)",category:"GitHub Copilot"},{command:"github.copilot.completions.toggle",title:"Toggle (Enable/Disable) Completions",enablement:"github.copilot.activated",category:"GitHub Copilot"},{command:"github.copilot.sendFeedback",title:"Send Feedback",category:"GitHub Copilot"},{command:"github.copilot.collectDiagnostics",title:"Collect Diagnostics",category:"GitHub Copilot",enablement:"!isWeb"},{command:"github.copilot.openLogs",title:"Open Logs",category:"GitHub Copilot"},{command:"github.copilot.openModelPicker",title:"Change Completions Model",category:"GitHub Copilot",enablement:"!isWeb"},{command:"github.copilot.sendCompletionFeedback",title:"Send Copilot Completion Feedback",category:"GitHub Copilot",enablement:"!isWeb"},{command:"github-copilot-completions-debugger-view.refresh",title:"Refresh",icon:"$(refresh)"}],keybindings:[{command:"github.copilot.acceptCursorPanelSolution",key:"ctrl+/",mac:"ctrl+/",when:"activeWebviewPanelId == 'GitHub Copilot Suggestions'"},{command:"github.copilot.previousPanelSolution",key:"alt+[",mac:"alt+[",when:"activeWebviewPanelId == 'GitHub Copilot Suggestions'"},{command:"github.copilot.nextPanelSolution",key:"alt+]",mac:"alt+]",when:"activeWebviewPanelId == 'GitHub Copilot Suggestions'"},{command:"github.copilot.acceptCursorComparisonPanelSolution",key:"ctrl+shift+/",mac:"ctrl+shift+/",when:"activeWebviewPanelId == 'GitHub Copilot Comparison' && github.copilot.comparisonPanelEnabled"},{command:"github.copilot.previousComparisonPanelSolution",key:"alt+shift+[",mac:"alt+shift+[",when:"activeWebviewPanelId == 'GitHub Copilot Comparison' && github.copilot.comparisonPanelEnabled"},{command:"github.copilot.nextComparisonPanelSolution",key:"alt+shift+]",mac:"alt+shift+]",when:"activeWebviewPanelId == 'GitHub Copilot Comparison' && github.copilot.comparisonPanelEnabled"},{command:"editor.action.inlineSuggest.trigger",key:"alt+\\",when:"editorTextFocus && !editorHasSelection && !inlineSuggestionsVisible"}],configuration:[{title:"GitHub Copilot",properties:{"github.copilot.selectedCompletionModel":{type:"string",default:"",markdownDescription:'The currently selected completion model ID. To select from a list of available models, use the __"Change Completions Model"__ command or open the model picker (from the Copilot menu in the VS Code title bar, select __"Configure Code Completions"__ then __"Change Completions Model"__. The value must be a valid model ID. An empty value indicates that the default model will be used.'},"github.copilot.advanced":{type:"object",title:"Advanced Settings",properties:{authProvider:{type:"string",enum:["github","github-enterprise"],enumDescriptions:["GitHub.com","GitHub Enterprise"],default:"github",description:"The GitHub identity to use for Copilot"},authPermissions:{type:"string",enum:["default","minimal"],markdownEnumDescriptions:["Default (recommended) - The default permissions enable the best that Copilot has to offer including, but not limited to, faster repo indexing and the power of the `@github` agent.","Minimal - The minimal permissions required for Copilot functionality."],default:"default",markdownDescription:"Controls what kind of permissions are asked for when signing in to Copilot. The options are\n* `default` - (strongly recommended) The default permissions enable the best that Copilot has to offer including, but not limited to, faster repo indexing and the power of the `@github` agent.\n* `minimal` - The minimal permissions are the least that Copilot needs to function. Some features may behave slower or not at all."},useLanguageServer:{type:"boolean",default:!1,description:"Experimental: Use language server"},"debug.overrideEngine":{type:"string",default:"",description:"Override engine name"},"debug.overrideProxyUrl":{type:"string",default:"",description:"Override GitHub authentication proxy full URL"},"debug.testOverrideProxyUrl":{type:"string",default:"",description:"Override GitHub authentication proxy URL when running tests"},"debug.overrideCapiUrl":{type:"string",default:"",description:"Override GitHub Copilot API full URL"},"debug.testOverrideCapiUrl":{type:"string",default:"",description:"Override GitHub Copilot API URL when running tests"},"debug.filterLogCategories":{type:"array",default:[],deprecationMessage:"Set overrideLogLevels.* to ERROR to filter out unwanted categories.",description:"Show only log categories listed in this setting. If an array is empty, show all loggers"}}},"github.copilot.enable":{type:"object",scope:"window",default:{"*":!0,plaintext:!1,markdown:!1,scminput:!1},additionalProperties:{type:"boolean"},markdownDescription:"Enable or disable auto triggering of Copilot completions for specified [languages](https://code.visualstudio.com/docs/languages/identifiers). You can still trigger suggestions manually using `Alt + \\`"}}}],configurationDefaults:{"editor.tokenColorCustomizations":{"[*Light*]":{textMateRules:[{scope:"ref.matchtext",settings:{foreground:"#000"}}]},"[*Dark*]":{textMateRules:[{scope:"ref.matchtext",settings:{foreground:"#fff"}}]}}},languages:[{id:"code-referencing"}],grammars:[{language:"code-referencing",scopeName:"text.ref",path:"./syntaxes/ref.tmGrammar.json"}],iconFonts:[{id:"copilot-font",src:[{path:"assets/copilot.woff",format:"woff"}]}],viewsContainers:{activitybar:[{id:"github-copilot-completions-debugger-panel",title:"Debugger",icon:"$(bug)",when:"config.github.copilot.internal.showWorkspaceContextDebugger && config.github.copilot.internal.useWorkspaceContextCoordinator"}]},views:{"github-copilot-completions-debugger-panel":[{id:"github-copilot-completions-debugger-view",name:"Debugger",when:"config.github.copilot.internal.showWorkspaceContextDebugger && config.github.copilot.internal.useWorkspaceContextCoordinator",icon:"$(bug)"}]},menus:{"view/title":[{command:"github-copilot-completions-debugger-view.refresh",when:"view == github-copilot-completions-debugger-view",group:"navigation"}]}},r9r={build:"tsx esbuild.ts",clean:"./script/build/clean.sh",compress:"tsx ./script/compressTokenizer.ts","forbid-sources-content:extension":"node script/forbid-sources-content.js --extension",generate_languages:"tsx script/generateLanguages.ts && prettier --write lib/src/language/generatedLanguages.ts",get_token:"tsx script/deviceFlow.ts --save-as-test-token",lint:'run-p --aggregate-output "lint:*"',"lint:deps":"depcruise -c .dependency-cruiser.js .","lint:eslint":"eslint -f visualstudio --quiet --cache .","lint:prettier":"prettier --check . 2>&1","lint:types":"tsc --noEmit && tsc --noEmit -p extension/src/copilotPanel/webview",prebuild:"npm install",pretest:"npm run build","pretest:headless":"npm run build","pretest:extension":"npm run build","pretest:lsp-client":"npm run build","pretest:lib-e2e":"npm run build",prewatch:"npm run build","prewatch:esbuild":"npm run build",start:"npm run watch",test:'npm-run-all "test:extension --ignore-scripts" "test:headless --ignore-scripts" lint',"test:headless":'npm-run-all test:lib test:agent "test:lib-e2e --ignore-scripts" test:prompt "test:lsp-client --ignore-scripts" lint',"test:agent":'mocha "agent/src/**/*.test.{ts,tsx}"',"test:extension":"tsx extension/test/runTest.ts","test:lib":'mocha "lib/src/**/*.test.{ts,tsx}"',"test:lib-e2e":'mocha "lib/e2e/src/**/*.test.{ts,tsx}" --exclude "lib/e2e/src/prompt/**/*.test.ts"',"test:lib-e2e-no-ci":'mocha "lib/e2e/no-ci/**/*.test.{ts,tsx}"',"test:lib-prompt-e2e":'mocha "lib/e2e/src/prompt/prompt.test.ts"',"test:lib-prompt-e2e-perf":"INCLUDE_PERFORMANCE=true npm run test:lib-prompt-e2e","test:lsp-client":'mocha "lsp-client/test/*.test.{ts,tsx}"',"test:prompt":'mocha "prompt/test/**/*.test.{ts,tsx}"',"test:prepare-msbench":"tsx script/setupMsbench.ts","test:run-msbench":"tsx lsp-client/test/msbench/agent/index.ts","vscode-dts":"vscode-dts dev && mv vscode.proposed.*.ts extension/src","vscode:prepublish":'run-s "build --ignore-scripts" forbid-sources-content:extension',"vscode:uninstall":"node dist/extensionUninstalled.js",vsix:"vsce package --allow-missing-repository",watch:'run-p "watch:esbuild --ignore-scripts" "watch:types -- --preserveWatchOutput"',"watch:esbuild":"tsx esbuild.ts --watch","watch:types":"tsc --noEmit --watch"},n9r={"@azure/identity":"^4.11.0","@azure/keyvault-secrets":"^4.10.0","@datadog/datadog-ci":"^3.17.0","@github/prettier-config":"0.0.6","@limegrass/eslint-plugin-import-alias":"^1.5.1","@parcel/watcher":"^2.5.1","@types/benchmark":"^2.1.5","@types/crypto-js":"^4.2.2","@types/diff":"^8.0.0","@types/git-url-parse":"^16.0.0","@types/js-yaml":"^4.0.6","@types/kerberos":"^1.1.2","@types/markdown-it":"^14.1.2","@types/mocha":"^10.0.10","@types/node":"~22.7.0","@types/semver":"^7.7.0","@types/sinon":"^17.0.4","@types/uuid":"^10.0.0","@types/vscode":"1.103.0","@types/yargs":"^17.0.24","@vscode/test-electron":"^2.5.2","@vscode/tree-sitter-wasm":"0.0.5-php.2","@vscode/vsce":"^3.6.0","@yao-pkg/pkg":"^6.8.0",benchmark:"^2.1.4",boxen:"^8.0.1",chalk:"^5.4.1","dependency-cruiser":"^17.0.1",electron:"^37.5.1",esbuild:"^0.25.8","esbuild-plugin-copy":"^2.1.1",eslint:"^9.32.0","eslint-formatter-visualstudio":"^8.40.0","eslint-plugin-mocha":"^10.5.0",glob:"^11.0.3",globals:"^16.3.0","js-yaml":"^4.1.0",mocha:"^11.2.2","mocha-junit-reporter":"^2.2.1","mocha-multi-reporters":"^1.5.1","npm-run-all":"^4.1.5",prettier:"^3.5.3","prettier-plugin-organize-imports":"^4.2.0",proxy:"^2.1.1","simple-git":"^3.28.0",sinon:"^20.0.0","ts-dedent":"^2.2.0",tsx:"^4.19.4",typescript:"^5.9.2","typescript-eslint":"^8.39.1","vscode-dts":"^0.3.3"},i9r={"@adobe/helix-fetch":"github:devm33/helix-fetch#2a08fa939591a0e14f34f611adcc3ed767579e9a","@anthropic-ai/sdk":"^0.56.0","@github/memoize":"1.1.5","@microsoft/1ds-post-js":"^4.3.9","@microsoft/applicationinsights-web-basic":"^3.3.6","@microsoft/tiktokenizer":"^1.0.10","@modelcontextprotocol/sdk":"^1.17.0","@octokit/graphql":"^8.0.1","@octokit/rest":"^22.0.0","@sinclair/typebox":"^0.34.33","@types/vscode-webview":"^1.57.4","@vscode/chat-lib":"^0.0.4","@vscode/codicons":"^0.0.39","@vscode/policy-watcher":"^1.3.2","@vscode/prompt-tsx":"0.4.0-alpha.1","@vscode/webview-ui-toolkit":"^1.3.1","await-lock":"^2.2.2","crypto-js":"^4.2.0",diff:"^8.0.2",dldr:"^0.0.10",events:"^3.3.0","get-stream":"^6.0.1","git-url-parse":"^16.0.3",kerberos:"^2.2.0","mac-ca":"^3.1.3","markdown-it":"^14.1.0",microjob:"^0.7.0",minimatch:"^9.0.3",open:"^10.2.0","os-browserify":"^0.3.0","path-browserify":"^1.0.1",semver:"^7.7.1",shiki:"~1.15.0","source-map-support":"^0.5.21",sqlite3:"^5.1.7",undici:"^7.16.0",uuid:"^11.1.0","vscode-languageclient":"^9.0.0","vscode-languageserver":"^9.0.0","vscode-languageserver-protocol":"^3.17","vscode-languageserver-textdocument":"~1.0.11","vscode-uri":"^3.1.0","web-tree-sitter":"^0.23.0","windows-ca-certs":"^0.2.2",yargs:"^17.7.2"},o9r={fsevents:"<0",bindings:"npm:bundled-bindings@^1.5.0"},s9r={name:N6r,displayName:L6r,description:M6r,version:B6r,build:O6r,buildType:F6r,publisher:U6r,preview:Q6r,homepage:q6r,license:j6r,bugs:$6r,qna:G6r,icon:H6r,pricing:W6r,extensionPack:V6r,engines:z6r,categories:K6r,keywords:Y6r,badges:J6r,activationEvents:X6r,browser:Z6r,main:e9r,enabledApiProposals:t9r,contributes:fDe,scripts:r9r,devDependencies:n9r,dependencies:i9r,overrides:o9r};var xt={Enable:"enable",UserSelectedCompletionModel:"selectedCompletionModel",ShowEditorCompletions:"editor.showEditorCompletions",EnableAutoCompletions:"editor.enableAutoCompletions",DelayCompletions:"editor.delayCompletions",FilterCompletions:"editor.filterCompletions",FetchStrategy:"fetchStrategy",ToolConfirmAutoApprove:"agent.toolConfirmAutoApprove",TrustToolAnnotations:"agent.trustToolAnnotations",MaxToolCallingLoop:"agent.maxToolCallingLoop",CompletionsDelay:"completionsDelay",CompletionsDebounce:"completionsDebounce",RelatedFilesVSCodeCSharp:"advanced.relatedFilesVSCodeCSharp",RelatedFilesVSCodeTypeScript:"advanced.relatedFilesVSCodeTypeScript",RelatedFilesVSCode:"advanced.relatedFilesVSCode",ContextProviders:"advanced.contextProviders",DebugOverrideLogLevels:"advanced.debug.overrideLogLevels",DebugFilterLogCategories:"advanced.debug.filterLogCategories",DebugSnippyOverrideUrl:"advanced.debug.codeRefOverrideUrl",DebugUseElectronFetcher:"advanced.debug.useElectronFetcher",DebugUseEditorFetcher:"advanced.debug.useEditorFetcher",UseSubsetMatching:"advanced.useSubsetMatching",ContextProviderTimeBudget:"advanced.contextProviderTimeBudget",DebugOverrideCapiUrl:"internal.capiUrl",DebugOverrideCapiUrlLegacy:"advanced.debug.overrideCapiUrl",DebugTestOverrideCapiUrl:"internal.capiTestUrl",DebugTestOverrideCapiUrlLegacy:"advanced.debug.testOverrideCapiUrl",DebugOverrideProxyUrl:"internal.completionsUrl",DebugOverrideProxyUrlLegacy:"advanced.debug.overrideProxyUrl",DebugTestOverrideProxyUrl:"internal.completionsTestUrl",DebugTestOverrideProxyUrlLegacy:"advanced.debug.testOverrideProxyUrl",DebugOverrideEngine:"internal.completionModel",DebugOverrideEngineLegacy:"advanced.debug.overrideEngine",AlwaysRequestMultiline:"internal.alwaysRequestMultiline",ModelAlwaysTerminatesSingleline:"internal.modelAlwaysTerminatesSingleline",TrimCompletionsAggressively:"internal.trimCompletionsAggressively",UseWorkspaceContextCoordinator:"internal.useWorkspaceContextCoordinator",ShowWorkspaceContextDebugger:"internal.showWorkspaceContextDebugger",IncludeNeighboringFiles:"internal.includeNeighboringFiles",ExcludeRelatedFiles:"internal.excludeRelatedFiles",DebugOverrideCppHeadersEnableSwitch:"internal.cppHeadersEnableSwitch",NESXTab:"internal.useXTab",UseSplitContextPrompt:"internal.useSplitContextPrompt",UseCompletionsComparisonPanel:"internal.useCompletionsComparisonPanel",ComparisonPanelModelIds:"internal.comparisonPanelModelIds",ComparisonPanelRandomizedMode:"internal.comparisonPanelRandomizedMode",UseFetchFetcher:"internal.useFetchFetcher"};function Nxt(t){return["server","parsingandserver"].includes(t)}a(Nxt,"shouldDoServerTrimming");var j1=class{static{a(this,"BlockModeConfig")}},GL=class extends j1{static{a(this,"ConfigBlockModeConfig")}forLanguage(e,r,n){let o=e.get(vt).overrideBlockMode(n);if(o)return pDe(o,r);let s=e.get(vt).enableProgressiveReveal(n);return(Ai(e,xt.AlwaysRequestMultiline)??s)||hC.isTrimmedByDefault(r)?pDe("moremultiline",r):r=="ruby"?"parsing":Wm(r)?"parsingandserver":"server"}};function a9r(t){return["parsing","parsingandserver","moremultiline"].includes(t)}a(a9r,"blockModeRequiresTreeSitter");function pDe(t,e){return t==="moremultiline"&&ru.isSupported(e)?t:a9r(t)&&!Wm(e)?"server":t}a(pDe,"toApplicableBlockMode");var Ma=class{static{a(this,"ConfigProvider")}requireReady(){return Promise.resolve()}},HL=class extends Ma{constructor(){super(...arguments);this.onDidChangeCopilotSettings=a(()=>({dispose:a(()=>{},"dispose")}),"onDidChangeCopilotSettings");this.onDidChangeHttpSettings=this.onDidChangeCopilotSettings}static{a(this,"DefaultsOnlyConfigProvider")}getConfig(r){return l9r(r)}getOptionalConfig(r){return u9r(r)}dumpForTelemetry(){return{}}getHttpSettings(){return{proxy:""}}},aP=class extends Ma{constructor(r,n){super();this.baseConfigProvider=r;this.overrides=n;this.copilotEmitter=new Yn;this.onDidChangeCopilotSettings=this.copilotEmitter.event;this.didChangeHttpSettingsEmitter=new Yn;this.onDidChangeHttpSettings=this.didChangeHttpSettingsEmitter.event;this.httpSettings=this.baseConfigProvider.getHttpSettings()}static{a(this,"InMemoryConfigProvider")}getOptionalOverride(r){return this.overrides.get(r)}getConfig(r){return this.getOptionalOverride(r)??this.baseConfigProvider.getConfig(r)}getOptionalConfig(r){return this.getOptionalOverride(r)??this.baseConfigProvider.getOptionalConfig(r)}setConfig(r,n){this.setCopilotSettings({[r]:n})}setCopilotSettings(r){for(let[n,o]of Object.entries(r))o!==void 0?this.overrides.set(n,o):this.overrides.delete(n);this.copilotEmitter.fire(this)}getHttpSettings(){return this.httpSettings}setHttpSettings(r){let n=xG(r);this.httpSettings=n,this.didChangeHttpSettingsEmitter.fire(this.getHttpSettings())}dumpForTelemetry(){let r=this.baseConfigProvider.dumpForTelemetry();for(let n of[xt.ShowEditorCompletions,xt.EnableAutoCompletions,xt.DelayCompletions,xt.FilterCompletions]){let o=this.overrides.get(n);o!==void 0&&(r[n]=JSON.stringify(o))}return r}};function c9r(t){return t?.type==="object"&&"properties"in t}a(c9r,"isContributesObject");function Lxt(t,e){let r=t,n=[];for(let o of e.split(".")){let s=[...n,o].join(".");r&&typeof r=="object"&&s in r?(r=r[s],n.length=0):n.push(o)}if(!(r===void 0||n.length>0))return r}a(Lxt,"getConfigKeyRecursively");function l9r(t){if($L.has(t))return $L.get(t);throw new Error(`Missing config default value: ${TQ}.${t}`)}a(l9r,"getConfigDefaultForKey");function u9r(t){return $L.get(t)}a(u9r,"getOptionalConfigDefaultForKey");var $L=new Map([[xt.DebugOverrideCppHeadersEnableSwitch,!1],[xt.RelatedFilesVSCodeCSharp,!1],[xt.RelatedFilesVSCodeTypeScript,!1],[xt.RelatedFilesVSCode,!1],[xt.IncludeNeighboringFiles,!1],[xt.ExcludeRelatedFiles,!1],[xt.ContextProviders,[]],[xt.DebugUseEditorFetcher,null],[xt.DebugUseElectronFetcher,null],[xt.DebugOverrideLogLevels,{}],[xt.DebugSnippyOverrideUrl,""],[xt.FetchStrategy,"auto"],[xt.ToolConfirmAutoApprove,!1],[xt.TrustToolAnnotations,!1],[xt.MaxToolCallingLoop,25],[xt.UseSubsetMatching,null],[xt.ContextProviderTimeBudget,void 0],[xt.DebugOverrideCapiUrl,""],[xt.DebugTestOverrideCapiUrl,""],[xt.DebugOverrideProxyUrl,""],[xt.DebugTestOverrideProxyUrl,""],[xt.DebugOverrideEngine,""],[xt.AlwaysRequestMultiline,void 0],[xt.ModelAlwaysTerminatesSingleline,void 0],[xt.TrimCompletionsAggressively,void 0],[xt.CompletionsDebounce,void 0],[xt.NESXTab,void 0],[xt.UseWorkspaceContextCoordinator,void 0],[xt.ShowWorkspaceContextDebugger,!1],[xt.CompletionsDelay,void 0],[xt.UseSplitContextPrompt,void 0],[xt.UseCompletionsComparisonPanel,void 0],[xt.ComparisonPanelModelIds,void 0],[xt.ComparisonPanelRandomizedMode,void 0],[xt.UseFetchFetcher,void 0],[xt.ShowEditorCompletions,void 0],[xt.EnableAutoCompletions,void 0],[xt.DelayCompletions,void 0],[xt.FilterCompletions,void 0]]);for(let t of Object.values(xt)){let e=fDe.configuration[0],r=[],n=`${TQ}.${t}`.split(".");for(;n.length>0;){r.push(n.shift());let o=e.properties[r.join(".")];if(c9r(o))r.length=0,e=o;else if(n.length==0&&o?.default!==void 0){if($L.has(t))throw new Error(`Duplicate config default value ${TQ}.${t}`);$L.set(t,o.default)}}if(!$L.has(t))throw new Error(`Missing config default value ${TQ}.${t}`)}function Ai(t,e){return t.get(Ma).getConfig(e)}a(Ai,"getConfig");function Tft(t){return t.get(Ma).dumpForTelemetry()}a(Tft,"dumpForTelemetry");var yi=class{constructor(){this.packageJson=dDe}static{a(this,"BuildInfo")}isPreRelease(){return this.getBuildType()==="nightly"}isProduction(){return this.getBuildType()!=="dev"}getBuildType(){return this.packageJson.buildType}getVersion(){return this.packageJson.version}getDisplayVersion(){return this.getBuildType()==="dev"?`${this.getVersion()}-dev`:this.getVersion()}getBuild(){return this.packageJson.build}getName(){return this.packageJson.name}};function ATe(t){return t.get(yi).isProduction()}a(ATe,"isProduction");function M9(t){return t.get(yi).getBuildType()==="dev"}a(M9,"isDevBuild");function wb(t){return t.get(yi).getBuildType()}a(wb,"getBuildType");function Ift(t){return t.get(yi).getBuild()}a(Ift,"getBuild");function m5(t){return t.get(yi).getVersion()}a(m5,"getVersion");var ls=class{constructor(e,r,n="none",o="desktop"){this.sessionId=e;this.machineId=r;this.remoteName=n;this.uiKind=o}static{a(this,"EditorSession")}};function sm({name:t,version:e}){return`${t}/${e}`}a(sm,"formatNameAndVersion");var Cr=class{static{a(this,"EditorAndPluginInfo")}getCopilotIntegrationId(){}getEditorPluginSpecificFilters(){return[]}},BL="2025-05-01";function om(t){let e=t.get(Cr);return{"Editor-Version":sm(e.getEditorInfo()),"Editor-Plugin-Version":sm(e.getEditorPluginInfo()),"Copilot-Language-Server-Version":m5(t)}}a(om,"editorVersionHeaders");var ag="Iv1.b507a08c87ecfe98",Mxt="350ee525b5da0e4a54c6e8e043edc1b99cc02f19",zl=class{static{a(this,"GitHubAppInfo")}findAppIdToAuthenticate(){return this.githubAppId??ag}};var Kt=class{static{a(this,"Fetcher")}getImplementation(){return this}};function GE(t,e,r,n,o,s,c,l,u,d){let p={...l,Authorization:`Bearer ${r}`,...om(t)};d===void 0&&(p["Openai-Organization"]="github-copilot",p["X-Request-Id"]=o,p["VScode-SessionId"]=t.get(ls).sessionId,p["VScode-MachineId"]=t.get(ls).machineId,p["X-GitHub-Api-Version"]=BL),n&&(p["OpenAI-Intent"]=n);let h={method:"POST",headers:p,json:s,timeout:u},m=t.get(Kt);if(c){let A=new AbortController;c.onCancellationRequested(()=>{tt(t,"networking.cancelRequest",sr.createAndMarkAsIssued({headerRequestId:o})),A.abort()}),h.signal=A.signal}return m.fetch(e,h).catch(A=>{if(d9r(A))return tt(t,"networking.disconnectAll"),m.disconnectAll().then(()=>m.fetch(e,h));throw A})}a(GE,"postRequest");function d9r(t){return t instanceof Error?t.message=="ERR_HTTP2_GOAWAY_SESSION"?!0:"code"in t?t.code=="ECONNRESET"||t.code=="ETIMEDOUT"||t.code=="ERR_HTTP2_INVALID_SESSION":!1:!1}a(d9r,"isInterruptedNetworkError");var f9r=new Set(["ERR_WORKER_OUT_OF_MEMORY","ENOMEM"]);function p9r(t){return f9r.has(t.code??"")||t.name==="RangeError"&&t.message==="WebAssembly.Memory(): could not allocate memory"}a(p9r,"isOomError");function YI(t,e,r,n=hr){if(!wd(e)){if(e instanceof Error){let o=e;p9r(o)?t.get(ro).setWarning("Out of memory"):o.code==="EMFILE"||o.code==="ENFILE"?t.get(ro).setWarning("Too many open files"):o.code==="CopilotPromptLoadFailure"?t.get(ro).setWarning("Corrupted Copilot installation"):`${o.code}`.startsWith("CopilotPromptWorkerExit")?t.get(ro).setWarning("Worker unexpectedly exited"):o.syscall==="uv_cwd"&&o.code==="ENOENT"&&t.get(ro).setWarning("Current working directory does not exist")}n.exception(t,e,r)}}a(YI,"handleException");function Bxt(t){process.addListener("uncaughtException",r=>{YI(t,r,"uncaughtException")});let e=!1;process.addListener("unhandledRejection",r=>{if(!e)try{e=!0,YI(t,r,"unhandledRejection")}finally{e=!1}})}a(Bxt,"registerDefaultHandlers");async function Oxt(t){try{await lG}catch(e){YI(t,e,"initializeTokenizers")}}a(Oxt,"waitForTokenizers");f();var JI=require("fs"),Fxt=require("os"),Uxt=ye(require("path")),WL=require("process");var In=class{static{a(this,"PersistenceManager")}},hDe=class extends In{constructor(r){super();this.directory=r}static{a(this,"FilePersistenceManager")}async read(r,n){try{return(await this.readJsonObject(r))[n]}catch{return}}async update(r,n,o){await JI.promises.mkdir(this.directory,{recursive:!0,mode:448});let s=`${this.directory}/${r}.json`,c;try{c=await EG.acquire(s);let l=await this.readJsonObject(r);l[n]=o,await JI.promises.writeFile(s,JSON.stringify(l)+`
|
|
1114
1114
|
`,{encoding:"utf8",mode:384})}finally{c&&await c()}}async delete(r,n){let o=`${this.directory}/${r}.json`,s;try{s=await EG.acquire(o);let c=await this.readJsonObject(r);delete c[n];let l=JSON.stringify(c)+`
|
|
1115
1115
|
`;l===`{}
|
|
1116
1116
|
`?await JI.promises.rm(o):await JI.promises.writeFile(o,l,{encoding:"utf8",mode:384})}catch{}finally{s&&await s()}}async deleteSetting(r){let n=`${this.directory}/${r}.json`,o;try{o=await EG.acquire(n),await JI.promises.rm(n)}catch{}finally{o&&await o()}}async listSettings(){try{return(await JI.promises.readdir(this.directory)).filter(n=>n.endsWith(".json")).map(n=>n.slice(0,-5))}catch{return[]}}async listKeys(r){return Object.keys(await this.readJsonObject(r))}async readJsonObject(r){let n=`${this.directory}/${r}.json`;try{let o=await JI.promises.readFile(n,{encoding:"utf8"});return JSON.parse(o)}catch{return{}}}},EG=class{static{a(this,"LockManager")}static{this.locks=new Map}static{this.DEFAULT_TIMEOUT_MS=1e4}static async acquire(e){await this.getLock(e);let r,n=new Promise(o=>{r=o});return this.locks.set(e,n),()=>Promise.resolve().then(()=>{r&&(r(),r=void 0,this.locks.get(e)===n&&this.locks.delete(e))})}static async getLock(e){let r=Date.now();for(;Date.now()-r<this.DEFAULT_TIMEOUT_MS;){let n=this.locks.get(e);if(!n)return;let o=this.DEFAULT_TIMEOUT_MS-(Date.now()-r);if(o<=0)return;let s=new Promise((c,l)=>{setTimeout(()=>{l(new Error("timeout"))},o)});try{await Promise.race([n,s])}catch{return}}}};function mDe(){return WL.env.XDG_CONFIG_HOME&&Uxt.isAbsolute(WL.env.XDG_CONFIG_HOME)?WL.env.XDG_CONFIG_HOME+"/github-copilot":(0,Fxt.platform)()==="win32"?WL.env.USERPROFILE+"\\AppData\\Local\\github-copilot":WL.env.HOME+"/.config/github-copilot"}a(mDe,"getXdgConfigPath");function Qxt(){return new hDe(mDe())}a(Qxt,"makeXdgPersistenceManager");f();f();f();var HE={abap:{extensions:[".abap"]},aspdotnet:{extensions:[".asax",".ascx",".ashx",".asmx",".aspx",".axd"]},bat:{extensions:[".bat",".cmd"]},bibtex:{extensions:[".bib",".bibtex"]},blade:{extensions:[".blade",".blade.php"]},BluespecSystemVerilog:{extensions:[".bsv"]},c:{extensions:[".c",".cats",".h",".h.in",".idc"]},csharp:{extensions:[".cake",".cs",".cs.pp",".csx",".linq"]},cpp:{extensions:[".c++",".cc",".cp",".cpp",".cppm",".cxx",".h",".h++",".hh",".hpp",".hxx",".idl",".inc",".inl",".ino",".ipp",".ixx",".rc",".re",".tcc",".tpp",".txx",".i"]},cobol:{extensions:[".cbl",".ccp",".cob",".cobol",".cpy"]},css:{extensions:[".css",".wxss"]},clojure:{extensions:[".bb",".boot",".cl2",".clj",".cljc",".cljs",".cljs.hl",".cljscm",".cljx",".edn",".hic"],filenames:["riemann.config"]},ql:{extensions:[".ql",".qll"]},coffeescript:{extensions:["._coffee",".cake",".cjsx",".coffee",".iced"],filenames:["Cakefile"]},cuda:{extensions:[".cu",".cuh"]},dart:{extensions:[".dart"]},dockerfile:{extensions:[".containerfile",".dockerfile"],filenames:["Containerfile","Dockerfile"]},dotenv:{extensions:[".env"],filenames:[".env",".env.ci",".env.dev",".env.development",".env.development.local",".env.example",".env.local",".env.prod",".env.production",".env.sample",".env.staging",".env.test",".env.testing"]},html:{extensions:[".ect",".ejs",".ejs.t",".jst",".hta",".htm",".html",".html.hl",".html5",".inc",".jsp",".njk",".tpl",".twig",".wxml",".xht",".xhtml",".phtml",".liquid"]},elixir:{extensions:[".ex",".exs"],filenames:["mix.lock"]},erlang:{extensions:[".app",".app.src",".erl",".es",".escript",".hrl",".xrl",".yrl"],filenames:["Emakefile","rebar.config","rebar.config.lock","rebar.lock"]},fsharp:{extensions:[".fs",".fsi",".fsx"]},go:{extensions:[".go"]},groovy:{extensions:[".gradle",".groovy",".grt",".gtpl",".gvy",".jenkinsfile"],filenames:["Jenkinsfile","Jenkinsfile"]},graphql:{extensions:[".gql",".graphql",".graphqls"]},terraform:{extensions:[".hcl",".nomad",".tf",".tfvars",".workflow"]},hlsl:{extensions:[".cginc",".fx",".fxh",".hlsl",".hlsli"]},erb:{extensions:[".erb",".erb.deface",".rhtml"]},razor:{extensions:[".cshtml",".razor"]},haml:{extensions:[".haml",".haml.deface"]},handlebars:{extensions:[".handlebars",".hbs"]},haskell:{extensions:[".hs",".hs-boot",".hsc"]},ini:{extensions:[".cfg",".cnf",".dof",".ini",".lektorproject",".prefs",".pro",".properties",".url"],filenames:[".buckconfig",".coveragerc",".flake8",".pylintrc","HOSTS","buildozer.spec","hosts","pylintrc","vlcrc"]},json:{extensions:[".4DForm",".4DProject",".JSON-tmLanguage",".avsc",".geojson",".gltf",".har",".ice",".json",".json.example",".jsonl",".mcmeta",".sarif",".tact",".tfstate",".tfstate.backup",".topojson",".webapp",".webmanifest",".yy",".yyp"],filenames:[".all-contributorsrc",".arcconfig",".auto-changelog",".c8rc",".htmlhintrc",".imgbotconfig",".nycrc",".tern-config",".tern-project",".watchmanconfig","MODULE.bazel.lock","Package.resolved","Pipfile.lock","bun.lock","composer.lock","deno.lock","flake.lock","mcmod.info"]},jsonc:{extensions:[".code-snippets",".code-workspace",".jsonc",".sublime-build",".sublime-color-scheme",".sublime-commands",".sublime-completions",".sublime-keymap",".sublime-macro",".sublime-menu",".sublime-mousemap",".sublime-project",".sublime-settings",".sublime-theme",".sublime-workspace",".sublime_metrics",".sublime_session"],filenames:[".babelrc",".devcontainer.json",".eslintrc.json",".jscsrc",".jshintrc",".jslintrc",".swcrc","api-extractor.json","argv.json","devcontainer.json","extensions.json","jsconfig.json","keybindings.json","language-configuration.json","launch.json","profiles.json","settings.json","tasks.json","tsconfig.json","tslint.json"]},java:{extensions:[".jav",".java",".jsh"]},javascript:{extensions:["._js",".bones",".cjs",".es",".es6",".frag",".gs",".jake",".javascript",".js",".jsb",".jscad",".jsfl",".jslib",".jsm",".jspre",".jss",".mjs",".njs",".pac",".sjs",".ssjs",".xsjs",".xsjslib"],filenames:["Jakefile"]},julia:{extensions:[".jl"]},kotlin:{extensions:[".kt",".ktm",".kts"]},less:{extensions:[".less"]},lua:{extensions:[".fcgi",".lua",".luau",".nse",".p8",".pd_lua",".rbxs",".rockspec",".wlua"],filenames:[".luacheckrc"]},makefile:{extensions:[".d",".mak",".make",".makefile",".mk",".mkfile"],filenames:["BSDmakefile","GNUmakefile","Kbuild","Makefile","Makefile.am","Makefile.boot","Makefile.frag","Makefile.in","Makefile.inc","Makefile.wat","makefile","makefile.sco","mkfile"]},markdown:{extensions:[".livemd",".markdown",".md",".mdown",".mdwn",".mdx",".mkd",".mkdn",".mkdown",".ronn",".scd",".workbook"],filenames:["contents.lr"]},"objective-c":{extensions:[".h",".m"]},"objective-cpp":{extensions:[".mm"]},php:{extensions:[".aw",".ctp",".fcgi",".inc",".install",".module",".php",".php3",".php4",".php5",".phps",".phpt",".theme"],filenames:[".php",".php_cs",".php_cs.dist","Phakefile"]},perl:{extensions:[".al",".cgi",".fcgi",".perl",".ph",".pl",".plx",".pm",".psgi",".t"],filenames:[".latexmkrc","Makefile.PL","Rexfile","ack","cpanfile","latexmkrc"]},powershell:{extensions:[".ps1",".psd1",".psm1"]},pug:{extensions:[".jade",".pug"]},python:{extensions:[".cgi",".codon",".fcgi",".gyp",".gypi",".lmi",".py",".py3",".pyde",".pyi",".pyp",".pyt",".pyw",".rpy",".sage",".spec",".tac",".wsgi",".xpy"],filenames:[".gclient","DEPS","SConscript","SConstruct","wscript"]},r:{extensions:[".r",".rd",".rsx"],filenames:[".Rprofile","expr-dist"]},ruby:{extensions:[".builder",".eye",".fcgi",".gemspec",".god",".jbuilder",".mspec",".pluginspec",".podspec",".prawn",".rabl",".rake",".rb",".rbi",".rbuild",".rbw",".rbx",".ru",".ruby",".spec",".thor",".watchr"],filenames:[".irbrc",".pryrc",".simplecov","Appraisals","Berksfile","Brewfile","Buildfile","Capfile","Dangerfile","Deliverfile","Fastfile","Gemfile","Guardfile","Jarfile","Mavenfile","Podfile","Puppetfile","Rakefile","Snapfile","Steepfile","Thorfile","Vagrantfile","buildfile"]},rust:{extensions:[".rs",".rs.in"]},scss:{extensions:[".scss"]},sql:{extensions:[".cql",".ddl",".inc",".mysql",".prc",".sql",".tab",".udf",".viw"]},sass:{extensions:[".sass"]},scala:{extensions:[".kojo",".sbt",".sc",".scala"]},shellscript:{extensions:[".bash",".bats",".cgi",".command",".fcgi",".fish",".ksh",".sh",".sh.in",".tmux",".tool",".trigger",".zsh",".zsh-theme"],filenames:[".bash_aliases",".bash_functions",".bash_history",".bash_logout",".bash_profile",".bashrc",".cshrc",".envrc",".flaskenv",".kshrc",".login",".profile",".tmux.conf",".zlogin",".zlogout",".zprofile",".zshenv",".zshrc","9fs","PKGBUILD","bash_aliases","bash_logout","bash_profile","bashrc","cshrc","gradlew","kshrc","login","man","profile","tmux.conf","zlogin","zlogout","zprofile","zshenv","zshrc"]},slang:{extensions:[".fxc",".hlsl",".s",".slang",".slangh",".usf",".ush",".vfx"]},slim:{extensions:[".slim"]},solidity:{extensions:[".sol"]},stylus:{extensions:[".styl"]},svelte:{extensions:[".svelte"]},swift:{extensions:[".swift"]},systemverilog:{extensions:[".sv",".svh",".vh"]},typescriptreact:{extensions:[".tsx"]},latex:{extensions:[".aux",".bbx",".cbx",".cls",".dtx",".ins",".lbx",".ltx",".mkii",".mkiv",".mkvi",".sty",".tex",".toc"]},typescript:{extensions:[".cts",".mts",".ts"]},verilog:{extensions:[".v",".veo"]},vim:{extensions:[".vba",".vim",".vimrc",".vmb"],filenames:[".exrc",".gvimrc",".nvimrc",".vimrc","_vimrc","gvimrc","nvimrc","vimrc"]},vb:{extensions:[".vb",".vbhtml",".Dsr",".bas",".cls",".ctl",".frm",".vbs"]},vue:{extensions:[".nvue",".vue"]},xml:{extensions:[".adml",".admx",".ant",".axaml",".axml",".builds",".ccproj",".ccxml",".clixml",".cproject",".cscfg",".csdef",".csl",".csproj",".ct",".depproj",".dita",".ditamap",".ditaval",".dll.config",".dotsettings",".filters",".fsproj",".fxml",".glade",".gml",".gmx",".gpx",".grxml",".gst",".hzp",".iml",".ivy",".jelly",".jsproj",".kml",".launch",".mdpolicy",".mjml",".mod",".mojo",".mxml",".natvis",".ncl",".ndproj",".nproj",".nuspec",".odd",".osm",".pkgproj",".plist",".pluginspec",".proj",".props",".ps1xml",".psc1",".pt",".pubxml",".qhelp",".rdf",".res",".resx",".rss",".sch",".scxml",".sfproj",".shproj",".srdf",".storyboard",".sublime-snippet",".svg",".sw",".targets",".tml",".typ",".ui",".urdf",".ux",".vbproj",".vcxproj",".vsixmanifest",".vssettings",".vstemplate",".vxml",".wixproj",".workflow",".wsdl",".wsf",".wxi",".wxl",".wxs",".x3d",".xacro",".xaml",".xib",".xlf",".xliff",".xmi",".xml",".xml.dist",".xmp",".xproj",".xsd",".xspec",".xul",".zcml"],filenames:[".classpath",".cproject",".project","App.config","NuGet.config","Settings.StyleCop","Web.Debug.config","Web.Release.config","Web.config","packages.config"]},xsl:{extensions:[".xsl",".xslt"]},yaml:{extensions:[".mir",".reek",".rviz",".sublime-syntax",".syntax",".yaml",".yaml-tmlanguage",".yaml.sed",".yml",".yml.mysql"],filenames:[".clang-format",".clang-tidy",".clangd",".gemrc","CITATION.cff","glide.lock","pixi.lock","yarn.lock"]},javascriptreact:{extensions:[".jsx"]},legend:{extensions:[".pure"]}};f();f();var qxt=[".ejs",".erb",".haml",".hbs",".j2",".jinja",".jinja2",".liquid",".mustache",".njk",".php",".pug",".slim",".webc"],jxt={".php":[".blade"]},cP=Object.keys(HE).flatMap(t=>HE[t].extensions);var gDe=ye(require("node:path"));var zL=class{constructor(e,r,n){this.languageId=e;this.isGuess=r;this.fileExtension=n}static{a(this,"Language")}},_G=class{static{a(this,"LanguageDetection")}},ADe=new Map,VL=new Map;for(let[t,{extensions:e,filenames:r}]of Object.entries(HE)){for(let n of e)ADe.set(n,[...ADe.get(n)??[],t]);for(let n of r??[])VL.set(n,[...VL.get(n)??[],t])}var yDe=class extends _G{static{a(this,"FilenameAndExensionLanguageDetection")}detectLanguage(e){let r=Zn(e.uri),n=gDe.extname(r).toLowerCase(),o=this.extensionWithoutTemplateLanguage(r,n),s=this.detectLanguageId(r,o),c=this.computeFullyQualifiedExtension(n,o);return s?new zL(s.languageId,s.isGuess,c):new zL(e.languageId,!0,c)}extensionWithoutTemplateLanguage(e,r){if(qxt.includes(r)){let n=e.substring(0,e.lastIndexOf(".")),o=gDe.extname(n).toLowerCase();if(o.length>0&&cP.includes(o)&&this.isExtensionValidForTemplateLanguage(r,o))return o}return r}isExtensionValidForTemplateLanguage(e,r){let n=jxt[e];return!n||n.includes(r)}detectLanguageId(e,r){if(VL.has(e))return{languageId:VL.get(e)[0],isGuess:!1};let n=ADe.get(r)??[];if(n.length>0)return{languageId:n[0],isGuess:n.length>1};for(;e.includes(".");)if(e=e.replace(/\.[^.]*$/,""),VL.has(e))return{languageId:VL.get(e)[0],isGuess:!1}}computeFullyQualifiedExtension(e,r){return e!==r?r+e:e}},bDe=class extends _G{constructor(r){super();this.delegate=r}static{a(this,"GroupingLanguageDetection")}detectLanguage(r){let n=this.delegate.detectLanguage(r),o=n.languageId;return o==="c"||o==="cpp"?new zL("cpp",n.isGuess,n.fileExtension):n}},CDe=class extends _G{constructor(r){super();this.delegate=r}static{a(this,"ClientProvidedLanguageDetection")}detectLanguage(r){return r.uri.startsWith("untitled:")||r.uri.startsWith("vscode-notebook-cell:")?new zL(r.languageId,!0,""):this.delegate.detectLanguage(r)}},h9r=new bDe(new CDe(new yDe));function Lg({uri:t,languageId:e}){let r=h9r.detectLanguage({uri:t,languageId:"UNKNOWN"});return r.languageId==="UNKNOWN"?e:r.languageId}a(Lg,"detectLanguage");f();f();f();f();function WE(t){if(t.isCancellationRequested)throw new dse}a(WE,"throwIfCancellationRequested");function $xt(t){return t instanceof dse?!0:t instanceof Error&&t.name===vDe&&t.message===vDe}a($xt,"isCancellationError");var dse=class extends Error{static{a(this,"CancellationError")}constructor(){super(vDe),this.name=this.message}},vDe="Canceled",fse=class{constructor(){this.items=[]}static{a(this,"Stack")}push(e){this.items.push(e)}pop(){return this.items.pop()}peek(){return this.items[this.items.length-1]}tryPeek(){return this.items.length>0}toArray(){return this.items}};function lP(t){switch(t){case 0:case 2:case 7:case 8:case 11:case 12:case 13:case 14:return!0;default:return!1}}a(lP,"isTypeDefinition");var As=class t{static{a(this,"TextRange")}static{this.empty=new t(0,0)}constructor(e,r){this.start=e,this.length=r}static fromBounds(e,r){return new t(e,r-e)}get end(){return this.start+this.length}contains(e){return this.start<=e&&this.end>=e}containsRange(e){return this.start<=e.start&&this.end>=e.end}equals(e){return this.start===e.start&&this.length===e.length}getText(e){return e.slice(this.start,this.end)}getTextWithIndentation(e,r){let n=[],o=this.start;for(o=Hxt(e,e.length,o),Gxt(n,r);o<this.end;)e[o]!=="\r"&&e[o]!==`
|
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"url": "git+https://github.com/github/copilot-language-server-release.git"
|
|
12
12
|
},
|
|
13
13
|
"license": "MIT",
|
|
14
|
-
"version": "1.
|
|
14
|
+
"version": "1.384.0",
|
|
15
15
|
"bin": {
|
|
16
16
|
"copilot-language-server": "../dist/language-server.js"
|
|
17
17
|
},
|
|
@@ -34,12 +34,12 @@
|
|
|
34
34
|
"vscode-languageserver-protocol": "^3.17.5"
|
|
35
35
|
},
|
|
36
36
|
"optionalDependencies": {
|
|
37
|
-
"@github/copilot-language-server-win32-x64": "1.
|
|
38
|
-
"@github/copilot-language-server-linux-x64": "1.
|
|
39
|
-
"@github/copilot-language-server-linux-arm64": "1.
|
|
40
|
-
"@github/copilot-language-server-darwin-x64": "1.
|
|
41
|
-
"@github/copilot-language-server-darwin-arm64": "1.
|
|
37
|
+
"@github/copilot-language-server-win32-x64": "1.384.0",
|
|
38
|
+
"@github/copilot-language-server-linux-x64": "1.384.0",
|
|
39
|
+
"@github/copilot-language-server-linux-arm64": "1.384.0",
|
|
40
|
+
"@github/copilot-language-server-darwin-x64": "1.384.0",
|
|
41
|
+
"@github/copilot-language-server-darwin-arm64": "1.384.0"
|
|
42
42
|
},
|
|
43
43
|
"buildType": "prod",
|
|
44
|
-
"build": "
|
|
44
|
+
"build": "1812"
|
|
45
45
|
}
|