libgit2

git_submodule_update_options

Version:

Submodule update options structure

Use the GIT_SUBMODULE_UPDATE_OPTIONS_INIT to get the default settings, like this:

git_submodule_update_options opts = GIT_SUBMODULE_UPDATE_OPTIONS_INIT;

Signature

typedef struct git_submodule_update_options { unsigned int version git_checkout_options checkout_opts git_fetch_options fetch_opts unsigned int clone_checkout_strategy };

Members

unsigned int
version
checkout_opts

These options are passed to the checkout step. To disable checkout, set the checkout_strategy to GIT_CHECKOUT_NONE. Generally you will want the use GIT_CHECKOUT_SAFE to update files in the working directory. Use the clone_checkout_strategy field to set the checkout strategy that will be used in the case where update needs to clone the repository.

fetch_opts

Options which control the fetch, including callbacks.

The callbacks to use for reporting fetch progress, and for acquiring credentials in the event they are needed.

unsigned int
clone_checkout_strategy

The checkout strategy to use when the sub repository needs to be cloned. Use GIT_CHECKOUT_SAFE to create all files in the working directory for the newly cloned repository.

Parameter To

Versions