The less
program displays a file’s contents one screen at a time. You can
navigate the file, move to a specific line, and search the file.
Here is an example file opened in less:
On the bottom you can see the message: sample_text lines 1-23/37 63%, which means that you’re viewing lines 1 to 23 of the file, which has 37 lines, and you’re viewing 63% of the file.
Here is a list of navigation commands used in less:
page down. space, f – one screen forward
page down, b – one screen backward
up arrow key – up a line
down arrow key – down a line
/ – searches the content
g NUMBER – moves to the specified line
q – quits the program
Here is an example file opened in less:
On the bottom you can see the message: sample_text lines 1-23/37 63%, which means that you’re viewing lines 1 to 23 of the file, which has 37 lines, and you’re viewing 63% of the file.
Here is a list of navigation commands used in less:
page down. space, f – one screen forward
page down, b – one screen backward
up arrow key – up a line
down arrow key – down a line
/ – searches the content
g NUMBER – moves to the specified line
q – quits the program
NOTE – the man system uses less to display information.
Post a Comment