remove all blank lines

When I 'vi' my test file I see some blank lines. However once I do :set list to display hidden characters, I see the empty lines literally like this:

^I$

How do I remove them? I cannot find a regex to match them.

did you try if it matches /\t+$/

Ok, I figured it out. the ^I represents the tab. So this one worked for me:

sed '/\t$/d' file-with-empty-lines > no-empty-lines

---------- Post updated at 05:34 PM ---------- Previous update was at 05:32 PM ----------

daptal, yes that was exactly the case (i am glad I got to the right answer independently, but thanks for your quick response!).

awk NF empty-lines-file >  no-empty-lines-file