diff options
Diffstat (limited to 'hosts/vidhar')
-rwxr-xr-x | hosts/vidhar/borg/copy.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/hosts/vidhar/borg/copy.py b/hosts/vidhar/borg/copy.py index 23c45fcf..64ae0a71 100755 --- a/hosts/vidhar/borg/copy.py +++ b/hosts/vidhar/borg/copy.py | |||
@@ -51,7 +51,7 @@ def read_repo(path): | |||
51 | return res | 51 | return res |
52 | 52 | ||
53 | class ToSync: | 53 | class ToSync: |
54 | to_sync = set() | 54 | to_sync = [] |
55 | 55 | ||
56 | def __iter__(self): | 56 | def __iter__(self): |
57 | return self | 57 | return self |
@@ -68,9 +68,7 @@ class ToSync: | |||
68 | print(err, file=stderr) | 68 | print(err, file=stderr) |
69 | continue | 69 | continue |
70 | 70 | ||
71 | for entry in src: | 71 | self.to_sync = [entry for entry in src if entry['name'] not in {dst_entry['name'] for dst_entry in dst} and not entry['name'].endswith('.checkpoint')] |
72 | if entry['name'] not in {dst_entry['name'] for dst_entry in dst} and not entry['name'].endswith('.checkpoint'): | ||
73 | self.to_sync.add(entry) | ||
74 | 72 | ||
75 | if self.to_sync: | 73 | if self.to_sync: |
76 | return self.to_sync.pop() | 74 | return self.to_sync.pop() |