I'm using VSCode and have the official Microsoft C# extension installed. Can't seem to figure out how to edit Omnisharp's formatting rules.
I have an 'omnisharp.json' file in the root of my directory, right next to the .sln file, but no changes I make in the JSON seem to affect the formatting in VSCode. I was under the impression that the project-specific omnisharp file would override any others that might be lurking around on my machine.
Extra Context:
- The Omnisharp output window has shown this message.
- Also getting a warning in the Omnisharp output window:
warn: OmniSharp.Roslyn.CSharp.Services.Navigation.FindUsagesService No symbol found. File: file\path\here.cs, Line: 51, Column: 16.
- The 'EnableEditorConfigSupport' setting is set to false in the JSON and is unchecked in VSCode's settings.
- To test if a solution has worked or not, I've been editing the omnisharp.json file so that many of the settings are drastically changed and would be easily noticeable, restarting Omnisharp using the OmniSharp: Restart OmniSharp command in VSCode, then formatting a couple of files to see if anything changes.
- Using this configuration
- I do not have the EditorConfig extension installed
What I've tried/read:
- https://strathweb.com/2017/01/c-code-formatting-settings-in-vs-code-and-omnisharp/
- https://github.com/OmniSharp/omnisharp-vscode/issues/5446
- https://github.com/OmniSharp/omnisharp-roslyn/wiki/Configuration-Options
- https://reese.codes/blog/post/the-real-ultimate-guide-to-fixing-omnisharp-in-vs-code/
- Setting C# formatting options for OmniSharp on Visual Studio Code?
- Not able to get full Intellisense in Visual Studio Code with Unity functions
- VSCode format curly brackets on the same line c#
- Not able to get full Intellisense in Visual Studio Code with Unity functions
- Omnisharp not loading properly - Visual Studio Code and Unity
What hasn't worked:
- Creating an omnisharp.json file in the same folder as the solution as well as the %APPDATA%/Code/User folder, the %userprofile%/.omnisharp folder, and the %userprofile%/.vscode/extensions/ms-dotnettools.csharp-1.25.7-win32-x64/.omnisharp/1.39.6-net6.0 folder.
- Setting EnableEditorConfigSupport to false in all omnisharp.json files and in all settings.json files.
- Completely uninstalling VSCode (deleting all user settings in the process), reinstalling the latest version of VSCode, reinstalling the latest version of .NET, and re-trying the above steps.
- Changing Unity's VSCode Editor Package to version 1.2.3
- Creating a config.json file and using this configuration
- Installing Mono
- Installing MSBuildTools
- Setting omnisharp.UseModernNet to false in the settings.json file in the project, user, and Code folders
- Installing .NET 6
Been wandering around the web for a couple of hours trying to solve this and nothing seems to work so far so, any help figuring out why this isn't working would be appreciated. Happy to provide any additional context or information if needed.