Compare commits

..

6 Commits

Author SHA1 Message Date
Aleksei Sviridkin
e4c9c3dff7 Merge d5119bc264 into 777f5e45e7 2025-02-20 21:00:49 +01:00
dw-0
777f5e45e7 master -> develop
master -> develop
2025-02-20 21:00:21 +01:00
Aleksei Sviridkin
d5119bc264 fix(git_utils): add a newline for better readability in git_cmd_clone
Signed-off-by: Aleksei Sviridkin <f@lex.la>
2025-02-20 02:56:17 +03:00
Aleksei Sviridkin
8cb66071ac feat(git_utils): enhance git_cmd_clone with depth and single-branch options
Signed-off-by: Aleksei Sviridkin <f@lex.la>
2025-02-20 02:52:23 +03:00
Paul Fertser
acf0faf158 fix: add ULA to trusted_clients in moonraker.conf (#637)
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2025-02-16 16:47:00 +01:00
dw-0
5c219ec544 master -> develop (#635) 2025-02-15 11:26:04 +01:00
2 changed files with 9 additions and 2 deletions

View File

@@ -10,6 +10,7 @@ trusted_clients:
169.254.0.0/16
172.16.0.0/12
192.168.0.0/16
FC00::/7
FE80::/10
::1/128
cors_domains:

View File

@@ -253,9 +253,15 @@ def get_remote_commit(repo: Path) -> str | None:
return None
def git_cmd_clone(repo: str, target_dir: Path) -> None:
def git_cmd_clone(repo: str, target_dir: Path, depth: int = 1) -> None:
try:
command = ["git", "clone", repo, target_dir.as_posix()]
command = [
"git", "clone",
"--depth", str(depth),
"--single-branch",
repo,
target_dir.as_posix()
]
run(command, check=True)
Logger.print_ok("Clone successful!")