From 37d57ee8ebd510d51e5962611023ceaaa4b6d562 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Fri, 18 Feb 2022 12:35:25 +0100 Subject: vidhar: ... --- hosts/vidhar/borg/copy.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'hosts') diff --git a/hosts/vidhar/borg/copy.py b/hosts/vidhar/borg/copy.py index be890cf1..37f7ff04 100755 --- a/hosts/vidhar/borg/copy.py +++ b/hosts/vidhar/borg/copy.py @@ -145,11 +145,11 @@ def copy_archive(src_repo_path, dst_repo_path, entry): else: print(f'{total_files} files, {naturalsize(total_size, binary=True)}', file=stderr) # print(f'Mounting to {dir}', file=stderr) - subprocess.run(['stat', dir], check=True) with subprocess.Popen(['borg', 'mount', '--foreground', '--progress', '--lock-wait=600', f'{src_repo_path}::{entry["name"]}', dir], preexec_fn=lambda: as_borg()) as mount_proc: with Halo(text='Waiting for mount', **halo_args) as sp: wait_start = datetime.now() while True: + subprocess.run(['mount'], check=True) ret = subprocess.run(['mountpoint', '-q', dir]) if ret.returncode == 0: break -- cgit v1.2.3