in reply to Append to file or create file depending on input filename.
open $filehandle, (@ARGV == 1 ? '>' : ()), @ARGV; [download]