loading...

re: Seeing Context with `grep` VIEW POST

FULL DISCUSSION
 

An even better way of "seeing the whole file" is to use cat... though if you only want a page or screenful at a time then less is definitely more.

 

Does cat do search highlighting?

 

No, because that's not its job. If you want search highlighting use a colourised grep. If you just want to see the whole file, use cat. Do one thing, do it well.

Yeah cool, just checking. Thanks for clarifying. This post was mostly about different ways to see more of the file as you searched for specific things, but you are right that if all you want to do is see the contents of the file, cat is the best option for short files. I appreciate the addition!

 
code of conduct - report abuse