save a copy of the dated dir that was copied to ftp server and remove any previously saved builds older than 7 days (granrose)

This commit is contained in:
cltbld 2004-10-18 21:57:15 +00:00
Родитель 725c1b81b4
Коммит 645b684c44
1 изменённых файлов: 4 добавлений и 1 удалений

Просмотреть файл

@ -648,8 +648,11 @@ sub main {
return returnStatus("Pushing package $upload_directory failed", ("testfailed")); return returnStatus("Pushing package $upload_directory failed", ("testfailed"));
} }
if ($cachebuild) { if ($cachebuild) {
# remove saved builds older than a week and save current build
TinderUtils::run_shell_command "find $mozilla_build_dir -type d -name \"200*-*\" -prune -mtime +7 -print | xargs rm -rf";
TinderUtils::run_shell_command "cp -rdpf $upload_directory $mozilla_build_dir/$datestamp";
unlink "last-built"; unlink "last-built";
open BLAH, ">last-built"; open BLAH, ">last-built";
close BLAH; close BLAH;