4

When installing Vim for Windows 10 64-bit, it also installed an "Edit with Vim" context menu option. Annoyingly, this opens the file in gVim.

How do I change the "Edit with Vim" context menu option to open vim.exe instead of gVim.exe?

I looked in the registry and couldn't find it.

  • Could you expand your question to indicate how you are calling the "Edit with Vim" context menu? vim.exe is called from the command line. gvim.exe will start a window. Could you give more detail on how you plan to work with an example file? – StandardEyre Mar 16 '17 at 20:22
  • @StandardEyre It would seem you don't regularly use Windows (lucky you ;)... When you install Vim in Windows: an explorer context menu option is added to File Explorer (ie: when you right-click a file). It reads "Edit with Vim" for a single file. When more than 1 file is selected, there are 3 options: 1) Edit with multiple Vims, 2) Edit with single Vim, and 3) Diff with Vim. See this link. – Roflo Mar 16 '17 at 21:17
  • 1
    @Roflo Yes, I do not use Windows that often. I do understand the context menu option. :-) What I don't understand is the Original Poster's need to change the context menu default settings. I'm seeking clarification on the reason why the "Edit with Vim" context menu option defaults need to change (from gvim.exe to vim.exe). – StandardEyre Mar 16 '17 at 21:35
  • 1
    I want to use vim over gvim. – Accumulator Mar 16 '17 at 21:53
  • Which version of windows? Based on my experience, at least some of the registry hacks changed from 7 to 8. – Herb Wolfe Mar 17 '17 at 4:11
5

I did this by changing the registry key in [HKEY_LOCAL_MACHINE\SOFTWARE\Vim\Gvim]

"Edit with Vim" opens gVim:

path=C:\Program Files\Vim\vim74\gvim.exe

"Edit with Vim" opens Vim:

path=C:\Program Files\Vim\vim74\vim.exe

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.