Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: git info format #23

Merged
merged 1 commit into from
Sep 17, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions gittyup.py
Original file line number Diff line number Diff line change
Expand Up @@ -305,9 +305,9 @@ def clone_or_pull_repo(repo_config: GitOpsRepository, clone_dir="repo") -> Optio
profile = Path(CLONE_DIR) / "profile.json"
if profile.exists():
payload = json.loads(profile.read_text(encoding="utf-8"))
payload["commit"] = commit
payload["branch"] = repo.branch
payload["url"] = repo.url
payload["commit"] = repo.commit[0] if isinstance(repo.commit, (tuple, list)) else repo.commit
payload["branch"] = repo.branch[0] if isinstance(repo.branch, (tuple, list)) else repo.branch
payload["url"] = repo.url[0] if isinstance(repo.url, (tuple, list)) else repo.url

cmd_id = f"gittyup-{int(time.time())}"
client.publish_tedge_command(
Expand Down