Closed alekratz closed 7 years ago
I really wanted this yesterday when trying to debug counting for python. Totally think this should be a thing. Will do this soon, thanks.
Added here: https://github.com/cgag/loc/commit/6f0ffd644f8ac08fae399161a990940f984a4382
Plus some nice cleanup of the filter logic. Surprisingly it's just as fast as this code here, which avoids doing a match on the regex for every file: https://github.com/cgag/loc/commit/c08ef5a6d69cb84b0979dd166103d865ed9647eb. Thanks branch predictors.
--exclude
feature is nice to have when counting large projects. However, it would be awesome if there was an--include
regex flag as well.