Jump to content

Grep Tutorial at Pinehead blog


amenditman

Recommended Posts

A really nice tutorial about using grep command. If you don't know it, you should. One of the most useful and powerful utilities built into Linux/Unix systems.

 

Check it out on pinehead.tv

 

The grep command allows searching the contents of a file from the

command line. It’s a very useful tool to find a particular line in,

say, a log file or a conf file. And because it’s a command line

program, you can combine it with other commands in various ways to

produce powerful results. In this tutorial, you will learn both the

basics and some more advanced applications of grep.

  • Like 2
Link to comment
Share on other sites

Nice tutorial!! I have used grep for many years but there were a few tips on that page that I was not familiar with. :thumbsup:

Yes, it is an extremely useful and flexible tool. But at the same time it follows the Unix philosophy, "a utility shall do only one thing and do it completely".

I am constantly reading the man page and the info pages for grep, every time I seem to find a new power feature I had not known before.

Link to comment
Share on other sites

Nice one! I learned something in the first example. Instead of doing

grep <needle> <haystack>

I've always done

cat <haystack> | grep <needle>

I will now save myself valuable seconds and wear on my fingers. :thumbsup: B)

  • Like 1
Link to comment
Share on other sites

Nice one! I learned something in the first example. Instead of doing

grep <needle> <haystack>

I've always done

cat <haystack> | grep <needle>

I will now save myself valuable seconds and wear on my fingers. :thumbsup: B)

Yay! Command line foo strikes again.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...