On 02/01/10 15:34, Tim Chase wrote:
Dennis German wrote:
Has anyone written a script to intercept :x being input as text and
execute the :x
( or a :q which would fail with warning if changes were made),
   avoiding  the syndrome known as

:x [ente...@#$! [DEL][DEL][DEL][ESC]:x[ENTER]

I've never had the problem because I tend to live in normal mode,
leaving insert mode as soon as I've entered my text.  However, it
wouldn't be too hard to do something like

   :inoremap :x<cr>  <esc>:x<cr>

-tim




Yeah, and then someday Dennis will find himself typing something about Vim, having forgotten that he's put such a useful abbreviation in his vimrc, and when he turns to talk about exiting... suddenly his Vim (or the current window at least) will go away :-P


Best regards,
Tony.
--
As long as war is regarded as wicked, it will always have its
fascination.  When it is looked upon as vulgar, it will cease to be
popular.
                -- Oscar Wilde

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Reply via email to