branch doc: update description for `--list`
The paragraph begins with a sample command line `git branch <name>` that has nothing to do with the option being described. Remove it, but use the space to instead show that multiple patterns can be given. Also mention the unfortunate `-l` that can be easily confused with it. Signed-off-by: Junio C Hamano <gitster@pobox.com> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com> Reviewed-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Junio C Hamano committed
Mar 23, 2017 at 21:17 UTC
75ec4a6cb0921688d01a7e7800a5dd5d9f1ad586
1 file changed
+7
-2
Documentation/git-branch.txt
+7
-2
@@ -142,8 +142,13 @@ This option is only applicable in non-verbose mode.
142
List both remote-tracking branches and local branches.
143
144
--list::
145
- Activate the list mode. `git branch <branchname>` would try to create a branch,
146
- use `git branch --list <pattern>` to list matching branches.
145
+ List branches. With optional `<pattern>...`, e.g. `git
146
+ branch --list 'maint-*'`, list only the branches that match
147
+ the pattern(s).
148
++
149
+This should not be confused with `git branch -l <branchname>`,
150
+which creates a branch named `<branchname>` with a reflog.
151
+See `--create-reflog` above for details.
152
153
-v::
154
-vv::