Right-click .cs
files or folders to run dotnet format
directly from the context menu.
- 📝 Format C# files using
dotnet format
- 📁 Works on single files or entire folders
- ⚙️ Automatically creates a
.editorconfig
if none is found
You must have the .NET SDK installed and accessible via the dotnet
command.
- Right-click a
.cs
file or folder in the Explorer or Editor - Select:
- RUN: Dotnet Format
- RUN: Dotnet Format
That’s it — the command runs dotnet format --include <target>
in the background.
If no .editorconfig
file is found in your project root, one will be created automatically with default formatting rules.