Skip to content

Instantly share code, notes, and snippets.

@jxu
Created October 18, 2019 21:27
Show Gist options
  • Save jxu/5e543d7d1703a2dee6f5db034f59c8c3 to your computer and use it in GitHub Desktop.
Save jxu/5e543d7d1703a2dee6f5db034f59c8c3 to your computer and use it in GitHub Desktop.
bash experiment
#!/bin/bash
# Doesn't seem to handle filenames with spaces correctly
find . -iname "*.png" -type f -exec identify -format '%w %h %i\n' '{}' \; |
awk '($1==1080 && $2==1920) || ($1==1920 && $2==1080) || ($1==648 && $2==1108) { print $3 }' | xargs cp -t filter
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment