git_submodule_add_to_index

Add current submodule HEAD commit to index of superproject.

extern (C) nothrow @nogc
int
git_submodule_add_to_index

Parameters

submodule libgit2_d.types.git_submodule*

The submodule to add to the index

write_index int

Boolean if this should immediately write the index file. If you pass this as false, you will have to get the git_index and explicitly call git_index_write() on it to save the change.

Return Value

Type: int

0 on success, <0 on failure

Meta