def release(github_access_token, repo_url, new_version):
"""
Run a release
Args:
github_access_token (str): The github access token
repo_url (str): URL for a repo
new_version (str): The version of the new release
"""
validate_dependencies()
with init_working_dir(github_access_token, repo_url):
check_call(["git", "checkout", "-qb", "release-candidate"])
old_version = update_version(new_version)
if parse_version(old_version) >= parse_version(new_version):
raise ReleaseException("old version is {old} but the new version {new} is not newer".format(
old=old_version,
new=new_version,
))
verify_new_commits(old_version)
update_release_notes(old_version, new_version)
build_release()
generate_release_pr(github_access_token, repo_url, old_version, new_version)
print("version {old_version} has been updated to {new_version}".format(
old_version=old_version,
new_version=new_version,
))
print("Go tell engineers to check their work. PR is on the repo.")
print("After they are done, run the finish_release.py script.")
评论列表
文章目录