use String::ShellQuote; # this package almost never works my $Temp = shell_quote_best_effort('BulletinV3, 1 Montana 20xx-xx-xx (print).pdf_FN_TEMPLATE'); if (-e $Temp) { `zenity --width 300 --info --text 'DBG> Got it!'`; } else { `zenity --width 300 --error --text 'DBG> Nope, not found!'`; # this is what I get all the time } $rc = rename("BulletinV3, 1 Montana 20xx-xx-xx (print).pdf_FN_TEMPLATE", "BulletinV3, 1 Montana $SundayDate (print).pdf_FN_TEMPLATE"); if($rc == 1) { $ExtTypes{'pdf_FN_TEMPLATE'}++; } else { `zenity --title \"Rename problem\" --width 400 --error --text \"File rename error (\\\"$!\\\"; \\\"BulletinV3, 1 Montana 20xx-xx-xx (print).pdf_FN_TEMPLATE\\\")\"`; }