Delete old files
This commit is contained in:
parent
2702fb96f4
commit
81a068f1db
@ -7,7 +7,6 @@ import argparse
|
||||
import contextlib
|
||||
import datetime
|
||||
import fcntl
|
||||
import glob
|
||||
import logging
|
||||
import os
|
||||
import re
|
||||
@ -541,8 +540,13 @@ Dir::Etc::preferencesparts "/var/empty";
|
||||
def sync(self) -> None:
|
||||
for branch in self.branches:
|
||||
remote = self.remote(branch)
|
||||
files = glob.glob(f'{self.images_dir}/{branch}/*')
|
||||
cmd = ['rsync', '-v'] + files + [remote]
|
||||
cmd = [
|
||||
'rsync',
|
||||
f'{self.images_dir}/{branch}/',
|
||||
'-rv',
|
||||
'--delete',
|
||||
remote,
|
||||
]
|
||||
self.call(cmd)
|
||||
|
||||
self.kick()
|
||||
|
Loading…
Reference in New Issue
Block a user