Skip to content

Commit d359541

Browse files
newrengitster
authored andcommitted
clone: avoid using deprecated sparse-checkout init
The previous commits marked `sparse-checkout init` as deprecated; we can just use `set` instead here and pass it no paths. Reviewed-by: Derrick Stolee <dstolee@microsoft.com> Reviewed-by: Victoria Dye <vdye@github.com> Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent d30e2bb commit d359541

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

builtin/clone.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -633,7 +633,7 @@ static int git_sparse_checkout_init(const char *repo)
633633
{
634634
struct strvec argv = STRVEC_INIT;
635635
int result = 0;
636-
strvec_pushl(&argv, "-C", repo, "sparse-checkout", "init", NULL);
636+
strvec_pushl(&argv, "-C", repo, "sparse-checkout", "set", NULL);
637637

638638
/*
639639
* We must apply the setting in the current process

0 commit comments

Comments
 (0)