Home » Questions » Computers [ Ask a new question ]

less command with multiple files: How to navigate to next/previous

less command with multiple files: How to navigate to next/previous

"I just found out I can use less with multiple files. less status line tells me
(END) - Next: file2.txt"

Asked by: Guest | Views: 279
Total answers/comments: 2
Guest [Entry]

"We read in the manpage:

:n Examine the next file (from the list of files given in the com‐
mand line). If a number N is specified, the N-th next file is
examined.
:p Examine the previous file in the command line list. If a number
N is specified, the N-th previous file is examined."
Guest [Entry]

Found out from :h (help window) that I can use :p (for previous) and :n (for next)