diff options
author | Luis Lozano <llozano@chromium.org> | 2015-11-04 17:48:32 -0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2015-11-05 03:15:34 +0000 |
commit | 1af9294993f129f2286c961a19a04babddd2572d (patch) | |
tree | 1e517fa6f6b56c683e51cc52eacadc8ca6d3f9b1 /auto_delete_nightly_test_data.py | |
parent | 89d263c7cf9773129cbe8e8858ad21ea539a2ba0 (diff) | |
download | toolchain-utils-1af9294993f129f2286c961a19a04babddd2572d.tar.gz |
Make cleaning of nightly data less verbose.
The nightly process for clean up of old data is too verbose
and makes the summary report difficult to follow.
BUG=None
TEST=None
Change-Id: I3b1e18c0d913e47d4281617970a7e9a2ea0d9eb1
Reviewed-on: https://chrome-internal-review.googlesource.com/237839
Commit-Ready: Luis Lozano <llozano@chromium.org>
Tested-by: Luis Lozano <llozano@chromium.org>
Reviewed-by: Han Shen <shenhan@google.com>
Diffstat (limited to 'auto_delete_nightly_test_data.py')
-rwxr-xr-x | auto_delete_nightly_test_data.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/auto_delete_nightly_test_data.py b/auto_delete_nightly_test_data.py index 8a9a105a..17e67e74 100755 --- a/auto_delete_nightly_test_data.py +++ b/auto_delete_nightly_test_data.py @@ -47,7 +47,7 @@ def CleanNumberedDir(s, dry_run=False): if dry_run: print cmd else: - if ce.RunCommand(cmd, return_output=False, print_to_console=True, + if ce.RunCommand(cmd, return_output=False, print_to_console=False, terminated_timeout=480) == 0: print 'Successfully removed "{0}".'.format(s) else: @@ -97,12 +97,12 @@ def CleanChromeOsTmpAndImages(): r'-amin +1440 ' r'-exec bash -c "echo rm -fr {{}}" \; ' r'-exec bash -c "rm -fr {{}}" \;').format(chromeos_chroot_tmp) - rv = ce.RunCommand(cmd, return_output=False, print_to_console=True) + rv = ce.RunCommand(cmd, return_output=False, print_to_console=False) if rv == 0: - print ('Successfully cleaned chromeos tree tmp directory ' + print ('Successfully cleaned chromeos tree tmp directory ' '"{0}".'.format(chromeos_chroot_tmp)) else: - print ('Some directories are not removed under chromeos tree ' + print ('Some directories were not removed under chromeos tree ' 'tmp directory -"{0}".'.format(chromeos_chroot_tmp)) # Clean image tar files, which were last accessed 1 hour ago and clean image @@ -113,11 +113,11 @@ def CleanChromeOsTmpAndImages(): r' -name "chromiumos_test_image.bin" -amin +1440 \) ' r'-exec bash -c "echo rm -f {{}}" \; ' r'-exec bash -c "rm -f {{}}" \;').format(chromeos_chroot_tmp) - rv2 = ce.RunCommand(cmd, return_output=False, print_to_console=True) + rv2 = ce.RunCommand(cmd, return_output=False, print_to_console=False) if rv2 == 0: - print 'Successfully cleaned chromeos images.' + print 'Successfully cleaned chromeos images.' else: - print 'Some chromeos images are not removed.' + print 'Some chromeos images were not removed.' return rv + rv2 |