Setup Raw Structure for implementing multi-workspace support with WorkspaceRoot (#5849)

* Setup Raw Structure for implementing multi-workspace support with WorkspaceRoot

* Remove Shortcut of Cline from its title
This commit is contained in:
Ara authored and GitHub committed 2025-09-02 16:14:55 -07:00
1 parent f2dbab814e
commit e3bc5f0143
27 files changed
+1073 -53

No files matched your search

@@ -1,7 +1,7 @@
import { workspaceResolver } from "@core/workspace"
import { openFile as openFileIntegration } from "@integrations/misc/open-file"
import { Empty, StringRequest } from "@shared/proto/cline/common"
import { getWorkspacePath } from "@utils/path"
import * as path from "path"
import { Controller } from ".."
/**
@@ -20,7 +20,12 @@ export async function openFileRelativePath(_controller: Controller, request: Str
if (request.value) {
// Resolve the relative path to absolute path
const absolutePath = path.resolve(workspacePath, request.value)
const resolvedPath = workspaceResolver.resolveWorkspacePath(
workspacePath,
request.value,
"Controller.openFileRelativePath",
)
const absolutePath = typeof resolvedPath === "string" ? resolvedPath : resolvedPath.absolutePath
// Open the file using the existing integration
openFileIntegration(absolutePath)