my $date = qx/date/; #### use POSIX 'strftime'; my $today = strftime '%d-%m-%Y', localtime;