summaryrefslogtreecommitdiff
path: root/hosts/vidhar/borg/copy.py
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2022-02-18 11:52:25 +0100
committerGregor Kleen <gkleen@yggdrasil.li>2022-02-18 11:52:25 +0100
commitacf3920a56b7b8b298f17e03441039bd97a1c232 (patch)
treecab997b72bee9a327b72bb7c9b403cf5e3666e0b /hosts/vidhar/borg/copy.py
parentfa3d816bce75223876744ce26857cb6d0fd49a2c (diff)
downloadnixos-acf3920a56b7b8b298f17e03441039bd97a1c232.tar
nixos-acf3920a56b7b8b298f17e03441039bd97a1c232.tar.gz
nixos-acf3920a56b7b8b298f17e03441039bd97a1c232.tar.bz2
nixos-acf3920a56b7b8b298f17e03441039bd97a1c232.tar.xz
nixos-acf3920a56b7b8b298f17e03441039bd97a1c232.zip
vidhar: ...
Diffstat (limited to 'hosts/vidhar/borg/copy.py')
-rwxr-xr-xhosts/vidhar/borg/copy.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/hosts/vidhar/borg/copy.py b/hosts/vidhar/borg/copy.py
index 7564378c..1714e2e8 100755
--- a/hosts/vidhar/borg/copy.py
+++ b/hosts/vidhar/borg/copy.py
@@ -56,7 +56,7 @@ def as_borg(caps=set()):
56def read_repo(path): 56def read_repo(path):
57 with Halo(text=f'Listing {path}', **halo_args) as sp: 57 with Halo(text=f'Listing {path}', **halo_args) as sp:
58 res = None 58 res = None
59 with subprocess.Popen(['borg', 'list', '--debug', '--lock-wait=600', '--json', path], stdout=subprocess.PIPE, preexec_fn=lambda: as_borg()) as proc: 59 with subprocess.Popen(['borg', 'list', '--info', '--lock-wait=600', '--json', path], stdout=subprocess.PIPE, preexec_fn=lambda: as_borg()) as proc:
60 res = json.load(proc.stdout)['archives'] 60 res = json.load(proc.stdout)['archives']
61 if sp.enabled: 61 if sp.enabled:
62 sp.succeed(f'{len(res)} archives in {path}') 62 sp.succeed(f'{len(res)} archives in {path}')