Page 1 of 1

Deleting all lines except lines containing "this charac

Posted: Wed Jun 20, 2012 12:59 am
by afikolami
Well, basically what the topic says. For example:

>1
ababababab
>2
bcbcbcbcbcb
>3
dedededede

I want to delete all lines that do not have the ">" character. So the output would look like this:

>1
>2
>3

Can anybody lend me a hand?

Posted: Wed Jun 20, 2012 7:00 am
by ben_josephs
Search for: ^[^>]*\n

[X] Regular expression
[ ] "." matches end of line characters [i.e., not selected]

Replace with: [nothing]