Wikia

Vim Tips Wiki

Changes: Avoiding the "Hit ENTER to continue" prompts

Edit

Back to page

(Uploaded by JohnBot from a locally edited file)
(Move categories to tip template)
Line 8: Line 8:
 
|version=5.7
 
|version=5.7
 
|rating=33/20
 
|rating=33/20
  +
|category1=Options
  +
|category2=Usage
 
}}
 
}}
The "Hit ENTER to continue" prompt is caused by not having enough space to display a message to the user before the screen is redrawn. To avoid the "Hit ENTER to continue" prompt, you can either shorten the messages or increase the space for displaying messages.
+
The "Hit ENTER to continue" prompt is caused by not having enough space to display a message to the user before the screen is redrawn. To avoid the "Hit ENTER to continue" prompt, you can either shorten the messages or increase the space for displaying messages.
   
 
To decrease message size, use the 'shortmess' option. Add the following line to your .vimrc file:
 
To decrease message size, use the 'shortmess' option. Add the following line to your .vimrc file:
Line 21: Line 23:
 
:set cmdheight=2
 
:set cmdheight=2
   
The default command height is 1. Increasing the cmdheight will allow more room for commands, although it will take some space away from editing.
+
The default command height is 1. Increasing the cmdheight will allow more room for commands, although it will take some space away from editing.
   
 
==References==
 
==References==
Line 32: Line 34:
   
 
----
 
----
[[Category:Options]]
 
[[Category:Usage]]
 

Revision as of 10:57, April 24, 2008

Tip 16 Printable Monobook Previous Next

created February 24, 2001 · complexity basic · author Yegappan · version 5.7


The "Hit ENTER to continue" prompt is caused by not having enough space to display a message to the user before the screen is redrawn. To avoid the "Hit ENTER to continue" prompt, you can either shorten the messages or increase the space for displaying messages.

To decrease message size, use the 'shortmess' option. Add the following line to your .vimrc file:

:set shortmess=a

This will use abbreviations for status messages to make lines shorter.

To give more space for displaying messages, you can increase the height of the command line to 2 or greater:

:set cmdheight=2

The default command height is 1. Increasing the cmdheight will allow more room for commands, although it will take some space away from editing.

References

Comments

The "Hit ENTER to continue" commands that I find most annoying are actually disabled by setting shortmess="oO" rather than "a". shortmess is set to "filnxtToO" by default, so these messages should not appear by default anyhow.


Around Wikia's network

Random Wiki