Created
March 7, 2019 10:59
-
-
Save vepetkov/5f8332940d6c01c525c55ae7e840fe8c to your computer and use it in GitHub Desktop.
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
# Unzip in-place (i.e. in the folder containing the file and not the current one) | |
find . -type f -name "*.zip" | xargs -P4 -I fileName sh -c 'unzip -o -d "$(dirname "fileName")" "fileName" && rm "fileName"' | |
# Gzip all CSV extracted from the ZIP files | |
find . -type f -name *.csv -print0 | xargs -0 -n1 -P4 gzip |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment