Exemplo n.º 1
0
def uncommitted_staged_changes_exist():
    try:
        git("diff-index", "--quiet", "--cached", "HEAD")
    except sh.ErrorReturnCode:
        return True
    else:
        return False
Exemplo n.º 2
0
def unstaged_changes_exist():
    try:
        git("diff-files", "--quiet")
    except sh.ErrorReturnCode:
        return True
    else:
        return False
Exemplo n.º 3
0
def current_branch():
    return git("rev-parse", "--abbrev-ref", "HEAD").strip()