There might be better places to ask but I already have an account here and like this ravenous crowd.
So, I have a script that uses an incrementing variable within a filename. That filename is generated using a leading zero for the digits "01" through "09." When I increment in the script, it drops the leading zero off rendering the script unable to locate the file.
Thanks!?Code:for ($day = 01; $day < 31; $day++) { system ("ssh remote_machine \"cat /log/reports/$year/$month/$day/summary_$year-$month-$day.txt | grep -v 'whatever'\" >> $temp_file 2>/dev/null");
Bookmarks