[RFC PATCH 1/1] Documentation/git-sparse-checkout.txt: add an OPTIONS section

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Add an OPTIONS section to the manual and move the descriptions about
these options from COMMANDS to the section.

Signed-off-by: Shaoxuan Yuan <shaoxuan.yuan02@xxxxxxxxx>
---
 Documentation/git-sparse-checkout.txt | 63 +++++++++++++++++----------
 1 file changed, 39 insertions(+), 24 deletions(-)

diff --git a/Documentation/git-sparse-checkout.txt b/Documentation/git-sparse-checkout.txt
index 06f23660f6..0bc742cb3a 100644
--- a/Documentation/git-sparse-checkout.txt
+++ b/Documentation/git-sparse-checkout.txt
@@ -35,30 +35,11 @@ COMMANDS IN THE PRESENCE OF SPARSE-CHECKOUTS, WILL LIKELY CHANGE IN
 THE FUTURE.
 
 
-COMMANDS
---------
-'list'::
-	Describe the directories or patterns in the sparse-checkout file.
-
-'set'::
-	Enable the necessary sparse-checkout config settings
-	(`core.sparseCheckout`, `core.sparseCheckoutCone`, and
-	`index.sparse`) if they are not already set to the desired values,
-	populate the sparse-checkout file from the list of arguments
-	following the 'set' subcommand, and update the working directory to
-	match.
-+
-To ensure that adjusting the sparse-checkout settings within a worktree
-does not alter the sparse-checkout settings in other worktrees, the 'set'
-subcommand will upgrade your repository config to use worktree-specific
-config if not already present. The sparsity defined by the arguments to
-the 'set' subcommand are stored in the worktree-specific sparse-checkout
-file. See linkgit:git-worktree[1] and the documentation of
-`extensions.worktreeConfig` in linkgit:git-config[1] for more details.
-+
-When the `--stdin` option is provided, the directories or patterns are
-read from standard in as a newline-delimited list instead of from the
-arguments.
+OPTIONS
+-------
+'--[no-]cone'::
+	Use with ['set'|'reapply'].
+	Specify using cone mode or not. The default is to use cone mode.
 +
 By default, the input list is considered a list of directories, matching
 the output of `git ls-tree -d --name-only`.  This includes interpreting
@@ -78,6 +59,11 @@ with the `--sparse-index` option, and will likely be incompatible with
 other new features as they are added.  See the "Non-cone Problems"
 section below and the "Sparse Checkout" section of
 linkgit:git-read-tree[1] for more details.
+
+'--[no-]sparse-index'::
+	Use with ['set'|'reapply'].
+	Specify using a sparse index or not. The default is to not use a 
+	sparse index.
 +
 Use the `--[no-]sparse-index` option to use a sparse index (the
 default is to not use it).  A sparse index reduces the size of the
@@ -94,6 +80,35 @@ to rewrite your index to not be sparse. Older versions of Git will not
 understand the sparse directory entries index extension and may fail to
 interact with your repository until it is disabled.
 
+'--stdin'::
+	Use with ['set'|'add'].
++
+When the `--stdin` option is provided, the directories or patterns are
+read from standard in as a newline-delimited list instead of from the
+arguments.
+
+
+COMMANDS
+--------
+'list'::
+	Describe the directories or patterns in the sparse-checkout file.
+
+'set'::
+	Enable the necessary sparse-checkout config settings
+	(`core.sparseCheckout`, `core.sparseCheckoutCone`, and
+	`index.sparse`) if they are not already set to the desired values,
+	populate the sparse-checkout file from the list of arguments
+	following the 'set' subcommand, and update the working directory to
+	match.
++
+To ensure that adjusting the sparse-checkout settings within a worktree
+does not alter the sparse-checkout settings in other worktrees, the 'set'
+subcommand will upgrade your repository config to use worktree-specific
+config if not already present. The sparsity defined by the arguments to
+the 'set' subcommand are stored in the worktree-specific sparse-checkout
+file. See linkgit:git-worktree[1] and the documentation of
+`extensions.worktreeConfig` in linkgit:git-config[1] for more details.
+
 'add'::
 	Update the sparse-checkout file to include additional directories
 	(in cone mode) or patterns (in non-cone mode).  By default, these
-- 
2.35.1




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux