Skip to content

Instantly share code, notes, and snippets.

@fitz123
Last active August 29, 2015 14:24
Show Gist options
  • Save fitz123/93a1dd777aeb3499b2a9 to your computer and use it in GitHub Desktop.
Save fitz123/93a1dd777aeb3499b2a9 to your computer and use it in GitHub Desktop.
Find all files video type
# find files of specific type
find /mnt/Private/YandexDisk/photos -type f -exec file -N -i -- {} + | sed -n 's!: video/[^:]*$!!p'
# exclude regex "127.0.*" from 4th column, "[ut][dc]p6" from 1st column, and exclude 2nd column 2 times
netstat -tulpan | awk '$4!~"127.0."' | awk '$1!~"[ut][dc]p6"' | sed -r 's/(\s+)?\S+//2' | sed -r 's/(\s+)?\S+//2'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment