1
0
Fork 0
bascht.com/content/tech/2009-11-24-exclude-svn-subd...

9 lines
826 B
HTML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: Exclude .svn subdirectories in your grep search
---
<p>Just a little reminder for myself: In 93 of 95 cases i want to exclude all of the <em>.svn</em> subdirectories lying around in my working copy.<br>Andreas brought that one to my mind again with a <a href="http://twitter.com/meandmymonkey/status/5827088917">nasty forest of grep pipes</a>. ;-)</p>
<p><code> grep -R --exclude \*.svn\* your_pattern</code></p>
<p>gives me only the output I really need.</p>
<p><strong>Update (2:42pm):</strong></p>
<p>Gosh. After <a href="http://twitter.com/denderello">@denderello</a> got nudged about my last blog post I gave <a href="http://betterthangrep.com/">http://betterthangrep.com/</a> a try.<br>It came via <strong>macports</strong> and I'm already loving it's colorful output and the per-file groups. Neato.</p>