mirror of
https://github.com/dw-0/kiauh.git
synced 2025-12-23 15:53:36 +05:00
Compare commits
1 Commits
3d5ac875b1
...
3492731012
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3492731012 |
@@ -9,8 +9,5 @@
|
|||||||
|
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
from core.backup_manager import BACKUP_ROOT_DIR
|
|
||||||
|
|
||||||
CROWSNEST_DIR = Path.home().joinpath("crowsnest")
|
CROWSNEST_DIR = Path.home().joinpath("crowsnest")
|
||||||
CROWSNEST_REPO = "https://github.com/mainsail-crew/crowsnest.git"
|
CROWSNEST_REPO = "https://github.com/mainsail-crew/crowsnest.git"
|
||||||
CROWSNEST_BACKUP_DIR = BACKUP_ROOT_DIR.joinpath("crowsnest-backups")
|
|
||||||
|
|||||||
@@ -14,11 +14,9 @@ from pathlib import Path
|
|||||||
from subprocess import run, CalledProcessError
|
from subprocess import run, CalledProcessError
|
||||||
from typing import List, Dict, Literal, Union
|
from typing import List, Dict, Literal, Union
|
||||||
|
|
||||||
from components.crowsnest import CROWSNEST_REPO, CROWSNEST_DIR, CROWSNEST_BACKUP_DIR
|
from components.crowsnest import CROWSNEST_REPO, CROWSNEST_DIR
|
||||||
from components.klipper.klipper import Klipper
|
from components.klipper.klipper import Klipper
|
||||||
from core.backup_manager.backup_manager import BackupManager
|
|
||||||
from core.instance_manager.instance_manager import InstanceManager
|
from core.instance_manager.instance_manager import InstanceManager
|
||||||
from core.settings.kiauh_settings import KiauhSettings
|
|
||||||
from utils.common import get_install_status, check_install_dependencies
|
from utils.common import get_install_status, check_install_dependencies
|
||||||
from utils.constants import COLOR_CYAN, RESET_FORMAT, CURRENT_USER
|
from utils.constants import COLOR_CYAN, RESET_FORMAT, CURRENT_USER
|
||||||
from utils.git_utils import (
|
from utils.git_utils import (
|
||||||
@@ -107,15 +105,6 @@ def update_crowsnest() -> None:
|
|||||||
else:
|
else:
|
||||||
Logger.print_status("Updating Crowsnest ...")
|
Logger.print_status("Updating Crowsnest ...")
|
||||||
|
|
||||||
settings = KiauhSettings()
|
|
||||||
if settings.get("kiauh", "backup_before_update"):
|
|
||||||
bm = BackupManager()
|
|
||||||
bm.backup_directory(
|
|
||||||
"crowsnest",
|
|
||||||
source=CROWSNEST_DIR,
|
|
||||||
target=CROWSNEST_BACKUP_DIR,
|
|
||||||
)
|
|
||||||
|
|
||||||
git_pull_wrapper(CROWSNEST_REPO, CROWSNEST_DIR)
|
git_pull_wrapper(CROWSNEST_REPO, CROWSNEST_DIR)
|
||||||
|
|
||||||
script = CROWSNEST_DIR.joinpath("tools/install.sh")
|
script = CROWSNEST_DIR.joinpath("tools/install.sh")
|
||||||
|
|||||||
Reference in New Issue
Block a user