From 3602b4e1ce5bc9003aafc8c9bf1add1d64512a23 Mon Sep 17 00:00:00 2001 From: "Dustin C. Hatch" Date: Sun, 12 Oct 2014 18:24:07 -0500 Subject: [PATCH] backup: Delete old files during backup --- backup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backup.py b/backup.py index 846e107..0a49a53 100755 --- a/backup.py +++ b/backup.py @@ -15,7 +15,7 @@ class BackupError(Exception): class Backup(object): RSYNC = os.environ.get('RSYNC', 'rsync') - RSYNC_DEFAULT_ARGS = ['-aO', '--partial'] + RSYNC_DEFAULT_ARGS = ['-aO', '--partial', '--delete'] RSYNC_EXTRA_ARGS = shlex.split(os.environ.get('RSYNC_EXTRA_ARGS', '')) log = logging.getLogger('backup')