prop-updt: check out the former branch back
@@ -66,9 +66,10 @@ class PackitAPI:
)
or up.specfile.get_full_version()
)
+ current_up_branch = up.local_project.git_repo.active_branch
+ try:
# TODO: this is problematic, since we may overwrite stuff in the repo
# but the thing is that we need to do it
- # and we also need to check out the original branch once we're done
# I feel like the ideal thing to do would be to clone the repo and work in tmpdir
# TODO: this is also naive, upstream may use different tagging scheme, e.g.
# release = 232, tag = v232
@@ -94,6 +95,8 @@ class PackitAPI:
dist_git_branch=dist_git_branch,
commit_msg_description=description
)
+ finally:
+ current_up_branch.checkout()
def sync(
self,
