Commit ba3a8304 by Josh Leeb-du Toit

Remove set of submodule update `checkout_strategy`

Remove overriding the `checkout_strategy` for `update_options` when
performing an update on a submodule. Users should be specifying the
correct checkout strategy in
`update_options.checkout_opts.checkout_strategy`.
parent 3e22bb71
...@@ -1160,7 +1160,6 @@ int git_submodule_update(git_submodule *sm, int init, git_submodule_update_optio ...@@ -1160,7 +1160,6 @@ int git_submodule_update(git_submodule *sm, int init, git_submodule_update_optio
* will checkout the specific commit manually. * will checkout the specific commit manually.
*/ */
clone_options.checkout_opts.checkout_strategy = GIT_CHECKOUT_NONE; clone_options.checkout_opts.checkout_strategy = GIT_CHECKOUT_NONE;
update_options.checkout_opts.checkout_strategy = GIT_CHECKOUT_SAFE;
if ((error = git_clone(&sub_repo, submodule_url, sm->path, &clone_options)) < 0 || if ((error = git_clone(&sub_repo, submodule_url, sm->path, &clone_options)) < 0 ||
(error = git_repository_set_head_detached(sub_repo, git_submodule_index_id(sm))) < 0 || (error = git_repository_set_head_detached(sub_repo, git_submodule_index_id(sm))) < 0 ||
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment