@@ -23,7 +23,7 @@ import { JobManagerView } from "./views/jobManager/jobManagerView";
2323import { SelfTreeDecorationProvider , selfCodesResultsView } from "./views/jobManager/selfCodes/selfCodesResultsView" ;
2424import { registerContinueProvider } from "./aiProviders/continue/continueContextProvider" ;
2525import { queryHistory } from "./views/queryHistoryView" ;
26- import { activateChat } from "./aiProviders/copilot" ;
26+ import { activateChat , registerCopilotProvider } from "./aiProviders/copilot" ;
2727
2828export interface Db2i {
2929 sqlJobManager : SQLJobManager ,
@@ -94,8 +94,6 @@ export function activate(context: vscode.ExtensionContext): Db2i {
9494 DbCache . resetCache ( ) ;
9595 selfCodesView . setRefreshEnabled ( false ) ;
9696 selfCodesView . setJobOnly ( false ) ;
97- // register continue provider
98- registerContinueProvider ( ) ;
9997 // Refresh the examples when we have it, so we only display certain examples
10098 onConnectOrServerInstall ( ) . then ( ( ) => {
10199 exampleBrowser . refresh ( ) ;
@@ -106,17 +104,11 @@ export function activate(context: vscode.ExtensionContext): Db2i {
106104 } ) ;
107105 } ) ;
108106
109- const copilot = vscode . extensions . getExtension ( `github.copilot-chat` ) ;
110107
111- if ( copilot ) {
112- if ( ! copilot . isActive ) {
113- copilot . activate ( ) . then ( ( ) => {
114- activateChat ( context ) ;
115- } ) ;
116- } else {
117- activateChat ( context ) ;
118- }
119- }
108+ // register copilot provider
109+ registerCopilotProvider ( context ) ;
110+ // register continue provider
111+ registerContinueProvider ( ) ;
120112
121113 instance . subscribe ( context , `disconnected` , `db2i-disconnected` , ( ) => ServerComponent . reset ( ) ) ;
122114
0 commit comments