1
0
Fork 0
mirror of https://gitlab.com/sortix/sortix.git synced 2023-02-13 20:55:38 -05:00
sortix--sortix/utils/pager.1
Juhani Krekelä 73e42780f4 Add more keybinds for scrolling in pager(1)
b commonly corresponds to Page Up, and f is added to match.

j and k for lines, ^F and ^B for pages, and g and G for home/end are from vi.

C-n and C-p for lines and C-v and M-v for pages are from Emacs.

< and > for home/end allow using Emacs M-< and M->, tho they are from less(1).
2021-05-04 22:14:47 +00:00

53 lines
1.4 KiB
Groff

.Dd October 5, 2016
.Dt PAGER 1
.Os
.Sh NAME
.Nm pager
.Nd display files one page at a time
.Sh SYNOPSIS
.Nm
.Op Fl Rr
.Ar file ...
.Sh DESCRIPTION
.Nm
displays the input one page at a time.
The input is the concatenation of the input files, or the standard input if no
files were specified and the standard input is not a terminal.
.Pp
The options are as follows:
.Bl -tag -width "12345678"
.It Fl R
Output only escape sequences that change font properties such as color and
boldness.
.It Fl r
Causes raw control characters to be dumped directly onto the terminal.
Usage of this option may cause output to be misleading for suspicious files, as
the escape codes in the file are rendered and can be used to hide parts of the
input.
Avoid the -r option if you want to see the actual bytes in the file, or use -R
to show only selected escape codes.
.El
.Sh COMMANDS
.Nm
supports the following key commands:
.Bl -tag -width "12345678"
.It Sy Enter , Down Arrow , j , ^N
Scroll the file one line down.
.It Sy Up Arrow , k , ^P
Scroll the file one line up.
.It Sy Space , Page Down , f , ^F , ^V
Scroll the file one page down.
.It Sy Page Up , b , ^B , ESC-v
Scroll the file one page up.
.It Sy End , G , >
Scroll all the way down to the end of the file.
.It Sy Home , g , <
Scroll all the way up to the beginning of the file.
.It Sy q , Q
Exit the pager.
.El
.Sh EXIT STATUS
.Nm
will exit 0 on success and non-zero otherwise.
.Sh SEE ALSO
.Xr editor 1