Find / GZIP

From Nocrashwiki

Find to exclude certain results.
This will find all files in the current directory excluding .gz .png, .tif*, .mov, .gif and .jpg and others...

find . -type f -not -name '*.gz' -not -name *.png -not -name '*.tif*' -not -name *.mov -not -name *.jpg -not -name '*.jpeg' -not -name '*.avi' -not -name *.gif -not -name '*.bz2' -not -name '*.zip' -not -name '*.rar' -exec gzip --best -v {} \;


Find files in a certain date range:

touch temp -t 200604141130
touch ntemp -t 200604261630
find /data/ -cnewer temp -and ! -cnewer ntemp