Skip to content

Instantly share code, notes, and snippets.

@cwvhogue
Last active December 23, 2015 18:19
Show Gist options
  • Select an option

  • Save cwvhogue/6675078 to your computer and use it in GitHub Desktop.

Select an option

Save cwvhogue/6675078 to your computer and use it in GitHub Desktop.
Command to clean up MapReduce ImageMagick identify output and convert to .csv file
cat mr_identify.txt | \
awk '{print $7 " " $1 " " $3}' | \
sed 's/.\///' | \
sort -n | \
sed -e 's/MB/ MB/' -e 's/KB/ KB/' | \
-e 's/+0+0//' -e 's/x/ /' | \
awk '{print $1 ", " $2 ", " $3 ", " $4 ", " $5}' > Getty_Filesizes.csv
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment