I'm trying to figure out a way to delete empty files in a directory. I have a cron that runs and creates a flat file every 15 mins. However, most times at night the flat file will be empty.
I'd like to run a script to delete empty files that end with *.dat
Read your man page before invoking this so you understand the implications - find goes through sub-directories by default and if you don't put the {} \; correctly, it will cause problems (could start deleting things you did not want to delete).