def get_index_commit(repo):
    tree = os.path.join(repo.getGitDir(), 'index')
    parents = [constants.COMMIT_HEAD]
    author = _get_bogus_author()
    committer = _get_bogus_author()
    comment = 'Uncommitted changes in the index'
    # XXX: it might be better to define a separate class for this
    return Commit(repo, constants.COMMIT_INDEX, tree, parents,
                  author, committer, comment)
get_index_commit(repo) --> commit
dataset/ETHPy150Open facebookarchive/git-review/src/gitreview/git/commit.py/get_index_commit