def get_current_hotfix_version_from_release_tags(): v = jenkins_utils.get_current_release_version() last_hotfix = -1 for repo in ["commcare-core", "commcare-android"]: repo_hotfix = util.get_last_hotfix_number_in_repo( repo, v.short_string()) last_hotfix = max(last_hotfix, repo_hotfix) return Version(v.major, v.minor, last_hotfix)
def get_current_hotfix_version_from_release_tags(): v = jenkins_utils.get_current_release_version() last_hotfix = -1 for repo in ["commcare-core", "commcare-android"]: repo_hotfix = util.get_last_hotfix_number_in_repo(repo, v.short_string()) last_hotfix = max(last_hotfix, repo_hotfix) return Version(v.major, v.minor, last_hotfix)
def build_jobs_against_hotfix_tags(hotfix_repos): """ Make release jobs for hotfix repos build off of the newly created hotfix tags. """ # NOTE PLM: not sure if the hotfix version is correct, but it is okay # because it isn't used here version = get_latest_release_job_version() version_short = version.short_string() for repo in hotfix_repos: last_hotfix = util.get_last_hotfix_number_in_repo(repo, version_short) hotfix_version = Version(version.major, version.minor, last_hotfix) tag = get_tag_name(hotfix_version) job_name = repo_to_jobs[repo] branch = get_branch_name(version) update_core_ref = (repo == "commcare-android" and "commcare-core" in hotfix_repos) make_release_job_use_tag(job_name, version.short_string(), branch, tag, update_core_ref)
def get_last_hotfix(repo, version): hotfix_number = util.get_last_hotfix_number_in_repo( repo, version.short_string()) return Version(version.major, version.minor, hotfix_number)
def get_last_hotfix(repo, version): hotfix_number = util.get_last_hotfix_number_in_repo(repo, version.short_string()) return Version(version.major, version.minor, hotfix_number)