def rev_parse(refname):
    status, stdout = git('rev-parse', '-q', '--verify', refname,
                         raise_exc=False)
    if 0 != status:
        return None
    return stdout.rstrip()
Return the referenced commit or None.
dataset/ETHPy150Open devstructure/blueprint/blueprint/git.py/rev_parse