I have looked for answers regarding this pretty far and wide and I’ve found many but none of them seem to be exactly like my issue. I have installed the dotbunny plug-in for VS Code and I’ve selected it as my code editor. Many people have told me to click on the flame at the bottom of the screen and select the -csproj.sln instead of the .sln, however only the .sln is available to choose from. I have reinstalled mono in brew as I found forum suggesting, but I haven’t had any luck. Is there anyone out there who knows how to solve this? Sorry if I was not thorough enough, I’m not great at asking questions.
I think they mean the .csproj file, not the .sln file. The sln is a solution file, so you want to open the:
.CSharp.csproj file. For example:
“My Awesome Game.CSharp.csproj”
Hey—I have the exact same problem as the OP. The -CSharp.csproj file isn’t available for selection in the OmniSharp console (which is what the flame icon opens), only the .sln is. If I try to navigate it to a different file, it just closes the OmniSharp terminal. Did OP ever find a solution? Is there an easy way to force OmniSharp to work off of a different project file?
Edit: Oop, just poked around a bit more and saw this in the omnisharp-vscode readme:
“Support for .csproj projects has been temporarily disabled on OS X and Linux. This will impact anyone doing .csproj development on OS X or Linux (e.g. Unity, Xamarin, etc.). Rest assured that this will be restored in the near future. However, for now, you can use the Legacy C# Support extension.”
Guess that’s what’s happening. Seems like a recent problem, maybe there’ll be a recent solution? Would love to hear how to use the Legacy C# Solution to fix this, this is all pretty new to me.
Edit 2:
Nvm, just fixed this! Uninstall any C# extensions you have in VSCode, then install Legacy C# Support (or uninstall and reinstall). Once VSCode has restarted, the OmniSharp terminal will still indicate that it’s using an .sln file, but Intellisense should be working without problems. Yahoo.
Another option would be to use Visual Studio (VSCode probably can to), to add a blank .sln… then add the csproj to that sln so you’d have an extra .sln with just the CSharp project. Not sure if that would work.
Any update on this topic? I get this error:
[INFORMATION:OmniSharp.Dnx.DnxProjectSystem] Scanning ‘/Users/alexanderbrazie/project-sidescroller’ for DNX projects
[INFORMATION:OmniSharp.Dnx.DnxProjectSystem] No project.json based projects found
[INFORMATION:OmniSharp.MSBuild.MSBuildProjectSystem] Detecting projects in ‘/Users/alexanderbrazie/project-sidescroller/project-sidescroller.sln’.
[INFORMATION:OmniSharp.MSBuild.MSBuildProjectSystem] Loading project from ‘/Users/alexanderbrazie/project-sidescroller/Assembly-CSharp-firstpass.csproj’.
[INFORMATION:OmniSharp.MSBuild.MSBuildProjectSystem] Loading project from ‘/Users/alexanderbrazie/project-sidescroller/Assembly-CSharp.csproj’.
[INFORMATION:OmniSharp.MSBuild.MSBuildProjectSystem] Loading project from ‘/Users/alexanderbrazie/project-sidescroller/Assembly-CSharp-Editor-firstpass.csproj’.
[INFORMATION:OmniSharp.MSBuild.MSBuildProjectSystem] Loading project from ‘/Users/alexanderbrazie/project-sidescroller/Assembly-CSharp-Editor.csproj’.
[ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol )', expecting
,’ or ;' [ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol
)‘, expecting ,' or
;’
[ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol )', expecting
,’ or ;' [ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol
)‘, expecting ,' or
;’
[ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol void' [ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol
void’
[ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol void' [ERROR:OmniSharp.MSBuild.MSBuildProjectSystem] Unexpected symbol
void’
[WARNING:OmniSharp.MSBuild.MSBuildProjectSystem] Failed to process project file ‘/Users/alexanderbrazie/project-sidescroller/Assembly-CSharp-Editor.csproj’.
/Users/alexanderbrazie/project-sidescroller/Assembly-CSharp-Editor.csproj
Using the legacy Omnisharp.