Skip to content

Commit

Permalink
Use actualRootPath instead of p.RootPath when peeking workspaces. (#1278
Browse files Browse the repository at this point in the history
)

This fix the issue where rootUri was ignored when using AutomaticWorkspaceInit.
  • Loading branch information
oupson authored Apr 29, 2024
1 parent ae9e687 commit 292e788
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/FsAutoComplete/LspServers/AdaptiveFSharpLspServer.fs
Original file line number Diff line number Diff line change
Expand Up @@ -316,15 +316,12 @@ type AdaptiveFSharpLspServer
| None -> p.RootPath

let projs =
match p.RootPath, c.AutomaticWorkspaceInit with
match actualRootPath, c.AutomaticWorkspaceInit with
| None, _
| _, false -> state.WorkspacePaths
| Some actualRootPath, true ->
| Some rootPath, true ->
let peeks =
WorkspacePeek.peek
actualRootPath
c.WorkspaceModePeekDeepLevel
(c.ExcludeProjectDirectories |> List.ofArray)
WorkspacePeek.peek rootPath c.WorkspaceModePeekDeepLevel (c.ExcludeProjectDirectories |> List.ofArray)
|> List.map Workspace.mapInteresting
|> List.sortByDescending (fun x ->
match x with
Expand Down

0 comments on commit 292e788

Please sign in to comment.