Lines Matching +full:in +full:- +full:line

4 less \- display the contents of a file in a terminal
6 .B "less \-?"
8 .B "less \-\-help"
10 .B "less \-V"
12 .B "less \-\-version"
14 .B "less [\-[+]aABcCdeEfFgGiIJKLmMnNqQrRsSuUVwWX\(ti]"
16 .B " [\-b \fIspace\/\fP] [\-h \fIlines\/\fP] [\-j \fIline\/\fP] [\-k \fIkeyfile\/\fP]"
18 .B " [\-{oO} \fIlogfile\/\fP] [\-p \fIpattern\/\fP] [\-P \fIprompt\/\fP] [\-t \fItag\/\fP]"
20 .B " [\-T \fItagsfile\/\fP] [\-x \fItab\/\fP,...] [\-y \fIlines\/\fP] [\-[z] \fIlines\/\fP]"
22 .B " [\-# \fIshift\/\fP] [+[+]\fIcmd\/\fP] [\-\-] [\fIfilename\/\fP]..."
47 called N in the descriptions below.
51 In the following descriptions, \(haX means control-X.
52 ESC stands for the ESCAPE key; for example ESC-v means the
58 Scroll forward N lines, default one window (see option \-z below).
63 .IP "ESC-SPACE"
65 end-of-file in the process.
73 .IP "b or \(haB or ESC-v"
74 Scroll backward N lines, default one window (see option \-z below).
77 Like ESC-v, but if N is specified, it becomes the new window size.
90 .IP "ESC-) or RIGHTARROW"
92 (see the \-# option).
95 While the text is scrolled, it acts as though the \-S option
96 (chop lines) were in effect.
97 .IP "ESC-( or LEFTARROW"
99 (see the \-# option).
102 .IP "ESC-} or \(haRIGHTARROW"
103 Scroll horizontally right to show the end of the longest displayed line.
104 .IP "ESC-{ or \(haLEFTARROW"
118 (The behavior is similar to the "tail \-f" command.)
122 you can also use \(haX or the character specified by the \-\-intr option.
123 If the input is a pipe and the \-\-exit-follow-on-close option is in effect,
127 .IP "ESC-F"
128 Like F, but as soon as a line is found which matches
131 .IP "g or < or ESC-<"
132 Go to line N in the file, default 1 (beginning of file).
134 .IP "G or > or ESC->"
135 Go to line N in the file, default the end of the file.
139 .IP "ESC-G"
141 goes to the last line which is currently buffered.
146 Go to the line containing byte offset N in the file.
148 If a left curly bracket appears in the top line displayed
152 line of the screen.
153 If there is more than one left curly bracket on the top line,
154 a number N may be used to specify the N-th bracket on the line.
156 If a right curly bracket appears in the bottom line displayed
160 line of the screen.
161 If there is more than one right curly bracket on the bottom line,
162 a number N may be used to specify the N-th bracket on the line.
171 .IP "ESC-\(haF"
176 go forward to the > which matches the < in the top displayed line.
177 .IP "ESC-\(haB"
182 go backward to the < which matches the > in the bottom displayed line.
185 marks the first displayed line with that letter.
186 If the status column is enabled via the \-J option,
187 the status column shows the marked line.
189 Acts like m, except the last displayed line is marked
190 rather than the first displayed line.
203 .IP "ESC-m"
207 Search forward in the file for the N-th line containing the pattern.
211 By default, searching is case-sensitive (uppercase and lowercase
212 are considered different); the \-i option can be used to change this.
213 The search starts at the first line displayed
214 (but see the \-a and \-j options, which change this).
226 the search continues in the next file in the command line list.
228 Begin the search at the first line of the FIRST file
229 in the command line list,
231 or the settings of the \-a or \-j options.
240 Only text which has a non-empty match for the N-th parenthesized SUB-PATTERN
247 to match more than one sub-pattern.
251 without finding a match, the search continues from the first line of the
252 current file up to the line where it started.
259 Search backward in the file for the N-th line containing the pattern.
260 The search starts at the last line displayed
261 (but see the \-a and \-j options, which change this).
263 Certain characters are special as in the / command:
271 the search continues in the previous file in the command line list.
273 Begin the search at the last line of the last file
274 in the command line list,
276 or the settings of the \-a or \-j options.
278 As in forward searches.
280 As in forward searches.
282 As in forward searches.
286 without finding a match, the search continues from the last line of the
287 current file up to the line where it started.
289 .IP "ESC-/pattern"
291 .IP "ESC-?pattern"
294 Repeat previous search, for N-th line containing the last pattern.
296 N-th line NOT containing the pattern.
298 in the next (or previous) file if not satisfied in the current file.
303 Repeat previous search, but in the reverse direction.
304 .IP "ESC-n"
307 .IP "ESC-N"
308 Repeat previous search, but in the reverse direction
310 .IP "ESC-u"
313 If highlighting is already off because of a previous ESC-u command,
316 (Highlighting can also be disabled by toggling the \-G option;
317 in that case search commands do not turn highlighting back on.)
318 .IP "ESC-U"
319 Like ESC-u but also clears the saved search pattern.
320 If the status column is enabled via the \-J option,
321 this clears all search matches marked in the status column.
327 While filtering is in effect, an ampersand is displayed at the
329 as a reminder that some lines in the file may be hidden.
330 Multiple & commands may be entered, in which case only lines
333 Certain characters are special as in the / command:
344 below) from the list of files in the command line is re-examined.
345 A percent sign (%) in the filename is replaced by the name of the
351 in the name.
353 The filename is inserted into the command line list of files
358 the entire filename should be enclosed in double quotes
359 (also see the \-" option).
365 Examine the next file (from the list of files given in the command line).
366 If a number N is specified, the N-th next file is examined.
368 Examine the previous file in the command line list.
369 If a number N is specified, the N-th previous file is examined.
371 Examine the first file in the command line list.
372 If a number N is specified, the N-th file in the list is examined.
377 See the \-t option for more details about tags.
381 Search forward in the file for the N-th next OSC 8 hyperlink.
383 Search backward in the file for the N-th previous OSC 8 hyperlink.
389 and the line number and byte offset of the bottom line being displayed.
391 the number of lines in the file
392 and the percent of the file above the last displayed line.
393 .IP \-
394 Followed by one of the command line option letters (see OPTIONS below),
397 If a \(haP (CONTROL-P) is entered immediately after the dash,
399 If the option letter has a numeric value (such as \-b or \-h),
400 or a string value (such as \-P or \-t),
404 .IP \-\-
405 Like the \- command, but takes a long option name (see OPTIONS below)
409 message describing the new setting, as in the \- command.
410 .IP \-+
411 Followed by one of the command line option letters
414 (The "\-+\fIX\fP" command does the same thing
415 as "\-+\fIX\fP" on the command line.)
416 This does not work for string-valued options.
417 .IP \-\-+
418 Like the \-+ command, but takes a long option name
420 .IP \-!
421 Followed by one of the command line option letters,
424 This does not work for numeric or string-valued options.
425 .IP \-\-!
426 Like the \-!\& command, but takes a long option name
430 Followed by one of the command line option letters,
462 .IP "! shell-command"
463 Invokes a shell to run the shell-command given.
464 A percent sign (%) in the command is replaced by the name of the
469 If a \(haP (CONTROL-P) is entered immediately after the !,
473 On MS-DOS, Windows, and OS/2 systems, the shell is the normal command processor.
474 .IP "# shell-command"
476 except that the command is expanded in the same way as prompt strings.
478 .IP "| <m> shell-command"
487 If a \(haP (CONTROL-P) is entered immediately after the mark letter,
494 Run a shell command to open the URI in the current OSC 8 hyperlink,
499 or is empty if there is no colon in the URI.
500 The value of the environment variable is then expanded in the same way as
501 prompt strings (in particular, any instance of "%o" is replaced with the URI)
510 the value of the id parameter in another OSC 8 link in the same file,
516 the specified filename is opened in the current instance of
520 In a simple case where the opener accepts the complete URI
521 as a command line parameter, the handler may be as simple as
527 In other cases, the URI may need to be modified, so the handler
541 set LESS_OSC8_file to "-" to indicate that the default value
547 The handler should take care to appropriately quote parameters in the opener command,
548 to prevent execution of unintended shell commands in the case of opening
557 such as while in the F command, pressing \(haX
565 The \-\-intr option can be used to specify a different character
575 Command line options are described below.
578 is running, via the "\-" command.
580 Some options may be given in one of two forms:
585 For example, \-\-quit-at-eof may be abbreviated \-\-quit, but not
586 \-\-qui, since both \-\-quit-at-eof and \-\-quiet begin with \-\-qui.
587 Some long option names are in uppercase, such as \-\-QUIT-AT-EOF, as
588 distinct from \-\-quit-at-eof.
590 the remainder of the name may be in either case.
591 For example, \-\-Quit-at-eof is equivalent to \-\-QUIT-AT-EOF.
595 to avoid typing "less \-options \&...\&" each time
600 setenv LESS "\-options"
605 LESS="\-options"; export LESS
607 On MS-DOS and Windows, you don't need the quotes, but you should
608 be careful that any percent signs in the options string are not
611 The environment variable is parsed before the command line,
612 so command line options override the LESS environment variable.
613 If an option appears in the LESS variable, it can be reset
614 to its default value on the command line by beginning the command
615 line option with "\-+".
617 Some options like \-k or \-D require a string to follow the option letter.
619 For example, you can set two \-D options like this:
623 If the \-\-use-backslash option appears earlier in the options, then
624 a dollar sign or backslash may be included literally in an option string
626 If the \-\-use-backslash option is not in effect, then backslashes are
628 in the option string.
629 .IP "\-? or \-\-help"
634 it may be necessary to quote the question mark, thus: "\-\e?".)
635 .IP "\-a or \-\-search-skip-screen"
639 which start after or before the "target" line respectively;
640 see the \-j option for more about the target line).
641 The \-a option causes forward searches to instead start at
645 .IP "\-A or \-\-SEARCH-SKIP-SCREEN"
646 Causes all forward searches (not just non-repeated searches)
647 to start just after the target line, and all backward searches
648 to start just before the target line.
650 (from the first line up to and including the target line).
652 from the last line up to and including the target line.
653 This was the default behavior in less versions prior to 441.
654 .IP "\-b\fIn\fP or \-\-buffers=\fIn\fP"
657 will use for each file, in units of kilobytes (1024 bytes).
659 (unless the file is a pipe; see the \-B option).
660 The \-b option specifies instead that \fIn\fP kilobytes of
662 If \fIn\fP is \-1, buffer space is unlimited; that is,
664 .IP "\-B or \-\-auto-buffers"
669 The \-B option disables this automatic allocation of buffers for pipes,
671 (or the amount of space specified by the \-b option)
673 Warning: use of \-B can result in erroneous display, since only the
674 most recently viewed part of the piped data is kept in memory;
677 .IP "\-c or \-\-clear-screen"
678 Causes full screen repaints to be painted from the top line down.
681 .IP "\-C or \-\-CLEAR-SCREEN"
682 Same as \-c, for compatibility with older versions of
684 .IP "\-d or \-\-dumb"
685 The \-d option suppresses the error message
689 The \-d option does not otherwise change the behavior of
692 .IP "\-D\fBx\fP\fIcolor\fP or \-\-color=\fBx\fP\fIcolor\fP"
704 Header lines and columns, set via the \-\-header option.
706 Mark letters in the status column.
708 Line numbers enabled via the \-N option.
716 The highlight enabled via the \-w option.
717 .IP "1-5"
718 The text in a search result which matches
719 the first through fifth parenthesized sub-pattern.
720 Sub-pattern coloring works only if
735 The uppercase letters and digits can be used only when the \-\-use-color option is enabled.
742 overstriking with backspaces (see the \-U option) and to non-content
743 text (such as line numbers and prompts),
744 but not to text formatted using ANSI escape sequences with the \-R option
745 (but see the note below for different behavior on Windows and MS-DOS).
749 For example, \-Dug displays underlined text as green without underlining;
751 But \-Du+g displays underlined text as both green and in underlined format.
753 \fIcolor\fP is either a 4-bit color string or an 8-bit color string:
755 A 4-bit color string is one or two characters, where
776 For example, \-DNGk displays line numbers as bright green text on a black
777 background, and \-DEbR displays error messages as blue text on a
779 If either character is a "-" or is omitted, the corresponding color
782 An 8-bit color string is one or two decimal integers separated by a dot,
790 If either integer is a "-" or is omitted,
793 A 4-bit or 8-bit color string may be followed by one or more of the
794 following characters to set text attributes in addition to the color.
804 On MS-DOS and Windows, the \-\-color option behaves
805 differently from what is described above in these ways:
811 escape sequences with \-R,
812 in addition to overstruck and non-content text (but see \-Da).
817 but instead as a 4-bit
824 https://learn.microsoft.com/en-us/windows/console/char-info-str).
828 be used after a lowercase color selector on MS-DOS/Windows.
833 Only a limited set of ANSI escape sequences to set color in the content work correctly.
834 4-bit color sequences work, but "CSI 38;5" color sequences do not.
836 The \-Da option makes the behavior of \-\-color
837 more similar to its behavior on non-MS-DOS/Windows systems by (1)
840 allowing "CSI 38;5" color sequences in the content
842 earlier Windows systems, such sequences do not work regardless of the setting of \-Da).
844 .IP "\-e or \-\-quit-at-eof"
848 the second time it reaches end-of-file.
852 .IP "\-E or \-\-QUIT-AT-EOF"
855 to automatically exit the first time it reaches end-of-file.
856 .IP "\-f or \-\-force"
857 Forces non-regular files to be opened.
858 (A non-regular file is a directory or a device special file.)
862 will refuse to open non-regular files.
864 to be read, even if \-f is set.
865 .IP "\-F or \-\-quit-if-one-screen"
870 .IP "\-g or \-\-hilite-search"
874 The \-g option changes this behavior to highlight only the particular string
879 .IP "\-G or \-\-HILITE-SEARCH"
880 The \-G option suppresses all highlighting of strings found by search commands.
881 .IP "\-h\fIn\fP or \-\-max-back-scroll=\fIn\fP"
884 the screen is repainted in a forward direction instead.
886 backward, \-h0 is implied.)
887 .IP "\-i or \-\-ignore-case"
891 appear in the search pattern;
892 in other words,
894 .IP "\-I or \-\-IGNORE-CASE"
895 Like \-i, but searches ignore case even if
897 .IP "\-j\fIn\fP or \-\-jump-target=\fIn\fP"
898 Specifies a line on the screen where the "target" line
900 The target line is the line specified by any command to
901 search for a pattern, jump to a line number,
903 The screen line may be specified by a number: the top line on the screen
905 The number may be negative to specify a line relative to the bottom
906 of the screen: the bottom line on the screen is \-1, the second
907 to the bottom is \-2, and so on.
908 Alternately, the screen line may be specified as a fraction of the height
909 of the screen, starting with a decimal point: \&.5 is in the middle of the
910 screen, \&.3 is three tenths down from the first line, and so on.
911 If the line is specified as a fraction, the actual line number
913 If the \-\-header option is used and the target line specified by \-j
914 would be obscured by the header, the target line is moved to the first
915 line after the header.
916 While the \-\-header option is active, the \-S option is ignored,
920 If any form of the \-j option is used,
922 begin at the line immediately after the target line,
923 and repeated backward searches begin at the target line,
924 unless changed by \-a or \-A.
925 For example, if "\-j4" is used, the target line is the
926 fourth line on the screen, so forward searches begin at the fifth line
931 .IP "\-J or \-\-status-column"
933 The character displayed in the status column may be one of:
936 The line is chopped with the \-S option, and
940 The line is horizontally shifted, and
944 The line is both chopped and shifted,
947 There are matches in the visible part of the line
949 .IP "a-z, A-Z"
950 The line has been marked with the corresponding letter via the m command.
952 .IP "\-k\fIfilename\fP or \-\-lesskey-file=\fIfilename\fP"
958 Multiple \-k options may be specified.
960 if a lesskey file is found in a standard place (see KEY BINDINGS),
964 Note the warning under "\-\-lesskey-content" below.
965 .IP "\-\-lesskey-src=\fIfilename\fP"
972 if a lesskey source file is found in a standard place (see KEY BINDINGS),
990 Note the warning under "\-\-lesskey-content" below.
991 .IP "\-\-lesskey-content=\fItext\fP"
995 In the text,
1002 which are used early in startup,
1003 cannot be set in a file specified by a command line option
1004 (\-\-lesskey, \-\-lesskey-src or \-\-lesskey-content). When using a
1009 a command line option.
1010 .IP "\-K or \-\-quit-on-intr"
1020 .IP "\-L or \-\-no-lessopen"
1027 .IP "\-m or \-\-long-prompt"
1036 .IP "\-M or \-\-LONG-PROMPT"
1041 .IP "\-n or \-\-line-numbers"
1042 Suppresses line numbers.
1043 The default (to use line numbers) may cause
1045 to run more slowly in some cases, especially with a very large input file.
1046 Suppressing line numbers with the \-n option will avoid this problem.
1047 Using line numbers means: the line number will be displayed in the verbose
1048 prompt and in the = command,
1049 and the v command will pass the current line number to the editor
1050 (see also the discussion of LESSEDIT in PROMPTS below).
1051 .IP "\-N or \-\-LINE-NUMBERS"
1052 Causes a line number to be displayed at the beginning of
1053 each line in the display.
1054 .IP "\-o\fIfilename\fP or \-\-log-file=\fIfilename\fP"
1063 .IP "\-O\fIfilename\fP or \-\-LOG-FILE=\fIfilename\fP"
1064 The \-O option is like \-o, but it will overwrite an existing
1068 the \-o and \-O options can be used from within
1072 The "s" command is equivalent to specifying \-o from within
1074 .IP "\-p\fIpattern\fP or \-\-pattern=\fIpattern\fP"
1075 The \-p option on the command line is equivalent to
1079 to start at the first occurrence of \fIpattern\fP in the file.
1080 .IP "\-P\fIprompt\fP or \-\-prompt=\fIprompt\fP"
1083 This option would normally be put in the LESS environment
1084 variable, rather than being typed in with each
1087 Such an option must either be the last option in the LESS variable,
1089 \-Ps followed by a string changes the default (short) prompt
1091 \-Pm changes the medium (\-m) prompt.
1092 \-PM changes the long (\-M) prompt.
1093 \-Ph changes the prompt for the help screen.
1094 \-P= changes the message printed by the = command.
1095 \-Pw changes the message printed while waiting for data (in the "F" command).
1100 .IP "\-q or \-\-quiet or \-\-silent"
1108 The default is to ring the terminal bell in all such cases.
1109 .IP "\-Q or \-\-QUIET or \-\-SILENT"
1112 If the terminal has a "visual bell", it is used in all cases
1114 .IP "\-r or \-\-raw-control-chars"
1117 for example, a control-A (octal 001) is displayed as "\(haA"
1118 (with some exceptions as described under the \-U option).
1119 Warning: when the \-r option is used,
1125 such as long lines being split in the wrong place.
1127 USE OF THE \-r OPTION IS NOT RECOMMENDED.
1128 .IP "\-R or \-\-RAW-CONTROL-CHARS"
1129 Like \-r, but only ANSI "color" escape sequences and OSC 8 hyperlink
1130 sequences are output in "raw" form.
1131 Unlike \-r, the screen appearance is maintained correctly,
1132 provided that there are no escape sequences in the file
1135 is changed within one line, not across lines.
1136 In other words, the beginning of each line is assumed to be
1137 normal (non-colored), regardless of any escape sequences in previous lines.
1146 or the two-character sequence "ESC \\".
1163 .IP "\-s or \-\-squeeze-blank-lines"
1164 Causes consecutive blank lines to be squeezed into a single blank line.
1168 .IP "\-S or \-\-chop-long-lines"
1171 That is, the portion of a long line that does not fit in
1172 the screen width is not displayed until you press RIGHT-ARROW.
1174 on the next line.
1175 See also the \-\-wordwrap option.
1176 .IP "\-t\fItag\fP or \-\-tag=\fItag\fP"
1177 The \-t option, followed immediately by a TAG,
1180 for example, there may be a file in the current directory called "tags",
1192 The \-t option may also be specified from within
1194 (using the \- command) as a way of examining a new file.
1195 The command ":t" is equivalent to specifying \-t from within
1197 .IP "\-T\fItagsfile\fP or \-\-tag-file=\fItagsfile\fP"
1199 .IP "\-u or \-\-underline-special"
1201 that is, they are sent to the terminal when they appear in the input.
1202 .IP "\-U or \-\-UNDERLINE-SPECIAL"
1205 that is, they are handled as specified by the \-r option.
1207 By default, if neither \-u nor \-U is given,
1218 Other carriage returns are handled as specified by the \-r option.
1222 if neither \-u nor \-U is in effect.
1224 See also the \-\-proc-backspace, \-\-proc-tab,
1225 and \-\-proc-return options.
1226 .IP "\-V or \-\-version"
1229 .IP "\-w or \-\-hilite-unread"
1230 Temporarily highlights the first "new" line after a forward movement
1232 The first "new" line is the line immediately following the line previously
1234 Also highlights the target line after a g or p command.
1236 If the \-\-status-line option is in effect, the entire line
1238 Otherwise, only the text in the line is highlighted,
1239 unless the \-J option is in effect,
1240 in which case only the status column is highlighted.
1241 .IP "\-W or \-\-HILITE-UNREAD"
1242 Like \-w, but temporarily highlights the first new line after any
1243 forward movement command larger than one line.
1244 .IP "\-x\fIn\fP,...\& or \-\-tabs=\fIn\fP,..."
1250 For example, "-x9,17" will set tabs at positions 9, 17, 25, 33, etc.
1252 .IP "\-X or \-\-no-init"
1257 .IP "\-y\fIn\fP or \-\-max-forw-scroll=\fIn\fP"
1261 The \-c or \-C option may be used to repaint from the top of
1264 .IP "\-z\fIn\fP or \-\-window=\fIn\fP or \-\fIn\fP"
1275 For example, if the screen is 24 lines, \fI\-z\-4\fP sets the
1278 .IP "\-\(dq\fIcc\fP\ or\ \-\-quotes=\fIcc\fP"
1291 remains \-" (a dash followed by a double quote).
1292 .IP "\-\(ti or \-\-tilde"
1295 .IP "\-# or \-\-shift"
1297 in the RIGHTARROW and LEFTARROW commands.
1305 .IP "\-\-exit-follow-on-close"
1310 .IP "\-\-file-size"
1311 If \-\-file-size is specified,
1315 Then the "=" command will display the number of lines in the file.
1317 is non-seekable (such as a pipe) and is large.
1318 .IP "\-\-follow-name"
1323 If \-\-follow-name is specified, during an F command
1331 .IP "\-\-header=\fIL\fP,\fIC\fP,\fIN\fP"
1340 The first header line is set to line number \fIN\fP in the file.
1342 the number of the line currently displayed in the first line of the screen
1343 (if the \-\-header command has been issued from within
1345 or 1 (if the \-\-header option has been given on the command line).
1346 The special form "\-\-header=\-" disables header lines and header columns,
1347 and is equivalent to "\-\-header=0,0".
1350 of the screen are replaced with the \fIL\fP lines of the file beginning at line \fIN\fP,
1352 When header lines are displayed, any file contents before the header line cannot be viewed.
1354 beginning of each line are replaced with the first \fIC\fP characters of the line,
1355 even if the rest of the line is scrolled horizontally.
1357 .IP "\-\-incsearch"
1360 will advance to the next line containing the search pattern
1361 as each character of the pattern is typed in.
1362 .IP "\-\-intr=\fIc\fP"
1369 .IP "\-\-line-num-width=\fIn\fP"
1370 Sets the minimum width of the line number field when the \-N option is in effect
1373 .IP "\-\-match-shift=\fIn\fP"
1374 When \-S is in effect, if a search match is not visible
1378 This option selects the column in which the first character
1380 In other words, there will be \fIn\fP characters visible
1388 .IP "\-\-modelines=\fIn\fP"
1392 will read the first \fIn\fP lines to try to find a vim-compatible
1400 A modeline contains, anywhere in the line,
1412 then tab stops are automatically set as if \-\-tabs=\fIn\fP had been given.
1413 See the \-\-tabs description for acceptable values of \fIn\fP.
1415 .IP "\-\-mouse"
1417 scrolling the mouse wheel down moves forward in the file,
1418 scrolling the mouse wheel up moves backwards in the file,
1419 left-click sets the "#" mark to the line where the mouse is clicked,
1420 and right-click (or any other) returns to the "#" mark position.
1421 If a left-click is performed with the mouse cursor on an OSC 8 hyperlink,
1423 If a left-click is performed with the mouse cursor on an OSC 8 hyperlink
1426 can be set by the \-\-wheel-lines option.
1430 .IP "\-\-MOUSE"
1431 Like \-\-mouse, except the direction scrolled
1433 .IP "\-\-no-keypad"
1437 keypad behave in an undesirable manner.
1438 .IP "\-\-no-histdups"
1440 file name is typed in, and the same string is already in the history list,
1442 Thus, a given string will appear only once in the history list.
1444 .IP "\-\-no-number-headers"
1445 Header lines (defined via the \-\-header option) are not assigned line numbers.
1446 Line number 1 is assigned to the first line after any header lines.
1447 .IP "\-\-no-search-header-lines"
1449 .IP "\-\-no-search-header-columns"
1451 .IP "\-\-no-search-headers"
1453 .IP "\-\-no-vbell"
1455 .IP "\-\-proc-backspace"
1456 If set, backspaces are handled as if neither the \-u option
1457 nor the \-U option were set.
1459 displayed in underline mode, and a backspace between identical
1460 characters cause text to be displayed in boldface mode.
1461 This option overrides the \-u and \-U options, so that display of
1463 If not set, backspace display is controlled by the \-u and \-U options.
1464 .IP "\-\-PROC-BACKSPACE"
1465 If set, backspaces are handled as if the \-U option were set;
1467 .IP "\-\-proc-return"
1468 If set, carriage returns are handled as if neither the \-u option
1469 nor the \-U option were set.
1471 This option overrides the \-u and \-U options, so that display of
1473 If not set, carriage return display is controlled by the \-u and \-U options.
1474 .IP "\-\-PROC-RETURN"
1475 If set, carriage returns are handled as if the \-U option were set;
1477 .IP "\-\-proc-tab"
1478 If set, tabs are handled as if the \-U option were not set.
1480 This option overrides the \-U option, so that display of
1482 If not set, tab display is controlled by the \-U options.
1483 .IP "\-\-PROC-TAB"
1484 If set, tabs are handled as if the \-U option were set;
1486 .IP "\-\-redraw-on-quit"
1494 .IP "\-\-rscroll=\fIc\fP"
1496 It may begin with a two-character attribute indicator like LESSBINFMT does.
1498 If set to "\-", truncated lines are not marked.
1499 .IP "\-\-save-marks"
1500 Save marks in the history file, so marks are retained
1503 .IP "\-\-search-options=\fI...\fP"
1509 For example, setting \-\-search-options=W is the same as
1514 The value "-" disables all default search modifiers.
1515 .IP "\-\-show-preproc-errors"
1517 then exits with a non-zero exit code,
1520 .IP "\-\-status-col-width=\fIn\fP"
1521 Sets the width of the status column when the \-J option is in effect.
1523 .IP "\-\-status-line"
1524 If a line is marked, the entire line (rather than just the status column)
1526 Also lines highlighted due to the \-w option will have
1527 the entire line highlighted.
1528 If \-\-use-color is set, the line is colored rather than highlighted.
1529 .IP "\-\-use-backslash"
1531 After the \-\-use-backslash option, any backslash in an option string is
1533 This allows a dollar sign to be included in option strings.
1534 .IP "\-\-use-color"
1535 Enables colored text in various places.
1536 The \-D option can be used to change the colors.
1538 ANSI color escape sequences (as defined in
1540 https://www.ecma-international.org/publications-and-standards/standards/ecma-48).
1542 .IP "\-\-wheel-lines=\fIn\fP"
1544 and the \-\-mouse or \-\-MOUSE option is in effect.
1545 The default is 1 line.
1546 .IP "\-\-wordwrap"
1547 When the \-S option is not in use,
1548 wrap each line at a space or tab if possible,
1551 .IP \-\-
1552 A command line argument of "\-\-" marks the end of option arguments.
1554 This can be useful when viewing a file whose name begins with a "\-" or "+".
1556 If a command line option begins with \fB+\fP,
1562 and +/xyz tells it to start at the first occurrence of "xyz" in the file.
1564 that is, it starts the display at the specified line number
1571 .SH "LINE EDITING"
1572 When entering a command line at the bottom of the screen
1575 certain keys can be used to manipulate the command line.
1576 Most commands have an alternate form in [ brackets ] which can be used if
1579 in some MS-DOS and Windows systems because ESC is the line erase character.)
1583 .IP "LEFTARROW [ ESC-h ]"
1585 .IP "RIGHTARROW [ ESC-l ]"
1587 .IP "\(haLEFTARROW [ ESC-b or ESC-LEFTARROW ]"
1590 .IP "\(haRIGHTARROW [ ESC-w or ESC-RIGHTARROW ]"
1593 .IP "HOME [ ESC-0 ]"
1594 Move the cursor to the beginning of the line.
1595 .IP "END [ ESC-$ ]"
1596 Move the cursor to the end of the line.
1599 or cancel the command if the command line is empty.
1600 .IP "DELETE or [ ESC-x ]"
1602 .IP "\(haBACKSPACE [ ESC-BACKSPACE ]"
1605 .IP "\(haDELETE [ ESC-X or ESC-DELETE ]"
1608 .IP "UPARROW [ ESC-k ]"
1609 Retrieve the previous command line.
1612 .IP "DOWNARROW [ ESC-j ]"
1613 Retrieve the next command line.
1619 is entered into the command line.
1622 (On MS-DOS and Windows systems, a "\e" is appended.)
1625 .IP "BACKTAB [ ESC-TAB ]"
1626 Like, TAB, but cycles in the reverse direction thru the matching filenames.
1630 the command line (if they fit).
1631 .IP "\(haU (Unix and OS/2) or ESC (MS-DOS and Windows)"
1632 Delete the entire command line,
1633 or cancel the command if the command line is empty.
1634 If you have changed your line-kill character in Unix to something
1637 Delete the entire command line and return to the main prompt.
1645 You may also change the line-editing keys (see LINE EDITING),
1657 looks in a standard place for the lesskey source file:
1661 On MS-DOS and Windows systems,
1664 then looks for a lesskey file called "_lesskey" in any directory specified
1665 in the PATH environment variable.
1669 then looks for a lesskey file called "lesskey.ini" in any directory specified
1670 in the INIT environment variable, and if it not found there,
1671 then looks for a lesskey file called "lesskey.ini" in any directory specified
1672 in the PATH environment variable.
1674 A system-wide lesskey source file may also be set up to provide key bindings.
1675 If a key is defined in both a local lesskey file and in the
1676 system-wide file, key bindings in the local file take precedence over
1677 those in the system-wide file.
1680 uses that as the name of the system-wide lesskey file.
1683 looks in a standard place for the system-wide lesskey file:
1684 On Unix systems, the system-wide lesskey file is /usr/local/etc/syslesskey.
1689 On MS-DOS and Windows systems, the system-wide lesskey file is c:\e_syslesskey.
1690 On OS/2 systems, the system-wide lesskey file is c:\esyslesskey.ini.
1711 in place of the contents of the original file.
1717 An input preprocessor receives one command line argument, the original filename,
1726 to a command line which will invoke your input preprocessor.
1727 This command line should include one occurrence of the string "%s",
1733 closes a file opened in such a way, it will call another program,
1735 which may perform any desired clean-up action (such as deleting the
1737 This program receives two command line arguments, the original filename
1740 to a command line which will invoke your input postprocessor.
1747 to keep files in compressed format, but still let
1755 case "$1" in
1759 uncompress \-c $1 >$TEMPFILE 2>/dev/null
1761 if [ \-s $TEMPFILE ]; then
1767 rm \-f $TEMPFILE
1802 make the first character in the LESSOPEN environment variable a
1804 As with non-pipe input preprocessors, the command string must contain one
1814 case "$1" in
1816 *.Z) uncompress \-c $1 2>/dev/null
1849 In this case, the replacement file name passed to the LESSCLOSE
1850 postprocessor is "\-".
1857 However, if the first character of LESSOPEN is a dash (\-),
1859 In this case, the dash is not considered to be part of
1864 (|\-) or two vertical bars and a dash (||\-),
1866 Again, in this case the dash is not considered to be part of
1870 There are three types of characters in the input file:
1875 in ordinary text files (such as backspace and tab).
1878 in text files.
1897 Selects a character set appropriate for MS-DOS.
1900 .IP IBM-1047
1903 by setting either LESSCHARSET=IBM-1047 or LC_CTYPE=en_US
1904 in your environment.
1905 .IP koi8-r
1909 .IP utf-8
1910 Selects the UTF-8 encoding of the ISO 10646 character set.
1911 UTF-8 is special in that it supports multi-byte characters in the input file.
1912 It is the only character set that supports multi-byte characters.
1916 In rare cases, it may be desired to tailor
1919 In this case, the environment variable LESSCHARDEF can be used
1921 It should be set to a string where each character in the string represents
1922 one character in the character set.
1943 IBM-1047 4cbcbc3b9cbccbccbb4c6bcc5b3cbbc4bc4bccbc
1946 koi8-r 8bcccbcc18b95.b128.
1953 but any of the strings "UTF-8", "UTF8", "utf-8" or "utf8"
1954 is found in the LC_ALL, LC_CTYPE or LANG
1955 environment variables, then the default character set is utf-8.
1967 interface is also not available, the default character set is utf-8.
1969 Control and binary characters are displayed in standout (reverse video).
1970 Each such character is displayed in caret notation if possible
1971 (e.g.\& \(haA for control-A). Caret notation is used only if
1972 inverting the 0100 bit results in a normal printable character.
1973 Otherwise, the character is displayed as a hex number in angle brackets.
1982 printf-style escape sequence (a % followed by x, X, o, d, etc.).
1984 are displayed in underlined hexadecimal surrounded by brackets.
1989 When the character set is utf-8, the LESSUTFBINFMT environment variable
1998 Problematic octets in a UTF-8 file (octets of a truncated sequence,
1999 octets of a complete but non-shortest form sequence, invalid octets,
2002 of how the UTF-8 file is ill-formed.
2004 When the character set is utf-8, in rare cases it may be desirable to
2006 For example, characters in a Private Use Area are normally treated as control
2008 in that range, it may be desirable to tell
2012 to a comma-separated list of
2021 If there are multiple comma-separated codepoint values,
2022 they must be in ascending numerical order.
2028 A wide (2-space) printable character.
2030 A binary (non-printable) character.
2038 E000-F8FF:p,F0000-FFFFD:p,100000-10FFFD:p
2043 The \-P option allows you to tailor the prompt to your preference.
2044 The string given to the \-P option replaces the specified prompt string.
2045 Certain characters in the string are interpreted specially.
2057 which specifies the line whose byte offset is to be used.
2058 If the character is a "t", the byte offset of the top line in the
2060 an "m" means use the middle line,
2061 a "b" means use the bottom line,
2062 a "B" means use the line just after the bottom line,
2063 and a "j" means use the "target" line, as specified by the \-j option.
2067 Replaced by the column number of the text appearing in the first
2070 Replaced by the page number of a line in the input file.
2071 The line to be used is determined by the \fIX\fP, as with the %b option.
2073 Replaced by the number of pages in the input file,
2074 or equivalently, the page number of the last line in the input file.
2084 Replaced by the shell-escaped name of the current input file.
2085 This is useful when the expanded string will be used in a shell command,
2086 such as in LESSEDIT.
2088 Replaced by the index of the current file in the list of
2091 Replaced by the line number of a line in the input file.
2092 The line to be used is determined by the \fIX\fP, as with the %b option.
2094 Replaced by the line number of the last line in the input file.
2100 This is used by OSC 8 handlers as explained in the \(haO\(haO command description.
2103 The line used is determined by the \fIX\fP as with the %b option.
2105 Replaced by the percent into the current input file, based on line numbers.
2106 The line used is determined by the \fIX\fP as with the %b option.
2114 However if viewing files via a tags list using the \-t option,
2117 Replaced by the name of the next input file in the list.
2127 and condition character, up to a period, are included in the prompt.
2131 the colon and the period are included in the string if and only if
2135 True if any characters have been included in the prompt so far.
2137 True if the byte offset of the specified line is known.
2143 True if the page number of the specified line is known.
2145 True if at end-of-file.
2150 True if the line number of the specified line is known.
2152 True if the line number of the last line in the file is known.
2156 True if this is the first prompt in a new input file.
2159 of the specified line is known.
2161 True if the percent into the current input file, based on line numbers,
2162 of the specified line is known.
2172 Any of the special characters may be included in the prompt literally
2182 ?f%f \&.?ltLine %lt:?pt%pt\e%:?btByte %bt:-...
2185 The filename is followed by the line number, if known,
2192 ?n?f%f\ .?m(%T %i of %m)\ ..?e(END)\ ?x-\ Next\e:\ %x..%t
2194 This prints the filename if this is the first prompt in a file,
2197 Then, if we are at end-of-file, the string "(END)" is printed
2202 the other two prompts (\-m and \-M respectively).
2206 ?n?f%f\ .?m(%T\ %i\ of\ %m)\ ..?e(END)\ ?x-\ Next\e:\ %x.:
2209 ?f%f\ .?n?m(%T\ %i\ of\ %m)\ ..?ltlines\ %lt-%lb?L/%L.\ :
2210 byte\ %bB?s/%s.\ .?e(END)\ ?x-\ Next\e:\ %x.:?pB%pB\e%..%t
2216 ?f%f\ .?m(%T\ %i\ of\ %m)\ .?ltlines\ %lt-%lb?L/%L.\ .
2223 The LESSEDIT string is expanded in the same way as the prompt strings.
2231 line number, followed by the shell-escaped file name.
2233 differences in invocation syntax, the LESSEDIT variable can be
2239 runs in a "secure" mode.
2240 In this mode, these features are disabled:
2246 metacharacters such as * in filenames,
2252 use of lesskey files (-k and \-\-lesskey-src)
2256 log files (s and \-o)
2268 use of tags files (-t)
2270 The LESSSECURE_ALLOW environment variable can be set to a comma-separated list
2272 Each feature name is the first word in each line in the above list.
2285 Less can also be compiled to be permanently in "secure" mode.
2286 In that case, the LESSSECURE and LESSSECURE_ALLOW variables are ignored.
2292 behaves (mostly) in conformance with the POSIX
2295 In this mode, less behaves differently in these ways:
2297 The \-e option works differently.
2298 If the \-e option is not set,
2300 behaves as if the \-e option were set.
2301 If the \-e option is set,
2303 behaves as if the \-E option were set.
2305 The \-m option works differently.
2306 If the \-m option is not set, the medium prompt is used,
2307 and it is prefixed with the string "\-\-More\-\-".
2308 If the \-m option is set, the short prompt is used.
2310 The \-n option acts like the \-z option.
2311 The normal behavior of the \-n option is unavailable in this mode.
2313 The parameter to the \-p option is taken to be a
2318 and the MORE environment variable is used in its place.
2321 Environment variables may be specified either in the system environment
2322 as usual, or in a
2325 If environment variables are defined in more than one place,
2326 variables defined in a local lesskey file take precedence over
2327 variables defined in the system environment, which take precedence
2328 over variables defined in the system-wide lesskey file.
2343 (only in the Windows version).
2359 end character in an ANSI color escape sequence
2362 Format for displaying non-printable, non-control characters.
2368 Command line to invoke the (optional) input-postprocessor.
2372 in filenames on Unix systems.
2377 Name of the command used by the \-t option to find global tags.
2385 If set to "\-" or "/dev/null", a history file is not used.
2391 .IP "Windows and MS-DOS"
2397 The maximum number of commands to save in the history file.
2408 The value is parsed as if it were the parameter of a \-\-lesskey-content option.
2410 Name of the default system-wide
2414 Name of the default system-wide
2420 Prefix which less will add before each metacharacter in a
2425 Command line to invoke the (optional) input-preprocessor.
2427 Runs less in "secure" mode.
2433 String to be appended to a directory name in filename completion.
2435 Format for displaying non-printable Unicode code points.
2459 Duration (in milliseconds) after starting to read data from the input,
2476 A space-separated list of command line options.
2478 on the command line or in the LESS environment variable.
2479 Options listed in LESS_UNSUPPORT can still be changed by the \- and \-\- commands.
2480 Each option in LESS_UNSUPPORT is a dash followed by a single character
2491 automatically when running in
2492 .BR more "-compatible mode."
2495 on MS-DOS, Windows, and OS/2 systems).
2518 Copyright (C) 1984-2024 Mark Nudelman
2525 See the file README in the less distribution for more details
2530 Suite 330, Boston, MA 02111-1307, USA.
2534 less is distributed in the hope that it will be useful, but