Open files in existing Gvim in multiple (new) tabs

前端 未结 6 1912
耶瑟儿~
耶瑟儿~ 2020-12-12 10:47

I have put some aliases in my .bashrc to open a group of project files in gvim, each in their own tab:

gvim -p 

        
6条回答
  •  青春惊慌失措
    2020-12-12 11:20

    Want your Windows context menu to allow you to open files in a new tab of the currently open gvim window?

    Save this as as a file called temp.reg and double-click it to add the settings to your registry. Be sure to modify the path to vim if yours is different.

    Windows Registry Editor Version 5.00
    [HKEY_CLASSES_ROOT\*\Shell\Open with &Vim]
    [HKEY_CLASSES_ROOT\*\Shell\Open with &Vim\command]
    @="\"C:\\Program Files (x86)\\Vim\\vim73\\gvim.exe\" -p --remote-tab-silent \"%1\" \"%*\""
    

    You will now have a context menu like this:

    vim context menu

提交回复
热议问题