Sometimes you want the computer to shut down after you've finished downloading something or converting some large file into some other format, but you want to go out or go to sleep instead of waiting and checking for it yourself.
For these situations I've come up with two tiny scripts. The first one waits until a file hasn't changed its size on three consecutive intervals of twenty seconds:
Code:
a=0 ; file="$1" ; if [ -f "$file.part" ] ; then file="$file.part"
...