Whenever I need to learn more about a git command I run into the documentation which is helpful but I don't understand the particular syntax that is used to describe the possible options.
For example
git help [-a|--all] [-g|--guide]
[-i|--info|-m|--man|-w|--web] [COMMAND|GUIDE]
What is this formatting or syntax called ?
I can infer that [a|--all] means -a or --all.
I don't understand why some options are separated and some are grouped into square brackets.
This is a simple example there are more complicated commands.
I tried using git help help but I didn't find anything useful (unless I missed something).
[]means the option is optional[a|b|c..|d]means any of thea,b,c, .., ordcan be used for this particular option.So if you want to see all the available commands use
git help -aorgit help --all