Kohei Nozaki's blog 

jEdit conditional line deleting with regex

Posted on Sunday Jan 31, 2016 at 06:03PM in Technology

How to delete lines that contains a keyword?

Open Search And Replace dialog and turn Regular expressions on then put ^.*KEYWORD.*$\n to Search for box, leave Replace with blank then hit Replace All.

How to delete lines that NOT contains a keyword?

With ^((?!KEYWORD).)*$\n do the same to the above. for detail check http://stackoverflow.com/questions/406230/regular-expression-to-match-line-that-doesnt-contain-a-word

No one has commented yet.

Leave a Comment

HTML Syntax: NOT allowed