diff options
author | Jordan <me@jordan.im> | 2022-09-14 12:37:30 -0700 |
---|---|---|
committer | Jordan <me@jordan.im> | 2022-09-14 12:37:30 -0700 |
commit | a53d2abdfe27f582488fa3d1324dffb177fb95e6 (patch) | |
tree | b72ace478e230de9379d1d6977acf8e29db16362 | |
parent | 3e78acc804ac53f75dee87f4edd499c6fad3a277 (diff) | |
download | koya-a53d2abdfe27f582488fa3d1324dffb177fb95e6.tar.gz koya-a53d2abdfe27f582488fa3d1324dffb177fb95e6.zip |
misc: log discovered repos before set return
-rwxr-xr-x | koya | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -71,13 +71,15 @@ class Koya: data = res["data"]["user"]["repositories"] repos.extend(data["results"]) + if len(data["results"]): + log.info(f"Discovered {len(data['results'])} repositories...") + cursor = data.get("cursor") if cursor: cursor_obj = f'''cursor: "{cursor}"''' else: return repos - log.info(f"Discovered {len(data['results'])} repositories...") time.sleep(self.delay) def multi_urljoin(*parts): @@ -121,8 +123,6 @@ if __name__ == "__main__": if os.path.exists(repo_path): fetch = ["git", "fetch", "--all", "--force", "--tags", "--prune"] subprocess.run(fetch, cwd=repo_path) - - time.sleep(args.delay) else: Path(repo_path).mkdir(parents=True, exist_ok=True) @@ -130,4 +130,4 @@ if __name__ == "__main__": clone = ["git", "clone", remote_url, repo_path] subprocess.run(clone) - time.sleep(args.delay) + time.sleep(args.delay) |