Skip to content

Commit

Permalink
amend! Rework LSP to allow multi-project/workspace setups
Browse files Browse the repository at this point in the history
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
julienvincent committed Jan 19, 2023
1 parent 146a10f commit 9ee6025
Showing 0 changed files with 0 additions and 0 deletions.

0 comments on commit 9ee6025

Please sign in to comment.