From 68cabbfda36b2e515802e13753637a987c4cf9a9 Mon Sep 17 00:00:00 2001 From: Denton Liu Date: Fri, 15 Feb 2019 01:26:41 -0800 Subject: submodule: document default behavior submodule's default behavior wasn't documented in both git-submodule.txt and in the usage text of git-submodule. Document the default behavior similar to how git-remote does it. Signed-off-by: Denton Liu Signed-off-by: Junio C Hamano --- Documentation/git-submodule.txt | 4 ++++ git-submodule.sh | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt index ba3c4df550..2794e29780 100644 --- a/Documentation/git-submodule.txt +++ b/Documentation/git-submodule.txt @@ -9,6 +9,7 @@ git-submodule - Initialize, update or inspect submodules SYNOPSIS -------- [verse] +'git submodule' [--quiet] [--cached] 'git submodule' [--quiet] add [] [--] [] 'git submodule' [--quiet] status [--cached] [--recursive] [--] [...] 'git submodule' [--quiet] init [--] [...] @@ -28,6 +29,9 @@ For more information about submodules, see linkgit:gitsubmodules[7]. COMMANDS -------- +With no arguments, shows the status of existing submodules. Several +subcommands are available to perform operations on the submodules. + add [-b ] [-f|--force] [--name ] [--reference ] [--depth ] [--] []:: Add the given repository as a submodule at the given path to the changeset to be committed next to the current diff --git a/git-submodule.sh b/git-submodule.sh index b5f2beee60..514ede2596 100755 --- a/git-submodule.sh +++ b/git-submodule.sh @@ -5,7 +5,8 @@ # Copyright (c) 2007 Lars Hjemli dashless=$(basename "$0" | sed -e 's/-/ /') -USAGE="[--quiet] add [-b ] [-f|--force] [--name ] [--reference ] [--] [] +USAGE="[--quiet] [--cached] + or: $dashless [--quiet] add [-b ] [-f|--force] [--name ] [--reference ] [--] [] or: $dashless [--quiet] status [--cached] [--recursive] [--] [...] or: $dashless [--quiet] init [--] [...] or: $dashless [--quiet] deinit [-f|--force] (--all| [--] ...) -- cgit v1.2.3