summaryrefslogtreecommitdiffstats
path: root/git-branch.txt
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2022-02-18 14:08:41 -0800
committerJunio C Hamano <gitster@pobox.com>2022-02-18 14:08:41 -0800
commit99a21c3fd90112166afacf1fe1ed3e1c5d74cea6 (patch)
treee7775783ce7319d96df3b6768de5470c7b4b2503 /git-branch.txt
parent034a2ff96f3a3aa981e5ae4e242cefa4bd00323b (diff)
downloadgit-htmldocs-99a21c3fd90112166afacf1fe1ed3e1c5d74cea6.tar.gz
Autogenerated HTML docs for v2.35.1-273-ge6ebf
Diffstat (limited to 'git-branch.txt')
-rw-r--r--git-branch.txt19
1 files changed, 18 insertions, 1 deletions
diff --git a/git-branch.txt b/git-branch.txt
index 731e340cb..c8b4f9ce3 100644
--- a/git-branch.txt
+++ b/git-branch.txt
@@ -16,7 +16,8 @@ SYNOPSIS
[--points-at <object>] [--format=<format>]
[(-r | --remotes) | (-a | --all)]
[--list] [<pattern>...]
-'git branch' [--track[=(direct|inherit)] | --no-track] [-f] <branchname> [<start-point>]
+'git branch' [--track[=(direct|inherit)] | --no-track] [-f]
+ [--recurse-submodules] <branchname> [<start-point>]
'git branch' (--set-upstream-to=<upstream> | -u <upstream>) [<branchname>]
'git branch' --unset-upstream [<branchname>]
'git branch' (-m | -M) [<oldbranch>] <newbranch>
@@ -235,6 +236,22 @@ how the `branch.<name>.remote` and `branch.<name>.merge` options are used.
Do not set up "upstream" configuration, even if the
branch.autoSetupMerge configuration variable is set.
+--recurse-submodules::
+ THIS OPTION IS EXPERIMENTAL! Causes the current command to
+ recurse into submodules if `submodule.propagateBranches` is
+ enabled. See `submodule.propagateBranches` in
+ linkgit:git-config[1]. Currently, only branch creation is
+ supported.
++
+When used in branch creation, a new branch <branchname> will be created
+in the superproject and all of the submodules in the superproject's
+<start-point>. In submodules, the branch will point to the submodule
+commit in the superproject's <start-point> but the branch's tracking
+information will be set up based on the submodule's branches and remotes
+e.g. `git branch --recurse-submodules topic origin/main` will create the
+submodule branch "topic" that points to the submodule commit in the
+superproject's "origin/main", but tracks the submodule's "origin/main".
+
--set-upstream::
As this option had confusing syntax, it is no longer supported.
Please use `--track` or `--set-upstream-to` instead.