How to list files based on sizes?
Posted on 2004-08-05
For you experts I guess it's a small thing, for me as newbie it's a puzzle.
I need a script (Bourne shell) which lists all files in a directory which are not 0 bytes.
So if the directory /tmp has the files
I expect a string back like "/tmp/file2.dat /tmp/file4.dat /tmp/file5.dat"
And it would be nice if I could pass the directory as input parameter (or via variable)
Can anyone help?