()
| 206 | } |
| 207 | |
| 208 | async function runDoctor(): Promise<void> { |
| 209 | const files = loadDevspaceFiles(); |
| 210 | console.log(`Config dir: ${files.dir}`); |
| 211 | console.log(`Config file: ${files.configExists ? files.configPath : "missing"}`); |
| 212 | console.log(`Auth file: ${files.authExists ? files.authPath : "missing"}`); |
| 213 | console.log(`Node: ${process.version} (${nodeVersionStatus()})`); |
| 214 | console.log(`Node ABI: ${process.versions.modules}`); |
| 215 | console.log(`Platform: ${process.platform} ${process.arch}`); |
| 216 | console.log(`Git: ${checkGitAvailable()}`); |
| 217 | console.log(`Bash shell: ${checkBashShell()}`); |
| 218 | console.log(`SQLite native dependency: ${checkSqliteNative()}`); |
| 219 | |
| 220 | try { |
| 221 | const config = loadConfig(); |
| 222 | console.log(`Local MCP URL: http://${config.host}:${config.port}/mcp`); |
| 223 | console.log(`Public MCP URL: ${new URL("/mcp", config.publicBaseUrl).toString()}`); |
| 224 | console.log(`Allowed roots: ${config.allowedRoots.join(", ")}`); |
| 225 | console.log(`Allowed hosts: ${config.allowedHosts.join(", ")}`); |
| 226 | } catch (error) { |
| 227 | console.log(`Config status: ${error instanceof Error ? error.message : String(error)}`); |
| 228 | } |
| 229 | } |
| 230 | |
| 231 | function runConfigCommand(args: string[]): void { |
| 232 | const [subcommand, key, ...rest] = args; |
no test coverage detected