Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

--solution command line option not honoured when multiple solutions available in project #115

Open
lem102 opened this issue Sep 18, 2023 · 0 comments

Comments

@lem102
Copy link

lem102 commented Sep 18, 2023

Hi,

First of all, thanks for csharp-ls 馃檹.

When I start csharp-ls in a directory that contains multiple solutions like this:

$ ls
solution1.sln solution2.sln xyz.csproj Program.cs ...
$ csharp-ls --solution solution2.sln

I can see from the output in emacs that despite providing a solution to load, the code will still attempt to load all the projects in the directory one at a time. This works, but if you have a directory that contains 100+ projects, the startup time can get a little long 馃槄.

[eglot] Connected! Server `EGLOT (csharpLsTestSolution/(csharp-ts-mode csharp-mode))' now managing `(csharp-ts-mode csharp-mode)' buffers in project `csharpLsTestSolution'.
[eglot] Server reports (type=4): csharp-ls: attempting to find and load solution based on root path ("/home/jacobl/dev/csharpLsTestSolution")..
[eglot] Server reports (type=4): csharp-ls: 2 solution(s) found: [/home/jacobl/dev/csharpLsTestSolution/csharpLsTestSolution2.sln, /home/jacobl/dev/csharpLsTestSolution/csharpLsTestSolution.sln]
[eglot] Server reports (type=4): csharp-ls: no or multiple .sln files found on /home/jacobl/dev/csharpLsTestSolution
[eglot] Server reports (type=4): csharp-ls: looking for .csproj/fsproj files on /home/jacobl/dev/csharpLsTestSolution..
[eglot] Server reports (type=4): csharp-ls: OK, 1 project files loaded

This seems like it should be a simple problem to fix (if it is indeed a problem), but I've never coded F# before 馃槩 so it'll take me a while before I can submit a PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant