title: Can Notepad++ save out search results to a text file?
body: <p>I need to do quite a few regular expression search/replaces throughout hundreds and hundreds of static files.  I'm looking to build an audit trail so I at least know what files were touched by what searches/replaces.</p>
  
  <p>I can do my regular expression searches in Notepad++ and it gives me file names/paths and number of hits in each file.  It also gives me the line #s which I don't really care that much about.</p>
  
  <p>What I really want is a separate text file of the file names/paths.  The # of hits in each file would be a nice addition, but really it's just a list of file names/paths that I'm after.</p>
  
  <p>In Notepad++'s search results pane, I can do a right click and copy, but that includes all the line #s and code which is just too much noise, especially when you're getting hundreds of matches.</p>
  
  <p>Anyone know how I can get these results to just the file name/paths?  I'm after something like:</p>
  
  <pre><code>/about/foo.html
  /about/bar.html
  /faq/2012/awesome.html
  /faq/2013/awesomer.html
  /foo/bar/baz/wee.html
  etc.
  </code></pre>
  
  <p>Then I can name that file regex_whatever_search.txt and at the top of it include the regex used for the search and replace.  Below that, I've got my list of files it touched.</p>
  
  <p><strong>UPDATE</strong> What looks like the easiest thing to do (at least that I've found) is to just copy all the search results into a new text file and run the following regex:</p>
  
  <p>^\tLine.+$</p>
  
  <p>And replace that with an empty string.  That'll give you just the file path and hit counts with a lot of empty space between each entry.  Then run the following regex:</p>
  
  <p>\s+\n</p>
  
  <p>And replace with:</p>
  
  <p>\n</p>
  
  <p>That'll strip out all the unwanted empty space and you'll be left with a nice list.</p>