Menu

del the line in many file

reww reww
2009-09-01
2012-11-13
  • reww reww

    reww reww - 2009-09-01

    if i want to del the line which include specific word.

    e.g.
    1234ab55678

    i want del all line that include "ab" at once
    how to do that?

     
    • Dave Brotherstone

      You can't really do that in Notepad++ as it stands, as far as I know.  You can blank the lines though, if that will do, using regular expressions. Just set the replace option to "regular expressions" and enter the following

      Find:
      ^.*ab.*$

      Replace:
      - just leave the replace field blank.

      Enhanced regular expression support is high on the wanted list, so hopefully it will be integrated soon.  Vote for it on ideatorrent (from the Hosted Apps menu on the Notepad++ project page)

      You can do it very easily with grep though, (have a look at the unxutils project - http://unxutils.sourceforge.net/\)

      grep -v ab filename.txt

      Hope that helps,
      Dave.

       
MongoDB Logo MongoDB