-
-
Save rot26/a1918a918dfc89632ce160030363deec to your computer and use it in GitHub Desktop.
Recursively find and grep through multiple Excel spreadsheets
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
# convert *.xlsx to *.xlsx.csv using https://github.com/dilshod/xlsx2csv | |
pip install xlsx2csv | |
# (shell-fu from http://stackoverflow.com/a/12965604) | |
find . -iname "*.xlsx" -exec sh -c 'xlsx2csv "$1" > "$1.csv"' x {} \; | |
# grep .csv files | |
brew install ripgrep | |
rg -i -g "*.csv" "waldo" | |
# ...or plain ole grep | |
grep -ir --include "*.csv" "waldo" . |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment