Home Explore Blog CI



git

2nd chunk of `Documentation/git-show-branch.adoc`
fda0ef4d3f7d25075d72c4ef1f271d9b48c62aa3ccd04ad3000000010000086d

--merge-base::
	Instead of showing the commit list, determine possible
	merge bases for the specified commits. All merge bases
	will be contained in all specified commits. This is
	different from how linkgit:git-merge-base[1] handles
	the case of three or more commits.

--independent::
	Among the <ref>s given, display only the ones that cannot be
	reached from any other <ref>.

--no-name::
	Do not show naming strings for each commit.

--sha1-name::
	Instead of naming the commits using the path to reach
	them from heads (e.g. "master~2" to mean the grandparent
	of "master"), name them with the unique prefix of their
	object names.

--topics::
	Shows only commits that are NOT on the first branch given.
	This helps track topic branches by hiding any commit that
	is already in the main line of development.  When given
	"git show-branch --topics master topic1 topic2", this
	will show the revisions given by "git rev-list {caret}master
	topic1 topic2"

-g::
--reflog[=<n>[,<base>]] [<ref>]::
	Shows <n> most recent ref-log entries for the given
	ref.  If <base> is given, <n> entries going back from
	that entry.  <base> can be specified as count or date.
	When no explicit <ref> parameter is given, it defaults to the
	current branch (or `HEAD` if it is detached).

--color[=<when>]::
	Color the status sign (one of these: `*` `!` `+` `-`) of each commit
	corresponding to the branch it's in.
	The value must be always (the default), never, or auto.

--no-color::
	Turn off colored output, even when the configuration file gives the
	default to color output.
	Same as `--color=never`.

Note that --more, --list, --independent, and --merge-base options
are mutually exclusive.


OUTPUT
------

Given N <ref>s, the first N lines are the one-line description from
their commit message. The branch head that is pointed at by
$GIT_DIR/HEAD is prefixed with an asterisk `*` character while other
heads are prefixed with a `!` character.

Following these N lines, a one-line log for each commit is
displayed, indented N places.  If a commit is on the I-th
branch, the I-th indentation character shows a `+` sign;
otherwise it shows a space.  Merge commits

Title: Git Show Branch Options and Output
Summary
The git-show-branch command offers various options to customize the display of branch and commit information, including merge bases, independent branches, and commit naming, and its output includes a one-line description of each commit and an indented log for each commit, showing its relationship to the specified branches.