def get_last_tag_by_version(directory=None):
    cmd = "git for-each-ref --sort='*authordate' " \
          "--format='%(refname:short)' refs/tags/upstream"
    output = check_output(cmd, shell=True, cwd=directory, stderr=PIPE)
    tags = []
    versions = []
    for line in output.splitlines():
        tags.append(line.strip())
        versions.append(parse_version(line.strip()))
    return tags[versions.index(max(versions))] if versions else ''
Return the header of the response.
dataset/ETHPy150Open ros-infrastructure/bloom/bloom/git.py/get_last_tag_by_version--crossover with--dataset/ETHPy150Open Zimbra-Community/python-zimbra/pythonzimbra/response.py/Response.get_header