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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not locate MSBuild instance to register with OmniSharp #792

Closed
Kaoruha opened this issue Jun 30, 2022 · 2 comments
Closed

Could not locate MSBuild instance to register with OmniSharp #792

Kaoruha opened this issue Jun 30, 2022 · 2 comments

Comments

@Kaoruha
Copy link

Kaoruha commented Jun 30, 2022

Hello,
I have installed omnisharp-vim with plug-vim.
And success installed omnisharp-roslyn.
But when the server start, it shows the message as title.

Logs like this:
[info]: OmniSharp.Stdio.Host
8 ¦ Starting OmniSharp on kali 2022.2 (x64)
9 [info]: OmniSharp.Services.DotNetCliService
10 ¦ Checking the 'DOTNET_ROOT' environment variable to find a .NET SDK
11 [info]: OmniSharp.Services.DotNetCliService
12 ¦ Using the 'dotnet' on the PATH.
13 [info]: OmniSharp.Services.DotNetCliService
14 ¦ DotNetPath set to dotnet
15 [info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
16 ¦ Located 0 MSBuild instance(s)

I have installed dotnet and mono.

dotnet msbuild -h
Microsoft (R) Build Engine version 17.2.0+41abc5629 for .NET
Copyright (C) Microsoft Corporation. All rights reserved.

mono --version
Mono JIT compiler version 6.8.0.105 (Debian 6.8.0.105+dfsg-3.2 Tue Jun 29 21:01:01 UTC 2021)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com

What should i do to solve this problem?

@nickspoons
Copy link
Member

If your project is a .net core project, try using the net6 version of the server. Installation steps described here: #791 (comment)

@Kaoruha
Copy link
Author

Kaoruha commented Jun 30, 2022

If your project is a .net core project, try using the net6 version of the server. Installation steps described here: #791 (comment)

Thanks.
The problem solved after setting "g:OmniSharp_server_use_net6 = 1" and reinstall the omnisharp server.

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

2 participants