Created
November 17, 2015 00:07
-
-
Save diegoperini/c853687fc7263e2a445f to your computer and use it in GitHub Desktop.
count-lines
This file contains 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
#!/bin/sh | |
# | |
# Simple shell script to count number of lines in every | |
# file with given file extension in current directory. | |
# | |
# Usage: | |
# ./count-lines.sh 'js' | |
# ./count-lines.sh 'cpp' | |
find . -name '*.'$1 | xargs wc -l |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment