Refactor for call consistency

merge-requests/6/merge
erik 1 year ago
parent 537a5836b9
commit 84d3e29c28

@ -27,11 +27,13 @@ class PrepareReleaseService():
class TagAndPushReleaseService():
def __init__(self, git_api: GitApi):
def __init__(self, git_api: GitApi, release_repo: ReleaseRepository = None):
self.git_api = git_api
self.release_repo = release_repo
self.release = release_repo.get_release()
def tag_release(self, release: Release):
annotation = 'v' + release.version.get_version_string()
def tag_release(self):
annotation = 'v' + self.release.version.get_version_string()
message = 'Release ' + annotation
# TODO: Why is the count a parameter? We always tag the second last commit in this process.
self.git_api.tag_annotated(annotation, message, 1)

Loading…
Cancel
Save