@@ -10,6 +10,7 @@ import { McpOAuthProvider } from "../../mcp/oauth-provider"
1010import { Config } from "@/config/config"
1111import { ConfigMCP } from "../../config/mcp"
1212import { Instance } from "../../project/instance"
13+ import { WithInstance } from "../../project/with-instance"
1314import { Installation } from "../../installation"
1415import { InstallationVersion } from "@opencode-ai/core/installation/version"
1516import path from "path"
@@ -114,7 +115,7 @@ export const McpListCommand = cmd({
114115 aliases : [ "ls" ] ,
115116 describe : "list MCP servers and their status" ,
116117 async handler ( ) {
117- await Instance . provide ( {
118+ await WithInstance . provide ( {
118119 directory : process . cwd ( ) ,
119120 async fn ( ) {
120121 UI . empty ( )
@@ -186,7 +187,7 @@ export const McpAuthCommand = cmd({
186187 } )
187188 . command ( McpAuthListCommand ) ,
188189 async handler ( args ) {
189- await Instance . provide ( {
190+ await WithInstance . provide ( {
190191 directory : process . cwd ( ) ,
191192 async fn ( ) {
192193 UI . empty ( )
@@ -318,7 +319,7 @@ export const McpAuthListCommand = cmd({
318319 aliases : [ "ls" ] ,
319320 describe : "list OAuth-capable MCP servers and their auth status" ,
320321 async handler ( ) {
321- await Instance . provide ( {
322+ await WithInstance . provide ( {
322323 directory : process . cwd ( ) ,
323324 async fn ( ) {
324325 UI . empty ( )
@@ -357,7 +358,7 @@ export const McpLogoutCommand = cmd({
357358 type : "string" ,
358359 } ) ,
359360 async handler ( args ) {
360- await Instance . provide ( {
361+ await WithInstance . provide ( {
361362 directory : process . cwd ( ) ,
362363 async fn ( ) {
363364 UI . empty ( )
@@ -448,7 +449,7 @@ export const McpAddCommand = cmd({
448449 command : "add" ,
449450 describe : "add an MCP server" ,
450451 async handler ( ) {
451- await Instance . provide ( {
452+ await WithInstance . provide ( {
452453 directory : process . cwd ( ) ,
453454 async fn ( ) {
454455 UI . empty ( )
@@ -618,7 +619,7 @@ export const McpDebugCommand = cmd({
618619 demandOption : true ,
619620 } ) ,
620621 async handler ( args ) {
621- await Instance . provide ( {
622+ await WithInstance . provide ( {
622623 directory : process . cwd ( ) ,
623624 async fn ( ) {
624625 UI . empty ( )
0 commit comments