git_index_write_tree

Write the index as a tree

This method will scan the index and write a representation of its current state back to disk; it recursively creates tree objects for each of the subtrees stored in the index, but only returns the OID of the root tree. This is the OID that can be used e.g. to create a commit.

The index instance cannot be bare, and needs to be associated to an existing repository.

The index must not contain any file in conflict.

@param out_ Pointer where to store the OID of the written tree @param index Index to write @return 0 on success, git_error_code.GIT_EUNMERGED when the index is not clean or an error code

extern (C) nothrow @nogc
int
git_index_write_tree

Meta