• Home
  • Docker
  • Kubernetes
  • LLMs
  • Java
  • Ubuntu
  • Maven
  • Big Data
  • Archived
Linux-Ubuntu | less -- displays files
  1. Notes
  2. Examples
  3. Command Help (man less)

  1. Notes

    The less command takes a list of file names for its arguments and displays its contents screen by screen.

    ► Press q to quit.

    ► Press e to scroll forward one line.
    ► Press y to scroll backward one line.

    ► Press f to scroll forward one window (or press the spacebar).
    ► Press b to scroll backward one window.
    ► Press d to scroll forward one half-window.
    ► Press u to scroll backward one half-window.

    ► Press g to jump to first line in the current file.
    ► Press G to jump to last line in current file.

    ► Press :n to move to the next file ().
    ► Press :q to move to the previous file.

    ► Press Ctrl+g (or Ctrl+G) to show the current file name, start/end number of lines shown, bytes read, and percentage of data shown. Example : file1 lines 52-102/118 byte 6992/8145 85% (press RETURN)
  2. Examples
  3. Command Help (man less)
    • The following commands can be used to scroll forward/backward:

    • The following commands can be used to search forward/backward:

      The pattern is a regular expression, as recognized by the regular expression library supplied by your system.
      The search starts at the first line displayed.

      Certain characters are special if entered at the beginning of the pattern; they modify the type of search rather than become part of the pattern (see bellow).

    • The following commands can be used to search forward/backward:
© 2025  mtitek