Permalink
Browse files

• exclude the +++/--- lines when calculating statistics (thanks to Gr…

…ant Hollingworth)

git-svn-id: http://svn.textmate.org/trunk/Bundles/Diff.tmbundle@6058 dfb7d73b-c2ec-0310-8fea-fb051d288c6d
  • Loading branch information...
1 parent 3744dc9 commit 6143dd6be421830b4066906eb84c817fd3f866a2 @sorbits sorbits committed Nov 10, 2006
Showing with 4 additions and 2 deletions.
  1. +4 −2 Commands/Statistics (Lines Added:Removed).plist
@@ -5,8 +5,10 @@
<key>beforeRunningCommand</key>
<string>nop</string>
<key>command</key>
- <string>tee &gt;(add=$(grep ^+|wc -l); echo 1&gt;&amp;2 "Lines Added $add") \
- |{ rem=$(grep ^-|wc -l); wait; echo "Lines Removed $rem"; }</string>
+ <string>egrep -v '^(\+\+\+|---) '|\
+ tee &gt;(add=$(grep ^+|wc -l); echo 1&gt;&amp;2 "Lines Added $add") \
+ |{ rem=$(grep ^-|wc -l); wait; echo "Lines Removed $rem"; }
+</string>
<key>input</key>
<string>document</string>
<key>keyEquivalent</key>

0 comments on commit 6143dd6

Please sign in to comment.