Next: Status Module Sections, Previous: Status Sections, Up: Status Buffer [Contents][Index]
The contents of status buffers is controlled using the hook
magit-status-sections-hook
(see Status Sections).
By default magit-insert-status-headers
is the first member of that
hook variable.
Insert headers sections appropriate for magit-status-mode
buffers.
The sections are inserted by running the functions on the hook
magit-status-headers-hook
.
Hook run to insert headers sections into the status buffer.
This hook is run by magit-insert-status-headers
, which in turn has
to be a member of magit-status-sections-hook
to be used at all.
By default the following functions are members of the above hook:
Insert a header line showing the message about the Git error that just occurred.
This function is only aware of the last error that occur when Git was run for side-effects. If, for example, an error occurs while generating a diff, then that error won’t be inserted. Refreshing the status buffer causes this section to disappear again.
Insert a header line showing the effective diff filters.
Insert a header line about the current branch or detached HEAD
.
Insert a header line about the branch that is usually pulled into the current branch.
Insert a header line about the branch that the current branch is usually pushed to.
Insert a header line about the current and/or next tag, along with
the number of commits between the tag and HEAD
.
The following functions can also be added to the above hook:
Insert a header line showing the path to the repository top-level.
Insert a header line about the remote of the current branch.
If no remote is configured for the current branch, then fall back showing the "origin" remote, or if that does not exist the first remote in alphabetic order.
Insert a header line about the current user.
Next: Status Module Sections, Previous: Status Sections, Up: Status Buffer [Contents][Index]