Home Explore Blog CI



man-pages

13th chunk of `less.man`
4393b33521abaa30d62c3970e9fdefac9bfbaa3f0c4307440000000100000fbd
 moderately "quiet" operation: the terminal bell is not rung if an attempt is made to scroll past the end of the file or before the beginning of the file.  If the terminal has a "visual bell", it is  used
              instead.  The bell will be rung on certain other errors, such as typing an invalid character.  The default is to ring the terminal bell in all such cases.

       -Q or --QUIET or --SILENT
              Causes totally "quiet" operation: the terminal bell is never rung.  If the terminal has a "visual bell", it is used in all cases where the terminal bell would have been rung.

       -r or --raw‐control‐chars
              Causes  "raw"  control characters to be displayed.  The default is to display control characters using the caret notation; for example, a control‐A (octal 001) is displayed as "^A".  Warning: when the -r option
              is used, less cannot keep track of the actual appearance of the screen (since this depends on how the screen responds to each type of control character).  Thus, various display problems may result, such as long
              lines being split in the wrong place.

              USE OF THE -r OPTION IS NOT RECOMMENDED.

       -R or --RAW‐CONTROL‐CHARS
              Like -r, but only ANSI "color" escape sequences and OSC 8 hyperlink sequences are output in "raw" form.  Unlike -r, the screen appearance is maintained correctly, provided that there are no escape sequences  in
              the  file  other  than these types of escape sequences.  Color escape sequences are only supported when the color is changed within one line, not across lines.  In other words, the beginning of each line is as‐
              sumed to be normal (non‐colored), regardless of any escape sequences in previous lines.  For the purpose of keeping track of screen appearance, these escape sequences are assumed to not move the cursor.

              OSC 8 hyperlinks are sequences of the form:

                   ESC ] 8 ; ... \7

              The terminating sequence may be either a BEL character (\7) or the two‐character sequence "ESC \".

              ANSI color escape sequences are sequences of the form:

                   ESC [ ... m

              where the "..." is zero or more color specification characters.  You can make less think that characters other than "m" can end ANSI color escape sequences by setting the environment  variable  LESSANSIENDCHARS
              to  the  list of characters which can end a color escape sequence.  And you can make less think that characters other than the standard ones may appear between the ESC and the m by setting the environment vari‐
              able LESSANSIMIDCHARS to the list of characters which can appear.

       -s or --squeeze‐blank‐lines
              Causes consecutive blank lines to be squeezed into a single blank line.  This is useful when viewing nroff output.

       -S or --chop‐long‐lines
              Causes lines longer than the screen width to be chopped (truncated) rather than wrapped.  That is, the portion of a long line that does not fit in the screen width is not displayed until you press  RIGHT‐ARROW.
              The default is to wrap long lines; that is, display the remainder on the next line.

       -ttag or --tag=tag
              The  -t  option,  followed  immediately  by  a TAG, will edit the file containing that tag.  For this to work, tag information must be available; for example, there may be a file in the current directory called
              "tags", which was previously built by ctags(1) or an equivalent command.  If the environment variable LESSGLOBALTAGS is set, it is taken to be the name of a command compatible with global(1), and  that  command
              is  executed  to  find  the tag.  (See http://www.gnu.org/software/global/global.html).  The -t option may also be specified from within less (using the - command) as a way of examining a new file.  The command
              ":t" is equivalent to specifying

Title: Less Command Options: Quiet Mode, Raw Control Characters, Squeezing Blank Lines, and Tag Editing
Summary
This section describes command-line options for `less`, including different levels of quiet operation to suppress terminal bell sounds (-q, -Q), how to display raw control characters (-r, -R), the ability to squeeze multiple blank lines into one (-s), truncating long lines (-S), and editing files containing a specific tag (-t).