Compare commits
3 Commits
dcca9c5167
...
072c2a26e6
| Author | SHA1 | Date | |
|---|---|---|---|
|
072c2a26e6
|
|||
|
b0c165b8b0
|
|||
|
6b8686351a
|
@@ -1,4 +1,4 @@
|
|||||||
# copyright (c) 2026 paul retourné
|
# Copyright (c) 2026 paul retourné
|
||||||
# spdx-license-identifier: gpl-3.0-or-later
|
# spdx-license-identifier: gpl-3.0-or-later
|
||||||
|
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|||||||
@@ -1,6 +1,9 @@
|
|||||||
# Copyright (C) 2025-2026 Paul Retourné
|
# Copyright (C) 2025-2026 Paul Retourné
|
||||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
|
||||||
|
from typing import NoReturn
|
||||||
|
import sys
|
||||||
|
|
||||||
class RemoteMountedError(Exception):
|
class RemoteMountedError(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
@@ -12,3 +15,7 @@ class UnknownSSHError(Exception):
|
|||||||
|
|
||||||
class FatalSyncError(Exception):
|
class FatalSyncError(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
def unisync_exit_fatal(reason:str) -> NoReturn:
|
||||||
|
print(reason)
|
||||||
|
sys.exit(1)
|
||||||
|
|||||||
@@ -73,9 +73,9 @@ class PathsManager:
|
|||||||
try:
|
try:
|
||||||
paths = self.user_select_files()
|
paths = self.user_select_files()
|
||||||
break
|
break
|
||||||
except subprocess.TimeoutExpired as e:
|
except subprocess.TimeoutExpired:
|
||||||
if input("Timeout expired do you want to retry (y/n): ") != "y":
|
if input("Timeout expired do you want to retry (y/n): ") != "y":
|
||||||
raise e
|
raise
|
||||||
self.write_new_paths(paths)
|
self.write_new_paths(paths)
|
||||||
|
|
||||||
def get_paths_to_sync(self) -> list[str]:
|
def get_paths_to_sync(self) -> list[str]:
|
||||||
|
|||||||
Reference in New Issue
Block a user