Created
August 29, 2011 06:05
-
-
Save TonnyXu/1177857 to your computer and use it in GitHub Desktop.
Count lines of source code files
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wc -l `find . -type f \( -name "*.h" -or -name "*.m" \)` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If we swap the order of
wc
andfind
command, we can get almost a same result, but a little different thatfind . -type f \( -name "*.h" -or -name "*.m" \) -exec wc -l {} \;
will not print the total result.