Search and view gzip’d files

You knew it already – but I keep forgetting – the power of zgrep and zcat both of which behave as their z-less counterparts.

So, to search a gzip’d file, you can simply zgrep <term> <filename.gz>, or to cat/view it, zcat <filename.gz>

Good to come back to in case of impending forgetfulness…

Tags: , , , ,

Your Reply