📅 2010-Nov-29 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ vim, visual studio ⬩ 📚 Archive
If you are a Vim user, you will find yourself wanting to open certain Visual Studio source files in Vim for performing searches or edits. Adding Vim as an external tool to Visual Studio makes this operation easier, here is how.
Add ViM as External Tool
This can be done by adding ViM as an External Tool in Visual Studio. Go to Tools → External Tools and add ViM to the list with the settings shown in the above screenshot.
+$(CurLine) $(ItemPath) opens the current file in ViM with the cursor nicely placed on the same line as it was in Visual Studio.
Assign ViM a Keyboard Shortcut
Once ViM is added, it can be invoked as Tools → ViM. It is handy to be able to invoke it using a keyboard shortcut. This can be done in the Tools → Options dialog under Environment → Keyboard. Note the position of ViM in the list of External Tools. If ViM is in position 3, its command name will be
Tools.ExternalCommand3 and so on. Assign a convenient shortcut and you can now invoke ViM in Visual Studio painlessly! 😊