This extension only works for the older editor. For VSMac 8.4, you should install VsVim instead as VsVim works on the new editor.
Some file types (e.g. F#) are still currently using the old editor in VSMac. This addin will still work for those file types while the transition is made to the new editor.
Interact with Visual Studio for Mac as follows:
Visual Studio -> Extensions -> Gallery -> IDE Extensions -> "VIM" -> Install
Then close the current document that you are working on and open a new document to activate the plugin.
Unfortunately, this addin does not work with the new editor that was made default in 8.1. To use this addin, make sure that the old editor is in use.
Alternatively, I have been working on making VsVim work for the new editor. If you want to try this out, please follow the instructions here
Most Vim commands should work. If you see something that doesn't work, please file an issue. There's a good chance that I just don't know about it.
- Vim split windows. XSVim uses VS for Mac's side by side mode to emulate this, but it's only possible to have 2 vertical split windows.
<C-w>s
and<C-w>v
both switch to side by side mode. - Visual block mode works for most tasks, but there are some differences in the way that VS handles virtual spacing at the end of lines.
- Selecting text with the mouse or using cmd+arrow keys doesn't switch to Visual mode
- No leader key support or configurable key bindings.
Some Vim keybindings (such as Ctrl-F, Ctrl-D etc) conflict with VS's own built in keybindings. However, there is a keybinding scheme included that you may apply if you want (Visual Studio + Vim)
gd
- Goto declarationgu
- Find usagesgb
- Go to base symbolgh
- Show tooltip at current caret location (G
oH
over)hjkl
support on the Solution Explorer pad and Test Explorer pad. Pressing<esc>
on these will switch focus back to the last editor window.jk
support on the Search Results pad.- Goto Pad shortcuts start with
gp
gps
- Go to solution explorergpc
- Go to class padgpe
- Go to error list padgpt
- Go to Task List padgpp
- Go to Property padgpo
- Go to document outline padgpb
- Go to breakpoint padgpl
- Go to locals padgpw
- Go to watch padgpi
- Go to immediate padgpn
- Go to F# Interactive padgpf
- When there is only one search results pad, go to itgpf1
- When there is more than one search results pad, go to the 1stgpf2
- When there is more than one search results pad, go to the 2nd....etc.gpdt
- Go to debugger threads padgpds
- Go to debugger stack trace padgput
- Go to unit test padgpur
- Go to unit test results pad
- Insert mode escape binding. See example screenshot to see how to configure
jj
to escape when in insert mode.
Check the release page as there is usually a more recent version of the addin here than on the Visual Studio for Mac feed. Grab the .mpack file and install it via Visual Studio -> Extensions -> Install from file
Jump in our Gitter channel and introduce yourself.
- @shirshov
- @mdizzy
- @tdfacer