Long Lines and Pagination

A session has a configuration that indicates the width of the terminal in characters and the length in lines. It uses these parameters to control handling of long input lines and to control pagination of multi-line output. For details about changing these parameters, see Understanding Terminal Parameters, page 16. Long lines come into play when a line is longer than the terminal width minus the prompt. In that case, part of the line will be hidden from display as indicated by ‘$’ at the beginning and/or end of the visible part of the line. For example:

my-device# $there is text to the left of what is visible here
my-device# there is text to the right of what is visible here$
my-device# $there is text at both ends of what is visible here$

The first line has scrolled left; the second line has scrolled right; the third line has been scrolled to the middle of a quite long line.

Pagination appears each time execution of a command causes output of more lines than what has been configured as the terminal length. A typical example is the output from show running-config. After the first several lines have been output, the pagination prompt is presented:

! [lines of text] -- more --, next page: Space, continue: g, quit: ^C

The following keys control pagination:

The terminal length (also sometimes called height) can be configured for the current session using the terminal length lines command. If lines = 0 is input, pagination is disabled.

my-device# terminal length 0
my-device# terminal length 25

The same is true for setting the terminal width in characters.

Last updated