My Fav bash less commands.

September 13th, 2013 by Andrea Matesi 1590 Views

Just kidding...

Everybody knows less (it doesn't mean people are becoming more stupid!), if you don't, you don't know what you're missing.

Let me show you less:

Knowing less means also knowing less is better than more :D

less I-know-less.log

It's especially useful when used with the log files from /var/log.

Once you know less, you should also know less commands!

less commands to do more than more!

This is a list of my favourite less commands.

I evidenced the most useful one (in my experience).

command description
My favourite less commands.
<spacebar> Scroll forward 1 page.
CTRL+B Scroll backward 1 page.
Finds the "txt2srch" string inside your open file.
Next occurrence of searched string (ie.with a /).
Search backwards.
Go to beginning of open file.
Go to EOF.
v Opens current file with vi (but then you'll have to quit twice...).
Opens next file (ie. less file1 file2).
Opens previous file.
Quit less.















Posted in LINUX, System Administration | Comments Off on My Fav bash less commands.

Comments are closed.