in reply to How do I test whether a file has some contents or not?
print "it's a non-empty text-ish file" if -s $file and -T $file; [download]