Subject: [PATCH 2/3] clone: reorder --recursive/--recurse-submodules

From: Junio C Hamano <[email-masked]>
Date: Mon, 16 Mar 2020 14:28:56 -0700

The previous step made an option that is an alias to another option
identify itself as an alias to the latter.  Because it is easier to
scan the list when a pointer goes backward to what a reader already
has seen, mention "recurse-submodules" first with its true short
help string, and then "recurse" with the statement that it is a
synonym to "recurse-submodules".

Signed-off-by: Junio C Hamano <[email-masked]>
---

 The history of --recursive/--recurse-submodules options dates back
 to ccdd3da6 (clone: add the --recurse-submodules option as alias
 for --recursive, 2010-11-04), where we decided to encourage use of
 more descriptive "--recurse-submodules" over "--recursive" which
 does not say to what extent the process is allowed to recurse.
 Documentation/git-clone.txt mentions only "--recurse-submodules"
 for this exact reason, and it may not be a bad idea to start
 planning to deprecate the alias "--recursive".  

 But that obviously is a separate topic.

 builtin/clone.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/builtin/clone.c b/builtin/clone.c
index 1ad26f4d8c..54b0acbe73 100644
--- a/builtin/clone.c
+++ b/builtin/clone.c
@@ -102,10 +102,10 @@ static struct option builtin_clone_options[] = {
 		    N_("don't use local hardlinks, always copy")),
 	OPT_BOOL('s', "shared", &option_shared,
 		    N_("setup as shared repository")),
-	OPT_ALIAS(0, "recursive", "recurse-submodules"),
 	{ OPTION_CALLBACK, 0, "recurse-submodules", &option_recurse_submodules,
 	  N_("pathspec"), N_("initialize submodules in the clone"),
 	  PARSE_OPT_OPTARG, recurse_submodules_cb, (intptr_t)"." },
+	OPT_ALIAS(0, "recursive", "recurse-submodules"),
 	OPT_INTEGER('j', "jobs", &max_jobs,
 		    N_("number of submodules cloned in parallel")),
 	OPT_STRING(0, "template", &option_template, N_("template-directory"),
-- 
2.26.0-rc1-11-g30e9940356