Issue
I’m using VS Code to try out ASP.NET a little bit, but when I try to do:
dnu restore
it fails.
If I try to do it within VS Code I get a error message:
Omnisharp server not running.
I don’t really know what to do 🙁
I’m running Windows 10 x64
Solution
Check the vs code Omnisharp log, Ctrl + Shift + U.
The Omnisharp server is not running
error can result from a problem in your project.json
causing issues with dnu restore
. e.g. Issues resolving packages for one of the target frameworks?
It probably will not help but, you can try restarting Omnisharp : F1 "omni restart"
C# support is not bundled but it does sound like you have successfully installed it. Otherwise add C# with F1 "ext install", Enter, "C#"
You are right that there is little documentation
- https://code.visualstudio.com/docs/languages/csharp – introduction to project types and omnisharp
https://docs.asp.net/en/latest/tutorials/your-first-mac-aspnet.html – yes OSX because windows instructions are for Visual Studio(page no longer available)- https://blogs.msdn.microsoft.com/visualstudioalm/2016/03/10/experimental-net-core-debugging-in-vs-code/ – expect better soon
Answered By – KCD
Answer Checked By – Robin (BugsFixing Admin)