Last active
March 16, 2017 21:51
-
-
Save zflat/f46c8007f902501b32be8d5bee5d41c9 to your computer and use it in GitHub Desktop.
Count lines in csv files
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
# Count the number of rows in csv files not counting the header row | |
# (assuming the header has a column named "header_col") | |
cat *.csv | grep -w "header_col" -c -v | |
# recursive | |
find `pwd` | xargs cat | grep -w "user_id" -c -v | |
# also listing files in order | |
ls -lR --group-directories-first |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment