neoclide / coc.nvim

Nodejs extension host for vim & neovim, load extensions like VSCode and host language servers.
Other
24.16k stars 954 forks source link

Is modifying current workspace available? #4938

Open QingCold opened 4 months ago

QingCold commented 4 months ago

Is your feature request related to a problem? Please describe. I recently open a complex project containing multi submodules which each owns a '.git'. So I wonder if there is a method that let me modify current workspace so that my lsp can run correctly.

Describe the solution you'd like I'd like to use CocCommand to modify the workspace. e.g. workspace.setCurrentWorkspace("/path/to/myproject/")

QingCold commented 4 months ago

My current solution is : bind call CocAction('AddWorkspaceFolder','path') to a command. Then execute CocCommand -- intelephense.index.workspace

fannheyward commented 4 months ago

There's currently no way to set workspace root.

coc.nvim resolved root for current document with root patterns, for monorepo with multi root patterns, the resolving maybe correct for some but fail for others.

Similar issues:

Will improve the resolving for monorepo.

QingCold commented 4 months ago

There's currently no way to set workspace root.

coc.nvim resolved root for current document with root patterns, for monorepo with multi root patterns, the resolving maybe correct for some but fail for others.

Similar issues:

Will improve the resolving for monorepo.

So is there a need to add feature 'set workspace root' ? I thought it will be better. Hope this does not bother you. :)