Sunday, December 6, 2009

Grep for space and new line

I had to grep the following pattern followed by a new line :
"belongs to "
so it is
grep belongs[[:space:]]to[[:space:]]*$

I had to use '*' as I guess there are more characters than
space at the end.

No comments:

Blog Archive