-
Notifications
You must be signed in to change notification settings - Fork 1
Browsing with less
Jason Charney edited this page Jan 30, 2015
·
1 revision
NOTE: For the Ruby/JavaScript thing called LESS, see LESS.
less is a utility that Linux that is described simply as "The opposite of more".
When I use less it is generally on the right side of a pipe with the following for options.
| less -eFMXR
-
-eQuit at end-of-file (EOF) -
-FQuit if one screen -
MMakelessprompt more verobsely thamore -
XDisable sending termcap initialization and deinitialization command to the screen. Prevents wiping the screen when you leave less pressingq. -
RAllow raw control characters, usefull if you like color output withlsorgrep.
There are plenty of uses for the less command.
cat file.ext | less -eFMXR # brows a file
ls -la | less -eFMXR # browse a folder with lots of files
More examples on [Browse directories with ls](Browse directories with ls)
tar -tjvf something.tar.bz2 | less -eFMXR # brows files in a package
More examples on [Download using curl and tar](Download using curl and tar)
dpkg --list | grep -i sed | less -eFMXR # browse filtered results
More examples on [Search files with grep](Search files with grep)
curl -SL http://www.weather.gov/lsx | less -eFMXR # browse the source code of a web page.
More examples on [Download using curl and tar](Download using curl and tar)
- [Search files with grep](Search files with grep)