You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/commands.rs
+27Lines changed: 27 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -120,6 +120,15 @@ pub enum Commands {
120
120
)]
121
121
sparse_paths:Option<Vec<String>>,
122
122
123
+
#[arg(
124
+
long = "use-git-default-sparse-checkout",
125
+
num_args = 0..=1,
126
+
value_parser = clap::value_parser!(bool),
127
+
default_missing_value = "true",
128
+
help = "Opt out of submod's deny-all-by-default sparse-checkout model and use git's built-in behaviour instead. When set, the `!/*` prefix is NOT prepended automatically."
129
+
)]
130
+
use_git_default_sparse_checkout:Option<bool>,
131
+
123
132
#[arg(
124
133
short = 'f',
125
134
long = "fetch",
@@ -166,6 +175,15 @@ pub enum Commands {
166
175
#[arg(requires("sparse_paths"), short = 'a', long = "append", value_parser = clap::value_parser!(bool), default_value = "false", default_missing_value = "true", help = "If given, appends the new sparse paths to the existing ones.")]
167
176
append:bool,
168
177
178
+
#[arg(
179
+
long = "use-git-default-sparse-checkout",
180
+
num_args = 0..=1,
181
+
value_parser = clap::value_parser!(bool),
182
+
default_missing_value = "true",
183
+
help = "Opt out of submod's deny-all-by-default sparse-checkout model and use git's built-in behaviour instead."
184
+
)]
185
+
use_git_default_sparse_checkout:Option<bool>,
186
+
169
187
#[arg(
170
188
short = 'i',
171
189
long = "ignore",
@@ -224,6 +242,15 @@ pub enum Commands {
224
242
help = "Sets the default update behavior for all submodules in this repository. This will override any individual submodule settings."
225
243
)]
226
244
update:Option<Update>,
245
+
246
+
#[arg(
247
+
long = "use-git-default-sparse-checkout",
248
+
num_args = 0..=1,
249
+
value_parser = clap::value_parser!(bool),
250
+
default_missing_value = "true",
251
+
help = "Set the global default for sparse-checkout mode. When true, all submodules use git's built-in behaviour instead of submod's deny-all-by-default model (unless overridden per-submodule)."
0 commit comments