New, Simpler Solution File Format

New, Simpler Solution File Format - Visual Studio Blog This looks like a nice improvement over the old proprietary format, along the same vein as the updated .csproj format. It’s xml based and looks much simpler to edit. What’s nice though is it looks like you only need to make sure you’re using the latest versions of tooling to migrate over to it.

New hotkey for commenting code

Today I learned that in a recent version of visual studio they added the keyboard shortcut ctrl+/ to toggle code comments so it works just like in vscode instead of the default of two different cumbersome hotkeys to comment/uncomment. This also led me to discover that Visual Studio comes with a builtin keyboard mapping scheme for VSCode hotkeys which has more modern defaults. For instance, it changes ctrl+p to open the fuzzy file finder instead of the print dialog… I don’t know that I’ve ever wanted to print a source code file… except one time long ago when I wanted to convince a higher-up the need to refactor a sql query so I taped together the 10+ page printout 😅. ...

Copy Nice Extension

Today I learned about a handy little Visual Studio extension called Copy Nice whose sole purpose is to address an annoyance I encounter frequently where the indentation is off when I copy and paste code snippets. With this extension, when code is copied it will automatically be formatted to take care of the leading indentation issue. Now if only there was some system-level utility to this do when copying from anywhere… ...

Copy git link extension

2025-06-16 Update: This is now built-in to Visual Studio. Today I learned about the Copy Git Link extension for Visual Studio which will give you the url of currently selected lines on your git hosting provider i.e azure devops or GitHub. Especially handy for quickly pointing a teammate to a particular part of the codebase.

You can save window layouts in Visual Studio

If you go to Window > Save Window Layout, it’ll save your current window layout in Visual Studio. For example, when I have to go from my monitor setup to just my laptop, I tend to set the solution explorer to auto-hide and make the Test Explorer smaller. Now I can do it with just a keyboard shortcut!

Visual Studio 2022 can stage individual lines in git

Visual Studio added support for staging to commit individual chunks of changes (also known as interactive staging). This essentially lets you commit only parts of the changes you’ve made to a file or easily undo those changes. This is probably my most-used feature in a git gui client. One caveat, it took me a minute to figure out how to use it in VS because if you have an external diff tool configured in git then clicking to view the diff in VS will open that tool instead of the VS diff viewer. But you can also stage lines by clicking on the margin annotations: ...

Create new files faster

You can use ctrl+shift+a to open the new quick add dialog in VS 2022: https://devblogs.microsoft.com/visualstudio/adding-new-files-just-got-a-lot-faster/