Given the following input…
;
; comment
; another comment
;
data
data
I am looking for a regular expression that can be used to strip the blank lines and return only the two lines containing the “data” (but leaving the line breaks intact).
Thanks.
Edit
Wait, I think I understand what you mean: you only want to preserve the line breaks after your “data” lines. If so, try:
A small explanation: