aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2022-08-17 00:06:55 +0200
committerNeels Hofmeyr <nhofmeyr@sysmocom.de>2022-08-17 15:32:07 +0200
commit7057a9f55d6a5d2f7c2417afaa4e86d973babdf3 (patch)
tree15ff51d77060f5e03d3b0ae94e5c06f33e6a0782
parent39cde7f098de2c84936840fa1b9aa4f8b7d0296e (diff)
obs: tweak logging output
-rw-r--r--scripts/obs/lib/git.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/scripts/obs/lib/git.py b/scripts/obs/lib/git.py
index 67f1d5e..29c183b 100644
--- a/scripts/obs/lib/git.py
+++ b/scripts/obs/lib/git.py
@@ -28,10 +28,10 @@ def clone(project, fetch=False):
if os.path.exists(repo_path):
if fetch:
- print(f"{project}: cloning {url} (cached, fetching)")
+ print(f"{project}: 'git fetch'")
lib.run_cmd(["git", "fetch"], cwd=repo_path)
else:
- print(f"{project}: cloning {url} (cached, not fetching)")
+ print(f"{project}: using cached {url} (not cloning, not fetching)")
return
print(f"{project}: cloning {url}")
@@ -46,13 +46,15 @@ def clone(project, fetch=False):
def clean(project):
repo_path = get_repo_path(project)
+ print(f"{project}: 'git clean -ffxd'")
lib.run_cmd(["git", "clean", "-ffxd"], cwd=repo_path)
def checkout(project, branch):
repo_path = get_repo_path(project)
- print(f"{project}: checking out {branch}")
+ print(f"{project}: 'git checkout -f {branch}'")
lib.run_cmd(["git", "checkout", "-f", branch], cwd=repo_path)
+ print(f"{project}: 'git reset --hard {branch}'")
lib.run_cmd(["git", "reset", "--hard", branch], cwd=repo_path)