Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
amend! Rework LSP to allow multi-project/workspace setups
Rework LSP to allow multi-project/workspace setups Right now Calva only supports opening clojure projects from the root of the project. This will be where the LSP process is started and the clojure LSP needs a deps.edn/project.clj file to exist at it's root in order to provide proper completions. This also means that multi-workspace setups in VSCode is not really supported. This commit refactors the LSP implementation to allow provisioning multiple LSP clients at different roots. Dependent systems can then request the LSP client governing a particular file/directory. This change simultaneously allows opening directories that contain multiple projects as well as setting up multi-workspace vscode configurations. The LSP initialization logic is also altered such that the server is started when a clojure file is opened rather than when Calva initializes. This prevents poluting non-clojure projects with .lsp and .clj-kondo directories. Closes BetterThanTomorrow#934 Closes BetterThanTomorrow#1706
- Loading branch information