-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add omnisharp language server #291
Conversation
Build is failing for macOS at "Setup build dependencies". I also noticed it failed on another PR in the last week so maybe unrelated to this work specifically? But happy to fix if needed to make PR go through if there's some insights into what the root issue is there |
@damienpontifex Did you manage to make it work? My main blocker to submit a pull request is the |
I'll echo @adelarsq's comments about the |
I did find the reason. For now my workaround is to use like that:
Just put a A better approach is to make |
I believe I did have it working, but testing this morning I agree with issues here. I'll have another look over the weekend |
I guess if it's matching exact patterns, we can use Edit: this does not work. Even though I'm using code from the examples in the readme: ['root_dir'] = function(fname)
return nvim_lsp.util.find_git_ancestor(fname) or nvim_lsp.util.root_pattern('.sln') or vim.loop.os_homedir()
end, I get this error:
So I don't think we can count on that. |
Not always the Also for me don't really solve, since I use with subversion... yes, sad! I'm thinking about ways to resolve the pattern, so we solve this problem for others language servers (like for F#). I did see some configs using |
Yeah, you're right… didn't think of that. I was intrigued by what you said about the pattern matching and I started looking at the code for this repository. It seems that the pattern matching occurs around these lines:
Unfortunately the It might take some additions to Hmm... I can verify that by using Try this: ['root_dir'] = function(fname)
local path = nvim_lsp.util.find_git_ancestor(fname) or nvim_lsp.util.root_pattern('.sln') or vim.loop.os_homedir()
vim.cmd('split foo | normal i'..path)
return path
end, |
The problem is with
I don't think. I was search for one but didn't find any.
I will do that on this weekend (a correction for the |
I can verify that using A couple of strange things are happening though:
Are these things happening for you too? |
Also did notice this days ago (I was using a
Didn't notice this. I have only |
I was having a play around with the I've also converted PR to draft as this is a bit more far reaching than my initial change and I'm in no near way do I have strong knowledge in lua or the impact on other packages so trying things out to make it work |
Yeah, the |
Thanks @damienpontifex. I did some tests with some language servers and its working. I have some issues with Elm language server but isn't related. Did some tests with the previous source code and the same issues occurs. |
Tomorrow I will make some more tests with Java and Elixir language servers. Its 3 AM and I need to sleep 😄 |
Someone else is having the same issues that we are with the diagnostics not updating correctly. It seems like it may not be |
@damienpontifex I just did replace my omnisharp config (just the
I just have finded why its failing. Neovim don't close the language server on exit:
|
Thanks for your work here, I was able to get this working on macos, except that I had to change the line Also, as others have mentioned, diagnostics doesn't work and the omnisharp servers seem to persist indefinitely, but otherwise it's working well |
Yes. Its pretty strange how diagnostics behaves. For me sometimes do works, sometimes not. But it's helping on daily work at least. Better performance then others options. |
I've noted a temporary workaround for some of the diagnostic-related bugs here for any that are using this in the meantime. |
What has worked well for me (so far) was to add this change to the roslyn server and this change to diagnostic-nvim. Update: After more digging, the former change to the roslyn server seems like a really bad idea |
Sorry I haven't had the time to pick this up again due to work - if there are fixes and someone is happy to add them and create another PR with those fixes? Sorry again |
@damienpontifex no problem. I can create another and link this as source. I will create tomorrow since today is too late. 😴 |
@adelarsq I updated the few path issues and grabbed the code of yours from #296 to make this work (pending that being merged) |
@damienpontifex Thanks! I was planning to work on this this weekend.
Yes. I think so. |
The OmniSharp LSP has been working well on my machine recently. Anyone else? |
@Iron-E I've been using daily and it's working well. Just notice some issues with diagnostics, but I think that is because I'm working with a huge code base (8 millions of lines). |
It's working great for me. |
Did notice an issue with it on macOS. After to download the LSP need to change permissions for the
EDITED: |
@adelarsq we'll have to create another PR with the small fix for |
note that in #334 i've proposed removing/deprecating the "install" routines in this repo, instead favoring documentation of install steps. |
Nice! Thanks @justinmk
I think that is a nice move. Would be a lot easier to maintain. @damienpontifex So let's wait for #334 so you add this step on the documentation. |
Getting inspiration from https://github.com/coc-extensions/coc-omnisharp and other lsp sources here to add omnisharp lsp to the available language servers