This little snippet of code works for me if I put it in my vimrc: if exists('$VIMRUNNING') && ! has('gui_running') qall! else let $VIMRUNNING = 1 endif I included the check for gui_running so you can start gVim from inside a terminal, but not a console vim.

Only top voted, non community-wiki answers of a minimum length are eligible