dotemacs

My Emacs configuration
git clone git://git.entf.net/dotemacs
Log | Files | Refs | LICENSE

magit.info (515541B)


      1 This is magit.info, produced by makeinfo version 6.7 from magit.texi.
      2 
      3      Copyright (C) 2015-2021 Jonas Bernoulli <jonas@bernoul.li>
      4 
      5      You can redistribute this document and/or modify it under the terms
      6      of the GNU General Public License as published by the Free Software
      7      Foundation, either version 3 of the License, or (at your option)
      8      any later version.
      9 
     10      This document is distributed in the hope that it will be useful,
     11      but WITHOUT ANY WARRANTY; without even the implied warranty of
     12      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
     13      General Public License for more details.
     14 
     15 INFO-DIR-SECTION Emacs
     16 START-INFO-DIR-ENTRY
     17 * Magit: (magit).       Using Git from Emacs with Magit.
     18 END-INFO-DIR-ENTRY
     19 
     20 
     21 File: magit.info,  Node: Top,  Next: Introduction,  Up: (dir)
     22 
     23 Magit User Manual
     24 *****************
     25 
     26 Magit is an interface to the version control system Git, implemented as
     27 an Emacs package.  Magit aspires to be a complete Git porcelain.  While
     28 we cannot (yet) claim that Magit wraps and improves upon each and every
     29 Git command, it is complete enough to allow even experienced Git users
     30 to perform almost all of their daily version control tasks directly from
     31 within Emacs.  While many fine Git clients exist, only Magit and Git
     32 itself deserve to be called porcelains.
     33 
     34 This manual is for Magit version 3.3.0.
     35 
     36      Copyright (C) 2015-2021 Jonas Bernoulli <jonas@bernoul.li>
     37 
     38      You can redistribute this document and/or modify it under the terms
     39      of the GNU General Public License as published by the Free Software
     40      Foundation, either version 3 of the License, or (at your option)
     41      any later version.
     42 
     43      This document is distributed in the hope that it will be useful,
     44      but WITHOUT ANY WARRANTY; without even the implied warranty of
     45      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
     46      General Public License for more details.
     47 
     48 * Menu:
     49 
     50 * Introduction::
     51 * Installation::
     52 * Getting Started::
     53 * Interface Concepts::
     54 * Inspecting::
     55 * Manipulating::
     56 * Transferring::
     57 * Miscellaneous::
     58 * Customizing::
     59 * Plumbing::
     60 * FAQ::
     61 * Debugging Tools::
     62 * Keystroke Index::
     63 * Command Index::
     64 * Function Index::
     65 * Variable Index::
     66 
     67 — The Detailed Node Listing —
     68 
     69 Installation
     70 
     71 * Installing from Melpa::
     72 * Installing from the Git Repository::
     73 * Post-Installation Tasks::
     74 
     75 Interface Concepts
     76 
     77 * Modes and Buffers::
     78 * Sections::
     79 * Transient Commands::
     80 * Transient Arguments and Buffer Variables::
     81 * Completion, Confirmation and the Selection: Completion Confirmation and the Selection.
     82 * Running Git::
     83 
     84 Modes and Buffers
     85 
     86 * Switching Buffers::
     87 * Naming Buffers::
     88 * Quitting Windows::
     89 * Automatic Refreshing of Magit Buffers::
     90 * Automatic Saving of File-Visiting Buffers::
     91 * Automatic Reverting of File-Visiting Buffers::
     92 
     93 
     94 Sections
     95 
     96 * Section Movement::
     97 * Section Visibility::
     98 * Section Hooks::
     99 * Section Types and Values::
    100 * Section Options::
    101 
    102 
    103 Completion, Confirmation and the Selection
    104 
    105 * Action Confirmation::
    106 * Completion and Confirmation::
    107 * The Selection::
    108 * The hunk-internal region::
    109 * Support for Completion Frameworks::
    110 * Additional Completion Options::
    111 
    112 
    113 Running Git
    114 
    115 * Viewing Git Output::
    116 * Git Process Status::
    117 * Running Git Manually::
    118 * Git Executable::
    119 * Global Git Arguments::
    120 
    121 
    122 Inspecting
    123 
    124 * Status Buffer::
    125 * Repository List::
    126 * Logging::
    127 * Diffing::
    128 * Ediffing::
    129 * References Buffer::
    130 * Bisecting::
    131 * Visiting Files and Blobs::
    132 * Blaming::
    133 
    134 Status Buffer
    135 
    136 * Status Sections::
    137 * Status Header Sections::
    138 * Status Module Sections::
    139 * Status Options::
    140 
    141 
    142 Logging
    143 
    144 * Refreshing Logs::
    145 * Log Buffer::
    146 * Log Margin::
    147 * Select from Log::
    148 * Reflog::
    149 * Cherries::
    150 
    151 
    152 Diffing
    153 
    154 * Refreshing Diffs::
    155 * Commands Available in Diffs::
    156 * Diff Options::
    157 * Revision Buffer::
    158 
    159 
    160 References Buffer
    161 
    162 * References Sections::
    163 
    164 
    165 Visiting Files and Blobs
    166 
    167 * General-Purpose Visit Commands::
    168 * Visiting Files and Blobs from a Diff::
    169 
    170 
    171 Manipulating
    172 
    173 * Creating Repository::
    174 * Cloning Repository::
    175 * Staging and Unstaging::
    176 * Applying::
    177 * Committing::
    178 * Branching::
    179 * Merging::
    180 * Resolving Conflicts::
    181 * Rebasing::
    182 * Cherry Picking::
    183 * Resetting::
    184 * Stashing::
    185 
    186 Staging and Unstaging
    187 
    188 * Staging from File-Visiting Buffers::
    189 
    190 
    191 Committing
    192 
    193 * Initiating a Commit::
    194 * Editing Commit Messages::
    195 
    196 
    197 Branching
    198 
    199 * The Two Remotes::
    200 * Branch Commands::
    201 * Branch Git Variables::
    202 * Auxiliary Branch Commands::
    203 
    204 
    205 Rebasing
    206 
    207 * Editing Rebase Sequences::
    208 * Information About In-Progress Rebase::
    209 
    210 
    211 Cherry Picking
    212 
    213 * Reverting::
    214 
    215 
    216 Transferring
    217 
    218 * Remotes::
    219 * Fetching::
    220 * Pulling::
    221 * Pushing::
    222 * Plain Patches::
    223 * Maildir Patches::
    224 
    225 Remotes
    226 
    227 * Remote Commands::
    228 * Remote Git Variables::
    229 
    230 
    231 Miscellaneous
    232 
    233 * Tagging::
    234 * Notes::
    235 * Submodules::
    236 * Subtree::
    237 * Worktree::
    238 * Bundle::
    239 * Common Commands::
    240 * Wip Modes::
    241 * Commands for Buffers Visiting Files::
    242 * Minor Mode for Buffers Visiting Blobs::
    243 
    244 Submodules
    245 
    246 * Listing Submodules::
    247 * Submodule Transient::
    248 
    249 
    250 Wip Modes
    251 
    252 * Wip Graph::
    253 * Legacy Wip Modes::
    254 
    255 
    256 Customizing
    257 
    258 * Per-Repository Configuration::
    259 * Essential Settings::
    260 
    261 Essential Settings
    262 
    263 * Safety::
    264 * Performance::
    265 * Default Bindings::
    266 
    267 
    268 Plumbing
    269 
    270 * Calling Git::
    271 * Section Plumbing::
    272 * Refreshing Buffers::
    273 * Conventions::
    274 
    275 Calling Git
    276 
    277 * Getting a Value from Git::
    278 * Calling Git for Effect::
    279 
    280 
    281 Section Plumbing
    282 
    283 * Creating Sections::
    284 * Section Selection::
    285 * Matching Sections::
    286 
    287 
    288 Conventions
    289 
    290 * Theming Faces::
    291 
    292 
    293 FAQ
    294 
    295 * FAQ - How to ...?::
    296 * FAQ - Issues and Errors::
    297 
    298 FAQ - How to ...?
    299 
    300 * How to pronounce Magit?::
    301 * How to show git's output?::
    302 * How to install the gitman info manual?::
    303 * How to show diffs for gpg-encrypted files?::
    304 * How does branching and pushing work?::
    305 * Can Magit be used as ediff-version-control-package?::
    306 * Should I disable VC?::
    307 
    308 
    309 FAQ - Issues and Errors
    310 
    311 * Magit is slow::
    312 * I changed several thousand files at once and now Magit is unusable::
    313 * I am having problems committing::
    314 * I am using MS Windows and cannot push with Magit::
    315 * I am using OS X and SOMETHING works in shell, but not in Magit: I am using OS X and SOMETHING works in shell but not in Magit.
    316 * Expanding a file to show the diff causes it to disappear::
    317 * Point is wrong in the COMMIT_EDITMSG buffer::
    318 * The mode-line information isn't always up-to-date::
    319 * A branch and tag sharing the same name breaks SOMETHING::
    320 * My Git hooks work on the command-line but not inside Magit::
    321 * git-commit-mode isn't used when committing from the command-line::
    322 * Point ends up inside invisible text when jumping to a file-visiting buffer::
    323 * I am unable to stage when using Tramp from MS Windows::
    324 * I am no longer able to save popup defaults::
    325 
    326 
    327 
    328 
    329 File: magit.info,  Node: Introduction,  Next: Installation,  Prev: Top,  Up: Top
    330 
    331 1 Introduction
    332 **************
    333 
    334 Magit is an interface to the version control system Git, implemented as
    335 an Emacs package.  Magit aspires to be a complete Git porcelain.  While
    336 we cannot (yet) claim that Magit wraps and improves upon each and every
    337 Git command, it is complete enough to allow even experienced Git users
    338 to perform almost all of their daily version control tasks directly from
    339 within Emacs.  While many fine Git clients exist, only Magit and Git
    340 itself deserve to be called porcelains.
    341 
    342    Staging and otherwise applying changes is one of the most important
    343 features in a Git porcelain and here Magit outshines anything else,
    344 including Git itself.  Git’s own staging interface (‘git add --patch’)
    345 is so cumbersome that many users only use it in exceptional cases.  In
    346 Magit staging a hunk or even just part of a hunk is as trivial as
    347 staging all changes made to a file.
    348 
    349    The most visible part of Magit’s interface is the status buffer,
    350 which displays information about the current repository.  Its content is
    351 created by running several Git commands and making their output
    352 actionable.  Among other things, it displays information about the
    353 current branch, lists unpulled and unpushed changes and contains
    354 sections displaying the staged and unstaged changes.  That might sound
    355 noisy, but, since sections are collapsible, it’s not.
    356 
    357    To stage or unstage a change one places the cursor on the change and
    358 then types ‘s’ or ‘u’.  The change can be a file or a hunk, or when the
    359 region is active (i.e.  when there is a selection) several files or
    360 hunks, or even just part of a hunk.  The change or changes that these
    361 commands - and many others - would act on are highlighted.
    362 
    363    Magit also implements several other "apply variants" in addition to
    364 staging and unstaging.  One can discard or reverse a change, or apply it
    365 to the working tree.  Git’s own porcelain only supports this for staging
    366 and unstaging and you would have to do something like ‘git diff ... |
    367 ??? | git apply ...’ to discard, revert, or apply a single hunk on the
    368 command line.  In fact that’s exactly what Magit does internally (which
    369 is what lead to the term "apply variants").
    370 
    371    Magit isn’t just for Git experts, but it does assume some prior
    372 experience with Git as well as Emacs.  That being said, many users have
    373 reported that using Magit was what finally taught them what Git is
    374 capable of and how to use it to its fullest.  Other users wished they
    375 had switched to Emacs sooner so that they would have gotten their hands
    376 on Magit earlier.
    377 
    378    While one has to know the basic features of Emacs to be able to make
    379 full use of Magit, acquiring just enough Emacs skills doesn’t take long
    380 and is worth it, even for users who prefer other editors.  Vim users are
    381 advised to give Evil (https://bitbucket.org/lyro/evil/wiki/Home), the
    382 "Extensible VI Layer for Emacs", and Spacemacs
    383 (https://github.com/syl20bnr/spacemacs), an "Emacs starter-kit focused
    384 on Evil" a try.
    385 
    386    Magit provides a consistent and efficient Git porcelain.  After a
    387 short learning period, you will be able to perform most of your daily
    388 version control tasks faster than you would on the command line.  You
    389 will likely also start using features that seemed too daunting in the
    390 past.
    391 
    392    Magit fully embraces Git.  It exposes many advanced features using a
    393 simple but flexible interface instead of only wrapping the trivial ones
    394 like many GUI clients do.  Of course Magit supports logging, cloning,
    395 pushing, and other commands that usually don’t fail in spectacular ways;
    396 but it also supports tasks that often cannot be completed in a single
    397 step.  Magit fully supports tasks such as merging, rebasing,
    398 cherry-picking, reverting, and blaming by not only providing a command
    399 to initiate these tasks but also by displaying context sensitive
    400 information along the way and providing commands that are useful for
    401 resolving conflicts and resuming the sequence after doing so.
    402 
    403    Magit wraps and in many cases improves upon at least the following
    404 Git porcelain commands: ‘add’, ‘am’, ‘bisect’, ‘blame’, ‘branch’,
    405 ‘checkout’, ‘cherry’, ‘cherry-pick’, ‘clean’, ‘clone’, ‘commit’,
    406 ‘config’, ‘describe’, ‘diff’, ‘fetch’, ‘format-patch’, ‘init’, ‘log’,
    407 ‘merge’, ‘merge-tree’, ‘mv’, ‘notes’, ‘pull’, ‘rebase’, ‘reflog’,
    408 ‘remote’, ‘request-pull’, ‘reset’, ‘revert’, ‘rm’, ‘show’, ‘stash’,
    409 ‘submodule’, ‘subtree’, ‘tag’, and ‘worktree.’ Many more Magit porcelain
    410 commands are implemented on top of Git plumbing commands.
    411 
    412 
    413 File: magit.info,  Node: Installation,  Next: Getting Started,  Prev: Introduction,  Up: Top
    414 
    415 2 Installation
    416 **************
    417 
    418 Magit can be installed using Emacs’ package manager or manually from its
    419 development repository.
    420 
    421 * Menu:
    422 
    423 * Installing from Melpa::
    424 * Installing from the Git Repository::
    425 * Post-Installation Tasks::
    426 
    427 
    428 File: magit.info,  Node: Installing from Melpa,  Next: Installing from the Git Repository,  Up: Installation
    429 
    430 2.1 Installing from Melpa
    431 =========================
    432 
    433 Magit is available from Melpa and Melpa-Stable.  If you haven’t used
    434 Emacs’ package manager before, then it is high time you familiarize
    435 yourself with it by reading the documentation in the Emacs manual, see
    436 *note (emacs)Packages::.  Then add one of the archives to
    437 ‘package-archives’:
    438 
    439    • To use Melpa:
    440 
    441      (require 'package)
    442      (add-to-list 'package-archives
    443                   '("melpa" . "http://melpa.org/packages/") t)
    444 
    445    • To use Melpa-Stable:
    446 
    447      (require 'package)
    448      (add-to-list 'package-archives
    449                   '("melpa-stable" . "http://stable.melpa.org/packages/") t)
    450 
    451    Once you have added your preferred archive, you need to update the
    452 local package list using:
    453 
    454      M-x package-refresh-contents RET
    455 
    456    Once you have done that, you can install Magit and its dependencies
    457 using:
    458 
    459      M-x package-install RET magit RET
    460 
    461    Now see *note Post-Installation Tasks::.
    462 
    463 
    464 File: magit.info,  Node: Installing from the Git Repository,  Next: Post-Installation Tasks,  Prev: Installing from Melpa,  Up: Installation
    465 
    466 2.2 Installing from the Git Repository
    467 ======================================
    468 
    469 Magit depends on the ‘dash’, ‘transient’ and ‘with-editor’ libraries
    470 which are available from Melpa and Melpa-Stable.  Install them using
    471 ‘M-x package-install RET <package> RET’.  Of course you may also install
    472 them manually from their repository.
    473 
    474    Then clone the Magit repository:
    475 
    476      $ git clone https://github.com/magit/magit.git ~/.emacs.d/site-lisp/magit
    477      $ cd ~/.emacs.d/site-lisp/magit
    478 
    479    Then compile the libraries and generate the info manuals:
    480 
    481      $ make
    482 
    483    If you haven’t installed ‘dash’, ‘transient’ and ‘with-editor’ from
    484 Melpa or at ‘/path/to/magit/../<package>’, then you have to tell ‘make’
    485 where to find them.  To do so create the file ‘/path/to/magit/config.mk’
    486 with the following content before running ‘make’:
    487 
    488      LOAD_PATH  = -L ~/.emacs.d/site-lisp/magit/lisp
    489      LOAD_PATH += -L ~/.emacs.d/site-lisp/dash
    490      LOAD_PATH += -L ~/.emacs.d/site-lisp/transient/lisp
    491      LOAD_PATH += -L ~/.emacs.d/site-lisp/with-editor
    492 
    493    Finally add this to your init file:
    494 
    495      (add-to-list 'load-path "~/.emacs.d/site-lisp/magit/lisp")
    496      (require 'magit)
    497 
    498      (with-eval-after-load 'info
    499        (info-initialize)
    500        (add-to-list 'Info-directory-list
    501                     "~/.emacs.d/site-lisp/magit/Documentation/"))
    502 
    503    Of course if you installed the dependencies manually as well, then
    504 you have to tell Emacs about them too, by prefixing the above with:
    505 
    506      (add-to-list 'load-path "~/.emacs.d/site-lisp/dash")
    507      (add-to-list 'load-path "~/.emacs.d/site-lisp/transient/lisp")
    508      (add-to-list 'load-path "~/.emacs.d/site-lisp/with-editor")
    509 
    510    Note that you have to add the ‘lisp’ subdirectory to the ‘load-path’,
    511 not the top-level of the repository, and that elements of ‘load-path’
    512 should not end with a slash, while those of ‘Info-directory-list’
    513 should.
    514 
    515    Instead of requiring the feature ‘magit’, you could load just the
    516 autoload definitions, by loading the file ‘magit-autoloads.el’.
    517 
    518      (load "/path/to/magit/lisp/magit-autoloads")
    519 
    520    Instead of running Magit directly from the repository by adding that
    521 to the ‘load-path’, you might want to instead install it in some other
    522 directory using ‘sudo make install’ and setting ‘load-path’ accordingly.
    523 
    524    To update Magit use:
    525 
    526      $ git pull
    527      $ make
    528 
    529    At times it might be necessary to run ‘make clean all’ instead.
    530 
    531    To view all available targets use ‘make help’.
    532 
    533    Now see *note Post-Installation Tasks::.
    534 
    535 
    536 File: magit.info,  Node: Post-Installation Tasks,  Prev: Installing from the Git Repository,  Up: Installation
    537 
    538 2.3 Post-Installation Tasks
    539 ===========================
    540 
    541 After installing Magit you should verify that you are indeed using the
    542 Magit, Git, and Emacs releases you think you are using.  It’s best to
    543 restart Emacs before doing so, to make sure you are not using an
    544 outdated value for ‘load-path’.
    545 
    546      M-x magit-version RET
    547 
    548    should display something like
    549 
    550      Magit 2.8.0, Git 2.10.2, Emacs 25.1.1, gnu/linux
    551 
    552    Then you might also want to read about options that many users likely
    553 want to customize.  See *note Essential Settings::.
    554 
    555    To be able to follow cross references to Git manpages found in this
    556 manual, you might also have to manually install the ‘gitman’ info
    557 manual, or advice ‘Info-follow-nearest-node’ to instead open the actual
    558 manpage.  See *note How to install the gitman info manual?::.
    559 
    560    If you are completely new to Magit then see *note Getting Started::.
    561 
    562    If you run into problems, then please see the *note FAQ::.  Also see
    563 the *note Debugging Tools::.
    564 
    565    And last but not least please consider making a donation, to ensure
    566 that I can keep working on Magit.  See <https://magit.vc/donations>.
    567 for various donation options.
    568 
    569 
    570 File: magit.info,  Node: Getting Started,  Next: Interface Concepts,  Prev: Installation,  Up: Top
    571 
    572 3 Getting Started
    573 *****************
    574 
    575 This short tutorial describes the most essential features that many
    576 Magitians use on a daily basis.  It only scratches the surface but
    577 should be enough to get you started.
    578 
    579    IMPORTANT: It is safest if you clone some repository just for this
    580 tutorial.  Alternatively you can use an existing local repository, but
    581 if you do that, then you should commit all uncommitted changes before
    582 proceeding.
    583 
    584    Type ‘C-x g’ to display information about the current Git repository
    585 in a dedicated buffer, called the status buffer.
    586 
    587    Most Magit commands are commonly invoked from the status buffer.  It
    588 can be considered the primary interface for interacting with Git using
    589 Magit.  Many other Magit buffers may exist at a given time, but they are
    590 often created from this buffer.
    591 
    592    Depending on what state your repository is in, this buffer may
    593 contain sections titled "Staged changes", "Unstaged changes", "Unmerged
    594 into origin/master", "Unpushed to origin/master", and many others.
    595 
    596    Since we are starting from a safe state, which you can easily return
    597 to (by doing a ‘git reset --hard PRE-MAGIT-STATE’), there currently are
    598 no staged or unstaged changes.  Edit some files and save the changes.
    599 Then go back to the status buffer, while at the same time refreshing it,
    600 by typing ‘C-x g’.  (When the status buffer, or any Magit buffer for
    601 that matter, is the current buffer, then you can also use just ‘g’ to
    602 refresh it).
    603 
    604    Move between sections using ‘p’ and ‘n’.  Note that the bodies of
    605 some sections are hidden.  Type ‘TAB’ to expand or collapse the section
    606 at point.  You can also use ‘C-tab’ to cycle the visibility of the
    607 current section and its children.  Move to a file section inside the
    608 section named "Unstaged changes" and type ‘s’ to stage the changes you
    609 have made to that file.  That file now appears under "Staged changes".
    610 
    611    Magit can stage and unstage individual hunks, not just complete
    612 files.  Move to the file you have just staged, expand it using ‘TAB’,
    613 move to one of the hunks using ‘n’, and unstage just that by typing ‘u’.
    614 Note how the staging (‘s’) and unstaging (‘u’) commands operate on the
    615 change at point.  Many other commands behave the same way.
    616 
    617    You can also un-/stage just part of a hunk.  Inside the body of a
    618 hunk section (move there using ‘C-n’), set the mark using ‘C-SPC’ and
    619 move down until some added and/or removed lines fall inside the region
    620 but not all of them.  Again type ‘s’ to stage.
    621 
    622    It is also possible to un-/stage multiple files at once.  Move to a
    623 file section, type ‘C-SPC’, move to the next file using ‘n’, and then
    624 ‘s’ to stage both files.  Note that both the mark and point have to be
    625 on the headings of sibling sections for this to work.  If the region
    626 looks like it does in other buffers, then it doesn’t select Magit
    627 sections that can be acted on as a unit.
    628 
    629    And then of course you want to commit your changes.  Type ‘c’.  This
    630 shows the available commit commands and arguments in a buffer at the
    631 bottom of the frame.  Each command and argument is prefixed with the key
    632 that invokes/sets it.  Do not worry about this for now.  We want to
    633 create a "normal" commit, which is done by typing ‘c’ again.
    634 
    635    Now two new buffers appear.  One is for writing the commit message,
    636 the other shows a diff with the changes that you are about to commit.
    637 Write a message and then type ‘C-c C-c’ to actually create the commit.
    638 
    639    You probably don’t want to push the commit you just created because
    640 you just committed some random changes, but if that is not the case you
    641 could push it by typing ‘P’ to show all the available push commands and
    642 arguments and then ‘p’ to push to a branch with the same name as the
    643 local branch onto the remote configured as the push-remote.  (If the
    644 push-remote is not configured yet, then you would first be prompted for
    645 the remote to push to.)
    646 
    647    So far we have mentioned the commit, push, and log menu commands.
    648 These are probably among the menus you will be using the most, but many
    649 others exist.  To show a menu that lists all other menus (as well as the
    650 various apply commands and some other essential commands), type ‘h’.
    651 Try a few.  (Such menus are also called "transient prefix commands" or
    652 just "transients".)
    653 
    654    The key bindings in that menu correspond to the bindings in Magit
    655 buffers, including but not limited to the status buffer.  So you could
    656 type ‘h d’ to bring up the diff menu, but once you remember that "d"
    657 stands for "diff", you would usually do so by just typing ‘d’.  But this
    658 "prefix of prefixes" is useful even once you have memorized all the
    659 bindings, as it can provide easy access to Magit commands from non-Magit
    660 buffers.  The global binding is ‘C-x M-g’.
    661 
    662    In file visiting buffers ‘C-c M-g’ brings up a similar menu featuring
    663 commands that act on just the visited file, see *note Commands for
    664 Buffers Visiting Files::.
    665 
    666    It is not necessary that you do so now, but if you stick with Magit,
    667 then it is highly recommended that you read the next section too.
    668 
    669 
    670 File: magit.info,  Node: Interface Concepts,  Next: Inspecting,  Prev: Getting Started,  Up: Top
    671 
    672 4 Interface Concepts
    673 ********************
    674 
    675 * Menu:
    676 
    677 * Modes and Buffers::
    678 * Sections::
    679 * Transient Commands::
    680 * Transient Arguments and Buffer Variables::
    681 * Completion, Confirmation and the Selection: Completion Confirmation and the Selection.
    682 * Running Git::
    683 
    684 
    685 File: magit.info,  Node: Modes and Buffers,  Next: Sections,  Up: Interface Concepts
    686 
    687 4.1 Modes and Buffers
    688 =====================
    689 
    690 Magit provides several major-modes.  For each of these modes there
    691 usually exists only one buffer per repository.  Separate modes and thus
    692 buffers exist for commits, diffs, logs, and some other things.
    693 
    694    Besides these special purpose buffers, there also exists an overview
    695 buffer, called the *status buffer*.  It’s usually from this buffer that
    696 the user invokes Git commands, or creates or visits other buffers.
    697 
    698    In this manual we often speak about "Magit buffers".  By that we mean
    699 buffers whose major-modes derive from ‘magit-mode’.
    700 
    701 ‘M-x magit-toggle-buffer-lock’     (‘magit-toggle-buffer-lock’)
    702 
    703      This command locks the current buffer to its value or if the buffer
    704      is already locked, then it unlocks it.
    705 
    706      Locking a buffer to its value prevents it from being reused to
    707      display another value.  The name of a locked buffer contains its
    708      value, which allows telling it apart from other locked buffers and
    709      the unlocked buffer.
    710 
    711      Not all Magit buffers can be locked to their values; for example,
    712      it wouldn’t make sense to lock a status buffer.
    713 
    714      There can only be a single unlocked buffer using a certain
    715      major-mode per repository.  So when a buffer is being unlocked and
    716      another unlocked buffer already exists for that mode and
    717      repository, then the former buffer is instead deleted and the
    718      latter is displayed in its place.
    719 
    720 * Menu:
    721 
    722 * Switching Buffers::
    723 * Naming Buffers::
    724 * Quitting Windows::
    725 * Automatic Refreshing of Magit Buffers::
    726 * Automatic Saving of File-Visiting Buffers::
    727 * Automatic Reverting of File-Visiting Buffers::
    728 
    729 
    730 File: magit.info,  Node: Switching Buffers,  Next: Naming Buffers,  Up: Modes and Buffers
    731 
    732 4.1.1 Switching Buffers
    733 -----------------------
    734 
    735  -- Function: magit-display-buffer buffer &optional display-function
    736 
    737      This function is a wrapper around ‘display-buffer’ and is used to
    738      display any Magit buffer.  It displays BUFFER in some window and,
    739      unlike ‘display-buffer’, also selects that window, provided
    740      ‘magit-display-buffer-noselect’ is ‘nil’.  It also runs the hooks
    741      mentioned below.
    742 
    743      If optional DISPLAY-FUNCTION is non-nil, then that is used to
    744      display the buffer.  Usually that is ‘nil’ and the function
    745      specified by ‘magit-display-buffer-function’ is used.
    746 
    747  -- Variable: magit-display-buffer-noselect
    748 
    749      When this is non-nil, then ‘magit-display-buffer’ only displays the
    750      buffer but forgoes also selecting the window.  This variable should
    751      not be set globally, it is only intended to be let-bound, by code
    752      that automatically updates "the other window".  This is used for
    753      example when the revision buffer is updated when you move inside
    754      the log buffer.
    755 
    756  -- User Option: magit-display-buffer-function
    757 
    758      The function specified here is called by ‘magit-display-buffer’
    759      with one argument, a buffer, to actually display that buffer.  This
    760      function should call ‘display-buffer’ with that buffer as first and
    761      a list of display actions as second argument.
    762 
    763      Magit provides several functions, listed below, that are suitable
    764      values for this option.  If you want to use different rules, then a
    765      good way of doing that is to start with a copy of one of these
    766      functions and then adjust it to your needs.
    767 
    768      Instead of using a wrapper around ‘display-buffer’, that function
    769      itself can be used here, in which case the display actions have to
    770      be specified by adding them to ‘display-buffer-alist’ instead.
    771 
    772      To learn about display actions, see *note (elisp)Choosing Window::.
    773 
    774  -- Function: magit-display-buffer-traditional buffer
    775 
    776      This function is the current default value of the option
    777      ‘magit-display-buffer-function’.  Before that option and this
    778      function were added, the behavior was hard-coded in many places all
    779      over the code base but now all the rules are contained in this one
    780      function (except for the "noselect" special case mentioned above).
    781 
    782  -- Function: magit-display-buffer-same-window-except-diff-v1
    783 
    784      This function displays most buffers in the currently selected
    785      window.  If a buffer’s mode derives from ‘magit-diff-mode’ or
    786      ‘magit-process-mode’, it is displayed in another window.
    787 
    788  -- Function: magit-display-buffer-fullframe-status-v1
    789 
    790      This function fills the entire frame when displaying a status
    791      buffer.  Otherwise, it behaves like
    792      ‘magit-display-buffer-traditional’.
    793 
    794  -- Function: magit-display-buffer-fullframe-status-topleft-v1
    795 
    796      This function fills the entire frame when displaying a status
    797      buffer.  It behaves like ‘magit-display-buffer-fullframe-status-v1’
    798      except that it displays buffers that derive from ‘magit-diff-mode’
    799      or ‘magit-process-mode’ to the top or left of the current buffer
    800      rather than to the bottom or right.  As a result, Magit buffers
    801      tend to pop up on the same side as they would if
    802      ‘magit-display-buffer-traditional’ were in use.
    803 
    804  -- Function: magit-display-buffer-fullcolumn-most-v1
    805 
    806      This function displays most buffers so that they fill the entire
    807      height of the frame.  However, the buffer is displayed in another
    808      window if (1) the buffer’s mode derives from ‘magit-process-mode’,
    809      or (2) the buffer’s mode derives from ‘magit-diff-mode’, provided
    810      that the mode of the current buffer derives from ‘magit-log-mode’
    811      or ‘magit-cherry-mode’.
    812 
    813  -- User Option: magit-pre-display-buffer-hook
    814 
    815      This hook is run by ‘magit-display-buffer’ before displaying the
    816      buffer.
    817 
    818  -- Function: magit-save-window-configuration
    819 
    820      This function saves the current window configuration.  Later when
    821      the buffer is buried, it may be restored by
    822      ‘magit-restore-window-configuration’.
    823 
    824  -- User Option: magit-post-display-buffer-hook
    825 
    826      This hook is run by ‘magit-display-buffer’ after displaying the
    827      buffer.
    828 
    829  -- Function: magit-maybe-set-dedicated
    830 
    831      This function remembers if a new window had to be created to
    832      display the buffer, or whether an existing window was reused.  This
    833      information is later used by ‘magit-mode-quit-window’, to determine
    834      whether the window should be deleted when its last Magit buffer is
    835      buried.
    836 
    837 
    838 File: magit.info,  Node: Naming Buffers,  Next: Quitting Windows,  Prev: Switching Buffers,  Up: Modes and Buffers
    839 
    840 4.1.2 Naming Buffers
    841 --------------------
    842 
    843  -- User Option: magit-generate-buffer-name-function
    844 
    845      The function used to generate the names of Magit buffers.
    846 
    847      Such a function should take the options
    848      ‘magit-uniquify-buffer-names’ as well as ‘magit-buffer-name-format’
    849      into account.  If it doesn’t, then should be clearly stated in the
    850      doc-string.  And if it supports %-sequences beyond those mentioned
    851      in the doc-string of the option ‘magit-buffer-name-format’, then
    852      its own doc-string should describe the additions.
    853 
    854  -- Function: magit-generate-buffer-name-default-function mode
    855 
    856      This function returns a buffer name suitable for a buffer whose
    857      major-mode is MODE and which shows information about the repository
    858      in which ‘default-directory’ is located.
    859 
    860      This function uses ‘magit-buffer-name-format’ and supporting all of
    861      the %-sequences mentioned the documentation of that option.  It
    862      also respects the option ‘magit-uniquify-buffer-names’.
    863 
    864  -- User Option: magit-buffer-name-format
    865 
    866      The format string used to name Magit buffers.
    867 
    868      At least the following %-sequences are supported:
    869 
    870         • ‘%m’
    871 
    872           The name of the major-mode, but with the ‘-mode’ suffix
    873           removed.
    874 
    875         • ‘%M’
    876 
    877           Like ‘%m’ but abbreviate ‘magit-status-mode’ as ‘magit’.
    878 
    879         • ‘%v’
    880 
    881           The value the buffer is locked to, in parentheses, or an empty
    882           string if the buffer is not locked to a value.
    883 
    884         • ‘%V’
    885 
    886           Like ‘%v’, but the string is prefixed with a space, unless it
    887           is an empty string.
    888 
    889         • ‘%t’
    890 
    891           The top-level directory of the working tree of the repository,
    892           or if ‘magit-uniquify-buffer-names’ is non-nil an abbreviation
    893           of that.
    894 
    895         • ‘%x’
    896 
    897           If ‘magit-uniquify-buffer-names’ is nil "*", otherwise the
    898           empty string.  Due to limitations of the ‘uniquify’ package,
    899           buffer names must end with the path.
    900 
    901         • ‘%T’
    902 
    903           Obsolete, use "%t%x" instead.  Like ‘%t’, but append an
    904           asterisk if and only if ‘magit-uniquify-buffer-names’ is nil.
    905 
    906      The value should always contain ‘%m’ or ‘%M’, ‘%v’ or ‘%V’, and
    907      ‘%t’ (or the obsolete ‘%T’).  If ‘magit-uniquify-buffer-names’ is
    908      non-nil, then the value must end with ‘%t’ or ‘%t%x’ (or the
    909      obsolete ‘%T’).  See issue #2841.
    910 
    911  -- User Option: magit-uniquify-buffer-names
    912 
    913      This option controls whether the names of Magit buffers are
    914      uniquified.  If the names are not being uniquified, then they
    915      contain the full path of the top-level of the working tree of the
    916      corresponding repository.  If they are being uniquified, then they
    917      end with the basename of the top-level, or if that would conflict
    918      with the name used for other buffers, then the names of all these
    919      buffers are adjusted until they no longer conflict.
    920 
    921      This is done using the ‘uniquify’ package; customize its options to
    922      control how buffer names are uniquified.
    923 
    924 
    925 File: magit.info,  Node: Quitting Windows,  Next: Automatic Refreshing of Magit Buffers,  Prev: Naming Buffers,  Up: Modes and Buffers
    926 
    927 4.1.3 Quitting Windows
    928 ----------------------
    929 
    930 ‘q’     (‘magit-mode-bury-buffer’)
    931 
    932      This command buries the current Magit buffer.
    933 
    934      With a prefix argument, it instead kills the buffer.  With a double
    935      prefix argument, also kills all other Magit buffers associated with
    936      the current project.
    937 
    938  -- User Option: magit-bury-buffer-function
    939 
    940      The function used to actually bury or kill the current buffer.
    941 
    942      ‘magit-mode-bury-buffer’ calls this function with one argument.  If
    943      the argument is non-nil, then the function has to kill the current
    944      buffer.  Otherwise it has to bury it alive.  The default value
    945      currently is ‘magit-restore-window-configuration’.
    946 
    947  -- Function: magit-restore-window-configuration kill-buffer
    948 
    949      Bury or kill the current buffer using ‘quit-window’, which is
    950      called with KILL-BUFFER as first and the selected window as second
    951      argument.
    952 
    953      Then restore the window configuration that existed right before the
    954      current buffer was displayed in the selected frame.  Unfortunately
    955      that also means that point gets adjusted in all the buffers, which
    956      are being displayed in the selected frame.
    957 
    958  -- Function: magit-mode-quit-window kill-buffer
    959 
    960      Bury or kill the current buffer using ‘quit-window’, which is
    961      called with KILL-BUFFER as first and the selected window as second
    962      argument.
    963 
    964      Then, if the window was originally created to display a Magit
    965      buffer and the buried buffer was the last remaining Magit buffer
    966      that was ever displayed in the window, then that is deleted.
    967 
    968 
    969 File: magit.info,  Node: Automatic Refreshing of Magit Buffers,  Next: Automatic Saving of File-Visiting Buffers,  Prev: Quitting Windows,  Up: Modes and Buffers
    970 
    971 4.1.4 Automatic Refreshing of Magit Buffers
    972 -------------------------------------------
    973 
    974 After running a command which may change the state of the current
    975 repository, the current Magit buffer and the corresponding status buffer
    976 are refreshed.  The status buffer can be automatically refreshed
    977 whenever a buffer is saved to a file inside the respective repository by
    978 adding a hook, like so:
    979 
    980      (with-eval-after-load 'magit-mode
    981        (add-hook 'after-save-hook 'magit-after-save-refresh-status t))
    982 
    983    Automatically refreshing Magit buffers ensures that the displayed
    984 information is up-to-date most of the time but can lead to a noticeable
    985 delay in big repositories.  Other Magit buffers are not refreshed to
    986 keep the delay to a minimum and also because doing so can sometimes be
    987 undesirable.
    988 
    989    Buffers can also be refreshed explicitly, which is useful in buffers
    990 that weren’t current during the last refresh and after changes were made
    991 to the repository outside of Magit.
    992 
    993 ‘g’     (‘magit-refresh’)
    994 
    995      This command refreshes the current buffer if its major mode derives
    996      from ‘magit-mode’ as well as the corresponding status buffer.
    997 
    998      If the option ‘magit-revert-buffers’ calls for it, then it also
    999      reverts all unmodified buffers that visit files being tracked in
   1000      the current repository.
   1001 
   1002 ‘G’     (‘magit-refresh-all’)
   1003 
   1004      This command refreshes all Magit buffers belonging to the current
   1005      repository and also reverts all unmodified buffers that visit files
   1006      being tracked in the current repository.
   1007 
   1008      The file-visiting buffers are always reverted, even if
   1009      ‘magit-revert-buffers’ is nil.
   1010 
   1011  -- User Option: magit-refresh-buffer-hook
   1012 
   1013      This hook is run in each Magit buffer that was refreshed during the
   1014      current refresh - normally the current buffer and the status
   1015      buffer.
   1016 
   1017  -- User Option: magit-refresh-status-buffer
   1018 
   1019      When this option is non-nil, then the status buffer is
   1020      automatically refreshed after running git for side-effects, in
   1021      addition to the current Magit buffer, which is always refreshed
   1022      automatically.
   1023 
   1024      Only set this to nil after exhausting all other options to improve
   1025      performance.
   1026 
   1027  -- Function: magit-after-save-refresh-status
   1028 
   1029      This function is intended to be added to ‘after-save-hook’.  After
   1030      doing that the corresponding status buffer is refreshed whenever a
   1031      buffer is saved to a file inside a repository.
   1032 
   1033      Note that refreshing a Magit buffer is done by re-creating its
   1034      contents from scratch, which can be slow in large repositories.  If
   1035      you are not satisfied with Magit’s performance, then you should
   1036      obviously not add this function to that hook.
   1037 
   1038 
   1039 File: magit.info,  Node: Automatic Saving of File-Visiting Buffers,  Next: Automatic Reverting of File-Visiting Buffers,  Prev: Automatic Refreshing of Magit Buffers,  Up: Modes and Buffers
   1040 
   1041 4.1.5 Automatic Saving of File-Visiting Buffers
   1042 -----------------------------------------------
   1043 
   1044 File-visiting buffers are by default saved at certain points in time.
   1045 This doesn’t guarantee that Magit buffers are always up-to-date, but,
   1046 provided one only edits files by editing them in Emacs and uses only
   1047 Magit to interact with Git, one can be fairly confident.  When in doubt
   1048 or after outside changes, type ‘g’ (‘magit-refresh’) to save and refresh
   1049 explicitly.
   1050 
   1051  -- User Option: magit-save-repository-buffers
   1052 
   1053      This option controls whether file-visiting buffers are saved before
   1054      certain events.
   1055 
   1056      If this is non-nil then all modified file-visiting buffers
   1057      belonging to the current repository may be saved before running
   1058      commands, before creating new Magit buffers, and before explicitly
   1059      refreshing such buffers.  If this is ‘dontask’ then this is done
   1060      without user intervention.  If it is ‘t’ then the user has to
   1061      confirm each save.
   1062 
   1063 
   1064 File: magit.info,  Node: Automatic Reverting of File-Visiting Buffers,  Prev: Automatic Saving of File-Visiting Buffers,  Up: Modes and Buffers
   1065 
   1066 4.1.6 Automatic Reverting of File-Visiting Buffers
   1067 --------------------------------------------------
   1068 
   1069 By default Magit automatically reverts buffers that are visiting files
   1070 that are being tracked in a Git repository, after they have changed on
   1071 disk.  When using Magit one often changes files on disk by running Git,
   1072 i.e.  "outside Emacs", making this a rather important feature.
   1073 
   1074    For example, if you discard a change in the status buffer, then that
   1075 is done by running ‘git apply --reverse ...’, and Emacs considers the
   1076 file to have "changed on disk".  If Magit did not automatically revert
   1077 the buffer, then you would have to type ‘M-x revert-buffer RET RET’ in
   1078 the visiting buffer before you could continue making changes.
   1079 
   1080  -- User Option: magit-auto-revert-mode
   1081 
   1082      When this mode is enabled, then buffers that visit tracked files
   1083      are automatically reverted after the visited files change on disk.
   1084 
   1085  -- User Option: global-auto-revert-mode
   1086 
   1087      When this mode is enabled, then any file-visiting buffer is
   1088      automatically reverted after the visited file changes on disk.
   1089 
   1090      If you like buffers that visit tracked files to be automatically
   1091      reverted, then you might also like any buffer to be reverted, not
   1092      just those visiting tracked files.  If that is the case, then
   1093      enable this mode _instead of_ ‘magit-auto-revert-mode’.
   1094 
   1095  -- User Option: magit-auto-revert-immediately
   1096 
   1097      This option controls whether Magit reverts buffers immediately.
   1098 
   1099      If this is non-nil and either ‘global-auto-revert-mode’ or
   1100      ‘magit-auto-revert-mode’ is enabled, then Magit immediately reverts
   1101      buffers by explicitly calling ‘auto-revert-buffers’ after running
   1102      Git for side-effects.
   1103 
   1104      If ‘auto-revert-use-notify’ is non-nil (and file notifications are
   1105      actually supported), then ‘magit-auto-revert-immediately’ does not
   1106      have to be non-nil, because the reverts happen immediately anyway.
   1107 
   1108      If ‘magit-auto-revert-immediately’ and ‘auto-revert-use-notify’ are
   1109      both ‘nil’, then reverts happen after ‘auto-revert-interval’
   1110      seconds of user inactivity.  That is not desirable.
   1111 
   1112  -- User Option: auto-revert-use-notify
   1113 
   1114      This option controls whether file notification functions should be
   1115      used.  Note that this variable unfortunately defaults to ‘t’ even
   1116      on systems on which file notifications cannot be used.
   1117 
   1118  -- User Option: magit-auto-revert-tracked-only
   1119 
   1120      This option controls whether ‘magit-auto-revert-mode’ only reverts
   1121      tracked files or all files that are located inside Git
   1122      repositories, including untracked files and files located inside
   1123      Git’s control directory.
   1124 
   1125  -- User Option: auto-revert-mode
   1126 
   1127      The global mode ‘magit-auto-revert-mode’ works by turning on this
   1128      local mode in the appropriate buffers (but
   1129      ‘global-auto-revert-mode’ is implemented differently).  You can
   1130      also turn it on or off manually, which might be necessary if Magit
   1131      does not notice that a previously untracked file now is being
   1132      tracked or vice-versa.
   1133 
   1134  -- User Option: auto-revert-stop-on-user-input
   1135 
   1136      This option controls whether the arrival of user input suspends the
   1137      automatic reverts for ‘auto-revert-interval’ seconds.
   1138 
   1139  -- User Option: auto-revert-interval
   1140 
   1141      This option controls how many seconds Emacs waits for before
   1142      resuming suspended reverts.
   1143 
   1144  -- User Option: auto-revert-buffer-list-filter
   1145 
   1146      This option specifies an additional filter used by
   1147      ‘auto-revert-buffers’ to determine whether a buffer should be
   1148      reverted or not.
   1149 
   1150      This option is provided by Magit, which also advises
   1151      ‘auto-revert-buffers’ to respect it.  Magit users who do not turn
   1152      on the local mode ‘auto-revert-mode’ themselves, are best served by
   1153      setting the value to ‘magit-auto-revert-repository-buffer-p’.
   1154 
   1155      However the default is nil, so as not to disturb users who do use
   1156      the local mode directly.  If you experience delays when running
   1157      Magit commands, then you should consider using one of the
   1158      predicates provided by Magit - especially if you also use Tramp.
   1159 
   1160      Users who do turn on ‘auto-revert-mode’ in buffers in which Magit
   1161      doesn’t do that for them, should likely not use any filter.  Users
   1162      who turn on ‘global-auto-revert-mode’, do not have to worry about
   1163      this option, because it is disregarded if the global mode is
   1164      enabled.
   1165 
   1166  -- User Option: auto-revert-verbose
   1167 
   1168      This option controls whether Emacs reports when a buffer has been
   1169      reverted.
   1170 
   1171    The options with the ‘auto-revert-’ prefix are located in the Custom
   1172 group named ‘auto-revert’.  The other, Magit-specific, options are
   1173 located in the ‘magit’ group.
   1174 
   1175 * Menu:
   1176 
   1177 * Risk of Reverting Automatically::
   1178 
   1179 
   1180 File: magit.info,  Node: Risk of Reverting Automatically,  Up: Automatic Reverting of File-Visiting Buffers
   1181 
   1182 Risk of Reverting Automatically
   1183 ...............................
   1184 
   1185 For the vast majority of users, automatically reverting file-visiting
   1186 buffers after they have changed on disk is harmless.
   1187 
   1188    If a buffer is modified (i.e.  it contains changes that haven’t been
   1189 saved yet), then Emacs will refuse to automatically revert it.  If you
   1190 save a previously modified buffer, then that results in what is seen by
   1191 Git as an uncommitted change.  Git will then refuse to carry out any
   1192 commands that would cause these changes to be lost.  In other words, if
   1193 there is anything that could be lost, then either Git or Emacs will
   1194 refuse to discard the changes.
   1195 
   1196    However, if you use file-visiting buffers as a sort of ad hoc
   1197 "staging area", then the automatic reverts could potentially cause data
   1198 loss.  So far I have heard from only one user who uses such a workflow.
   1199 
   1200    An example: You visit some file in a buffer, edit it, and save the
   1201 changes.  Then, outside of Emacs (or at least not using Magit or by
   1202 saving the buffer) you change the file on disk again.  At this point the
   1203 buffer is the only place where the intermediate version still exists.
   1204 You have saved the changes to disk, but that has since been overwritten.
   1205 Meanwhile Emacs considers the buffer to be unmodified (because you have
   1206 not made any changes to it since you last saved it to the visited file)
   1207 and therefore would not object to it being automatically reverted.  At
   1208 this point an Auto-Revert mode would kick in.  It would check whether
   1209 the buffer is modified and since that is not the case it would revert
   1210 it.  The intermediate version would be lost.  (Actually you could still
   1211 get it back using the ‘undo’ command.)
   1212 
   1213    If your workflow depends on Emacs preserving the intermediate version
   1214 in the buffer, then you have to disable all Auto-Revert modes.  But
   1215 please consider that such a workflow would be dangerous even without
   1216 using an Auto-Revert mode, and should therefore be avoided.  If Emacs
   1217 crashes or if you quit Emacs by mistake, then you would also lose the
   1218 buffer content.  There would be no autosave file still containing the
   1219 intermediate version (because that was deleted when you saved the
   1220 buffer) and you would not be asked whether you want to save the buffer
   1221 (because it isn’t modified).
   1222 
   1223 
   1224 File: magit.info,  Node: Sections,  Next: Transient Commands,  Prev: Modes and Buffers,  Up: Interface Concepts
   1225 
   1226 4.2 Sections
   1227 ============
   1228 
   1229 Magit buffers are organized into nested sections, which can be collapsed
   1230 and expanded, similar to how sections are handled in Org mode.  Each
   1231 section also has a type, and some sections also have a value.  For each
   1232 section type there can also be a local keymap, shared by all sections of
   1233 that type.
   1234 
   1235    Taking advantage of the section value and type, many commands operate
   1236 on the current section, or when the region is active and selects
   1237 sections of the same type, all of the selected sections.  Commands that
   1238 only make sense for a particular section type (as opposed to just
   1239 behaving differently depending on the type) are usually bound in section
   1240 type keymaps.
   1241 
   1242 * Menu:
   1243 
   1244 * Section Movement::
   1245 * Section Visibility::
   1246 * Section Hooks::
   1247 * Section Types and Values::
   1248 * Section Options::
   1249 
   1250 
   1251 File: magit.info,  Node: Section Movement,  Next: Section Visibility,  Up: Sections
   1252 
   1253 4.2.1 Section Movement
   1254 ----------------------
   1255 
   1256 To move within a section use the usual keys (‘C-p’, ‘C-n’, ‘C-b’, ‘C-f’
   1257 etc), whose global bindings are not shadowed.  To move to another
   1258 section use the following commands.
   1259 
   1260 ‘p’     (‘magit-section-backward’)
   1261 
   1262      When not at the beginning of a section, then move to the beginning
   1263      of the current section.  At the beginning of a section, instead
   1264      move to the beginning of the previous visible section.
   1265 
   1266 ‘n’     (‘magit-section-forward’)
   1267 
   1268      Move to the beginning of the next visible section.
   1269 
   1270 ‘M-p’     (‘magit-section-backward-siblings’)
   1271 
   1272      Move to the beginning of the previous sibling section.  If there is
   1273      no previous sibling section, then move to the parent section
   1274      instead.
   1275 
   1276 ‘M-n’     (‘magit-section-forward-siblings’)
   1277 
   1278      Move to the beginning of the next sibling section.  If there is no
   1279      next sibling section, then move to the parent section instead.
   1280 
   1281 ‘^’     (‘magit-section-up’)
   1282 
   1283      Move to the beginning of the parent of the current section.
   1284 
   1285    The above commands all call the hook ‘magit-section-movement-hook’.
   1286 Any of the functions listed below can be used as members of this hook.
   1287 
   1288    You might want to remove some of the functions that Magit adds using
   1289 ‘add-hook’.  In doing so you have to make sure you do not attempt to
   1290 remove function that haven’t even been added yet, for example:
   1291 
   1292      (with-eval-after-load 'magit-diff
   1293        (remove-hook 'magit-section-movement-hook
   1294                     'magit-hunk-set-window-start))
   1295 
   1296  -- Variable: magit-section-movement-hook
   1297 
   1298      This hook is run by all of the above movement commands, after
   1299      arriving at the destination.
   1300 
   1301  -- Function: magit-hunk-set-window-start
   1302 
   1303      This hook function ensures that the beginning of the current
   1304      section is visible, provided it is a ‘hunk’ section.  Otherwise, it
   1305      does nothing.
   1306 
   1307      Loading ‘magit-diff’ adds this function to the hook.
   1308 
   1309  -- Function: magit-section-set-window-start
   1310 
   1311      This hook function ensures that the beginning of the current
   1312      section is visible, regardless of the section’s type.  If you add
   1313      this to ‘magit-section-movement-hook’, then you must remove the
   1314      hunk-only variant in turn.
   1315 
   1316  -- Function: magit-log-maybe-show-more-commits
   1317 
   1318      This hook function only has an effect in log buffers, and ‘point’
   1319      is on the "show more" section.  If that is the case, then it
   1320      doubles the number of commits that are being shown.
   1321 
   1322      Loading ‘magit-log’ adds this function to the hook.
   1323 
   1324  -- Function: magit-log-maybe-update-revision-buffer
   1325 
   1326      When moving inside a log buffer, then this function updates the
   1327      revision buffer, provided it is already being displayed in another
   1328      window of the same frame.
   1329 
   1330      Loading ‘magit-log’ adds this function to the hook.
   1331 
   1332  -- Function: magit-log-maybe-update-blob-buffer
   1333 
   1334      When moving inside a log buffer and another window of the same
   1335      frame displays a blob buffer, then this function instead displays
   1336      the blob buffer for the commit at point in that window.
   1337 
   1338  -- Function: magit-status-maybe-update-revision-buffer
   1339 
   1340      When moving inside a status buffer, then this function updates the
   1341      revision buffer, provided it is already being displayed in another
   1342      window of the same frame.
   1343 
   1344  -- Function: magit-status-maybe-update-stash-buffer
   1345 
   1346      When moving inside a status buffer, then this function updates the
   1347      stash buffer, provided it is already being displayed in another
   1348      window of the same frame.
   1349 
   1350  -- Function: magit-status-maybe-update-blob-buffer
   1351 
   1352      When moving inside a status buffer and another window of the same
   1353      frame displays a blob buffer, then this function instead displays
   1354      the blob buffer for the commit at point in that window.
   1355 
   1356  -- Function: magit-stashes-maybe-update-stash-buffer
   1357 
   1358      When moving inside a buffer listing stashes, then this function
   1359      updates the stash buffer, provided it is already being displayed in
   1360      another window of the same frame.
   1361 
   1362  -- User Option: magit-update-other-window-delay
   1363 
   1364      Delay before automatically updating the other window.
   1365 
   1366      When moving around in certain buffers, then certain other buffers,
   1367      which are being displayed in another window, may optionally be
   1368      updated to display information about the section at point.
   1369 
   1370      When holding down a key to move by more than just one section, then
   1371      that would update that buffer for each section on the way.  To
   1372      prevent that, updating the revision buffer is delayed, and this
   1373      option controls for how long.  For optimal experience you might
   1374      have to adjust this delay and/or the keyboard repeat rate and delay
   1375      of your graphical environment or operating system.
   1376 
   1377 
   1378 File: magit.info,  Node: Section Visibility,  Next: Section Hooks,  Prev: Section Movement,  Up: Sections
   1379 
   1380 4.2.2 Section Visibility
   1381 ------------------------
   1382 
   1383 Magit provides many commands for changing the visibility of sections,
   1384 but all you need to get started are the next two.
   1385 
   1386 ‘TAB’     (‘magit-section-toggle’)
   1387 
   1388      Toggle the visibility of the body of the current section.
   1389 
   1390 ‘C-<tab>’     (‘magit-section-cycle’)
   1391 
   1392      Cycle the visibility of current section and its children.
   1393 
   1394 ‘M-<tab>’     (‘magit-section-cycle-diffs’)
   1395 
   1396      Cycle the visibility of diff-related sections in the current
   1397      buffer.
   1398 
   1399 ‘S-<tab>’     (‘magit-section-cycle-global’)
   1400 
   1401      Cycle the visibility of all sections in the current buffer.
   1402 
   1403 ‘1’     (‘magit-section-show-level-1’)
   1404 ‘2’     (‘magit-section-show-level-2’)
   1405 ‘3’     (‘magit-section-show-level-3’)
   1406 ‘4’     (‘magit-section-show-level-4’)
   1407 
   1408      Show sections surrounding the current section up to level N.
   1409 
   1410 ‘M-1’     (‘magit-section-show-level-1-all’)
   1411 ‘M-2’     (‘magit-section-show-level-2-all’)
   1412 ‘M-3’     (‘magit-section-show-level-3-all’)
   1413 ‘M-4’     (‘magit-section-show-level-4-all’)
   1414 
   1415      Show all sections up to level N.
   1416 
   1417    Some functions, which are used to implement the above commands, are
   1418 also exposed as commands themselves.  By default no keys are bound to
   1419 these commands, as they are generally perceived to be much less useful.
   1420 But your mileage may vary.
   1421 
   1422  -- Command: magit-section-show
   1423 
   1424      Show the body of the current section.
   1425 
   1426  -- Command: magit-section-hide
   1427 
   1428      Hide the body of the current section.
   1429 
   1430  -- Command: magit-section-show-headings
   1431 
   1432      Recursively show headings of children of the current section.  Only
   1433      show the headings.  Previously shown text-only bodies are hidden.
   1434 
   1435  -- Command: magit-section-show-children
   1436 
   1437      Recursively show the bodies of children of the current section.
   1438      With a prefix argument show children down to the level of the
   1439      current section, and hide deeper children.
   1440 
   1441  -- Command: magit-section-hide-children
   1442 
   1443      Recursively hide the bodies of children of the current section.
   1444 
   1445  -- Command: magit-section-toggle-children
   1446 
   1447      Toggle visibility of bodies of children of the current section.
   1448 
   1449    When a buffer is first created then some sections are shown expanded
   1450 while others are not.  This is hard coded.  When a buffer is refreshed
   1451 then the previous visibility is preserved.  The initial visibility of
   1452 certain sections can also be overwritten using the hook
   1453 ‘magit-section-set-visibility-hook’.
   1454 
   1455  -- User Option: magit-section-initial-visibility-alist
   1456 
   1457      This options can be used to override the initial visibility of
   1458      sections.  In the future it will also be used to define the
   1459      defaults, but currently a section’s default is still hardcoded.
   1460 
   1461      The value is an alist.  Each element maps a section type or lineage
   1462      to the initial visibility state for such sections.  The state has
   1463      to be one of ‘show’ or ‘hide’, or a function that returns one of
   1464      these symbols.  A function is called with the section as the only
   1465      argument.
   1466 
   1467      Use the command ‘magit-describe-section-briefly’ to determine a
   1468      section’s lineage or type.  The vector in the output is the section
   1469      lineage and the type is the first element of that vector.
   1470      Wildcards can be used, see ‘magit-section-match’.
   1471 
   1472  -- User Option: magit-section-cache-visibility
   1473 
   1474      This option controls for which sections the previous visibility
   1475      state should be restored if a section disappears and later appears
   1476      again.  The value is a boolean or a list of section types.  If t,
   1477      then the visibility of all sections is cached.  Otherwise this is
   1478      only done for sections whose type matches one of the listed types.
   1479 
   1480      This requires that the function ‘magit-section-cached-visibility’
   1481      is a member of ‘magit-section-set-visibility-hook’.
   1482 
   1483  -- Variable: magit-section-set-visibility-hook
   1484 
   1485      This hook is run when first creating a buffer and also when
   1486      refreshing an existing buffer, and is used to determine the
   1487      visibility of the section currently being inserted.
   1488 
   1489      Each function is called with one argument, the section being
   1490      inserted.  It should return ‘hide’ or ‘show’, or to leave the
   1491      visibility undefined ‘nil’.  If no function decides on the
   1492      visibility and the buffer is being refreshed, then the visibility
   1493      is preserved; or if the buffer is being created, then the hard
   1494      coded default is used.
   1495 
   1496      Usually this should only be used to set the initial visibility but
   1497      not during refreshes.  If ‘magit-insert-section--oldroot’ is
   1498      non-nil, then the buffer is being refreshed and these functions
   1499      should immediately return ‘nil’.
   1500 
   1501  -- User Option: magit-section-visibility-indicator
   1502 
   1503      This option controls whether and how to indicate that a section can
   1504      be expanded/collapsed.
   1505 
   1506      If nil, then no visibility indicators are shown.  Otherwise the
   1507      value has to have one of these two forms:
   1508 
   1509         • ‘(EXPANDABLE-BITMAP . COLLAPSIBLE-BITMAP)’
   1510 
   1511           Both values have to be variables whose values are fringe
   1512           bitmaps.  In this case every section that can be expanded or
   1513           collapsed gets an indicator in the left fringe.
   1514 
   1515           To provide extra padding around the indicator, set
   1516           ‘left-fringe-width’ in ‘magit-mode-hook’, e.g.:
   1517 
   1518                (add-hook 'magit-mode-hook (lambda ()
   1519                                             (setq left-fringe-width 20)))
   1520 
   1521         • ‘(STRING . BOOLEAN)’
   1522 
   1523           In this case STRING (usually an ellipsis) is shown at the end
   1524           of the heading of every collapsed section.  Expanded sections
   1525           get no indicator.  The cdr controls whether the appearance of
   1526           these ellipsis take section highlighting into account.  Doing
   1527           so might potentially have an impact on performance, while not
   1528           doing so is kinda ugly.
   1529 
   1530 
   1531 File: magit.info,  Node: Section Hooks,  Next: Section Types and Values,  Prev: Section Visibility,  Up: Sections
   1532 
   1533 4.2.3 Section Hooks
   1534 -------------------
   1535 
   1536 Which sections are inserted into certain buffers is controlled with
   1537 hooks.  This includes the status and the refs buffers.  For other
   1538 buffers, e.g.  log and diff buffers, this is not possible.  The command
   1539 ‘magit-describe-section’ can be used to see which hook (if any) was
   1540 responsible for inserting the section at point.
   1541 
   1542    For buffers whose sections can be customized by the user, a hook
   1543 variable called ‘magit-TYPE-sections-hook’ exists.  This hook should be
   1544 changed using ‘magit-add-section-hook’.  Avoid using ‘add-hooks’ or the
   1545 Custom interface.
   1546 
   1547    The various available section hook variables are described later in
   1548 this manual along with the appropriate "section inserter functions".
   1549 
   1550  -- Function: magit-add-section-hook hook function &optional at append
   1551           local
   1552 
   1553      Add the function FUNCTION to the value of section hook HOOK.
   1554 
   1555      Add FUNCTION at the beginning of the hook list unless optional
   1556      APPEND is non-nil, in which case FUNCTION is added at the end.  If
   1557      FUNCTION already is a member then move it to the new location.
   1558 
   1559      If optional AT is non-nil and a member of the hook list, then add
   1560      FUNCTION next to that instead.  Add before or after AT, or replace
   1561      AT with FUNCTION depending on APPEND.  If APPEND is the symbol
   1562      ‘replace’, then replace AT with FUNCTION.  For any other non-nil
   1563      value place FUNCTION right after AT.  If nil, then place FUNCTION
   1564      right before AT.  If FUNCTION already is a member of the list but
   1565      AT is not, then leave FUNCTION where ever it already is.
   1566 
   1567      If optional LOCAL is non-nil, then modify the hook’s buffer-local
   1568      value rather than its global value.  This makes the hook local by
   1569      copying the default value.  That copy is then modified.
   1570 
   1571      HOOK should be a symbol.  If HOOK is void, it is first set to nil.
   1572      HOOK’s value must not be a single hook function.  FUNCTION should
   1573      be a function that takes no arguments and inserts one or multiple
   1574      sections at point, moving point forward.  FUNCTION may choose not
   1575      to insert its section(s), when doing so would not make sense.  It
   1576      should not be abused for other side-effects.
   1577 
   1578    To remove a function from a section hook, use ‘remove-hook’.
   1579 
   1580 
   1581 File: magit.info,  Node: Section Types and Values,  Next: Section Options,  Prev: Section Hooks,  Up: Sections
   1582 
   1583 4.2.4 Section Types and Values
   1584 ------------------------------
   1585 
   1586 Each section has a type, for example ‘hunk’, ‘file’, and ‘commit’.
   1587 Instances of certain section types also have a value.  The value of a
   1588 section of type ‘file’, for example, is a file name.
   1589 
   1590    Users usually do not have to worry about a section’s type and value,
   1591 but knowing them can be handy at times.
   1592 
   1593 ‘H’     (‘magit-describe-section’)
   1594 
   1595      This command shows information about the section at point in a
   1596      separate buffer.
   1597 
   1598  -- Command: magit-describe-section-briefly
   1599 
   1600      This command shows information about the section at point in the
   1601      echo area, as ‘#<magit-section VALUE [TYPE PARENT-TYPE...]
   1602      BEGINNING-END>’.
   1603 
   1604    Many commands behave differently depending on the type of the section
   1605 at point and/or somehow consume the value of that section.  But that is
   1606 only one of the reasons why the same key may do something different,
   1607 depending on what section is current.
   1608 
   1609    Additionally for each section type a keymap *might* be defined, named
   1610 ‘magit-TYPE-section-map’.  That keymap is used as text property keymap
   1611 of all text belonging to any section of the respective type.  If such a
   1612 map does not exist for a certain type, then you can define it yourself,
   1613 and it will automatically be used.
   1614 
   1615 
   1616 File: magit.info,  Node: Section Options,  Prev: Section Types and Values,  Up: Sections
   1617 
   1618 4.2.5 Section Options
   1619 ---------------------
   1620 
   1621 This section describes options that have an effect on more than just a
   1622 certain type of sections.  As you can see there are not many of those.
   1623 
   1624  -- User Option: magit-section-show-child-count
   1625 
   1626      Whether to append the number of children to section headings.  This
   1627      only affects sections that could benefit from this information.
   1628 
   1629 
   1630 File: magit.info,  Node: Transient Commands,  Next: Transient Arguments and Buffer Variables,  Prev: Sections,  Up: Interface Concepts
   1631 
   1632 4.3 Transient Commands
   1633 ======================
   1634 
   1635 Many Magit commands are implemented as *transient* commands.  First the
   1636 user invokes a *prefix* command, which causes its *infix* arguments and
   1637 *suffix* commands to be displayed in the echo area.  The user then
   1638 optionally sets some infix arguments and finally invokes one of the
   1639 suffix commands.
   1640 
   1641    This is implemented in the library ‘transient’.  Earlier Magit
   1642 releases used the package ‘magit-popup’ and even earlier versions
   1643 library ‘magit-key-mode’.
   1644 
   1645    Transient is documented in *note (transient)Top::.
   1646 
   1647 ‘C-c C-c’     (‘magit-dispatch’)
   1648 
   1649      This transient prefix command binds most of Magit’s other prefix
   1650      commands as suffix commands and displays them in a temporary buffer
   1651      until one of them is invoked.  Invoking such a sub-prefix causes
   1652      the suffixes of that command to be bound and displayed instead of
   1653      those of ‘magit-dispatch’.
   1654 
   1655    This command is also, or especially, useful outside Magit buffers, so
   1656 you should setup a global binding:
   1657 
   1658      (global-set-key (kbd "C-x M-g") 'magit-dispatch)
   1659 
   1660 
   1661 File: magit.info,  Node: Transient Arguments and Buffer Variables,  Next: Completion Confirmation and the Selection,  Prev: Transient Commands,  Up: Interface Concepts
   1662 
   1663 4.4 Transient Arguments and Buffer Variables
   1664 ============================================
   1665 
   1666 The infix arguments of many of Magit’s transient prefix commands cease
   1667 to have an effect once the ‘git’ command that is called with those
   1668 arguments has returned.  Commands that create a commit are a good
   1669 example for this.  If the user changes the arguments, then that only
   1670 affects the next invocation of a suffix command.  If the same transient
   1671 prefix command is later invoked again, then the arguments are initially
   1672 reset to the default value.  This default value can be set for the
   1673 current Emacs session or saved permanently, see *note (transient)Saving
   1674 Values::.  It is also possible to cycle through previously used sets of
   1675 arguments using ‘M-p’ and ‘M-n’, see *note (transient)Using History::.
   1676 
   1677    However the infix arguments of many other transient commands continue
   1678 to have an effect even after the ‘git’ command that was called with
   1679 those arguments has returned.  The most important commands like this are
   1680 those that display a diff or log in a dedicated buffer.  Their arguments
   1681 obviously continue to have an effect for as long as the respective diff
   1682 or log is being displayed.  Furthermore the used arguments are stored in
   1683 buffer-local variables for future reference.
   1684 
   1685    For commands in the second group it isn’t always desirable to reset
   1686 their arguments to the global value when the transient prefix command is
   1687 invoked again.
   1688 
   1689    As mentioned above, it is possible to cycle through previously used
   1690 sets of arguments while a transient popup is visible.  That means that
   1691 we could always reset the infix arguments to the default because the set
   1692 of arguments that is active in the existing buffer is only a few ‘M-p’
   1693 away.  Magit can be configured to behave like that, but because I expect
   1694 that most users would not find that very convenient, it is not the
   1695 default.
   1696 
   1697    Also note that it is possible to change the diff and log arguments
   1698 used in the current buffer (including the status buffer, which contains
   1699 both diff and log sections) using the respective "refresh" transient
   1700 prefix commands on ‘D’ and ‘L’.  (‘d’ and ‘l’ on the other hand are
   1701 intended to change *what* diff or log is being displayed.  It is
   1702 possible to also change *how* the diff or log is being displayed at the
   1703 same time, but if you only want to do the latter, then you should use
   1704 the refresh variants.)  Because these secondary diff and log transient
   1705 prefixes are about *changing* the arguments used in the current buffer,
   1706 they *always* start out with the set of arguments that are currently in
   1707 effect in that buffer.
   1708 
   1709    Some commands are usually invoked directly even though they can also
   1710 be invoked as the suffix of a transient prefix command.  Most
   1711 prominently ‘magit-show-commit’ is usually invoked by typing ‘RET’ while
   1712 point is on a commit in a log, but it can also be invoked from the
   1713 ‘magit-diff’ transient prefix.
   1714 
   1715    When such a command is invoked directly, then it is important to
   1716 reuse the arguments as specified by the respective buffer-local values,
   1717 instead of using the default arguments.  Imagine you press ‘RET’ in a
   1718 log to display the commit at point in a different buffer and then use
   1719 ‘D’ to change how the diff is displayed in that buffer.  And then you
   1720 press ‘RET’ on another commit to show that instead and the diff
   1721 arguments are reset to the default.  Not cool; so Magit does not do that
   1722 by default.
   1723 
   1724  -- User Option: magit-prefix-use-buffer-arguments
   1725 
   1726      This option controls whether the infix arguments initially shown in
   1727      certain transient prefix commands are based on the arguments that
   1728      are currently in effect in the buffer that their suffixes update.
   1729 
   1730      The ‘magit-diff’ and ‘magit-log’ transient prefix commands are
   1731      affected by this option.
   1732 
   1733  -- User Option: magit-direct-use-buffer-arguments
   1734 
   1735      This option controls whether certain commands, when invoked
   1736      directly (i.e.  not as the suffix of a transient prefix command),
   1737      use the arguments that are currently active in the buffer that they
   1738      are about to update.  The alternative is to use the default value
   1739      for these arguments, which might change the arguments that are used
   1740      in the buffer.
   1741 
   1742 Valid values for both of the above options are:
   1743 
   1744    • ‘always’: Always use the set of arguments that is currently active
   1745      in the respective buffer, provided that buffer exists of course.
   1746 
   1747    • ‘selected’ or ‘t’: Use the set of arguments from the respective
   1748      buffer, but only if it is displayed in a window of the current
   1749      frame.  This is the default for both variables.
   1750 
   1751    • ‘current’: Use the set of arguments from the respective buffer, but
   1752      only if it is the current buffer.
   1753 
   1754    • ‘never’: Never use the set of arguments from the respective buffer.
   1755 
   1756 I am afraid it gets more complicated still:
   1757 
   1758    • The global diff and log arguments are set for each supported mode
   1759      individually.  The diff arguments for example have different values
   1760      in ‘magit-diff-mode’, ‘magit-revision-mode’,
   1761      ‘magit-merge-preview-mode’ and ‘magit-status-mode’ buffers.
   1762      Setting or saving the value for one mode does not change the value
   1763      for other modes.  The history however is shared.
   1764 
   1765    • When ‘magit-show-commit’ is invoked directly from a log buffer,
   1766      then the file filter is picked up from that buffer, not from the
   1767      revision buffer or the mode’s global diff arguments.
   1768 
   1769    • Even though they are suffixes of the diff prefix
   1770      ‘magit-show-commit’ and ‘magit-stash-show’ do not use the diff
   1771      buffer used by the diff commands, instead they use the dedicated
   1772      revision and stash buffers.
   1773 
   1774      At the time you invoke the diff prefix it is unknown to Magit which
   1775      of the suffix commands you are going to invoke.  While not certain,
   1776      more often than not users invoke one of the commands that use the
   1777      diff buffer, so the initial infix arguments are those used in that
   1778      buffer.  However if you invoke one of these commands directly, then
   1779      Magit knows that it should use the arguments from the revision
   1780      resp.  stash buffer.
   1781 
   1782    • The log prefix also features reflog commands, but these commands do
   1783      not use the log arguments.
   1784 
   1785    • If ‘magit-show-refs’ is invoked from a ‘magit-refs-mode’ buffer,
   1786      then it acts as a refresh prefix and therefore unconditionally uses
   1787      the buffer’s arguments as initial arguments.  If it is invoked
   1788      elsewhere with a prefix argument, then it acts as regular prefix
   1789      and therefore respects ‘magit-prefix-use-buffer-arguments’.  If it
   1790      is invoked elsewhere without a prefix argument, then it acts as a
   1791      direct command and therefore respects
   1792      ‘magit-direct-use-buffer-arguments’.
   1793 
   1794 
   1795 File: magit.info,  Node: Completion Confirmation and the Selection,  Next: Running Git,  Prev: Transient Arguments and Buffer Variables,  Up: Interface Concepts
   1796 
   1797 4.5 Completion, Confirmation and the Selection
   1798 ==============================================
   1799 
   1800 * Menu:
   1801 
   1802 * Action Confirmation::
   1803 * Completion and Confirmation::
   1804 * The Selection::
   1805 * The hunk-internal region::
   1806 * Support for Completion Frameworks::
   1807 * Additional Completion Options::
   1808 
   1809 
   1810 File: magit.info,  Node: Action Confirmation,  Next: Completion and Confirmation,  Up: Completion Confirmation and the Selection
   1811 
   1812 4.5.1 Action Confirmation
   1813 -------------------------
   1814 
   1815 By default many actions that could potentially lead to data loss have to
   1816 be confirmed.  This includes many very common actions, so this can
   1817 quickly become annoying.  Many of these actions can be undone and if you
   1818 have thought about how to undo certain mistakes, then it should be safe
   1819 to disable confirmation for the respective actions.
   1820 
   1821    The option ‘magit-no-confirm’ can be used to tell Magit to perform
   1822 certain actions without the user having to confirm them.  Note that
   1823 while this option can only be used to disable confirmation for a
   1824 specific set of actions, the next section explains another way of
   1825 telling Magit to ask fewer questions.
   1826 
   1827  -- User Option: magit-no-confirm
   1828 
   1829      The value of this option is a list of symbols, representing actions
   1830      that do not have to be confirmed by the user before being carried
   1831      out.
   1832 
   1833      By default many potentially dangerous commands ask the user for
   1834      confirmation.  Each of the below symbols stands for an action
   1835      which, when invoked unintentionally or without being fully aware of
   1836      the consequences, could lead to tears.  In many cases there are
   1837      several commands that perform variations of a certain action, so we
   1838      don’t use the command names but more generic symbols.
   1839 
   1840         • Applying changes:
   1841 
   1842              • ‘discard’ Discarding one or more changes (i.e.  hunks or
   1843                the complete diff for a file) loses that change,
   1844                obviously.
   1845 
   1846              • ‘reverse’ Reverting one or more changes can usually be
   1847                undone by reverting the reversion.
   1848 
   1849              • ‘stage-all-changes’, ‘unstage-all-changes’ When there are
   1850                both staged and unstaged changes, then un-/staging
   1851                everything would destroy that distinction.  Of course
   1852                that also applies when un-/staging a single change, but
   1853                then less is lost and one does that so often that having
   1854                to confirm every time would be unacceptable.
   1855 
   1856         • Files:
   1857 
   1858              • ‘delete’ When a file that isn’t yet tracked by Git is
   1859                deleted, then it is completely lost, not just the last
   1860                changes.  Very dangerous.
   1861 
   1862              • ‘trash’ Instead of deleting a file it can also be move to
   1863                the system trash.  Obviously much less dangerous than
   1864                deleting it.
   1865 
   1866                Also see option ‘magit-delete-by-moving-to-trash’.
   1867 
   1868              • ‘resurrect’ A deleted file can easily be resurrected by
   1869                "deleting" the deletion, which is done using the same
   1870                command that was used to delete the same file in the
   1871                first place.
   1872 
   1873              • ‘untrack’ Untracking a file can be undone by tracking it
   1874                again.
   1875 
   1876              • ‘rename’ Renaming a file can easily be undone.
   1877 
   1878         • Sequences:
   1879 
   1880              • ‘reset-bisect’ Aborting (known to Git as "resetting") a
   1881                bisect operation loses all information collected so far.
   1882 
   1883              • ‘abort-rebase’ Aborting a rebase throws away all already
   1884                modified commits, but it’s possible to restore those from
   1885                the reflog.
   1886 
   1887              • ‘abort-merge’ Aborting a merge throws away all conflict
   1888                resolutions which have already been carried out by the
   1889                user.
   1890 
   1891              • ‘merge-dirty’ Merging with a dirty worktree can make it
   1892                hard to go back to the state before the merge was
   1893                initiated.
   1894 
   1895         • References:
   1896 
   1897              • ‘delete-unmerged-branch’ Once a branch has been deleted,
   1898                it can only be restored using low-level recovery tools
   1899                provided by Git.  And even then the reflog is gone.  The
   1900                user always has to confirm the deletion of a branch by
   1901                accepting the default choice (or selecting another
   1902                branch), but when a branch has not been merged yet, also
   1903                make sure the user is aware of that.
   1904 
   1905              • ‘delete-pr-remote’ When deleting a branch that was
   1906                created from a pull-request and if no other branches
   1907                still exist on that remote, then ‘magit-branch-delete’
   1908                offers to delete the remote as well.  This should be safe
   1909                because it only happens if no other refs exist in the
   1910                remotes namespace, and you can recreate the remote if
   1911                necessary.
   1912 
   1913              • ‘drop-stashes’ Dropping a stash is dangerous because Git
   1914                stores stashes in the reflog.  Once a stash is removed,
   1915                there is no going back without using low-level recovery
   1916                tools provided by Git.  When a single stash is dropped,
   1917                then the user always has to confirm by accepting the
   1918                default (or selecting another).  This action only
   1919                concerns the deletion of multiple stashes at once.
   1920 
   1921         • Publishing:
   1922 
   1923              • ‘set-and-push’ When pushing to the upstream or the
   1924                push-remote and that isn’t actually configured yet, then
   1925                the user can first set the target.  If s/he confirms the
   1926                default too quickly, then s/he might end up pushing to
   1927                the wrong branch and if the remote repository is
   1928                configured to disallow fixing such mistakes, then that
   1929                can be quite embarrassing and annoying.
   1930 
   1931         • Edit published history:
   1932 
   1933           Without adding these symbols here, you will be warned before
   1934           editing commits that have already been pushed to one of the
   1935           branches listed in ‘magit-published-branches’.
   1936 
   1937              • ‘amend-published’ Affects most commands that amend to
   1938                "HEAD".
   1939 
   1940              • ‘rebase-published’ Affects commands that perform
   1941                interactive rebases.  This includes commands from the
   1942                commit transient that modify a commit other than "HEAD",
   1943                namely the various fixup and squash variants.
   1944 
   1945              • ‘edit-published’ Affects the commands
   1946                ‘magit-edit-line-commit’ and
   1947                ‘magit-diff-edit-hunk-commit’.  These two commands make
   1948                it quite easy to accidentally edit a published commit, so
   1949                you should think twice before configuring them not to ask
   1950                for confirmation.
   1951 
   1952           To disable confirmation completely, add all three symbols here
   1953           or set ‘magit-published-branches’ to ‘nil’.
   1954 
   1955         • Various:
   1956 
   1957              • ‘kill-process’ There seldom is a reason to kill a
   1958                process.
   1959 
   1960         • Global settings:
   1961 
   1962           Instead of adding all of the above symbols to the value of
   1963           this option, you can also set it to the atom ‘t’, which has
   1964           the same effect as adding all of the above symbols.  Doing
   1965           that most certainly is a bad idea, especially because other
   1966           symbols might be added in the future.  So even if you don’t
   1967           want to be asked for confirmation for any of these actions,
   1968           you are still better of adding all of the respective symbols
   1969           individually.
   1970 
   1971           When ‘magit-wip-before-change-mode’ is enabled, then the
   1972           following actions can be undone fairly easily: ‘discard’,
   1973           ‘reverse’, ‘stage-all-changes’, and ‘unstage-all-changes’.  If
   1974           and only if this mode is enabled, then ‘safe-with-wip’ has the
   1975           same effect as adding all of these symbols individually.
   1976 
   1977 
   1978 File: magit.info,  Node: Completion and Confirmation,  Next: The Selection,  Prev: Action Confirmation,  Up: Completion Confirmation and the Selection
   1979 
   1980 4.5.2 Completion and Confirmation
   1981 ---------------------------------
   1982 
   1983 Many Magit commands ask the user to select from a list of possible
   1984 things to act on, while offering the most likely choice as the default.
   1985 For many of these commands the default is the thing at point, provided
   1986 that it actually is a valid thing to act on.  For many commands that act
   1987 on a branch, the current branch serves as the default if there is no
   1988 branch at point.
   1989 
   1990    These commands combine asking for confirmation and asking for a
   1991 target to act on into a single action.  The user can confirm the default
   1992 target using ‘RET’ or abort using ‘C-g’.  This is similar to a
   1993 ‘y-or-n-p’ prompt, but the keys to confirm or abort differ.
   1994 
   1995    At the same time the user is also given the opportunity to select
   1996 another target, which is useful because for some commands and/or in some
   1997 situations you might want to select the action before selecting the
   1998 target by moving to it.
   1999 
   2000    However you might find that for some commands you always want to use
   2001 the default target, if any, or even that you want the command to act on
   2002 the default without requiring any confirmation at all.  The option
   2003 ‘magit-dwim-selection’ can be used to configure certain commands to that
   2004 effect.
   2005 
   2006    Note that when the region is active then many commands act on the
   2007 things that are selected using a mechanism based on the region, in many
   2008 cases after asking for confirmation.  This region-based mechanism is
   2009 called the "selection" and is described in detail in the next section.
   2010 When a selection exists that is valid for the invoked command, then that
   2011 command never offers to act on something else, and whether it asks for
   2012 confirmation is not controlled by this option.
   2013 
   2014    Also note that Magit asks for confirmation of certain actions that
   2015 are not coupled with completion (or the selection).  Such dialogs are
   2016 also not affected by this option and are described in the previous
   2017 section.
   2018 
   2019  -- User Option: magit-dwim-selection
   2020 
   2021    This option can be used to tell certain commands to use the thing at
   2022 point instead of asking the user to select a candidate to act on, with
   2023 or without confirmation.
   2024 
   2025    The value has the form ‘((COMMAND nil|PROMPT DEFAULT)...)’.
   2026 
   2027    • COMMAND is the command that should not prompt for a choice.  To
   2028      have an effect, the command has to use the function
   2029      ‘magit-completing-read’ or a utility function which in turn uses
   2030      that function.
   2031 
   2032    • If the command uses ‘magit-completing-read’ multiple times, then
   2033      PROMPT can be used to only affect one of these uses.  PROMPT, if
   2034      non-nil, is a regular expression that is used to match against the
   2035      PROMPT argument passed to ‘magit-completing-read’.
   2036 
   2037    • DEFAULT specifies how to use the default.  If it is ‘t’, then the
   2038      DEFAULT argument passed to ‘magit-completing-read’ is used without
   2039      confirmation.  If it is ‘ask’, then the user is given a chance to
   2040      abort.  DEFAULT can also be ‘nil’, in which case the entry has no
   2041      effect.
   2042 
   2043 
   2044 File: magit.info,  Node: The Selection,  Next: The hunk-internal region,  Prev: Completion and Confirmation,  Up: Completion Confirmation and the Selection
   2045 
   2046 4.5.3 The Selection
   2047 -------------------
   2048 
   2049 If the region is active, then many Magit commands act on the things that
   2050 are selected using a mechanism based on the region instead of one single
   2051 thing.  When the region is not active, then these commands act on the
   2052 thing at point or read a single thing to act on.  This is described in
   2053 the previous section — this section only covers how multiple things are
   2054 selected, how that is visualized, and how certain commands behave when
   2055 that is the case.
   2056 
   2057    Magit’s mechanism for selecting multiple things, or rather sections
   2058 that represent these things, is based on the Emacs region, but the area
   2059 that Magit considers to be selected is typically larger than the region
   2060 and additional restrictions apply.
   2061 
   2062    Magit makes a distinction between a region that qualifies as forming
   2063 a valid Magit selection and a region that does not.  If the region does
   2064 not qualify, then it is displayed as it is in other Emacs buffers.  If
   2065 the region does qualify as a Magit selection, then the selection is
   2066 always visualized, while the region itself is only visualized if it
   2067 begins and ends on the same line.
   2068 
   2069    For a region to qualify as a Magit selection, it must begin in the
   2070 heading of one section and end in the heading of a sibling section.
   2071 Note that if the end of the region is at the very beginning of section
   2072 heading (i.e.  at the very beginning of a line) then that section is
   2073 considered to be *inside* the selection.
   2074 
   2075    This is not consistent with how the region is normally treated in
   2076 Emacs — if the region ends at the beginning of a line, then that line is
   2077 outside the region.  Due to how Magit visualizes the selection, it
   2078 should be obvious that this difference exists.
   2079 
   2080    Not every command acts on every valid selection.  Some commands do
   2081 not even consider the location of point, others may act on the section
   2082 at point but not support acting on the selection, and even commands that
   2083 do support the selection of course only do so if it selects things that
   2084 they can act on.
   2085 
   2086    This is the main reason why the selection must include the section at
   2087 point.  Even if a selection exists, the invoked command may disregard
   2088 it, in which case it may act on the current section only.  It is much
   2089 safer to only act on the current section but not the other selected
   2090 sections than it is to act on the current section *instead* of the
   2091 selected sections.  The latter would be much more surprising and if the
   2092 current section always is part of the selection, then that cannot
   2093 happen.
   2094 
   2095  -- Variable: magit-keep-region-overlay
   2096 
   2097      This variable controls whether the region is visualized as usual
   2098      even when a valid Magit selection or a hunk-internal region exists.
   2099      See the doc-string for more information.
   2100 
   2101 
   2102 File: magit.info,  Node: The hunk-internal region,  Next: Support for Completion Frameworks,  Prev: The Selection,  Up: Completion Confirmation and the Selection
   2103 
   2104 4.5.4 The hunk-internal region
   2105 ------------------------------
   2106 
   2107 Somewhat related to the Magit selection described in the previous
   2108 section is the hunk-internal region.
   2109 
   2110    Like the selection, the hunk-internal region is based on the Emacs
   2111 region but causes that region to not be visualized as it would in other
   2112 Emacs buffers, and includes the line on which the region ends even if it
   2113 ends at the very beginning of that line.
   2114 
   2115    Unlike the selection, which is based on a region that must begin in
   2116 the heading of one section and ends in the section of a sibling section,
   2117 the hunk-internal region must begin inside the *body* of a hunk section
   2118 and end in the body of the *same* section.
   2119 
   2120    The hunk-internal region is honored by "apply" commands, which can,
   2121 among other targets, act on a hunk.  If the hunk-internal region is
   2122 active, then such commands act only on the marked part of the hunk
   2123 instead of on the complete hunk.
   2124 
   2125 
   2126 File: magit.info,  Node: Support for Completion Frameworks,  Next: Additional Completion Options,  Prev: The hunk-internal region,  Up: Completion Confirmation and the Selection
   2127 
   2128 4.5.5 Support for Completion Frameworks
   2129 ---------------------------------------
   2130 
   2131 The built-in option ‘completing-read-function’ specifies the low-level
   2132 function used by ‘completing-read’ to ask a user to select from a list
   2133 of choices.  Its default value is ‘completing-read-default’.
   2134 Alternative completion frameworks typically activate themselves by
   2135 substituting their own implementation.
   2136 
   2137    Mostly for historic reasons Magit provides a similar option named
   2138 ‘magit-completing-read-function’, which only controls the low-level
   2139 function used by ‘magit-completing-read’.  This option also makes it
   2140 possible to use a different completing mechanism for Magit than for the
   2141 rest of Emacs, but doing that is not recommend.
   2142 
   2143    You most likely don’t have to customize the magit-specific option to
   2144 use an alternative completion framework.  For example, if you enable
   2145 ‘ivy-mode’, then Magit will respect that, and if you enable ‘helm-mode’,
   2146 then you are done too.
   2147 
   2148    However if you want to use Ido, then ‘ido-mode’ won’t do the trick.
   2149 You will also have to install the ‘ido-completing-read+’ package and use
   2150 ‘magit-ido-completing-read’ as ‘magit-completing-read-function’.
   2151 
   2152  -- User Option: magit-completing-read-function
   2153 
   2154      The value of this variable is the low-level function used to
   2155      perform completion by code that uses ‘magit-completing-read’ (as
   2156      opposed to the built-in ‘completing-read’).
   2157 
   2158      The default value, ‘magit-builtin-completing-read’, is suitable for
   2159      the standard completion mechanism, ‘ivy-mode’, and ‘helm-mode’ at
   2160      least.
   2161 
   2162      The built-in ‘completing-read’ and ‘completing-read-default’ are
   2163      *not* suitable to be used here.  ‘magit-builtin-completing-read’
   2164      performs some additional work, and any function used in its place
   2165      has to do the same.
   2166 
   2167  -- Function: magit-builtin-completing-read prompt choices &optional
   2168           predicate require-match initial-input hist def
   2169 
   2170      This function performs completion using the built-in
   2171      ‘completing-read’ and does some additional magit-specific work.
   2172 
   2173  -- Function: magit-ido-completing-read prompt choices &optional
   2174           predicate require-match initial-input hist def
   2175 
   2176      This function performs completion using ‘ido-completing-read+’ from
   2177      the package by the same name (which you have to explicitly install)
   2178      and does some additional magit-specific work.
   2179 
   2180      We have to use ‘ido-completing-read+’ instead of the
   2181      ‘ido-completing-read’ that comes with Ido itself, because the
   2182      latter, while intended as a drop-in replacement, cannot serve that
   2183      purpose because it violates too many of the implicit conventions.
   2184 
   2185  -- Function: magit-completing-read prompt choices &optional predicate
   2186           require-match initial-input hist def fallback
   2187 
   2188      This is the function that Magit commands use when they need the
   2189      user to select a single thing to act on.  The arguments have the
   2190      same meaning as for ‘completing-read’, except for FALLBACK, which
   2191      is unique to this function and is described below.
   2192 
   2193      Instead of asking the user to choose from a list of possible
   2194      candidates, this function may just return the default specified by
   2195      DEF, with or without requiring user confirmation.  Whether that is
   2196      the case depends on PROMPT, ‘this-command’ and
   2197      ‘magit-dwim-selection’.  See the documentation of the latter for
   2198      more information.
   2199 
   2200      If it does read a value in the minibuffer, then this function acts
   2201      similar to ‘completing-read’, except for the following:
   2202 
   2203         • COLLECTION must be a list of choices.  A function is not
   2204           supported.
   2205 
   2206         • If REQUIRE-MATCH is ‘nil’ and the user exits without a choice,
   2207           then ‘nil’ is returned instead of an empty string.
   2208 
   2209         • If REQUIRE-MATCH is non-nil and the users exits without a
   2210           choice, an user-error is raised.
   2211 
   2212         • FALLBACK specifies a secondary default that is only used if
   2213           the primary default DEF is ‘nil’.  The secondary default is
   2214           not subject to ‘magit-dwim-selection’ — if DEF is ‘nil’ but
   2215           FALLBACK is not, then this function always asks the user to
   2216           choose a candidate, just as if both defaults were ‘nil’.
   2217 
   2218         • ": " is appended to PROMPT.
   2219 
   2220         • PROMPT is modified to end with \" (default DEF|FALLBACK): \"
   2221           provided that DEF or FALLBACK is non-nil, that neither
   2222           ‘ivy-mode’ nor ‘helm-mode’ is enabled, and that
   2223           ‘magit-completing-read-function’ is set to its default value
   2224           of ‘magit-builtin-completing-read’.
   2225 
   2226 
   2227 File: magit.info,  Node: Additional Completion Options,  Prev: Support for Completion Frameworks,  Up: Completion Confirmation and the Selection
   2228 
   2229 4.5.6 Additional Completion Options
   2230 -----------------------------------
   2231 
   2232  -- User Option: magit-list-refs-sortby
   2233 
   2234      For many commands that read a ref or refs from the user, the value
   2235      of this option can be used to control the order of the refs.  Valid
   2236      values include any key accepted by the ‘--sort’ flag of ‘git
   2237      for-each-ref’.  By default, refs are sorted alphabetically by their
   2238      full name (e.g., "refs/heads/master").
   2239 
   2240 
   2241 File: magit.info,  Node: Running Git,  Prev: Completion Confirmation and the Selection,  Up: Interface Concepts
   2242 
   2243 4.6 Running Git
   2244 ===============
   2245 
   2246 * Menu:
   2247 
   2248 * Viewing Git Output::
   2249 * Git Process Status::
   2250 * Running Git Manually::
   2251 * Git Executable::
   2252 * Global Git Arguments::
   2253 
   2254 
   2255 File: magit.info,  Node: Viewing Git Output,  Next: Git Process Status,  Up: Running Git
   2256 
   2257 4.6.1 Viewing Git Output
   2258 ------------------------
   2259 
   2260 Magit runs Git either for side-effects (e.g.  when pushing) or to get
   2261 some value (e.g.  the name of the current branch).
   2262 
   2263    When Git is run for side-effects, the process output is logged in a
   2264 per-repository log buffer, which can be consulted using the
   2265 ‘magit-process’ command when things don’t go as expected.
   2266 
   2267    The output/errors for up to ‘magit-process-log-max’ Git commands are
   2268 retained.
   2269 
   2270 ‘$’     (‘magit-process’)
   2271 
   2272      This commands displays the process buffer for the current
   2273      repository.
   2274 
   2275    Inside that buffer, the usual key bindings for navigating and showing
   2276 sections are available.  There is one additional command.
   2277 
   2278 ‘k’     (‘magit-process-kill’)
   2279 
   2280      This command kills the process represented by the section at point.
   2281 
   2282  -- Variable: magit-git-debug
   2283 
   2284      This option controls whether additional reporting of git errors is
   2285      enabled.
   2286 
   2287      Magit basically calls git for one of these two reasons: for
   2288      side-effects or to do something with its standard output.
   2289 
   2290      When git is run for side-effects then its output, including error
   2291      messages, go into the process buffer which is shown when using ‘$’.
   2292 
   2293      When git’s output is consumed in some way, then it would be too
   2294      expensive to also insert it into this buffer, but when this option
   2295      is non-nil and git returns with a non-zero exit status, then at
   2296      least its standard error is inserted into this buffer.
   2297 
   2298      This is only intended for debugging purposes.  Do not enable this
   2299      permanently, that would negatively affect performance.
   2300 
   2301  -- Variable: magit-process-extreme-logging
   2302 
   2303      This option controls whether ‘magit-process-file’ logs to the
   2304      ‘*Messages*’ buffer.
   2305 
   2306      Only intended for temporary use when you try to figure out how
   2307      Magit uses Git behind the scene.  Output that normally goes to the
   2308      magit-process buffer continues to go there.  Not all output goes to
   2309      either of these two buffers.
   2310 
   2311 
   2312 File: magit.info,  Node: Git Process Status,  Next: Running Git Manually,  Prev: Viewing Git Output,  Up: Running Git
   2313 
   2314 4.6.2 Git Process Status
   2315 ------------------------
   2316 
   2317 When a Git process is running for side-effects, Magit displays an
   2318 indicator in the mode line, using the ‘magit-mode-line-process’ face.
   2319 
   2320    If the Git process exits successfully, the process indicator is
   2321 removed from the mode line immediately.
   2322 
   2323    In the case of a Git error, the process indicator is not removed, but
   2324 is instead highlighted with the ‘magit-mode-line-process-error’ face,
   2325 and the error details from the process buffer are provided as a tooltip
   2326 for mouse users.  This error indicator persists in the mode line until
   2327 the next magit buffer refresh.
   2328 
   2329    If you do not wish process errors to be indicated in the mode line,
   2330 customize the ‘magit-process-display-mode-line-error’ user option.
   2331 
   2332    Process errors are additionally indicated at the top of the status
   2333 buffer.
   2334 
   2335 
   2336 File: magit.info,  Node: Running Git Manually,  Next: Git Executable,  Prev: Git Process Status,  Up: Running Git
   2337 
   2338 4.6.3 Running Git Manually
   2339 --------------------------
   2340 
   2341 While Magit provides many Emacs commands to interact with Git, it does
   2342 not cover everything.  In those cases your existing Git knowledge will
   2343 come in handy.  Magit provides some commands for running arbitrary Git
   2344 commands by typing them into the minibuffer, instead of having to switch
   2345 to a shell.
   2346 
   2347 ‘!’     (‘magit-run’)
   2348 
   2349      This transient prefix command binds the following suffix commands
   2350      and displays them in a temporary buffer until a suffix is invoked.
   2351 
   2352 ‘! !’     (‘magit-git-command-topdir’)
   2353 
   2354      This command reads a command from the user and executes it in the
   2355      top-level directory of the current working tree.
   2356 
   2357      The string "git " is used as initial input when prompting the user
   2358      for the command.  It can be removed to run another command.
   2359 
   2360 ‘:’     (‘magit-git-command’)
   2361 ‘! p’     (‘magit-git-command’)
   2362 
   2363      This command reads a command from the user and executes it in
   2364      ‘default-directory’.  With a prefix argument the command is
   2365      executed in the top-level directory of the current working tree
   2366      instead.
   2367 
   2368      The string "git " is used as initial input when prompting the user
   2369      for the command.  It can be removed to run another command.
   2370 
   2371 ‘! s’     (‘magit-shell-command-topdir’)
   2372 
   2373      This command reads a command from the user and executes it in the
   2374      top-level directory of the current working tree.
   2375 
   2376 ‘! S’     (‘magit-shell-command’)
   2377 
   2378      This command reads a command from the user and executes it in
   2379      ‘default-directory’.  With a prefix argument the command is
   2380      executed in the top-level directory of the current working tree
   2381      instead.
   2382 
   2383  -- User Option: magit-shell-command-verbose-prompt
   2384 
   2385      Whether the prompt, used by the above commands when reading a shell
   2386      command, shows the directory in which it will be run.
   2387 
   2388    These suffix commands start external gui tools.
   2389 
   2390 ‘! k’     (‘magit-run-gitk’)
   2391 
   2392      This command runs ‘gitk’ in the current repository.
   2393 
   2394 ‘! a’     (‘magit-run-gitk-all’)
   2395 
   2396      This command runs ‘gitk --all’ in the current repository.
   2397 
   2398 ‘! b’     (‘magit-run-gitk-branches’)
   2399 
   2400      This command runs ‘gitk --branches’ in the current repository.
   2401 
   2402 ‘! g’     (‘magit-run-git-gui’)
   2403 
   2404      This command runs ‘git gui’ in the current repository.
   2405 
   2406 
   2407 File: magit.info,  Node: Git Executable,  Next: Global Git Arguments,  Prev: Running Git Manually,  Up: Running Git
   2408 
   2409 4.6.4 Git Executable
   2410 --------------------
   2411 
   2412 When Magit calls Git, then it may do so using the absolute path to the
   2413 ‘git’ executable, or using just its name.
   2414 
   2415    When running ‘git’ locally and the ‘system-type’ is ‘windows-nt’ (any
   2416 Windows version) or ‘darwin’ (macOS) then ‘magit-git-executable’ is set
   2417 to an absolute path when Magit is loaded.
   2418 
   2419    On Windows it is necessary to use an absolute path because Git comes
   2420 with several wrapper scripts for the actual ‘git’ binary, which are also
   2421 placed on ‘$PATH’, and using one of these wrappers instead of the binary
   2422 would degrade performance horribly.  For some macOS users using just the
   2423 name of the executable also performs horribly, so we avoid doing that on
   2424 that platform as well.  On other platforms, using just the name seems to
   2425 work just fine.
   2426 
   2427    Using an absolute path when running ‘git’ on a remote machine over
   2428 Tramp, would be problematic to use an absolute path that is suitable on
   2429 the local machine, so a separate option is used to control the name or
   2430 path that is used on remote machines.
   2431 
   2432  -- User Option: magit-git-executable
   2433 
   2434      The ‘git’ executable used by Magit on the local host.  This should
   2435      be either the absolute path to the executable, or the string "git"
   2436      to let Emacs find the executable itself, using the standard
   2437      mechanism for doing such things.
   2438 
   2439  -- User Option: magit-remote-git-executable
   2440 
   2441      The ‘git’ executable used by Magit on remote machines over Tramp.
   2442      Normally this should be just the string "git".  Consider
   2443      customizing ‘tramp-remote-path’ instead of this option.
   2444 
   2445    If Emacs is unable to find the correct executable, then you can work
   2446 around that by explicitly setting the value of one of these two options.
   2447 Doing that should be considered a kludge; it is better to make sure that
   2448 the order in ‘exec-path’ or ‘tramp-remote-path’ is correct.
   2449 
   2450    Note that ‘exec-path’ is set based on the value of the ‘PATH’
   2451 environment variable that is in effect when Emacs is started.  If you
   2452 set ‘PATH’ in your shell’s init files, then that only has an effect on
   2453 Emacs if you start it from that shell (because the environment of a
   2454 process is only passed to its child processes, not to arbitrary other
   2455 processes).  If that is not how you start Emacs, then the
   2456 ‘exec-path-from-shell’ package can help; though honestly I consider that
   2457 a kludge too.
   2458 
   2459    The command ‘magit-debug-git-executable’ can be useful to find out
   2460 where Emacs is searching for ‘git’.
   2461 
   2462 ‘M-x magit-debug-git-executable’     (‘magit-debug-git-executable’)
   2463 
   2464      This command displays a buffer with information about
   2465      ‘magit-git-executable’ and ‘magit-remote-git-executable’.
   2466 
   2467 ‘M-x magit-version’     (‘magit-version’)
   2468 
   2469      This command shows the currently used versions of Magit, Git, and
   2470      Emacs in the echo area.  Non-interactively this just returns the
   2471      Magit version.
   2472 
   2473 
   2474 File: magit.info,  Node: Global Git Arguments,  Prev: Git Executable,  Up: Running Git
   2475 
   2476 4.6.5 Global Git Arguments
   2477 --------------------------
   2478 
   2479  -- User Option: magit-git-global-arguments
   2480 
   2481      The arguments set here are used every time the git executable is
   2482      run as a subprocess.  They are placed right after the executable
   2483      itself and before the git command - as in ‘git HERE... COMMAND
   2484      REST’.  For valid arguments see *note (gitman)git::.
   2485 
   2486      Be careful what you add here, especially if you are using Tramp to
   2487      connect to servers with ancient Git versions.  Never remove
   2488      anything that is part of the default value, unless you really know
   2489      what you are doing.  And think very hard before adding something;
   2490      it will be used every time Magit runs Git for any purpose.
   2491 
   2492 
   2493 File: magit.info,  Node: Inspecting,  Next: Manipulating,  Prev: Interface Concepts,  Up: Top
   2494 
   2495 5 Inspecting
   2496 ************
   2497 
   2498 The functionality provided by Magit can be roughly divided into three
   2499 groups: inspecting existing data, manipulating existing data or adding
   2500 new data, and transferring data.  Of course that is a rather crude
   2501 distinction that often falls short, but it’s more useful than no
   2502 distinction at all.  This section is concerned with inspecting data, the
   2503 next two with manipulating and transferring it.  Then follows a section
   2504 about miscellaneous functionality, which cannot easily be fit into this
   2505 distinction.
   2506 
   2507    Of course other distinctions make sense too, e.g.  Git’s distinction
   2508 between porcelain and plumbing commands, which for the most part is
   2509 equivalent to Emacs’ distinction between interactive commands and
   2510 non-interactive functions.  All of the sections mentioned before are
   2511 mainly concerned with the porcelain – Magit’s plumbing layer is
   2512 described later.
   2513 
   2514 * Menu:
   2515 
   2516 * Status Buffer::
   2517 * Repository List::
   2518 * Logging::
   2519 * Diffing::
   2520 * Ediffing::
   2521 * References Buffer::
   2522 * Bisecting::
   2523 * Visiting Files and Blobs::
   2524 * Blaming::
   2525 
   2526 
   2527 File: magit.info,  Node: Status Buffer,  Next: Repository List,  Up: Inspecting
   2528 
   2529 5.1 Status Buffer
   2530 =================
   2531 
   2532 While other Magit buffers contain e.g.  one particular diff or one
   2533 particular log, the status buffer contains the diffs for staged and
   2534 unstaged changes, logs for unpushed and unpulled commits, lists of
   2535 stashes and untracked files, and information related to the current
   2536 branch.
   2537 
   2538    During certain incomplete operations – for example when a merge
   2539 resulted in a conflict – additional information is displayed that helps
   2540 proceeding with or aborting the operation.
   2541 
   2542    The command ‘magit-status’ displays the status buffer belonging to
   2543 the current repository in another window.  This command is used so often
   2544 that it should be bound globally.  We recommend using ‘C-x g’:
   2545 
   2546      (global-set-key (kbd "C-x g") 'magit-status)
   2547 
   2548 ‘C-x g’     (‘magit-status’)
   2549 
   2550      When invoked from within an existing Git repository, then this
   2551      command shows the status of that repository in a buffer.
   2552 
   2553      If the current directory isn’t located within a Git repository,
   2554      then this command prompts for an existing repository or an
   2555      arbitrary directory, depending on the option
   2556      ‘magit-repository-directories’, and the status for the selected
   2557      repository is shown instead.
   2558 
   2559         • If that option specifies any existing repositories, then the
   2560           user is asked to select one of them.
   2561 
   2562         • Otherwise the user is asked to select an arbitrary directory
   2563           using regular file-name completion.  If the selected directory
   2564           is the top-level directory of an existing working tree, then
   2565           the status buffer for that is shown.
   2566 
   2567         • Otherwise the user is offered to initialize the selected
   2568           directory as a new repository.  After creating the repository
   2569           its status buffer is shown.
   2570 
   2571      These fallback behaviors can also be forced using one or more
   2572      prefix arguments:
   2573 
   2574         • With two prefix arguments (or more precisely a numeric prefix
   2575           value of 16 or greater) an arbitrary directory is read, which
   2576           is then acted on as described above.  The same could be
   2577           accomplished using the command ‘magit-init’.
   2578 
   2579         • With a single prefix argument an existing repository is read
   2580           from the user, or if no repository can be found based on the
   2581           value of ‘magit-repository-directories’, then the behavior is
   2582           the same as with two prefix arguments.
   2583 
   2584  -- User Option: magit-repository-directories
   2585 
   2586      List of directories that are Git repositories or contain Git
   2587      repositories.
   2588 
   2589      Each element has the form ‘(DIRECTORY . DEPTH)’.  DIRECTORY has to
   2590      be a directory or a directory file-name, a string.  DEPTH, an
   2591      integer, specifies the maximum depth to look for Git repositories.
   2592      If it is 0, then only add DIRECTORY itself.
   2593 
   2594      This option controls which repositories are being listed by
   2595      ‘magit-list-repositories’.  It also affects ‘magit-status’ (which
   2596      see) in potentially surprising ways (see above).
   2597 
   2598  -- Command: magit-status-quick
   2599 
   2600      This command is an alternative to ‘magit-status’ that usually
   2601      avoids refreshing the status buffer.
   2602 
   2603      If the status buffer of the current Git repository exists but isn’t
   2604      being displayed in the selected frame, then it is displayed without
   2605      being refreshed.
   2606 
   2607      If the status buffer is being displayed in the selected frame, then
   2608      this command refreshes it.
   2609 
   2610      Prefix arguments have the same meaning as for ‘magit-status’, and
   2611      additionally cause the buffer to be refresh.
   2612 
   2613      To use this command add this to your init file:
   2614 
   2615           (global-set-key (kbd "C-x g") 'magit-status-quick).
   2616 
   2617      If you do that and then for once want to redisplay the buffer and
   2618      also immediately refresh it, then type ‘C-x g’ followed by ‘g’.
   2619 
   2620      A possible alternative command is
   2621      ‘magit-display-repository-buffer’.  It supports displaying any
   2622      existing Magit buffer that belongs to the current repository; not
   2623      just the status buffer.
   2624 
   2625  -- Command: ido-enter-magit-status
   2626 
   2627      From an Ido prompt used to open a file, instead drop into
   2628      ‘magit-status’.  This is similar to ‘ido-magic-delete-char’, which,
   2629      despite its name, usually causes a Dired buffer to be created.
   2630 
   2631      To make this command available, use something like:
   2632 
   2633           (add-hook 'ido-setup-hook
   2634                     (lambda ()
   2635                       (define-key ido-completion-map
   2636                         (kbd \"C-x g\") 'ido-enter-magit-status)))
   2637 
   2638      Starting with Emacs 25.1 the Ido keymaps are defined just once
   2639      instead of every time Ido is invoked, so now you can modify it like
   2640      pretty much every other keymap:
   2641 
   2642           (define-key ido-common-completion-map
   2643             (kbd \"C-x g\") 'ido-enter-magit-status)
   2644 
   2645 * Menu:
   2646 
   2647 * Status Sections::
   2648 * Status Header Sections::
   2649 * Status Module Sections::
   2650 * Status Options::
   2651 
   2652 
   2653 File: magit.info,  Node: Status Sections,  Next: Status Header Sections,  Up: Status Buffer
   2654 
   2655 5.1.1 Status Sections
   2656 ---------------------
   2657 
   2658 The contents of status buffers is controlled using the hook
   2659 ‘magit-status-sections-hook’.  See *note Section Hooks:: to learn about
   2660 such hooks and how to customize them.
   2661 
   2662  -- User Option: magit-status-sections-hook
   2663 
   2664      Hook run to insert sections into a status buffer.
   2665 
   2666    The first function on that hook by default is
   2667 ‘magit-insert-status-headers’; it is described in the next section.  By
   2668 default the following functions are also members of that hook:
   2669 
   2670  -- Function: magit-insert-merge-log
   2671 
   2672      Insert section for the on-going merge.  Display the heads that are
   2673      being merged.  If no merge is in progress, do nothing.
   2674 
   2675  -- Function: magit-insert-rebase-sequence
   2676 
   2677      Insert section for the on-going rebase sequence.  If no such
   2678      sequence is in progress, do nothing.
   2679 
   2680  -- Function: magit-insert-am-sequence
   2681 
   2682      Insert section for the on-going patch applying sequence.  If no
   2683      such sequence is in progress, do nothing.
   2684 
   2685  -- Function: magit-insert-sequencer-sequence
   2686 
   2687      Insert section for the on-going cherry-pick or revert sequence.  If
   2688      no such sequence is in progress, do nothing.
   2689 
   2690  -- Function: magit-insert-bisect-output
   2691 
   2692      While bisecting, insert section with output from ‘git bisect’.
   2693 
   2694  -- Function: magit-insert-bisect-rest
   2695 
   2696      While bisecting, insert section visualizing the bisect state.
   2697 
   2698  -- Function: magit-insert-bisect-log
   2699 
   2700      While bisecting, insert section logging bisect progress.
   2701 
   2702  -- Function: magit-insert-untracked-files
   2703 
   2704      Maybe insert a list or tree of untracked files.
   2705 
   2706      Do so depending on the value of ‘status.showUntrackedFiles’.  Note
   2707      that even if the value is ‘all’, Magit still initially only shows
   2708      directories.  But the directory sections can then be expanded using
   2709      ‘TAB’.
   2710 
   2711  -- Function: magit-insert-unstaged-changes
   2712 
   2713      Insert section showing unstaged changes.
   2714 
   2715  -- Function: magit-insert-staged-changes
   2716 
   2717      Insert section showing staged changes.
   2718 
   2719  -- Function: magit-insert-stashes &optional ref heading
   2720 
   2721      Insert the ‘stashes’ section showing reflog for "refs/stash".  If
   2722      optional REF is non-nil show reflog for that instead.  If optional
   2723      HEADING is non-nil use that as section heading instead of
   2724      "Stashes:".
   2725 
   2726  -- Function: magit-insert-unpulled-from-upstream
   2727 
   2728      Insert section showing commits that haven’t been pulled from the
   2729      upstream branch yet.
   2730 
   2731  -- Function: magit-insert-unpulled-from-pushremote
   2732 
   2733      Insert section showing commits that haven’t been pulled from the
   2734      push-remote branch yet.
   2735 
   2736  -- Function: magit-insert-unpushed-to-upstream
   2737 
   2738      Insert section showing commits that haven’t been pushed to the
   2739      upstream yet.
   2740 
   2741  -- Function: magit-insert-unpushed-to-pushremote
   2742 
   2743      Insert section showing commits that haven’t been pushed to the
   2744      push-remote yet.
   2745 
   2746    The following functions can also be added to the above hook:
   2747 
   2748  -- Function: magit-insert-tracked-files
   2749 
   2750      Insert a tree of tracked files.
   2751 
   2752  -- Function: magit-insert-ignored-files
   2753 
   2754      Insert a tree of ignored files.  Its possible to limit the logs in
   2755      the current buffer to a certain directory using ‘D = f <DIRECTORY>
   2756      RET g’.  If you do that, then that that also affects this command.
   2757 
   2758      The log filter can be used to limit to multiple files.  In that
   2759      case this function only respects the first of the files and only if
   2760      it is a directory.
   2761 
   2762  -- Function: magit-insert-skip-worktree-files
   2763 
   2764      Insert a tree of skip-worktree files.  If the first element of
   2765      ‘magit-buffer-diff-files’ is a directory, then limit the list to
   2766      files below that.  The value of that variable can be set using ‘D
   2767      -- DIRECTORY RET g’.
   2768 
   2769  -- Function: magit-insert-assumed-unchanged-files
   2770 
   2771      Insert a tree of files that are assumed to be unchanged.  If the
   2772      first element of ‘magit-buffer-diff-files’ is a directory, then
   2773      limit the list to files below that.  The value of that variable can
   2774      be set using ‘D -- DIRECTORY RET g’.
   2775 
   2776  -- Function: magit-insert-unpulled-or-recent-commits
   2777 
   2778      Insert section showing unpulled or recent commits.  If an upstream
   2779      is configured for the current branch and it is ahead of the current
   2780      branch, then show the missing commits.  Otherwise, show the last
   2781      ‘magit-log-section-commit-count’ commits.
   2782 
   2783  -- Function: magit-insert-recent-commits
   2784 
   2785      Insert section showing the last ‘magit-log-section-commit-count’
   2786      commits.
   2787 
   2788  -- User Option: magit-log-section-commit-count
   2789 
   2790      How many recent commits ‘magit-insert-recent-commits’ and
   2791      ‘magit-insert-unpulled-or-recent-commits’ (provided there are no
   2792      unpulled commits) show.
   2793 
   2794  -- Function: magit-insert-unpulled-cherries
   2795 
   2796      Insert section showing unpulled commits.  Like
   2797      ‘magit-insert-unpulled-commits’ but prefix each commit that has not
   2798      been applied yet (i.e.  a commit with a patch-id not shared with
   2799      any local commit) with "+", and all others with "-".
   2800 
   2801  -- Function: magit-insert-unpushed-cherries
   2802 
   2803      Insert section showing unpushed commits.  Like
   2804      ‘magit-insert-unpushed-commits’ but prefix each commit which has
   2805      not been applied to upstream yet (i.e.  a commit with a patch-id
   2806      not shared with any upstream commit) with "+" and all others with
   2807      "-".
   2808 
   2809    See *note References Buffer:: for some more section inserters, which
   2810 could be used here.
   2811 
   2812 
   2813 File: magit.info,  Node: Status Header Sections,  Next: Status Module Sections,  Prev: Status Sections,  Up: Status Buffer
   2814 
   2815 5.1.2 Status Header Sections
   2816 ----------------------------
   2817 
   2818 The contents of status buffers is controlled using the hook
   2819 ‘magit-status-sections-hook’ (see *note Status Sections::).
   2820 
   2821    By default ‘magit-insert-status-headers’ is the first member of that
   2822 hook variable.
   2823 
   2824  -- Function: magit-insert-status-headers
   2825 
   2826      Insert headers sections appropriate for ‘magit-status-mode’
   2827      buffers.  The sections are inserted by running the functions on the
   2828      hook ‘magit-status-headers-hook’.
   2829 
   2830  -- User Option: magit-status-headers-hook
   2831 
   2832      Hook run to insert headers sections into the status buffer.
   2833 
   2834      This hook is run by ‘magit-insert-status-headers’, which in turn
   2835      has to be a member of ‘magit-status-sections-hook’ to be used at
   2836      all.
   2837 
   2838    By default the following functions are members of the above hook:
   2839 
   2840  -- Function: magit-insert-error-header
   2841 
   2842      Insert a header line showing the message about the Git error that
   2843      just occurred.
   2844 
   2845      This function is only aware of the last error that occur when Git
   2846      was run for side-effects.  If, for example, an error occurs while
   2847      generating a diff, then that error won’t be inserted.  Refreshing
   2848      the status buffer causes this section to disappear again.
   2849 
   2850  -- Function: magit-insert-diff-filter-header
   2851 
   2852      Insert a header line showing the effective diff filters.
   2853 
   2854  -- Function: magit-insert-head-branch-header
   2855 
   2856      Insert a header line about the current branch or detached ‘HEAD’.
   2857 
   2858  -- Function: magit-insert-upstream-branch-header
   2859 
   2860      Insert a header line about the branch that is usually pulled into
   2861      the current branch.
   2862 
   2863  -- Function: magit-insert-push-branch-header
   2864 
   2865      Insert a header line about the branch that the current branch is
   2866      usually pushed to.
   2867 
   2868  -- Function: magit-insert-tags-header
   2869 
   2870      Insert a header line about the current and/or next tag, along with
   2871      the number of commits between the tag and ‘HEAD’.
   2872 
   2873    The following functions can also be added to the above hook:
   2874 
   2875  -- Function: magit-insert-repo-header
   2876 
   2877      Insert a header line showing the path to the repository top-level.
   2878 
   2879  -- Function: magit-insert-remote-header
   2880 
   2881      Insert a header line about the remote of the current branch.
   2882 
   2883      If no remote is configured for the current branch, then fall back
   2884      showing the "origin" remote, or if that does not exist the first
   2885      remote in alphabetic order.
   2886 
   2887  -- Function: magit-insert-user-header
   2888 
   2889      Insert a header line about the current user.
   2890 
   2891 
   2892 File: magit.info,  Node: Status Module Sections,  Next: Status Options,  Prev: Status Header Sections,  Up: Status Buffer
   2893 
   2894 5.1.3 Status Module Sections
   2895 ----------------------------
   2896 
   2897 The contents of status buffers is controlled using the hook
   2898 ‘magit-status-sections-hook’ (see *note Status Sections::).
   2899 
   2900    By default ‘magit-insert-modules’ is _not_ a member of that hook
   2901 variable.
   2902 
   2903  -- Function: magit-insert-modules
   2904 
   2905      Insert submodule sections.
   2906 
   2907      Hook ‘magit-module-sections-hook’ controls which module sections
   2908      are inserted, and option ‘magit-module-sections-nested’ controls
   2909      whether they are wrapped in an additional section.
   2910 
   2911  -- User Option: magit-module-sections-hook
   2912 
   2913      Hook run by ‘magit-insert-modules’.
   2914 
   2915  -- User Option: magit-module-sections-nested
   2916 
   2917      This option controls whether ‘magit-insert-modules’ wraps inserted
   2918      sections in an additional section.
   2919 
   2920      If this is non-nil, then only a single top-level section is
   2921      inserted.  If it is nil, then all sections listed in
   2922      ‘magit-module-sections-hook’ become top-level sections.
   2923 
   2924  -- Function: magit-insert-modules-overview
   2925 
   2926      Insert sections for all submodules.  For each section insert the
   2927      path, the branch, and the output of ‘git describe --tags’, or,
   2928      failing that, the abbreviated HEAD commit hash.
   2929 
   2930      Press ‘RET’ on such a submodule section to show its own status
   2931      buffer.  Press ‘RET’ on the "Modules" section to display a list of
   2932      submodules in a separate buffer.  This shows additional information
   2933      not displayed in the super-repository’s status buffer.
   2934 
   2935  -- Function: magit-insert-modules-unpulled-from-upstream
   2936 
   2937      Insert sections for modules that haven’t been pulled from the
   2938      upstream yet.  These sections can be expanded to show the
   2939      respective commits.
   2940 
   2941  -- Function: magit-insert-modules-unpulled-from-pushremote
   2942 
   2943      Insert sections for modules that haven’t been pulled from the
   2944      push-remote yet.  These sections can be expanded to show the
   2945      respective commits.
   2946 
   2947  -- Function: magit-insert-modules-unpushed-to-upstream
   2948 
   2949      Insert sections for modules that haven’t been pushed to the
   2950      upstream yet.  These sections can be expanded to show the
   2951      respective commits.
   2952 
   2953  -- Function: magit-insert-modules-unpushed-to-pushremote
   2954 
   2955      Insert sections for modules that haven’t been pushed to the
   2956      push-remote yet.  These sections can be expanded to show the
   2957      respective commits.
   2958 
   2959 
   2960 File: magit.info,  Node: Status Options,  Prev: Status Module Sections,  Up: Status Buffer
   2961 
   2962 5.1.4 Status Options
   2963 --------------------
   2964 
   2965  -- User Option: magit-status-refresh-hook
   2966 
   2967      Hook run after a status buffer has been refreshed.
   2968 
   2969  -- User Option: magit-status-margin
   2970 
   2971      This option specifies whether the margin is initially shown in
   2972      Magit-Status mode buffers and how it is formatted.
   2973 
   2974      The value has the form ‘(INIT STYLE WIDTH AUTHOR AUTHOR-WIDTH)’.
   2975 
   2976         • If INIT is non-nil, then the margin is shown initially.
   2977 
   2978         • STYLE controls how to format the author or committer date.  It
   2979           can be one of ‘age’ (to show the age of the commit),
   2980           ‘age-abbreviated’ (to abbreviate the time unit to a
   2981           character), or a string (suitable for ‘format-time-string’) to
   2982           show the actual date.  Option
   2983           ‘magit-log-margin-show-committer-date’ controls which date is
   2984           being displayed.
   2985 
   2986         • WIDTH controls the width of the margin.  This exists for
   2987           forward compatibility and currently the value should not be
   2988           changed.
   2989 
   2990         • AUTHOR controls whether the name of the author is also shown
   2991           by default.
   2992 
   2993         • AUTHOR-WIDTH has to be an integer.  When the name of the
   2994           author is shown, then this specifies how much space is used to
   2995           do so.
   2996 
   2997    Also see the proceeding section for more options concerning status
   2998 buffers.
   2999 
   3000 
   3001 File: magit.info,  Node: Repository List,  Next: Logging,  Prev: Status Buffer,  Up: Inspecting
   3002 
   3003 5.2 Repository List
   3004 ===================
   3005 
   3006  -- Command: magit-list-repositories
   3007 
   3008      This command displays a list of repositories in a separate buffer.
   3009 
   3010      The options ‘magit-repository-directories’ and
   3011      ‘magit-repository-directories-depth’ control which repositories are
   3012      displayed.
   3013 
   3014  -- User Option: magit-repolist-columns
   3015 
   3016      This option controls what columns are displayed by the command
   3017      ‘magit-list-repositories’ and how they are displayed.
   3018 
   3019      Each element has the form ‘(HEADER WIDTH FORMAT PROPS)’.
   3020 
   3021      HEADER is the string displayed in the header.  WIDTH is the width
   3022      of the column.  FORMAT is a function that is called with one
   3023      argument, the repository identification (usually its basename), and
   3024      with ‘default-directory’ bound to the toplevel of its working tree.
   3025      It has to return a string to be inserted or nil.  PROPS is an alist
   3026      that supports the keys ‘:right-align’ and ‘:pad-right’.
   3027 
   3028      You may wish to display a range of numeric columns using just one
   3029      character per column and without any padding between columns, in
   3030      which case you should use an appropriate HEADER, set WIDTH to 1,
   3031      and set ‘:pad-right’ to 0.  ‘+’ is substituted for numbers higher
   3032      than 9.
   3033 
   3034    The following functions can be added to the above option:
   3035 
   3036  -- Function: magit-repolist-column-ident
   3037 
   3038      This function inserts the identification of the repository.
   3039      Usually this is just its basename.
   3040 
   3041  -- Function: magit-repolist-column-path
   3042 
   3043      This function inserts the absolute path of the repository.
   3044 
   3045  -- Function: magit-repolist-column-version
   3046 
   3047      This function inserts a description of the repository’s ‘HEAD’
   3048      revision.
   3049 
   3050  -- Function: magit-repolist-column-branch
   3051 
   3052      This function inserts the name of the current branch.
   3053 
   3054  -- Function: magit-repolist-column-upstream
   3055 
   3056      This function inserts the name of the upstream branch of the
   3057      current branch.
   3058 
   3059  -- Function: magit-repolist-column-branches
   3060 
   3061      This function inserts the number of branches.
   3062 
   3063  -- Function: magit-repolist-column-stashes
   3064 
   3065      This function inserts the number of stashes.
   3066 
   3067  -- Function: magit-repolist-column-flag
   3068 
   3069      This function inserts a flag as specified by
   3070      ‘magit-repolist-column-flag-alist’.
   3071 
   3072      By default this indicates whether there are uncommitted changes.
   3073 
   3074         • ‘N’ if there is at least one untracked file.
   3075 
   3076         • ‘U’ if there is at least one unstaged file.
   3077 
   3078         • ‘S’ if there is at least one staged file.
   3079 
   3080      Only the first one of these that applies is shown.
   3081 
   3082  -- Function: magit-repolist-column-unpulled-from-upstream
   3083 
   3084      This function inserts the number of upstream commits not in the
   3085      current branch.
   3086 
   3087  -- Function: magit-repolist-column-unpulled-from-pushremote
   3088 
   3089      This function inserts the number of commits in the push branch but
   3090      not the current branch.
   3091 
   3092  -- Function: magit-repolist-column-unpushed-to-upstream
   3093 
   3094      This function inserts the number of commits in the current branch
   3095      but not its upstream.
   3096 
   3097  -- Function: magit-repolist-column-unpushed-to-pushremote
   3098 
   3099      This function inserts the number of commits in the current branch
   3100      but not its push branch.
   3101 
   3102 
   3103 File: magit.info,  Node: Logging,  Next: Diffing,  Prev: Repository List,  Up: Inspecting
   3104 
   3105 5.3 Logging
   3106 ===========
   3107 
   3108 The status buffer contains logs for the unpushed and unpulled commits,
   3109 but that obviously isn’t enough.  The transient prefix command
   3110 ‘magit-log’, on ‘l’, features several suffix commands, which show a
   3111 specific log in a separate log buffer.
   3112 
   3113    Like other transient prefix commands, ‘magit-log’ also features
   3114 several infix arguments that can be changed before invoking one of the
   3115 suffix commands.  However, in the case of the log transient, these
   3116 arguments may be taken from those currently in use in the current
   3117 repository’s log buffer, depending on the value of
   3118 ‘magit-prefix-use-buffer-arguments’ (see *note Transient Arguments and
   3119 Buffer Variables::).
   3120 
   3121    For information about the various arguments, see *note
   3122 (gitman)git-log::.
   3123 
   3124    The switch ‘++order=VALUE’ is converted to one of
   3125 ‘--author-date-order’, ‘--date-order’, or ‘--topo-order’ before being
   3126 passed to ‘git log’.
   3127 
   3128    The log transient also features several reflog commands.  See *note
   3129 Reflog::.
   3130 
   3131 ‘l’     (‘magit-log’)
   3132 
   3133      This transient prefix command binds the following suffix commands
   3134      along with the appropriate infix arguments and displays them in a
   3135      temporary buffer until a suffix is invoked.
   3136 
   3137 ‘l l’     (‘magit-log-current’)
   3138 
   3139      Show log for the current branch.  When ‘HEAD’ is detached or with a
   3140      prefix argument, show log for one or more revs read from the
   3141      minibuffer.
   3142 
   3143 ‘l o’     (‘magit-log-other’)
   3144 
   3145      Show log for one or more revs read from the minibuffer.  The user
   3146      can input any revision or revisions separated by a space, or even
   3147      ranges, but only branches, tags, and a representation of the commit
   3148      at point are available as completion candidates.
   3149 
   3150 ‘l h’     (‘magit-log-head’)
   3151 
   3152      Show log for ‘HEAD’.
   3153 
   3154 ‘l L’     (‘magit-log-branches’)
   3155 
   3156      Show log for all local branches and ‘HEAD’.
   3157 
   3158 ‘l b’     (‘magit-log-all-branches’)
   3159 
   3160      Show log for all local and remote branches and ‘HEAD’.
   3161 
   3162 ‘l a’     (‘magit-log-all’)
   3163 
   3164      Show log for all references and ‘HEAD’.
   3165 
   3166    Two additional commands that show the log for the file or blob that
   3167 is being visited in the current buffer exists, see *note Commands for
   3168 Buffers Visiting Files::.  The command ‘magit-cherry’ also shows a log,
   3169 see *note Cherries::.
   3170 
   3171 * Menu:
   3172 
   3173 * Refreshing Logs::
   3174 * Log Buffer::
   3175 * Log Margin::
   3176 * Select from Log::
   3177 * Reflog::
   3178 * Cherries::
   3179 
   3180 
   3181 File: magit.info,  Node: Refreshing Logs,  Next: Log Buffer,  Up: Logging
   3182 
   3183 5.3.1 Refreshing Logs
   3184 ---------------------
   3185 
   3186 The transient prefix command ‘magit-log-refresh’, on ‘L’, can be used to
   3187 change the log arguments used in the current buffer, without changing
   3188 which log is shown.  This works in dedicated log buffers, but also in
   3189 the status buffer.
   3190 
   3191 ‘L’     (‘magit-log-refresh’)
   3192 
   3193      This transient prefix command binds the following suffix commands
   3194      along with the appropriate infix arguments and displays them in a
   3195      temporary buffer until a suffix is invoked.
   3196 
   3197 ‘L g’     (‘magit-log-refresh’)
   3198 
   3199      This suffix command sets the local log arguments for the current
   3200      buffer.
   3201 
   3202 ‘L s’     (‘magit-log-set-default-arguments’)
   3203 
   3204      This suffix command sets the default log arguments for buffers of
   3205      the same type as that of the current buffer.  Other existing
   3206      buffers of the same type are not affected because their local
   3207      values have already been initialized.
   3208 
   3209 ‘L w’     (‘magit-log-save-default-arguments’)
   3210 
   3211      This suffix command sets the default log arguments for buffers of
   3212      the same type as that of the current buffer, and saves the value
   3213      for future sessions.  Other existing buffers of the same type are
   3214      not affected because their local values have already been
   3215      initialized.
   3216 
   3217 ‘L t’     (‘magit-toggle-margin’)
   3218 
   3219      Show or hide the margin.
   3220 
   3221 
   3222 File: magit.info,  Node: Log Buffer,  Next: Log Margin,  Prev: Refreshing Logs,  Up: Logging
   3223 
   3224 5.3.2 Log Buffer
   3225 ----------------
   3226 
   3227 ‘L’     (‘magit-log-refresh’)
   3228 
   3229      This transient prefix command binds the following suffix commands
   3230      along with the appropriate infix arguments and displays them in a
   3231      temporary buffer until a suffix is invoked.
   3232 
   3233      See *note Refreshing Logs::.
   3234 
   3235 ‘q’     (‘magit-log-bury-buffer’)
   3236 
   3237      Bury the current buffer or the revision buffer in the same frame.
   3238      Like ‘magit-mode-bury-buffer’ (which see) but with a negative
   3239      prefix argument instead bury the revision buffer, provided it is
   3240      displayed in the current frame.
   3241 
   3242 ‘C-c C-b’     (‘magit-go-backward’)
   3243 
   3244      Move backward in current buffer’s history.
   3245 
   3246 ‘C-c C-f’     (‘magit-go-forward’)
   3247 
   3248      Move forward in current buffer’s history.
   3249 
   3250 ‘C-c C-n’     (‘magit-log-move-to-parent’)
   3251 
   3252      Move to a parent of the current commit.  By default, this is the
   3253      first parent, but a numeric prefix can be used to specify another
   3254      parent.
   3255 
   3256 ‘j’     (‘magit-log-move-to-revision’)
   3257 
   3258      Read a revision and move to it in current log buffer.
   3259 
   3260      If the chosen reference or revision isn’t being displayed in the
   3261      current log buffer, then inform the user about that and do nothing
   3262      else.
   3263 
   3264      If invoked outside any log buffer, then display the log buffer of
   3265      the current repository first; creating it if necessary.
   3266 
   3267 ‘SPC’     (‘magit-diff-show-or-scroll-up’)
   3268 
   3269      Update the commit or diff buffer for the thing at point.
   3270 
   3271      Either show the commit or stash at point in the appropriate buffer,
   3272      or if that buffer is already being displayed in the current frame
   3273      and contains information about that commit or stash, then instead
   3274      scroll the buffer up.  If there is no commit or stash at point,
   3275      then prompt for a commit.
   3276 
   3277 ‘DEL’     (‘magit-diff-show-or-scroll-down’)
   3278 
   3279      Update the commit or diff buffer for the thing at point.
   3280 
   3281      Either show the commit or stash at point in the appropriate buffer,
   3282      or if that buffer is already being displayed in the current frame
   3283      and contains information about that commit or stash, then instead
   3284      scroll the buffer down.  If there is no commit or stash at point,
   3285      then prompt for a commit.
   3286 
   3287 ‘=’     (‘magit-log-toggle-commit-limit’)
   3288 
   3289      Toggle the number of commits the current log buffer is limited to.
   3290      If the number of commits is currently limited, then remove that
   3291      limit.  Otherwise set it to 256.
   3292 
   3293 ‘+’     (‘magit-log-double-commit-limit’)
   3294 
   3295      Double the number of commits the current log buffer is limited to.
   3296 
   3297 ‘-’     (‘magit-log-half-commit-limit’)
   3298 
   3299      Half the number of commits the current log buffer is limited to.
   3300 
   3301  -- User Option: magit-log-auto-more
   3302 
   3303      Insert more log entries automatically when moving past the last
   3304      entry.  Only considered when moving past the last entry with
   3305      ‘magit-goto-*-section’ commands.
   3306 
   3307  -- User Option: magit-log-show-refname-after-summary
   3308 
   3309      Whether to show the refnames after the commit summaries.  This is
   3310      useful if you use really long branch names.
   3311 
   3312    Magit displays references in logs a bit differently from how Git does
   3313 it.
   3314 
   3315    Local branches are blue and remote branches are green.  Of course
   3316 that depends on the used theme, as do the colors used for other types of
   3317 references.  The current branch has a box around it, as do remote
   3318 branches that are their respective remote’s ‘HEAD’ branch.
   3319 
   3320    If a local branch and its push-target point at the same commit, then
   3321 their names are combined to preserve space and to make that relationship
   3322 visible.  For example:
   3323 
   3324      origin/feature
   3325      [green][blue-]
   3326 
   3327      instead of
   3328 
   3329      feature origin/feature
   3330      [blue-] [green-------]
   3331 
   3332    Also note that while the transient features the ‘--show-signature’
   3333 argument, that won’t actually be used when enabled, because Magit
   3334 defaults to use just one line per commit.  Instead the commit colorized
   3335 to indicate the validity of the signed commit object, using the faces
   3336 named ‘magit-signature-*’ (which see).
   3337 
   3338    For a description of ‘magit-log-margin’ see *note Log Margin::.
   3339 
   3340 
   3341 File: magit.info,  Node: Log Margin,  Next: Select from Log,  Prev: Log Buffer,  Up: Logging
   3342 
   3343 5.3.3 Log Margin
   3344 ----------------
   3345 
   3346 In buffers which show one or more logs, it is possible to show
   3347 additional information about each commit in the margin.  The options
   3348 used to configure the margin are named ‘magit-INFIX-margin’, where INFIX
   3349 is the same as in the respective major-mode ‘magit-INFIX-mode’.  In
   3350 regular log buffers that would be ‘magit-log-margin’.
   3351 
   3352  -- User Option: magit-log-margin
   3353 
   3354      This option specifies whether the margin is initially shown in
   3355      Magit-Log mode buffers and how it is formatted.
   3356 
   3357      The value has the form ‘(INIT STYLE WIDTH AUTHOR AUTHOR-WIDTH)’.
   3358 
   3359         • If INIT is non-nil, then the margin is shown initially.
   3360 
   3361         • STYLE controls how to format the author or committer date.  It
   3362           can be one of ‘age’ (to show the age of the commit),
   3363           ‘age-abbreviated’ (to abbreviate the time unit to a
   3364           character), or a string (suitable for ‘format-time-string’) to
   3365           show the actual date.  Option
   3366           ‘magit-log-margin-show-committer-date’ controls which date is
   3367           being displayed.
   3368 
   3369         • WIDTH controls the width of the margin.  This exists for
   3370           forward compatibility and currently the value should not be
   3371           changed.
   3372 
   3373         • AUTHOR controls whether the name of the author is also shown
   3374           by default.
   3375 
   3376         • AUTHOR-WIDTH has to be an integer.  When the name of the
   3377           author is shown, then this specifies how much space is used to
   3378           do so.
   3379 
   3380    You can change the STYLE and AUTHOR-WIDTH of all ‘magit-INFIX-margin’
   3381 options to the same values by customizing ‘magit-log-margin’ *before*
   3382 ‘magit’ is loaded.  If you do that, then the respective values for the
   3383 other options will default to what you have set for that variable.
   3384 Likewise if you set INIT in ‘magit-log-margin’ to ‘nil’, then that is
   3385 used in the default of all other options.  But setting it to ‘t’, i.e.
   3386 re-enforcing the default for that option, does not carry to other
   3387 options.
   3388 
   3389  -- User Option: magit-log-margin-show-committer-date
   3390 
   3391      This option specifies whether to show the committer date in the
   3392      margin.  This option only controls whether the committer date is
   3393      displayed instead of the author date.  Whether some date is
   3394      displayed in the margin and whether the margin is displayed at all
   3395      is controlled by other options.
   3396 
   3397 ‘L’     (‘magit-margin-settings’)
   3398 
   3399      This transient prefix command binds the following suffix commands,
   3400      each of which changes the appearance of the margin in some way.
   3401 
   3402    In some buffers that support the margin, ‘L’ is instead bound to
   3403 ‘magit-log-refresh’, but that transient features the same commands, and
   3404 then some other unrelated commands.
   3405 
   3406 ‘L L’     (‘magit-toggle-margin’)
   3407 
   3408      This command shows or hides the margin.
   3409 
   3410 ‘L l’     (‘magit-cycle-margin-style’)
   3411 
   3412      This command cycles the style used for the margin.
   3413 
   3414 ‘L d’     (‘magit-toggle-margin-details’)
   3415 
   3416      This command shows or hides details in the margin.
   3417 
   3418 
   3419 File: magit.info,  Node: Select from Log,  Next: Reflog,  Prev: Log Margin,  Up: Logging
   3420 
   3421 5.3.4 Select from Log
   3422 ---------------------
   3423 
   3424 When the user has to select a recent commit that is reachable from
   3425 ‘HEAD’, using regular completion would be inconvenient (because most
   3426 humans cannot remember hashes or "HEAD~5", at least not without double
   3427 checking).  Instead a log buffer is used to select the commit, which has
   3428 the advantage that commits are presented in order and with the commit
   3429 message.
   3430 
   3431    Such selection logs are used when selecting the beginning of a rebase
   3432 and when selecting the commit to be squashed into.
   3433 
   3434    In addition to the key bindings available in all log buffers, the
   3435 following additional key bindings are available in selection log
   3436 buffers:
   3437 
   3438 ‘C-c C-c’     (‘magit-log-select-pick’)
   3439 
   3440      Select the commit at point and act on it.  Call
   3441      ‘magit-log-select-pick-function’ with the selected commit as
   3442      argument.
   3443 
   3444 ‘C-c C-k’     (‘magit-log-select-quit’)
   3445 
   3446      Abort selecting a commit, don’t act on any commit.
   3447 
   3448  -- User Option: magit-log-select-margin
   3449 
   3450      This option specifies whether the margin is initially shown in
   3451      Magit-Log-Select mode buffers and how it is formatted.
   3452 
   3453      The value has the form ‘(INIT STYLE WIDTH AUTHOR AUTHOR-WIDTH)’.
   3454 
   3455         • If INIT is non-nil, then the margin is shown initially.
   3456 
   3457         • STYLE controls how to format the author or committer date.  It
   3458           can be one of ‘age’ (to show the age of the commit),
   3459           ‘age-abbreviated’ (to abbreviate the time unit to a
   3460           character), or a string (suitable for ‘format-time-string’) to
   3461           show the actual date.  Option
   3462           ‘magit-log-margin-show-committer-date’ controls which date is
   3463           being displayed.
   3464 
   3465         • WIDTH controls the width of the margin.  This exists for
   3466           forward compatibility and currently the value should not be
   3467           changed.
   3468 
   3469         • AUTHOR controls whether the name of the author is also shown
   3470           by default.
   3471 
   3472         • AUTHOR-WIDTH has to be an integer.  When the name of the
   3473           author is shown, then this specifies how much space is used to
   3474           do so.
   3475 
   3476 
   3477 File: magit.info,  Node: Reflog,  Next: Cherries,  Prev: Select from Log,  Up: Logging
   3478 
   3479 5.3.5 Reflog
   3480 ------------
   3481 
   3482 Also see *note (gitman)git-reflog::.
   3483 
   3484    These reflog commands are available from the log transient.  See
   3485 *note Logging::.
   3486 
   3487 ‘l r’     (‘magit-reflog-current’)
   3488 
   3489      Display the reflog of the current branch.
   3490 
   3491 ‘l O’     (‘magit-reflog-other’)
   3492 
   3493      Display the reflog of a branch or another ref.
   3494 
   3495 ‘l H’     (‘magit-reflog-head’)
   3496 
   3497      Display the ‘HEAD’ reflog.
   3498 
   3499  -- User Option: magit-reflog-margin
   3500 
   3501      This option specifies whether the margin is initially shown in
   3502      Magit-Reflog mode buffers and how it is formatted.
   3503 
   3504      The value has the form ‘(INIT STYLE WIDTH AUTHOR AUTHOR-WIDTH)’.
   3505 
   3506         • If INIT is non-nil, then the margin is shown initially.
   3507 
   3508         • STYLE controls how to format the author or committer date.  It
   3509           can be one of ‘age’ (to show the age of the commit),
   3510           ‘age-abbreviated’ (to abbreviate the time unit to a
   3511           character), or a string (suitable for ‘format-time-string’) to
   3512           show the actual date.  Option
   3513           ‘magit-log-margin-show-committer-date’ controls which date is
   3514           being displayed.
   3515 
   3516         • WIDTH controls the width of the margin.  This exists for
   3517           forward compatibility and currently the value should not be
   3518           changed.
   3519 
   3520         • AUTHOR controls whether the name of the author is also shown
   3521           by default.
   3522 
   3523         • AUTHOR-WIDTH has to be an integer.  When the name of the
   3524           author is shown, then this specifies how much space is used to
   3525           do so.
   3526 
   3527 
   3528 File: magit.info,  Node: Cherries,  Prev: Reflog,  Up: Logging
   3529 
   3530 5.3.6 Cherries
   3531 --------------
   3532 
   3533 Cherries are commits that haven’t been applied upstream (yet), and are
   3534 usually visualized using a log.  Each commit is prefixed with ‘-’ if it
   3535 has an equivalent in the upstream and ‘+’ if it does not, i.e.  if it is
   3536 a cherry.
   3537 
   3538    The command ‘magit-cherry’ shows cherries for a single branch, but
   3539 the references buffer (see *note References Buffer::) can show cherries
   3540 for multiple "upstreams" at once.
   3541 
   3542    Also see *note (gitman)git-reflog::.
   3543 
   3544 ‘Y’     (‘magit-cherry’)
   3545 
   3546      Show commits that are in a certain branch but that have not been
   3547      merged in the upstream branch.
   3548 
   3549  -- User Option: magit-cherry-margin
   3550 
   3551      This option specifies whether the margin is initially shown in
   3552      Magit-Cherry mode buffers and how it is formatted.
   3553 
   3554      The value has the form ‘(INIT STYLE WIDTH AUTHOR AUTHOR-WIDTH)’.
   3555 
   3556         • If INIT is non-nil, then the margin is shown initially.
   3557 
   3558         • STYLE controls how to format the author or committer date.  It
   3559           can be one of ‘age’ (to show the age of the commit),
   3560           ‘age-abbreviated’ (to abbreviate the time unit to a
   3561           character), or a string (suitable for ‘format-time-string’) to
   3562           show the actual date.  Option
   3563           ‘magit-log-margin-show-committer-date’ controls which date is
   3564           being displayed.
   3565 
   3566         • WIDTH controls the width of the margin.  This exists for
   3567           forward compatibility and currently the value should not be
   3568           changed.
   3569 
   3570         • AUTHOR controls whether the name of the author is also shown
   3571           by default.
   3572 
   3573         • AUTHOR-WIDTH has to be an integer.  When the name of the
   3574           author is shown, then this specifies how much space is used to
   3575           do so.
   3576 
   3577 
   3578 File: magit.info,  Node: Diffing,  Next: Ediffing,  Prev: Logging,  Up: Inspecting
   3579 
   3580 5.4 Diffing
   3581 ===========
   3582 
   3583 The status buffer contains diffs for the staged and unstaged commits,
   3584 but that obviously isn’t enough.  The transient prefix command
   3585 ‘magit-diff’, on ‘d’, features several suffix commands, which show a
   3586 specific diff in a separate diff buffer.
   3587 
   3588    Like other transient prefix commands, ‘magit-diff’ also features
   3589 several infix arguments that can be changed before invoking one of the
   3590 suffix commands.  However, in the case of the diff transient, these
   3591 arguments may be taken from those currently in use in the current
   3592 repository’s diff buffer, depending on the value of
   3593 ‘magit-prefix-use-buffer-arguments’ (see *note Transient Arguments and
   3594 Buffer Variables::).
   3595 
   3596    Also see *note (gitman)git-diff::.
   3597 
   3598 ‘d’     (‘magit-diff’)
   3599 
   3600      This transient prefix command binds the following suffix commands
   3601      along with the appropriate infix arguments and displays them in a
   3602      temporary buffer until a suffix is invoked.
   3603 
   3604 ‘d d’     (‘magit-diff-dwim’)
   3605 
   3606      Show changes for the thing at point.
   3607 
   3608 ‘d r’     (‘magit-diff-range’)
   3609 
   3610      Show differences between two commits.
   3611 
   3612      RANGE should be a range (A..B or A...B) but can also be a single
   3613      commit.  If one side of the range is omitted, then it defaults to
   3614      ‘HEAD’.  If just a commit is given, then changes in the working
   3615      tree relative to that commit are shown.
   3616 
   3617      If the region is active, use the revisions on the first and last
   3618      line of the region.  With a prefix argument, instead of diffing the
   3619      revisions, choose a revision to view changes along, starting at the
   3620      common ancestor of both revisions (i.e., use a "..." range).
   3621 
   3622 ‘d w’     (‘magit-diff-working-tree’)
   3623 
   3624      Show changes between the current working tree and the ‘HEAD’
   3625      commit.  With a prefix argument show changes between the working
   3626      tree and a commit read from the minibuffer.
   3627 
   3628 ‘d s’     (‘magit-diff-staged’)
   3629 
   3630      Show changes between the index and the ‘HEAD’ commit.  With a
   3631      prefix argument show changes between the index and a commit read
   3632      from the minibuffer.
   3633 
   3634 ‘d u’     (‘magit-diff-unstaged’)
   3635 
   3636      Show changes between the working tree and the index.
   3637 
   3638 ‘d p’     (‘magit-diff-paths’)
   3639 
   3640      Show changes between any two files on disk.
   3641 
   3642    All of the above suffix commands update the repository’s diff buffer.
   3643 The diff transient also features two commands which show differences in
   3644 another buffer:
   3645 
   3646 ‘d c’     (‘magit-show-commit’)
   3647 
   3648      Show the commit at point.  If there is no commit at point or with a
   3649      prefix argument, prompt for a commit.
   3650 
   3651 ‘d t’     (‘magit-stash-show’)
   3652 
   3653      Show all diffs of a stash in a buffer.
   3654 
   3655    Two additional commands that show the diff for the file or blob that
   3656 is being visited in the current buffer exists, see *note Commands for
   3657 Buffers Visiting Files::.
   3658 
   3659 * Menu:
   3660 
   3661 * Refreshing Diffs::
   3662 * Commands Available in Diffs::
   3663 * Diff Options::
   3664 * Revision Buffer::
   3665 
   3666 
   3667 File: magit.info,  Node: Refreshing Diffs,  Next: Commands Available in Diffs,  Up: Diffing
   3668 
   3669 5.4.1 Refreshing Diffs
   3670 ----------------------
   3671 
   3672 The transient prefix command ‘magit-diff-refresh’, on ‘D’, can be used
   3673 to change the diff arguments used in the current buffer, without
   3674 changing which diff is shown.  This works in dedicated diff buffers, but
   3675 also in the status buffer.
   3676 
   3677 ‘D’     (‘magit-diff-refresh’)
   3678 
   3679      This transient prefix command binds the following suffix commands
   3680      along with the appropriate infix arguments and displays them in a
   3681      temporary buffer until a suffix is invoked.
   3682 
   3683 ‘D g’     (‘magit-diff-refresh’)
   3684 
   3685      This suffix command sets the local diff arguments for the current
   3686      buffer.
   3687 
   3688 ‘D s’     (‘magit-diff-set-default-arguments’)
   3689 
   3690      This suffix command sets the default diff arguments for buffers of
   3691      the same type as that of the current buffer.  Other existing
   3692      buffers of the same type are not affected because their local
   3693      values have already been initialized.
   3694 
   3695 ‘D w’     (‘magit-diff-save-default-arguments’)
   3696 
   3697      This suffix command sets the default diff arguments for buffers of
   3698      the same type as that of the current buffer, and saves the value
   3699      for future sessions.  Other existing buffers of the same type are
   3700      not affected because their local values have already been
   3701      initialized.
   3702 
   3703 ‘D t’     (‘magit-diff-toggle-refine-hunk’)
   3704 
   3705      This command toggles hunk refinement on or off.
   3706 
   3707 ‘D r’     (‘magit-diff-switch-range-type’)
   3708 
   3709      This command converts the diff range type from "revA..revB" to
   3710      "revB...revA", or vice versa.
   3711 
   3712 ‘D f’     (‘magit-diff-flip-revs’)
   3713 
   3714      This command swaps revisions in the diff range from "revA..revB" to
   3715      "revB..revA", or vice versa.
   3716 
   3717 ‘D F’     (‘magit-diff-toggle-file-filter’)
   3718 
   3719      This command toggles the file restriction of the diffs in the
   3720      current buffer, allowing you to quickly switch between viewing all
   3721      the changes in the commit and the restricted subset.  As a special
   3722      case, when this command is called from a log buffer, it toggles the
   3723      file restriction in the repository’s revision buffer, which is
   3724      useful when you display a revision from a log buffer that is
   3725      restricted to a file or files.
   3726 
   3727    In addition to the above transient, which allows changing any of the
   3728 supported arguments, there also exist some commands that change only a
   3729 particular argument.
   3730 
   3731 ‘-’     (‘magit-diff-less-context’)
   3732 
   3733      This command decreases the context for diff hunks by COUNT lines.
   3734 
   3735 ‘+’     (‘magit-diff-more-context’)
   3736 
   3737      This command increases the context for diff hunks by COUNT lines.
   3738 
   3739 ‘0’     (‘magit-diff-default-context’)
   3740 
   3741      This command resets the context for diff hunks to the default
   3742      height.
   3743 
   3744    The following commands quickly change what diff is being displayed
   3745 without having to using one of the diff transient.
   3746 
   3747 ‘C-c C-d’     (‘magit-diff-while-committing’)
   3748 
   3749      While committing, this command shows the changes that are about to
   3750      be committed.  While amending, invoking the command again toggles
   3751      between showing just the new changes or all the changes that will
   3752      be committed.
   3753 
   3754      This binding is available in the diff buffer as well as the commit
   3755      message buffer.
   3756 
   3757 ‘C-c C-b’     (‘magit-go-backward’)
   3758 
   3759      This command moves backward in current buffer’s history.
   3760 
   3761 ‘C-c C-f’     (‘magit-go-forward’)
   3762 
   3763      This command moves forward in current buffer’s history.
   3764 
   3765 
   3766 File: magit.info,  Node: Commands Available in Diffs,  Next: Diff Options,  Prev: Refreshing Diffs,  Up: Diffing
   3767 
   3768 5.4.2 Commands Available in Diffs
   3769 ---------------------------------
   3770 
   3771 Some commands are only available if point is inside a diff.
   3772 
   3773    ‘magit-diff-visit-file’ and related commands visit the appropriate
   3774 version of the file that the diff at point is about.  Likewise
   3775 ‘magit-diff-visit-worktree-file’ and related commands visit the worktree
   3776 version of the file that the diff at point is about.  See *note Visiting
   3777 Files and Blobs from a Diff:: for more information and the key bindings.
   3778 
   3779 ‘C-c C-t’     (‘magit-diff-trace-definition’)
   3780 
   3781      This command shows a log for the definition at point.
   3782 
   3783  -- User Option: magit-log-trace-definition-function
   3784 
   3785      The function specified by this option is used by
   3786      ‘magit-log-trace-definition’ to determine the function at point.
   3787      For major-modes that have special needs, you could set the local
   3788      value using the mode’s hook.
   3789 
   3790 ‘C-c C-e’     (‘magit-diff-edit-hunk-commit’)
   3791 
   3792      From a hunk, this command edits the respective commit and visits
   3793      the file.
   3794 
   3795      First it visits the file being modified by the hunk at the correct
   3796      location using ‘magit-diff-visit-file’.  This actually visits a
   3797      blob.  When point is on a diff header, not within an individual
   3798      hunk, then this visits the blob the first hunk is about.
   3799 
   3800      Then it invokes ‘magit-edit-line-commit’, which uses an interactive
   3801      rebase to make the commit editable, or if that is not possible
   3802      because the commit is not reachable from ‘HEAD’ by checking out
   3803      that commit directly.  This also causes the actual worktree file to
   3804      be visited.
   3805 
   3806      Neither the blob nor the file buffer are killed when finishing the
   3807      rebase.  If that is undesirable, then it might be better to use
   3808      ‘magit-rebase-edit-command’ instead of this command.
   3809 
   3810 ‘j’     (‘magit-jump-to-diffstat-or-diff’)
   3811 
   3812      This command jumps to the diffstat or diff.  When point is on a
   3813      file inside the diffstat section, then jump to the respective diff
   3814      section.  Otherwise, jump to the diffstat section or a child
   3815      thereof.
   3816 
   3817    The next two commands are not specific to Magit-Diff mode (or and
   3818 Magit buffer for that matter), but it might be worth pointing out that
   3819 they are available here too.
   3820 
   3821 ‘SPC’     (‘scroll-up’)
   3822 
   3823      This command scrolls text upward.
   3824 
   3825 ‘DEL’     (‘scroll-down’)
   3826 
   3827      This command scrolls text downward.
   3828 
   3829 
   3830 File: magit.info,  Node: Diff Options,  Next: Revision Buffer,  Prev: Commands Available in Diffs,  Up: Diffing
   3831 
   3832 5.4.3 Diff Options
   3833 ------------------
   3834 
   3835  -- User Option: magit-diff-refine-hunk
   3836 
   3837      Whether to show word-granularity differences within diff hunks.
   3838 
   3839         • ‘nil’ Never show fine differences.
   3840 
   3841         • ‘t’ Show fine differences for the current diff hunk only.
   3842 
   3843         • ‘all’ Show fine differences for all displayed diff hunks.
   3844 
   3845  -- User Option: magit-diff-refine-ignore-whitespace
   3846 
   3847      Whether to ignore whitespace changes in word-granularity
   3848      differences.
   3849 
   3850  -- User Option: magit-diff-adjust-tab-width
   3851 
   3852      Whether to adjust the width of tabs in diffs.
   3853 
   3854      Determining the correct width can be expensive if it requires
   3855      opening large and/or many files, so the widths are cached in the
   3856      variable ‘magit-diff--tab-width-cache’.  Set that to nil to
   3857      invalidate the cache.
   3858 
   3859         • ‘nil’ Never adjust tab width.  Use ‘tab-width’s value from the
   3860           Magit buffer itself instead.
   3861 
   3862         • ‘t’ If the corresponding file-visiting buffer exits, then use
   3863           ‘tab-width’’s value from that buffer.  Doing this is cheap, so
   3864           this value is used even if a corresponding cache entry exists.
   3865 
   3866         • ‘always’ If there is no such buffer, then temporarily visit
   3867           the file to determine the value.
   3868 
   3869         • NUMBER Like ‘always’, but don’t visit files larger than NUMBER
   3870           bytes.
   3871 
   3872  -- User Option: magit-diff-paint-whitespace
   3873 
   3874      Specify where to highlight whitespace errors.
   3875 
   3876      See ‘magit-diff-highlight-trailing’,
   3877      ‘magit-diff-highlight-indentation’.  The symbol ‘t’ means in all
   3878      diffs, ‘status’ means only in the status buffer, and nil means
   3879      nowhere.
   3880 
   3881         • ‘nil’ Never highlight whitespace errors.
   3882 
   3883         • ‘t’ Highlight whitespace errors everywhere.
   3884 
   3885         • ‘uncommitted’ Only highlight whitespace errors in diffs
   3886           showing uncommitted changes.  For backward compatibility
   3887           ‘status’ is treated as a synonym.
   3888 
   3889  -- User Option: magit-diff-paint-whitespace-lines
   3890 
   3891      Specify in what kind of lines to highlight whitespace errors.
   3892 
   3893         • ‘t’ Highlight only in added lines.
   3894 
   3895         • ‘both’ Highlight in added and removed lines.
   3896 
   3897         • ‘all’ Highlight in added, removed and context lines.
   3898 
   3899  -- User Option: magit-diff-highlight-trailing
   3900 
   3901      Whether to highlight whitespace at the end of a line in diffs.
   3902      Used only when ‘magit-diff-paint-whitespace’ is non-nil.
   3903 
   3904  -- User Option: magit-diff-highlight-indentation
   3905 
   3906      This option controls whether to highlight the indentation in case
   3907      it used the "wrong" indentation style.  Indentation is only
   3908      highlighted if ‘magit-diff-paint-whitespace’ is also non-nil.
   3909 
   3910      The value is an alist of the form ‘((REGEXP . INDENT)...)’.  The
   3911      path to the current repository is matched against each element in
   3912      reverse order.  Therefore if a REGEXP matches, then earlier
   3913      elements are not tried.
   3914 
   3915      If the used INDENT is ‘tabs’, highlight indentation with tabs.  If
   3916      INDENT is an integer, highlight indentation with at least that many
   3917      spaces.  Otherwise, highlight neither.
   3918 
   3919  -- User Option: magit-diff-hide-trailing-cr-characters
   3920 
   3921      Whether to hide ^M characters at the end of a line in diffs.
   3922 
   3923  -- User Option: magit-diff-highlight-hunk-region-functions
   3924 
   3925      This option specifies the functions used to highlight the
   3926      hunk-internal region.
   3927 
   3928      ‘magit-diff-highlight-hunk-region-dim-outside’ overlays the outside
   3929      of the hunk internal selection with a face that causes the added
   3930      and removed lines to have the same background color as context
   3931      lines.  This function should not be removed from the value of this
   3932      option.
   3933 
   3934      ‘magit-diff-highlight-hunk-region-using-overlays’ and
   3935      ‘magit-diff-highlight-hunk-region-using-underline’ emphasize the
   3936      region by placing delimiting horizontal lines before and after it.
   3937      Both of these functions have glitches which cannot be fixed due to
   3938      limitations of Emacs’ display engine.  For more information see
   3939      <https://github.com/magit/magit/issues/2758> ff.
   3940 
   3941      Instead of, or in addition to, using delimiting horizontal lines,
   3942      to emphasize the boundaries, you may which to emphasize the text
   3943      itself, using ‘magit-diff-highlight-hunk-region-using-face’.
   3944 
   3945      In terminal frames it’s not possible to draw lines as the overlay
   3946      and underline variants normally do, so there they fall back to
   3947      calling the face function instead.
   3948 
   3949  -- User Option: magit-diff-unmarked-lines-keep-foreground
   3950 
   3951      This option controls whether added and removed lines outside the
   3952      hunk-internal region only lose their distinct background color or
   3953      also the foreground color.  Whether the outside of the region is
   3954      dimmed at all depends on
   3955      ‘magit-diff-highlight-hunk-region-functions’.
   3956 
   3957  -- User Option: magit-diff-extra-stat-arguments
   3958 
   3959      This option specifies additional arguments to be used alongside
   3960      ‘--stat’.
   3961 
   3962      The value is a list of zero or more arguments or a function that
   3963      takes no argument and returns such a list.  These arguments are
   3964      allowed here: ‘--stat-width’, ‘--stat-name-width’,
   3965      ‘--stat-graph-width’ and ‘--compact-summary’.  Also see *note
   3966      (gitman)git-diff::.
   3967 
   3968 
   3969 File: magit.info,  Node: Revision Buffer,  Prev: Diff Options,  Up: Diffing
   3970 
   3971 5.4.4 Revision Buffer
   3972 ---------------------
   3973 
   3974  -- User Option: magit-revision-insert-related-refs
   3975 
   3976      Whether to show related branches in revision buffers.
   3977 
   3978         • ‘nil’ Don’t show any related branches.
   3979 
   3980         • ‘t’ Show related local branches.
   3981 
   3982         • ‘all’ Show related local and remote branches.
   3983 
   3984         • ‘mixed’ Show all containing branches and local merged
   3985           branches.
   3986 
   3987  -- User Option: magit-revision-show-gravatars
   3988 
   3989      Whether to show gravatar images in revision buffers.
   3990 
   3991      If ‘nil’, then don’t insert any gravatar images.  If ‘t’, then
   3992      insert both images.  If ‘author’ or ‘committer’, then insert only
   3993      the respective image.
   3994 
   3995      If you have customized the option ‘magit-revision-headers-format’
   3996      and want to insert the images then you might also have to specify
   3997      where to do so.  In that case the value has to be a cons-cell of
   3998      two regular expressions.  The car specifies where to insert the
   3999      author’s image.  The top half of the image is inserted right after
   4000      the matched text, the bottom half on the next line in the same
   4001      column.  The cdr specifies where to insert the committer’s image,
   4002      accordingly.  Either the car or the cdr may be nil."
   4003 
   4004  -- User Option: magit-revision-use-hash-sections
   4005 
   4006      Whether to turn hashes inside the commit message into sections.
   4007 
   4008      If non-nil, then hashes inside the commit message are turned into
   4009      ‘commit’ sections.  There is a trade off to be made between
   4010      performance and reliability:
   4011 
   4012         • ‘slow’ calls git for every word to be absolutely sure.
   4013 
   4014         • ‘quick’ skips words less than seven characters long.
   4015 
   4016         • ‘quicker’ additionally skips words that don’t contain a
   4017           number.
   4018 
   4019         • ‘quickest’ uses all words that are at least seven characters
   4020           long and which contain at least one number as well as at least
   4021           one letter.
   4022 
   4023      If nil, then no hashes are turned into sections, but you can still
   4024      visit the commit at point using "RET".
   4025 
   4026    The diffs shown in the revision buffer may be automatically
   4027 restricted to a subset of the changed files.  If the revision buffer is
   4028 displayed from a log buffer, the revision buffer will share the same
   4029 file restriction as that log buffer (also see the command
   4030 ‘magit-diff-toggle-file-filter’).
   4031 
   4032  -- User Option: magit-revision-filter-files-on-follow
   4033 
   4034      Whether showing a commit from a log buffer honors the log’s file
   4035      filter when the log arguments include ‘--follow’.
   4036 
   4037      When this option is nil, displaying a commit from a log ignores the
   4038      log’s file filter if the log arguments include ‘--follow’.  Doing
   4039      so avoids showing an empty diff in revision buffers for commits
   4040      before a rename event.  In such cases, the ‘--patch’ argument of
   4041      the log transient can be used to show the file-restricted diffs
   4042      inline.
   4043 
   4044      Set this option to non-nil to keep the log’s file restriction even
   4045      if ‘--follow’ is present in the log arguments.
   4046 
   4047    If the revision buffer is not displayed from a log buffer, the file
   4048 restriction is determined as usual (see *note Transient Arguments and
   4049 Buffer Variables::).
   4050 
   4051 
   4052 File: magit.info,  Node: Ediffing,  Next: References Buffer,  Prev: Diffing,  Up: Inspecting
   4053 
   4054 5.5 Ediffing
   4055 ============
   4056 
   4057 This section describes how to enter Ediff from Magit buffers.  For
   4058 information on how to use Ediff itself, see *note (ediff)Top::.
   4059 
   4060 ‘e’     (‘magit-ediff-dwim’)
   4061 
   4062      Compare, stage, or resolve using Ediff.
   4063 
   4064      This command tries to guess what file, and what commit or range the
   4065      user wants to compare, stage, or resolve using Ediff.  It might
   4066      only be able to guess either the file, or range/commit, in which
   4067      case the user is asked about the other.  It might not always guess
   4068      right, in which case the appropriate ‘magit-ediff-*’ command has to
   4069      be used explicitly.  If it cannot read the user’s mind at all, then
   4070      it asks the user for a command to run.
   4071 
   4072 ‘E’     (‘magit-ediff’)
   4073 
   4074      This transient prefix command binds the following suffix commands
   4075      and displays them in a temporary buffer until a suffix is invoked.
   4076 
   4077 ‘E r’     (‘magit-ediff-compare’)
   4078 
   4079      Compare two revisions of a file using Ediff.
   4080 
   4081      If the region is active, use the revisions on the first and last
   4082      line of the region.  With a prefix argument, instead of diffing the
   4083      revisions, choose a revision to view changes along, starting at the
   4084      common ancestor of both revisions (i.e., use a "..." range).
   4085 
   4086 ‘E m’     (‘magit-ediff-resolve’)
   4087 
   4088      Resolve outstanding conflicts in a file using Ediff, defaulting to
   4089      the file at point.
   4090 
   4091      Provided that the value of ‘merge.conflictstyle’ is ‘diff3’, you
   4092      can view the file’s merge-base revision using ‘/’ in the Ediff
   4093      control buffer.
   4094 
   4095      In the rare event that you want to manually resolve all conflicts,
   4096      including those already resolved by Git, use
   4097      ‘ediff-merge-revisions-with-ancestor’.
   4098 
   4099 ‘E s’     (‘magit-ediff-stage’)
   4100 
   4101      Stage and unstage changes to a file using Ediff, defaulting to the
   4102      file at point.
   4103 
   4104 ‘E u’     (‘magit-ediff-show-unstaged’)
   4105 
   4106      Show unstaged changes to a file using Ediff.
   4107 
   4108 ‘E i’     (‘magit-ediff-show-staged’)
   4109 
   4110      Show staged changes to a file using Ediff.
   4111 
   4112 ‘E w’     (‘magit-ediff-show-working-tree’)
   4113 
   4114      Show changes in a file between ‘HEAD’ and working tree using Ediff.
   4115 
   4116 ‘E c’     (‘magit-ediff-show-commit’)
   4117 
   4118      Show changes to a file introduced by a commit using Ediff.
   4119 
   4120 ‘E z’     (‘magit-ediff-show-stash’)
   4121 
   4122      Show changes to a file introduced by a stash using Ediff.
   4123 
   4124  -- User Option: magit-ediff-dwim-show-on-hunks
   4125 
   4126      This option controls what command ‘magit-ediff-dwim’ calls when
   4127      point is on uncommitted hunks.  When nil, always run
   4128      ‘magit-ediff-stage’.  Otherwise, use ‘magit-ediff-show-staged’ and
   4129      ‘magit-ediff-show-unstaged’ to show staged and unstaged changes,
   4130      respectively.
   4131 
   4132  -- User Option: magit-ediff-show-stash-with-index
   4133 
   4134      This option controls whether ‘magit-ediff-show-stash’ includes a
   4135      buffer containing the file’s state in the index at the time the
   4136      stash was created.  This makes it possible to tell which changes in
   4137      the stash were staged.
   4138 
   4139  -- User Option: magit-ediff-quit-hook
   4140 
   4141      This hook is run after quitting an Ediff session that was created
   4142      using a Magit command.  The hook functions are run inside the Ediff
   4143      control buffer, and should not change the current buffer.
   4144 
   4145      This is similar to ‘ediff-quit-hook’ but takes the needs of Magit
   4146      into account.  The regular ‘ediff-quit-hook’ is ignored by Ediff
   4147      sessions that were created using a Magit command.
   4148 
   4149 
   4150 File: magit.info,  Node: References Buffer,  Next: Bisecting,  Prev: Ediffing,  Up: Inspecting
   4151 
   4152 5.6 References Buffer
   4153 =====================
   4154 
   4155 ‘y’     (‘magit-show-refs’)
   4156 
   4157      This command lists branches and tags in a dedicated buffer.
   4158 
   4159      However if this command is invoked again from this buffer or if it
   4160      is invoked with a prefix argument, then it acts as a transient
   4161      prefix command, which binds the following suffix commands and some
   4162      infix arguments.
   4163 
   4164    All of the following suffix commands list exactly the same branches
   4165 and tags.  The only difference the optional feature that can be enabled
   4166 by changing the value of ‘magit-refs-show-commit-count’ (see below).
   4167 These commands specify a different branch or commit against which all
   4168 the other references are compared.
   4169 
   4170 ‘y y’     (‘magit-show-refs-head’)
   4171 
   4172      This command lists branches and tags in a dedicated buffer.  Each
   4173      reference is being compared with ‘HEAD’.
   4174 
   4175 ‘y c’     (‘magit-show-refs-current’)
   4176 
   4177      This command lists branches and tags in a dedicated buffer.  Each
   4178      reference is being compared with the current branch or ‘HEAD’ if it
   4179      is detached.
   4180 
   4181 ‘y o’     (‘magit-show-refs-other’)
   4182 
   4183      This command lists branches and tags in a dedicated buffer.  Each
   4184      reference is being compared with a branch read from the user.
   4185 
   4186 ‘y r’     (‘magit-refs-set-show-commit-count’)
   4187 
   4188      This command changes for which refs the commit count is shown.
   4189 
   4190  -- User Option: magit-refs-show-commit-count
   4191 
   4192      Whether to show commit counts in Magit-Refs mode buffers.
   4193 
   4194         • ‘all’ Show counts for branches and tags.
   4195 
   4196         • ‘branch’ Show counts for branches only.
   4197 
   4198         • ‘nil’ Never show counts.
   4199 
   4200      The default is ‘nil’ because anything else can be very expensive.
   4201 
   4202  -- User Option: magit-refs-pad-commit-counts
   4203 
   4204      Whether to pad all commit counts on all sides in Magit-Refs mode
   4205      buffers.
   4206 
   4207      If this is nil, then some commit counts are displayed right next to
   4208      one of the branches that appear next to the count, without any
   4209      space in between.  This might look bad if the branch name faces
   4210      look too similar to ‘magit-dimmed’.
   4211 
   4212      If this is non-nil, then spaces are placed on both sides of all
   4213      commit counts.
   4214 
   4215  -- User Option: magit-refs-show-remote-prefix
   4216 
   4217      Whether to show the remote prefix in lists of remote branches.
   4218 
   4219      Showing the prefix is redundant because the name of the remote is
   4220      already shown in the heading preceding the list of its branches.
   4221 
   4222  -- User Option: magit-refs-primary-column-width
   4223 
   4224      Width of the primary column in ‘magit-refs-mode’ buffers.  The
   4225      primary column is the column that contains the name of the branch
   4226      that the current row is about.
   4227 
   4228      If this is an integer, then the column is that many columns wide.
   4229      Otherwise it has to be a cons-cell of two integers.  The first
   4230      specifies the minimal width, the second the maximal width.  In that
   4231      case the actual width is determined using the length of the names
   4232      of the shown local branches.  (Remote branches and tags are not
   4233      taken into account when calculating to optimal width.)
   4234 
   4235  -- User Option: magit-refs-focus-column-width
   4236 
   4237      Width of the focus column in ‘magit-refs-mode’ buffers.
   4238 
   4239      The focus column is the first column, which marks one branch
   4240      (usually the current branch) as the focused branch using ‘*’ or
   4241      ‘@’.  For each other reference, this column optionally shows how
   4242      many commits it is ahead of the focused branch and ‘<’, or if it
   4243      isn’t ahead then the commits it is behind and ‘>’, or if it isn’t
   4244      behind either, then a ‘=’.
   4245 
   4246      This column may also display only ‘*’ or ‘@’ for the focused
   4247      branch, in which case this option is ignored.  Use ‘L v’ to change
   4248      the verbosity of this column.
   4249 
   4250  -- User Option: magit-refs-margin
   4251 
   4252      This option specifies whether the margin is initially shown in
   4253      Magit-Refs mode buffers and how it is formatted.
   4254 
   4255      The value has the form ‘(INIT STYLE WIDTH AUTHOR AUTHOR-WIDTH)’.
   4256 
   4257         • If INIT is non-nil, then the margin is shown initially.
   4258 
   4259         • STYLE controls how to format the author or committer date.  It
   4260           can be one of ‘age’ (to show the age of the commit),
   4261           ‘age-abbreviated’ (to abbreviate the time unit to a
   4262           character), or a string (suitable for ‘format-time-string’) to
   4263           show the actual date.  Option
   4264           ‘magit-log-margin-show-committer-date’ controls which date is
   4265           being displayed.
   4266 
   4267         • WIDTH controls the width of the margin.  This exists for
   4268           forward compatibility and currently the value should not be
   4269           changed.
   4270 
   4271         • AUTHOR controls whether the name of the author is also shown
   4272           by default.
   4273 
   4274         • AUTHOR-WIDTH has to be an integer.  When the name of the
   4275           author is shown, then this specifies how much space is used to
   4276           do so.
   4277 
   4278  -- User Option: magit-refs-margin-for-tags
   4279 
   4280      This option specifies whether to show information about tags in the
   4281      margin.  This is disabled by default because it is slow if there
   4282      are many tags.
   4283 
   4284    The following variables control how individual refs are displayed.
   4285 If you change one of these variables (especially the "%c" part), then
   4286 you should also change the others to keep things aligned.  The following
   4287 %-sequences are supported:
   4288 
   4289    • ‘%a’ Number of commits this ref has over the one we compare to.
   4290 
   4291    • ‘%b’ Number of commits the ref we compare to has over this one.
   4292 
   4293    • ‘%c’ Number of commits this ref has over the one we compare to.
   4294      For the ref which all other refs are compared this is instead "@",
   4295      if it is the current branch, or "#" otherwise.
   4296 
   4297    • ‘%C’ For the ref which all other refs are compared this is "@", if
   4298      it is the current branch, or "#" otherwise.  For all other refs "
   4299      ".
   4300 
   4301    • ‘%h’ Hash of this ref’s tip.
   4302 
   4303    • ‘%m’ Commit summary of the tip of this ref.
   4304 
   4305    • ‘%n’ Name of this ref.
   4306 
   4307    • ‘%u’ Upstream of this local branch.
   4308 
   4309    • ‘%U’ Upstream of this local branch and additional local vs.
   4310      upstream information.
   4311 
   4312  -- User Option: magit-refs-filter-alist
   4313 
   4314      The purpose of this option is to forgo displaying certain refs
   4315      based on their name.  If you want to not display any refs of a
   4316      certain type, then you should remove the appropriate function from
   4317      ‘magit-refs-sections-hook’ instead.
   4318 
   4319      This alist controls which tags and branches are omitted from being
   4320      displayed in ‘magit-refs-mode’ buffers.  If it is ‘nil’, then all
   4321      refs are displayed (subject to ‘magit-refs-sections-hook’).
   4322 
   4323      All keys are tried in order until one matches.  Then its value is
   4324      used and subsequent elements are ignored.  If the value is non-nil,
   4325      then the reference is displayed, otherwise it is not.  If no
   4326      element matches, then the reference is displayed.
   4327 
   4328      A key can either be a regular expression that the refname has to
   4329      match, or a function that takes the refname as only argument and
   4330      returns a boolean.  A remote branch such as "origin/master" is
   4331      displayed as just "master", however for this comparison the former
   4332      is used.
   4333 
   4334 ‘RET’     (‘magit-visit-ref’)
   4335 
   4336      This command visits the reference or revision at point in another
   4337      buffer.  If there is no revision at point or with a prefix argument
   4338      then it prompts for a revision.
   4339 
   4340      This command behaves just like ‘magit-show-commit’ as described
   4341      above, except if point is on a reference in a ‘magit-refs-mode’
   4342      buffer, in which case the behavior may be different, but only if
   4343      you have customized the option ‘magit-visit-ref-behavior’.
   4344 
   4345  -- User Option: magit-visit-ref-behavior
   4346 
   4347      This option controls how ‘magit-visit-ref’ behaves in
   4348      ‘magit-refs-mode’ buffers.
   4349 
   4350      By default ‘magit-visit-ref’ behaves like ‘magit-show-commit’, in
   4351      all buffers, including ‘magit-refs-mode’ buffers.  When the type of
   4352      the section at point is ‘commit’ then "RET" is bound to
   4353      ‘magit-show-commit’, and when the type is either ‘branch’ or ‘tag’
   4354      then it is bound to ‘magit-visit-ref’.
   4355 
   4356      "RET" is one of Magit’s most essential keys and at least by default
   4357      it should behave consistently across all of Magit, especially
   4358      because users quickly learn that it does something very harmless;
   4359      it shows more information about the thing at point in another
   4360      buffer.
   4361 
   4362      However "RET" used to behave differently in ‘magit-refs-mode’
   4363      buffers, doing surprising things, some of which cannot really be
   4364      described as "visit this thing".  If you’ve grown accustomed this
   4365      behavior, you can restore it by adding one or more of the below
   4366      symbols to the value of this option.  But keep in mind that by
   4367      doing so you don’t only introduce inconsistencies, you also lose
   4368      some functionality and might have to resort to ‘M-x
   4369      magit-show-commit’ to get it back.
   4370 
   4371      ‘magit-visit-ref’ looks for these symbols in the order in which
   4372      they are described here.  If the presence of a symbol applies to
   4373      the current situation, then the symbols that follow do not affect
   4374      the outcome.
   4375 
   4376         • ‘focus-on-ref’
   4377 
   4378           With a prefix argument update the buffer to show commit counts
   4379           and lists of cherry commits relative to the reference at point
   4380           instead of relative to the current buffer or ‘HEAD’.
   4381 
   4382           Instead of adding this symbol, consider pressing "C-u y o
   4383           RET".
   4384 
   4385         • ‘create-branch’
   4386 
   4387           If point is on a remote branch, then create a new local branch
   4388           with the same name, use the remote branch as its upstream, and
   4389           then check out the local branch.
   4390 
   4391           Instead of adding this symbol, consider pressing "b c RET
   4392           RET", like you would do in other buffers.
   4393 
   4394         • ‘checkout-any’
   4395 
   4396           Check out the reference at point.  If that reference is a tag
   4397           or a remote branch, then this results in a detached ‘HEAD’.
   4398 
   4399           Instead of adding this symbol, consider pressing "b b RET",
   4400           like you would do in other buffers.
   4401 
   4402         • ‘checkout-branch’
   4403 
   4404           Check out the local branch at point.
   4405 
   4406           Instead of adding this symbol, consider pressing "b b RET",
   4407           like you would do in other buffers.
   4408 
   4409 * Menu:
   4410 
   4411 * References Sections::
   4412 
   4413 
   4414 File: magit.info,  Node: References Sections,  Up: References Buffer
   4415 
   4416 5.6.1 References Sections
   4417 -------------------------
   4418 
   4419 The contents of references buffers is controlled using the hook
   4420 ‘magit-refs-sections-hook’.  See *note Section Hooks:: to learn about
   4421 such hooks and how to customize them.  All of the below functions are
   4422 members of the default value.  Note that it makes much less sense to
   4423 customize this hook than it does for the respective hook used for the
   4424 status buffer.
   4425 
   4426  -- User Option: magit-refs-sections-hook
   4427 
   4428      Hook run to insert sections into a references buffer.
   4429 
   4430  -- Function: magit-insert-local-branches
   4431 
   4432      Insert sections showing all local branches.
   4433 
   4434  -- Function: magit-insert-remote-branches
   4435 
   4436      Insert sections showing all remote-tracking branches.
   4437 
   4438  -- Function: magit-insert-tags
   4439 
   4440      Insert sections showing all tags.
   4441 
   4442 
   4443 File: magit.info,  Node: Bisecting,  Next: Visiting Files and Blobs,  Prev: References Buffer,  Up: Inspecting
   4444 
   4445 5.7 Bisecting
   4446 =============
   4447 
   4448 Also see *note (gitman)git-bisect::.
   4449 
   4450 ‘B’     (‘magit-bisect’)
   4451 
   4452      This transient prefix command binds the following suffix commands
   4453      and displays them in a temporary buffer until a suffix is invoked.
   4454 
   4455    When bisecting is not in progress, then the transient features the
   4456 following suffix commands.
   4457 
   4458 ‘B B’     (‘magit-bisect-start’)
   4459 
   4460      Start a bisect session.
   4461 
   4462      Bisecting a bug means to find the commit that introduced it.  This
   4463      command starts such a bisect session by asking for a known good
   4464      commit and a known bad commit.  If you’re bisecting a change that
   4465      isn’t a regression, you can select alternate terms that are
   4466      conceptually more fitting than "bad" and "good", but the infix
   4467      arguments to do so are disabled by default.
   4468 
   4469 ‘B s’     (‘magit-bisect-run’)
   4470 
   4471      Bisect automatically by running commands after each step.
   4472 
   4473    When bisecting in progress, then the transient instead features the
   4474 following suffix commands.
   4475 
   4476 ‘B b’     (‘magit-bisect-bad’)
   4477 
   4478      Mark the current commit as bad.  Use this after you have asserted
   4479      that the commit does contain the bug in question.
   4480 
   4481 ‘B g’     (‘magit-bisect-good’)
   4482 
   4483      Mark the current commit as good.  Use this after you have asserted
   4484      that the commit does not contain the bug in question.
   4485 
   4486 ‘B m’     (‘magit-bisect-mark’)
   4487 
   4488      Mark the current commit with one of the bisect terms.  This command
   4489      provides an alternative to ‘magit-bisect-bad’ and
   4490      ‘magit-bisect-good’ and is useful when using terms other than "bad"
   4491      and "good".  This suffix is disabled by default.
   4492 
   4493 ‘B k’     (‘magit-bisect-skip’)
   4494 
   4495      Skip the current commit.  Use this if for some reason the current
   4496      commit is not a good one to test.  This command lets Git choose a
   4497      different one.
   4498 
   4499 ‘B r’     (‘magit-bisect-reset’)
   4500 
   4501      After bisecting, cleanup bisection state and return to original
   4502      ‘HEAD’.
   4503 
   4504    By default the status buffer shows information about the ongoing
   4505 bisect session.
   4506 
   4507  -- User Option: magit-bisect-show-graph
   4508 
   4509      This option controls whether a graph is displayed for the log of
   4510      commits that still have to be bisected.
   4511 
   4512 
   4513 File: magit.info,  Node: Visiting Files and Blobs,  Next: Blaming,  Prev: Bisecting,  Up: Inspecting
   4514 
   4515 5.8 Visiting Files and Blobs
   4516 ============================
   4517 
   4518 Magit provides several commands that visit a file or blob (the version
   4519 of a file that is stored in a certain commit).  Actually it provides
   4520 several *groups* of such commands and the several *variants* within each
   4521 group.
   4522 
   4523 * Menu:
   4524 
   4525 * General-Purpose Visit Commands::
   4526 * Visiting Files and Blobs from a Diff::
   4527 
   4528 
   4529 File: magit.info,  Node: General-Purpose Visit Commands,  Next: Visiting Files and Blobs from a Diff,  Up: Visiting Files and Blobs
   4530 
   4531 5.8.1 General-Purpose Visit Commands
   4532 ------------------------------------
   4533 
   4534 These commands can be used anywhere to open any blob.  Currently no keys
   4535 are bound to these commands by default, but that is likely to change.
   4536 
   4537  -- Command: magit-find-file
   4538 
   4539      This command reads a filename and revision from the user and visits
   4540      the respective blob in a buffer.  The buffer is displayed in the
   4541      selected window.
   4542 
   4543  -- Command: magit-find-file-other-window
   4544 
   4545      This command reads a filename and revision from the user and visits
   4546      the respective blob in a buffer.  The buffer is displayed in
   4547      another window.
   4548 
   4549  -- Command: magit-find-file-other-frame
   4550 
   4551      This command reads a filename and revision from the user and visits
   4552      the respective blob in a buffer.  The buffer is displayed in
   4553      another frame.
   4554 
   4555 
   4556 File: magit.info,  Node: Visiting Files and Blobs from a Diff,  Prev: General-Purpose Visit Commands,  Up: Visiting Files and Blobs
   4557 
   4558 5.8.2 Visiting Files and Blobs from a Diff
   4559 ------------------------------------------
   4560 
   4561 These commands can only be used when point is inside a diff.
   4562 
   4563 ‘RET’     (‘magit-diff-visit-file’)
   4564 
   4565      This command visits the appropriate version of the file that the
   4566      diff at point is about.
   4567 
   4568      This commands visits the worktree version of the appropriate file.
   4569      The location of point inside the diff determines which file is
   4570      being visited.  The visited version depends on what changes the
   4571      diff is about.
   4572 
   4573         • If the diff shows uncommitted changes (i.e.  staged or
   4574           unstaged changes), then visit the file in the working tree
   4575           (i.e.  the same "real" file that ‘find-file’ would visit.  In
   4576           all other cases visit a "blob" (i.e.  the version of a file as
   4577           stored in some commit).
   4578 
   4579         • If point is on a removed line, then visit the blob for the
   4580           first parent of the commit that removed that line, i.e.  the
   4581           last commit where that line still exists.
   4582 
   4583         • If point is on an added or context line, then visit the blob
   4584           that adds that line, or if the diff shows from more than a
   4585           single commit, then visit the blob from the last of these
   4586           commits.
   4587 
   4588      In the file-visiting buffer this command goes to the line that
   4589      corresponds to the line that point is on in the diff.
   4590 
   4591      The buffer is displayed in the selected window.  With a prefix
   4592      argument the buffer is displayed in another window instead.
   4593 
   4594  -- User Option: magit-diff-visit-previous-blob
   4595 
   4596      This option controls whether ‘magit-diff-visit-file’ may visit the
   4597      previous blob.  When this is ‘t’ (the default) and point is on a
   4598      removed line in a diff for a committed change, then
   4599      ‘magit-diff-visit-file’ visits the blob from the last revision
   4600      which still had that line.
   4601 
   4602      Currently this is only supported for committed changes, for staged
   4603      and unstaged changes ‘magit-diff-visit-file’ always visits the file
   4604      in the working tree.
   4605 
   4606 ‘C-<return>’     (‘magit-diff-visit-file-worktree’)
   4607 
   4608      This command visits the worktree version of the appropriate file.
   4609      The location of point inside the diff determines which file is
   4610      being visited.  Unlike ‘magit-diff-visit-file’ it always visits the
   4611      "real" file in the working tree, i.e the "current version" of the
   4612      file.
   4613 
   4614      In the file-visiting buffer this command goes to the line that
   4615      corresponds to the line that point is on in the diff.  Lines that
   4616      were added or removed in the working tree, the index and other
   4617      commits in between are automatically accounted for.
   4618 
   4619      The buffer is displayed in the selected window.  With a prefix
   4620      argument the buffer is displayed in another window instead.
   4621 
   4622    Variants of the above two commands exist that instead visit the file
   4623 in another window or in another frame.  If you prefer such behavior,
   4624 then you may want to change the above key bindings, but note that the
   4625 above commands also use another window when invoked with a prefix
   4626 argument.
   4627 
   4628  -- Command: magit-diff-visit-file-other-window
   4629  -- Command: magit-diff-visit-file-other-frame
   4630  -- Command: magit-diff-visit-worktree-file-other-window
   4631  -- Command: magit-diff-visit-worktree-file-other-frame
   4632 
   4633 
   4634 File: magit.info,  Node: Blaming,  Prev: Visiting Files and Blobs,  Up: Inspecting
   4635 
   4636 5.9 Blaming
   4637 ===========
   4638 
   4639 Also see *note (gitman)git-blame::.
   4640 
   4641    To start blaming invoke the ‘magit-file-dispatch’ transient prefix
   4642 command by pressing ‘C-c M-g’.
   4643 
   4644    The blaming suffix commands can be invoked from the dispatch
   4645 transient.  However if you want to set an infix argument, then you have
   4646 to enter the blaming sub-transient first.
   4647 
   4648    The key bindings shown below assume that you enter the dispatch
   4649 transient using the default binding.
   4650 
   4651 ‘C-c M-g B’     (‘magit-blame’)
   4652 
   4653      This transient prefix command binds the following suffix commands
   4654      along with the appropriate infix arguments and displays them in a
   4655      temporary buffer until a suffix is invoked.
   4656 
   4657    Note that not all of the following suffixes are available at all
   4658 times.  For example if ‘magit-blame-mode’ is not enabled, then the
   4659 command whose purpose is to turn off that mode would not be of any use
   4660 and therefore isn’t available.
   4661 
   4662 ‘C-c M-g b’     (‘magit-blame-addition’)
   4663 ‘C-c M-g B b’     (‘magit-blame-addition’)
   4664 
   4665      This command augments each line or chunk of lines in the current
   4666      file-visiting or blob-visiting buffer with information about what
   4667      commits last touched these lines.
   4668 
   4669      If the buffer visits a revision of that file, then history up to
   4670      that revision is considered.  Otherwise, the file’s full history is
   4671      considered, including uncommitted changes.
   4672 
   4673      If Magit-Blame mode is already turned on in the current buffer then
   4674      blaming is done recursively, by visiting REVISION:FILE (using
   4675      ‘magit-find-file’), where REVISION is a parent of the revision that
   4676      added the current line or chunk of lines.
   4677 
   4678 ‘C-c M-g r’     (‘magit-blame-removal’)
   4679 ‘C-c M-g B r’     (‘magit-blame-removal’)
   4680 
   4681      This command augments each line or chunk of lines in the current
   4682      blob-visiting buffer with information about the revision that
   4683      removes it.  It cannot be used in file-visiting buffers.
   4684 
   4685      Like ‘magit-blame-addition’, this command can be used recursively.
   4686 
   4687 ‘C-c M-g f’     (‘magit-blame-reverse’)
   4688 ‘C-c M-g B f’     (‘magit-blame-reverse’)
   4689 
   4690      This command augments each line or chunk of lines in the current
   4691      file-visiting or blob-visiting buffer with information about the
   4692      last revision in which a line still existed.
   4693 
   4694      Like ‘magit-blame-addition’, this command can be used recursively.
   4695 
   4696 ‘C-c M-g e’     (‘magit-blame-echo’)
   4697 ‘C-c M-g B e’     (‘magit-blame-echo’)
   4698 
   4699      This command is like ‘magit-blame-addition’ except that it doesn’t
   4700      turn on ‘read-only-mode’ and that it initially uses the
   4701      visualization style specified by option ‘magit-blame-echo-style’.
   4702 
   4703    The following key bindings are available when Magit-Blame mode is
   4704 enabled and Read-Only mode is not enabled.  These commands are also
   4705 available in other buffers; here only the behavior is described that is
   4706 relevant in file-visiting buffers that are being blamed.
   4707 
   4708 ‘RET’     (‘magit-show-commit’)
   4709 
   4710      This command shows the commit that last touched the line at point.
   4711 
   4712 ‘SPC’     (‘magit-diff-show-or-scroll-up’)
   4713 
   4714      This command updates the commit buffer.
   4715 
   4716      This either shows the commit that last touched the line at point in
   4717      the appropriate buffer, or if that buffer is already being
   4718      displayed in the current frame and if that buffer contains
   4719      information about that commit, then the buffer is scrolled up
   4720      instead.
   4721 
   4722 ‘DEL’     (‘magit-diff-show-or-scroll-down’)
   4723 
   4724      This command updates the commit buffer.
   4725 
   4726      This either shows the commit that last touched the line at point in
   4727      the appropriate buffer, or if that buffer is already being
   4728      displayed in the current frame and if that buffer contains
   4729      information about that commit, then the buffer is scrolled down
   4730      instead.
   4731 
   4732    The following key bindings are available when both Magit-Blame mode
   4733 and Read-Only mode are enabled.
   4734 
   4735 ‘b’     (‘magit-blame’)
   4736 
   4737      See above.
   4738 
   4739 ‘n’     (‘magit-blame-next-chunk’)
   4740 
   4741      This command moves to the next chunk.
   4742 
   4743 ‘N’     (‘magit-blame-next-chunk-same-commit’)
   4744 
   4745      This command moves to the next chunk from the same commit.
   4746 
   4747 ‘p’     (‘magit-blame-previous-chunk’)
   4748 
   4749      This command moves to the previous chunk.
   4750 
   4751 ‘P’     (‘magit-blame-previous-chunk-same-commit’)
   4752 
   4753      This command moves to the previous chunk from the same commit.
   4754 
   4755 ‘q’     (‘magit-blame-quit’)
   4756 
   4757      This command turns off Magit-Blame mode.  If the buffer was created
   4758      during a recursive blame, then it also kills the buffer.
   4759 
   4760 ‘M-w’     (‘magit-blame-copy-hash’)
   4761 
   4762      This command saves the hash of the current chunk’s commit to the
   4763      kill ring.
   4764 
   4765      When the region is active, the command saves the region’s content
   4766      instead of the hash, like ‘kill-ring-save’ would.
   4767 
   4768 ‘c’     (‘magit-blame-cycle-style’)
   4769 
   4770      This command changes how blame information is visualized in the
   4771      current buffer by cycling through the styles specified using the
   4772      option ‘magit-blame-styles’.
   4773 
   4774    Blaming is also controlled using the following options.
   4775 
   4776  -- User Option: magit-blame-styles
   4777 
   4778      This option defines a list of styles used to visualize blame
   4779      information.  For now see its doc-string to learn more.
   4780 
   4781  -- User Option: magit-blame-echo-style
   4782 
   4783      This option specifies the blame visualization style used by the
   4784      command ‘magit-blame-echo’.  This must be a symbol that is used as
   4785      the identifier for one of the styles defined in
   4786      ‘magit-blame-styles’.
   4787 
   4788  -- User Option: magit-blame-time-format
   4789 
   4790      This option specifies the format string used to display times when
   4791      showing blame information.
   4792 
   4793  -- User Option: magit-blame-read-only
   4794 
   4795      This option controls whether blaming a buffer also makes
   4796      temporarily read-only.
   4797 
   4798  -- User Option: magit-blame-disable-modes
   4799 
   4800      This option lists incompatible minor-modes that should be disabled
   4801      temporarily when a buffer contains blame information.  They are
   4802      enabled again when the buffer no longer shows blame information.
   4803 
   4804  -- User Option: magit-blame-goto-chunk-hook
   4805 
   4806      This hook is run when moving between chunks.
   4807 
   4808 
   4809 File: magit.info,  Node: Manipulating,  Next: Transferring,  Prev: Inspecting,  Up: Top
   4810 
   4811 6 Manipulating
   4812 **************
   4813 
   4814 * Menu:
   4815 
   4816 * Creating Repository::
   4817 * Cloning Repository::
   4818 * Staging and Unstaging::
   4819 * Applying::
   4820 * Committing::
   4821 * Branching::
   4822 * Merging::
   4823 * Resolving Conflicts::
   4824 * Rebasing::
   4825 * Cherry Picking::
   4826 * Resetting::
   4827 * Stashing::
   4828 
   4829 
   4830 File: magit.info,  Node: Creating Repository,  Next: Cloning Repository,  Up: Manipulating
   4831 
   4832 6.1 Creating Repository
   4833 =======================
   4834 
   4835 ‘I’     (‘magit-init’)
   4836 
   4837      This command initializes a repository and then shows the status
   4838      buffer for the new repository.
   4839 
   4840      If the directory is below an existing repository, then the user has
   4841      to confirm that a new one should be created inside.  If the
   4842      directory is the root of the existing repository, then the user has
   4843      to confirm that it should be reinitialized.
   4844 
   4845 
   4846 File: magit.info,  Node: Cloning Repository,  Next: Staging and Unstaging,  Prev: Creating Repository,  Up: Manipulating
   4847 
   4848 6.2 Cloning Repository
   4849 ======================
   4850 
   4851 To clone a remote or local repository use ‘C’, which is bound to the
   4852 command ‘magit-clone’.  This command either act as a transient prefix
   4853 command, which binds several infix arguments and suffix commands, or it
   4854 can invoke ‘git clone’ directly, depending on whether a prefix argument
   4855 is used and on the value of ‘magit-clone-always-transient’.
   4856 
   4857  -- User Option: magit-clone-always-transient
   4858 
   4859      This option controls whether the command ‘magit-clone’ always acts
   4860      as a transient prefix command, regardless of whether a prefix
   4861      argument is used or not.  If ‘t’, then that command always acts as
   4862      a transient prefix.  If ‘nil’, then a prefix argument has to be
   4863      used for it to act as a transient.
   4864 
   4865 ‘C’     (‘magit-clone’)
   4866 
   4867      This command either acts as a transient prefix command as described
   4868      above or does the same thing as ‘transient-clone-regular’ as
   4869      described below.
   4870 
   4871      If it acts as a transient prefix, then it binds the following
   4872      suffix commands and several infix arguments.
   4873 
   4874 ‘C C’     (‘magit-clone-regular’)
   4875 
   4876      This command creates a regular clone of an existing repository.
   4877      The repository and the target directory are read from the user.
   4878 
   4879 ‘C s’     (‘magit-clone-shallow’)
   4880 
   4881      This command creates a shallow clone of an existing repository.
   4882      The repository and the target directory are read from the user.  By
   4883      default the depth of the cloned history is a single commit, but
   4884      with a prefix argument the depth is read from the user.
   4885 
   4886 ‘C b’     (‘magit-clone-bare’)
   4887 
   4888      This command creates a bare clone of an existing repository.  The
   4889      repository and the target directory are read from the user.
   4890 
   4891 ‘C m’     (‘magit-clone-mirror’)
   4892 
   4893      This command creates a mirror of an existing repository.  The
   4894      repository and the target directory are read from the user.
   4895 
   4896    The following suffixes are disabled by default.  See *note
   4897 (transient)Enabling and Disabling Suffixes:: for how to enable them.
   4898 
   4899 ‘C d’     (‘magit-clone-shallow-since’)
   4900 
   4901      This command creates a shallow clone of an existing repository.
   4902      Only commits that were committed after a date are cloned, which is
   4903      read from the user.  The repository and the target directory are
   4904      also read from the user.
   4905 
   4906 ‘C e’     (‘magit-clone-shallow-exclude’)
   4907 
   4908      This command creates a shallow clone of an existing repository.
   4909      This reads a branch or tag from the user.  Commits that are
   4910      reachable from that are not cloned.  The repository and the target
   4911      directory are also read from the user.
   4912 
   4913  -- User Option: magit-clone-set-remote-head
   4914 
   4915      This option controls whether cloning causes the reference
   4916      ‘refs/remotes/<remote>/HEAD’ to be created in the clone.  The
   4917      default is to delete the reference after running ‘git clone’, which
   4918      insists on creating it.  This is because the reference has not been
   4919      found to be particularly useful as it is not automatically updated
   4920      when the ‘HEAD’ of the remote changes.  Setting this option to ‘t’
   4921      preserves Git’s default behavior of creating the reference.
   4922 
   4923  -- User Option: magit-clone-set-remote.pushDefault
   4924 
   4925      This option controls whether the value of the Git variable
   4926      ‘remote.pushDefault’ is set after cloning.
   4927 
   4928         • If ‘t’, then it is always set without asking.
   4929 
   4930         • If ‘ask’, then the users are asked every time they clone a
   4931           repository.
   4932 
   4933         • If ‘nil’, then it is never set.
   4934 
   4935  -- User Option: magit-clone-default-directory
   4936 
   4937      This option control the default directory name used when reading
   4938      the destination for a cloning operation.
   4939 
   4940         • If ‘nil’ (the default), then the value of ‘default-directory’
   4941           is used.
   4942 
   4943         • If a directory, then that is used.
   4944 
   4945         • If a function, then that is called with the remote url as the
   4946           only argument and the returned value is used.
   4947 
   4948  -- User Option: magit-clone-name-alist
   4949 
   4950      This option maps regular expressions, which match repository names,
   4951      to repository urls, making it possible for users to enter short
   4952      names instead of urls when cloning repositories.
   4953 
   4954      Each element has the form ‘(REGEXP HOSTNAME USER)’.  When the user
   4955      enters a name when a cloning command asks for a name or url, then
   4956      that is looked up in this list.  The first element whose REGEXP
   4957      matches is used.
   4958 
   4959      The format specified by option ‘magit-clone-url-format’ is used to
   4960      turn the name into an url, using HOSTNAME and the repository name.
   4961      If the provided name contains a slash, then that is used.
   4962      Otherwise if the name omits the owner of the repository, then the
   4963      default user specified in the matched entry is used.
   4964 
   4965      If USER contains a dot, then it is treated as a Git variable and
   4966      the value of that is used as the username.  Otherwise it is used as
   4967      the username itself.
   4968 
   4969  -- User Option: magit-clone-url-format
   4970 
   4971      The format specified by this option is used when turning repository
   4972      names into urls.  ‘%h’ is the hostname and ‘%n’ is the repository
   4973      name, including the name of the owner.
   4974 
   4975 
   4976 File: magit.info,  Node: Staging and Unstaging,  Next: Applying,  Prev: Cloning Repository,  Up: Manipulating
   4977 
   4978 6.3 Staging and Unstaging
   4979 =========================
   4980 
   4981 Like Git, Magit can of course stage and unstage complete files.  Unlike
   4982 Git, it also allows users to gracefully un-/stage individual hunks and
   4983 even just part of a hunk.  To stage individual hunks and parts of hunks
   4984 using Git directly, one has to use the very modal and rather clumsy
   4985 interface of a ‘git add --interactive’ session.
   4986 
   4987    With Magit, on the other hand, one can un-/stage individual hunks by
   4988 just moving point into the respective section inside a diff displayed in
   4989 the status buffer or a separate diff buffer and typing ‘s’ or ‘u’.  To
   4990 operate on just parts of a hunk, mark the changes that should be
   4991 un-/staged using the region and then press the same key that would be
   4992 used to un-/stage.  To stage multiple files or hunks at once use a
   4993 region that starts inside the heading of such a section and ends inside
   4994 the heading of a sibling section of the same type.
   4995 
   4996    Besides staging and unstaging, Magit also provides several other
   4997 "apply variants" that can also operate on a file, multiple files at
   4998 once, a hunk, multiple hunks at once, and on parts of a hunk.  These
   4999 apply variants are described in the next section.
   5000 
   5001    You can also use Ediff to stage and unstage.  See *note Ediffing::.
   5002 
   5003 ‘s’     (‘magit-stage’)
   5004 
   5005      Add the change at point to the staging area.
   5006 
   5007      With a prefix argument and an untracked file (or files) at point,
   5008      stage the file but not its content.  This makes it possible to
   5009      stage only a subset of the new file’s changes.
   5010 
   5011 ‘S’     (‘magit-stage-modified’)
   5012 
   5013      Stage all changes to files modified in the worktree.  Stage all new
   5014      content of tracked files and remove tracked files that no longer
   5015      exist in the working tree from the index also.  With a prefix
   5016      argument also stage previously untracked (but not ignored) files.
   5017 
   5018 ‘u’     (‘magit-unstage’)
   5019 
   5020      Remove the change at point from the staging area.
   5021 
   5022      Only staged changes can be unstaged.  But by default this command
   5023      performs an action that is somewhat similar to unstaging, when it
   5024      is called on a committed change: it reverses the change in the
   5025      index but not in the working tree.
   5026 
   5027 ‘U’     (‘magit-unstage-all’)
   5028 
   5029      Remove all changes from the staging area.
   5030 
   5031  -- User Option: magit-unstage-committed
   5032 
   5033      This option controls whether ‘magit-unstage’ "unstages" committed
   5034      changes by reversing them in the index but not the working tree.
   5035      The alternative is to raise an error.
   5036 
   5037 ‘M-x magit-reverse-in-index’     (‘magit-reverse-in-index’)
   5038 
   5039      This command reverses the committed change at point in the index
   5040      but not the working tree.  By default no key is bound directly to
   5041      this command, but it is indirectly called when ‘u’
   5042      (‘magit-unstage’) is pressed on a committed change.
   5043 
   5044      This allows extracting a change from ‘HEAD’, while leaving it in
   5045      the working tree, so that it can later be committed using a
   5046      separate commit.  A typical workflow would be:
   5047 
   5048         • Optionally make sure that there are no uncommitted changes.
   5049 
   5050         • Visit the ‘HEAD’ commit and navigate to the change that should
   5051           not have been included in that commit.
   5052 
   5053         • Type ‘u’ (‘magit-unstage’) to reverse it in the index.  This
   5054           assumes that ‘magit-unstage-committed-changes’ is non-nil.
   5055 
   5056         • Type ‘c e’ to extend ‘HEAD’ with the staged changes, including
   5057           those that were already staged before.
   5058 
   5059         • Optionally stage the remaining changes using ‘s’ or ‘S’ and
   5060           then type ‘c c’ to create a new commit.
   5061 
   5062 ‘M-x magit-reset-index’     (‘magit-reset-index’)
   5063 
   5064      Reset the index to some commit.  The commit is read from the user
   5065      and defaults to the commit at point.  If there is no commit at
   5066      point, then it defaults to ‘HEAD’.
   5067 
   5068 * Menu:
   5069 
   5070 * Staging from File-Visiting Buffers::
   5071 
   5072 
   5073 File: magit.info,  Node: Staging from File-Visiting Buffers,  Up: Staging and Unstaging
   5074 
   5075 6.3.1 Staging from File-Visiting Buffers
   5076 ----------------------------------------
   5077 
   5078 Fine-grained un-/staging has to be done from the status or a diff
   5079 buffer, but it’s also possible to un-/stage all changes made to the file
   5080 visited in the current buffer right from inside that buffer.
   5081 
   5082 ‘M-x magit-stage-file’     (‘magit-stage-file’)
   5083 
   5084      When invoked inside a file-visiting buffer, then stage all changes
   5085      to that file.  In a Magit buffer, stage the file at point if any.
   5086      Otherwise prompt for a file to be staged.  With a prefix argument
   5087      always prompt the user for a file, even in a file-visiting buffer
   5088      or when there is a file section at point.
   5089 
   5090 ‘M-x magit-unstage-file’     (‘magit-unstage-file’)
   5091 
   5092      When invoked inside a file-visiting buffer, then unstage all
   5093      changes to that file.  In a Magit buffer, unstage the file at point
   5094      if any.  Otherwise prompt for a file to be unstaged.  With a prefix
   5095      argument always prompt the user for a file, even in a file-visiting
   5096      buffer or when there is a file section at point.
   5097 
   5098 
   5099 File: magit.info,  Node: Applying,  Next: Committing,  Prev: Staging and Unstaging,  Up: Manipulating
   5100 
   5101 6.4 Applying
   5102 ============
   5103 
   5104 Magit provides several "apply variants": stage, unstage, discard,
   5105 reverse, and "regular apply".  At least when operating on a hunk they
   5106 are all implemented using ‘git apply’, which is why they are called
   5107 "apply variants".
   5108 
   5109    • Stage.  Apply a change from the working tree to the index.  The
   5110      change also remains in the working tree.
   5111 
   5112    • Unstage.  Remove a change from the index.  The change remains in
   5113      the working tree.
   5114 
   5115    • Discard.  On a staged change, remove it from the working tree and
   5116      the index.  On an unstaged change, remove it from the working tree
   5117      only.
   5118 
   5119    • Reverse.  Reverse a change in the working tree.  Both committed and
   5120      staged changes can be reversed.  Unstaged changes cannot be
   5121      reversed.  Discard them instead.
   5122 
   5123    • Apply.  Apply a change to the working tree.  Both committed and
   5124      staged changes can be applied.  Unstaged changes cannot be applied
   5125      - as they already have been applied.
   5126 
   5127    The previous section described the staging and unstaging commands.
   5128 What follows are the commands which implement the remaining apply
   5129 variants.
   5130 
   5131 ‘a’     (‘magit-apply’)
   5132 
   5133      Apply the change at point to the working tree.
   5134 
   5135      With a prefix argument fallback to a 3-way merge.  Doing so causes
   5136      the change to be applied to the index as well.
   5137 
   5138 ‘k’     (‘magit-discard’)
   5139 
   5140      Remove the change at point from the working tree.
   5141 
   5142      On a hunk or file with unresolved conflicts prompt which side to
   5143      keep (while discarding the other).  If point is within the text of
   5144      a side, then keep that side without prompting.
   5145 
   5146 ‘v’     (‘magit-reverse’)
   5147 
   5148      Reverse the change at point in the working tree.
   5149 
   5150      With a prefix argument fallback to a 3-way merge.  Doing so causes
   5151      the change to be applied to the index as well.
   5152 
   5153    With a prefix argument all apply variants attempt a 3-way merge when
   5154 appropriate (i.e.  when ‘git apply’ is used internally).
   5155 
   5156 
   5157 File: magit.info,  Node: Committing,  Next: Branching,  Prev: Applying,  Up: Manipulating
   5158 
   5159 6.5 Committing
   5160 ==============
   5161 
   5162 When the user initiates a commit, Magit calls ‘git commit’ without any
   5163 arguments, so Git has to get it from the user.  It creates the file
   5164 ‘.git/COMMIT_EDITMSG’ and then opens that file in an editor.  Magit
   5165 arranges for that editor to be the Emacsclient.  Once the user finishes
   5166 the editing session, the Emacsclient exits and Git creates the commit
   5167 using the file’s content as message.
   5168 
   5169 * Menu:
   5170 
   5171 * Initiating a Commit::
   5172 * Editing Commit Messages::
   5173 
   5174 
   5175 File: magit.info,  Node: Initiating a Commit,  Next: Editing Commit Messages,  Up: Committing
   5176 
   5177 6.5.1 Initiating a Commit
   5178 -------------------------
   5179 
   5180 Also see *note (gitman)git-commit::.
   5181 
   5182 ‘c’     (‘magit-commit’)
   5183 
   5184      This transient prefix command binds the following suffix commands
   5185      along with the appropriate infix arguments and displays them in a
   5186      temporary buffer until a suffix is invoked.
   5187 
   5188 ‘c c’     (‘magit-commit-create’)
   5189 
   5190      Create a new commit on ‘HEAD’.  With a prefix argument amend to the
   5191      commit at ‘HEAD’ instead.
   5192 
   5193 ‘c a’     (‘magit-commit-amend’)
   5194 
   5195      Amend the last commit.
   5196 
   5197 ‘c e’     (‘magit-commit-extend’)
   5198 
   5199      Amend the last commit, without editing the message.  With a prefix
   5200      argument keep the committer date, otherwise change it.  The option
   5201      ‘magit-commit-extend-override-date’ can be used to inverse the
   5202      meaning of the prefix argument.
   5203 
   5204      Non-interactively respect the optional OVERRIDE-DATE argument and
   5205      ignore the option.
   5206 
   5207 ‘c w’     (‘magit-commit-reword’)
   5208 
   5209      Reword the last commit, ignoring staged changes.  With a prefix
   5210      argument keep the committer date, otherwise change it.  The option
   5211      ‘magit-commit-reword-override-date’ can be used to inverse the
   5212      meaning of the prefix argument.
   5213 
   5214      Non-interactively respect the optional OVERRIDE-DATE argument and
   5215      ignore the option.
   5216 
   5217 ‘c f’     (‘magit-commit-fixup’)
   5218 
   5219      Create a fixup commit.
   5220 
   5221      With a prefix argument the target commit has to be confirmed.
   5222      Otherwise the commit at point may be used without confirmation
   5223      depending on the value of option ‘magit-commit-squash-confirm’.
   5224 
   5225 ‘c F’     (‘magit-commit-instant-fixup’)
   5226 
   5227      Create a fixup commit and instantly rebase.
   5228 
   5229 ‘c s’     (‘magit-commit-squash’)
   5230 
   5231      Create a squash commit, without editing the squash message.
   5232 
   5233      With a prefix argument the target commit has to be confirmed.
   5234      Otherwise the commit at point may be used without confirmation
   5235      depending on the value of option ‘magit-commit-squash-confirm’.
   5236 
   5237 ‘c S’     (‘magit-commit-instant-squash’)
   5238 
   5239      Create a squash commit and instantly rebase.
   5240 
   5241 ‘c A’     (‘magit-commit-augment’)
   5242 
   5243      Create a squash commit, editing the squash message.
   5244 
   5245      With a prefix argument the target commit has to be confirmed.
   5246      Otherwise the commit at point may be used without confirmation
   5247      depending on the value of option ‘magit-commit-squash-confirm’.
   5248 
   5249  -- User Option: magit-commit-ask-to-stage
   5250 
   5251      Whether to ask to stage all unstaged changes when committing and
   5252      nothing is staged.
   5253 
   5254  -- User Option: magit-commit-show-diff
   5255 
   5256      Whether the relevant diff is automatically shown when committing.
   5257 
   5258  -- User Option: magit-commit-extend-override-date
   5259 
   5260      Whether using ‘magit-commit-extend’ changes the committer date.
   5261 
   5262  -- User Option: magit-commit-reword-override-date
   5263 
   5264      Whether using ‘magit-commit-reword’ changes the committer date.
   5265 
   5266  -- User Option: magit-commit-squash-confirm
   5267 
   5268      Whether the commit targeted by squash and fixup has to be
   5269      confirmed.  When non-nil then the commit at point (if any) is used
   5270      as default choice.  Otherwise it has to be confirmed.  This option
   5271      only affects ‘magit-commit-squash’ and ‘magit-commit-fixup’.  The
   5272      "instant" variants always require confirmation because making an
   5273      error while using those is harder to recover from.
   5274 
   5275  -- User Option: magit-post-commit-hook
   5276 
   5277      Hook run after creating a commit without the user editing a
   5278      message.
   5279 
   5280      This hook is run by ‘magit-refresh’ if ‘this-command’ is a member
   5281      of ‘magit-post-stage-hook-commands’.  This only includes commands
   5282      named ‘magit-commit-*’ that do *not* require that the user edits
   5283      the commit message in a buffer.
   5284 
   5285      Also see ‘git-commit-post-finish-hook’.
   5286 
   5287  -- User Option: magit-commit-diff-inhibit-same-window
   5288 
   5289      Whether to inhibit use of same window when showing diff while
   5290      committing.
   5291 
   5292      When writing a commit, then a diff of the changes to be committed
   5293      is automatically shown.  The idea is that the diff is shown in a
   5294      different window of the same frame and for most users that just
   5295      works.  In other words most users can completely ignore this option
   5296      because its value doesn’t make a difference for them.
   5297 
   5298      However for users who configured Emacs to never create a new window
   5299      even when the package explicitly tries to do so, then displaying
   5300      two new buffers necessarily means that the first is immediately
   5301      replaced by the second.  In our case the message buffer is
   5302      immediately replaced by the diff buffer, which is of course highly
   5303      undesirable.
   5304 
   5305      A workaround is to suppress this user configuration in this
   5306      particular case.  Users have to explicitly opt-in by toggling this
   5307      option.  We cannot enable the workaround unconditionally because
   5308      that again causes issues for other users: if the frame is too tiny
   5309      or the relevant settings too aggressive, then the diff buffer would
   5310      end up being displayed in a new frame.
   5311 
   5312      Also see <https://github.com/magit/magit/issues/4132>.
   5313 
   5314 
   5315 File: magit.info,  Node: Editing Commit Messages,  Prev: Initiating a Commit,  Up: Committing
   5316 
   5317 6.5.2 Editing Commit Messages
   5318 -----------------------------
   5319 
   5320 After initiating a commit as described in the previous section, two new
   5321 buffers appear.  One shows the changes that are about to be committed,
   5322 while the other is used to write the message.
   5323 
   5324    Commit messages are edited in an edit session - in the background
   5325 ‘git’ is waiting for the editor, in our case ‘emacsclient’, to save the
   5326 commit message in a file (in most cases ‘.git/COMMIT_EDITMSG’) and then
   5327 return.  If the editor returns with a non-zero exit status then ‘git’
   5328 does not create the commit.  So the most important commands are those
   5329 for finishing and aborting the commit.
   5330 
   5331 ‘C-c C-c’     (‘with-editor-finish’)
   5332 
   5333      Finish the current editing session by returning with exit code 0.
   5334      Git then creates the commit using the message it finds in the file.
   5335 
   5336 ‘C-c C-k’     (‘with-editor-cancel’)
   5337 
   5338      Cancel the current editing session by returning with exit code 1.
   5339      Git then cancels the commit, but leaves the file untouched.
   5340 
   5341    In addition to being used by ‘git commit’, messages may also be
   5342 stored in a ring that persists until Emacs is closed.  By default the
   5343 message is stored at the beginning and the end of an edit session
   5344 (regardless of whether the session is finished successfully or was
   5345 canceled).  It is sometimes useful to bring back messages from that
   5346 ring.
   5347 
   5348 ‘C-c M-s’     (‘git-commit-save-message’)
   5349 
   5350      Save the current buffer content to the commit message ring.
   5351 
   5352 ‘M-p’     (‘git-commit-prev-message’)
   5353 
   5354      Cycle backward through the commit message ring, after saving the
   5355      current message to the ring.  With a numeric prefix ARG, go back
   5356      ARG comments.
   5357 
   5358 ‘M-n’     (‘git-commit-next-message’)
   5359 
   5360      Cycle forward through the commit message ring, after saving the
   5361      current message to the ring.  With a numeric prefix ARG, go back
   5362      ARG comments.
   5363 
   5364    By default the diff for the changes that are about to be committed
   5365 are automatically shown when invoking the commit.  To prevent that,
   5366 remove ‘magit-commit-diff’ from ‘server-switch-hook’.
   5367 
   5368    When amending to an existing commit it may be useful to show either
   5369 the changes that are about to be added to that commit or to show those
   5370 changes alongside those that have already been committed.
   5371 
   5372 ‘C-c C-d’     (‘magit-diff-while-committing’)
   5373 
   5374      While committing, show the changes that are about to be committed.
   5375      While amending, invoking the command again toggles between showing
   5376      just the new changes or all the changes that will be committed.
   5377 
   5378 * Menu:
   5379 
   5380 * Using the Revision Stack::
   5381 * Commit Pseudo Headers::
   5382 * Commit Mode and Hooks::
   5383 * Commit Message Conventions::
   5384 
   5385 
   5386 File: magit.info,  Node: Using the Revision Stack,  Next: Commit Pseudo Headers,  Up: Editing Commit Messages
   5387 
   5388 Using the Revision Stack
   5389 ........................
   5390 
   5391 ‘C-c C-w’     (‘magit-pop-revision-stack’)
   5392 
   5393      This command inserts a representation of a revision into the
   5394      current buffer.  It can be used inside buffers used to write commit
   5395      messages but also in other buffers such as buffers used to edit
   5396      emails or ChangeLog files.
   5397 
   5398      By default this command pops the revision which was last added to
   5399      the ‘magit-revision-stack’ and inserts it into the current buffer
   5400      according to ‘magit-pop-revision-stack-format’.  Revisions can be
   5401      put on the stack using ‘magit-copy-section-value’ and
   5402      ‘magit-copy-buffer-revision’.
   5403 
   5404      If the stack is empty or with a prefix argument it instead reads a
   5405      revision in the minibuffer.  By using the minibuffer history this
   5406      allows selecting an item which was popped earlier or to insert an
   5407      arbitrary reference or revision without first pushing it onto the
   5408      stack.
   5409 
   5410      When reading the revision from the minibuffer, then it might not be
   5411      possible to guess the correct repository.  When this command is
   5412      called inside a repository (e.g.  while composing a commit
   5413      message), then that repository is used.  Otherwise (e.g.  while
   5414      composing an email) then the repository recorded for the top
   5415      element of the stack is used (even though we insert another
   5416      revision).  If not called inside a repository and with an empty
   5417      stack, or with two prefix arguments, then read the repository in
   5418      the minibuffer too.
   5419 
   5420  -- User Option: magit-pop-revision-stack-format
   5421 
   5422      This option controls how the command ‘magit-pop-revision-stack’
   5423      inserts a revision into the current buffer.
   5424 
   5425      The entries on the stack have the format ‘(HASH TOPLEVEL)’ and this
   5426      option has the format ‘(POINT-FORMAT EOB-FORMAT INDEX-REGEXP)’, all
   5427      of which may be nil or a string (though either one of EOB-FORMAT or
   5428      POINT-FORMAT should be a string, and if INDEX-REGEXP is non-nil,
   5429      then the two formats should be too).
   5430 
   5431      First INDEX-REGEXP is used to find the previously inserted entry,
   5432      by searching backward from point.  The first submatch must match
   5433      the index number.  That number is incremented by one, and becomes
   5434      the index number of the entry to be inserted.  If you don’t want to
   5435      number the inserted revisions, then use nil for INDEX-REGEXP.
   5436 
   5437      If INDEX-REGEXP is non-nil then both POINT-FORMAT and EOB-FORMAT
   5438      should contain \"%N\", which is replaced with the number that was
   5439      determined in the previous step.
   5440 
   5441      Both formats, if non-nil and after removing %N, are then expanded
   5442      using ‘git show --format=FORMAT ...’ inside TOPLEVEL.
   5443 
   5444      The expansion of POINT-FORMAT is inserted at point, and the
   5445      expansion of EOB-FORMAT is inserted at the end of the buffer (if
   5446      the buffer ends with a comment, then it is inserted right before
   5447      that).
   5448 
   5449 
   5450 File: magit.info,  Node: Commit Pseudo Headers,  Next: Commit Mode and Hooks,  Prev: Using the Revision Stack,  Up: Editing Commit Messages
   5451 
   5452 Commit Pseudo Headers
   5453 .....................
   5454 
   5455 Some projects use pseudo headers in commit messages.  Magit colorizes
   5456 such headers and provides some commands to insert such headers.
   5457 
   5458  -- User Option: git-commit-known-pseudo-headers
   5459 
   5460      A list of Git pseudo headers to be highlighted.
   5461 
   5462 ‘C-c C-i’     (‘git-commit-insert-pseudo-header’)
   5463 
   5464      Insert a commit message pseudo header.
   5465 
   5466 ‘C-c C-a’     (‘git-commit-ack’)
   5467 
   5468      Insert a header acknowledging that you have looked at the commit.
   5469 
   5470 ‘C-c C-r’     (‘git-commit-review’)
   5471 
   5472      Insert a header acknowledging that you have reviewed the commit.
   5473 
   5474 ‘C-c C-s’     (‘git-commit-signoff’)
   5475 
   5476      Insert a header to sign off the commit.
   5477 
   5478 ‘C-c C-t’     (‘git-commit-test’)
   5479 
   5480      Insert a header acknowledging that you have tested the commit.
   5481 
   5482 ‘C-c C-o’     (‘git-commit-cc’)
   5483 
   5484      Insert a header mentioning someone who might be interested.
   5485 
   5486 ‘C-c C-p’     (‘git-commit-reported’)
   5487 
   5488      Insert a header mentioning the person who reported the issue being
   5489      fixed by the commit.
   5490 
   5491 ‘C-c M-i’     (‘git-commit-suggested’)
   5492 
   5493      Insert a header mentioning the person who suggested the change.
   5494 
   5495 
   5496 File: magit.info,  Node: Commit Mode and Hooks,  Next: Commit Message Conventions,  Prev: Commit Pseudo Headers,  Up: Editing Commit Messages
   5497 
   5498 Commit Mode and Hooks
   5499 .....................
   5500 
   5501 ‘git-commit-mode’ is a minor mode that is only used to establish certain
   5502 key bindings.  This makes it possible to use an arbitrary major mode in
   5503 buffers used to edit commit messages.  It is even possible to use
   5504 different major modes in different repositories, which is useful when
   5505 different projects impose different commit message conventions.
   5506 
   5507  -- User Option: git-commit-major-mode
   5508 
   5509      The value of this option is the major mode used to edit Git commit
   5510      messages.
   5511 
   5512    Because ‘git-commit-mode’ is a minor mode, we don’t use its mode hook
   5513 to setup the buffer, except for the key bindings.  All other setup
   5514 happens in the function ‘git-commit-setup’, which among other things
   5515 runs the hook ‘git-commit-setup-hook’.
   5516 
   5517  -- User Option: git-commit-setup-hook
   5518 
   5519      Hook run at the end of ‘git-commit-setup’.
   5520 
   5521 The following functions are suitable for this hook:
   5522 
   5523  -- Function: git-commit-save-message
   5524 
   5525      Save the current buffer content to the commit message ring.
   5526 
   5527  -- Function: git-commit-setup-changelog-support
   5528 
   5529      After this function is called, ChangeLog entries are treated as
   5530      paragraphs.
   5531 
   5532  -- Function: git-commit-turn-on-auto-fill
   5533 
   5534      Turn on ‘auto-fill-mode’ and set ‘fill-column’ to the value of
   5535      ‘git-commit-fill-column’.
   5536 
   5537  -- Function: git-commit-turn-on-flyspell
   5538 
   5539      Turn on Flyspell mode.  Also prevent comments from being checked
   5540      and finally check current non-comment text.
   5541 
   5542  -- Function: git-commit-propertize-diff
   5543 
   5544      Propertize the diff shown inside the commit message buffer.  Git
   5545      inserts such diffs into the commit message template when the
   5546      ‘--verbose’ argument is used.  ‘magit-commit’ by default does not
   5547      offer that argument because the diff that is shown in a separate
   5548      buffer is more useful.  But some users disagree, which is why this
   5549      function exists.
   5550 
   5551  -- Function: bug-reference-mode
   5552 
   5553      Hyperlink bug references in the buffer.
   5554 
   5555  -- Function: with-editor-usage-message
   5556 
   5557      Show usage information in the echo area.
   5558 
   5559  -- User Option: git-commit-setup-hook
   5560 
   5561      Hook run after the user finished writing a commit message.
   5562 
   5563      This hook is only run after pressing ‘C-c C-c’ in a buffer used to
   5564      edit a commit message.  If a commit is created without the user
   5565      typing a message into a buffer, then this hook is not run.
   5566 
   5567      This hook is not run until the new commit has been created.  If
   5568      doing so takes Git longer than one second, then this hook isn’t run
   5569      at all.  For certain commands such as ‘magit-rebase-continue’ this
   5570      hook is never run because doing so would lead to a race condition.
   5571 
   5572      This hook is only run if ‘magit’ is available.
   5573 
   5574      Also see ‘magit-post-commit-hook’.
   5575 
   5576 
   5577 File: magit.info,  Node: Commit Message Conventions,  Prev: Commit Mode and Hooks,  Up: Editing Commit Messages
   5578 
   5579 Commit Message Conventions
   5580 ..........................
   5581 
   5582 Git-Commit highlights certain violations of commonly accepted commit
   5583 message conventions.  Certain violations even cause Git-Commit to ask
   5584 you to confirm that you really want to do that.  This nagging can of
   5585 course be turned off, but the result of doing that usually is that
   5586 instead of some code it’s now the human who is reviewing your commits
   5587 who has to waste some time telling you to fix your commits.
   5588 
   5589  -- User Option: git-commit-summary-max-length
   5590 
   5591      The intended maximal length of the summary line of commit messages.
   5592      Characters beyond this column are colorized to indicate that this
   5593      preference has been violated.
   5594 
   5595  -- User Option: git-commit-fill-column
   5596 
   5597      Column beyond which automatic line-wrapping should happen in commit
   5598      message buffers.
   5599 
   5600  -- User Option: git-commit-finish-query-functions
   5601 
   5602      List of functions called to query before performing commit.
   5603 
   5604      The commit message buffer is current while the functions are
   5605      called.  If any of them returns nil, then the commit is not
   5606      performed and the buffer is not killed.  The user should then fix
   5607      the issue and try again.
   5608 
   5609      The functions are called with one argument.  If it is non-nil then
   5610      that indicates that the user used a prefix argument to force
   5611      finishing the session despite issues.  Functions should usually
   5612      honor this wish and return non-nil.
   5613 
   5614      By default the only member is ‘git-commit-check-style-conventions’.
   5615 
   5616  -- Function: git-commit-check-style-conventions
   5617 
   5618      This function checks for violations of certain basic style
   5619      conventions.  For each violation it asks users if they want to
   5620      proceed anyway.
   5621 
   5622  -- User Option: git-commit-style-convention-checks
   5623 
   5624      This option controls what conventions the function by the same name
   5625      tries to enforce.  The value is a list of self-explanatory symbols
   5626      identifying certain conventions; ‘non-empty-second-line’ and
   5627      ‘overlong-summary-line’.
   5628 
   5629 
   5630 File: magit.info,  Node: Branching,  Next: Merging,  Prev: Committing,  Up: Manipulating
   5631 
   5632 6.6 Branching
   5633 =============
   5634 
   5635 * Menu:
   5636 
   5637 * The Two Remotes::
   5638 * Branch Commands::
   5639 * Branch Git Variables::
   5640 * Auxiliary Branch Commands::
   5641 
   5642 
   5643 File: magit.info,  Node: The Two Remotes,  Next: Branch Commands,  Up: Branching
   5644 
   5645 6.6.1 The Two Remotes
   5646 ---------------------
   5647 
   5648 The upstream branch of some local branch is the branch into which the
   5649 commits on that local branch should eventually be merged, usually
   5650 something like ‘origin/master’.  For the ‘master’ branch itself the
   5651 upstream branch and the branch it is being pushed to, are usually the
   5652 same remote branch.  But for a feature branch the upstream branch and
   5653 the branch it is being pushed to should differ.
   5654 
   5655    The commits on feature branches too should _eventually_ end up in a
   5656 remote branch such as ‘origin/master’ or ‘origin/maint’.  Such a branch
   5657 should therefore be used as the upstream.  But feature branches
   5658 shouldn’t be pushed directly to such branches.  Instead a feature branch
   5659 ‘my-feature’ is usually pushed to ‘my-fork/my-feature’ or if you are a
   5660 contributor ‘origin/my-feature’.  After the new feature has been
   5661 reviewed, the maintainer merges the feature into ‘master’.  And finally
   5662 ‘master’ (not ‘my-feature’ itself) is pushed to ‘origin/master’.
   5663 
   5664    But new features seldom are perfect on the first try, and so feature
   5665 branches usually have to be reviewed, improved, and re-pushed several
   5666 times.  Pushing should therefore be easy to do, and for that reason many
   5667 Git users have concluded that it is best to use the remote branch to
   5668 which the local feature branch is being pushed as its upstream.
   5669 
   5670    But luckily Git has long ago gained support for a push-remote which
   5671 can be configured separately from the upstream branch, using the
   5672 variables ‘branch.<name>.pushRemote’ and ‘remote.pushDefault’.  So we no
   5673 longer have to choose which of the two remotes should be used as "the
   5674 remote".
   5675 
   5676    Each of the fetching, pulling, and pushing transient commands
   5677 features three suffix commands that act on the current branch and some
   5678 other branch.  Of these, ‘p’ is bound to a command which acts on the
   5679 push-remote, ‘u’ is bound to a command which acts on the upstream, and
   5680 ‘e’ is bound to a command which acts on any other branch.  The status
   5681 buffer shows unpushed and unpulled commits for both the push-remote and
   5682 the upstream.
   5683 
   5684    It’s fairly simple to configure these two remotes.  The values of all
   5685 the variables that are related to fetching, pulling, and pushing (as
   5686 well as some other branch-related variables) can be inspected and
   5687 changed using the command ‘magit-branch-configure’, which is available
   5688 from many transient prefix commands that deal with branches.  It is also
   5689 possible to set the push-remote or upstream while pushing (see *note
   5690 Pushing::).
   5691 
   5692 
   5693 File: magit.info,  Node: Branch Commands,  Next: Branch Git Variables,  Prev: The Two Remotes,  Up: Branching
   5694 
   5695 6.6.2 Branch Commands
   5696 ---------------------
   5697 
   5698 The transient prefix command ‘magit-branch’ is used to create and
   5699 checkout branches, and to make changes to existing branches.  It is not
   5700 used to fetch, pull, merge, rebase, or push branches, i.e.  this command
   5701 deals with branches themselves, not with the commits reachable from
   5702 them.  Those features are available from separate transient command.
   5703 
   5704 ‘b’     (‘magit-branch’)
   5705 
   5706      This transient prefix command binds the following suffix commands
   5707      and displays them in a temporary buffer until a suffix is invoked.
   5708 
   5709      By default it also binds and displays the values of some
   5710      branch-related Git variables and allows changing their values.
   5711 
   5712  -- User Option: magit-branch-direct-configure
   5713 
   5714      This option controls whether the transient command ‘magit-branch’
   5715      can be used to directly change the values of Git variables.  This
   5716      defaults to ‘t’ (to avoid changing key bindings).  When set to
   5717      ‘nil’, then no variables are displayed by that transient command,
   5718      and its suffix command ‘magit-branch-configure’ has to be used
   5719      instead to view and change branch related variables.
   5720 
   5721 ‘b C’     (‘magit-branch-configure’)
   5722 ‘f C’     (‘magit-branch-configure’)
   5723 ‘F C’     (‘magit-branch-configure’)
   5724 ‘P C’     (‘magit-branch-configure’)
   5725 
   5726      This transient prefix command binds commands that set the value of
   5727      branch-related variables and displays them in a temporary buffer
   5728      until the transient is exited.
   5729 
   5730      With a prefix argument, this command always prompts for a branch.
   5731 
   5732      Without a prefix argument this depends on whether it was invoked as
   5733      a suffix of ‘magit-branch’ and on the
   5734      ‘magit-branch-direct-configure’ option.  If ‘magit-branch’ already
   5735      displays the variables for the current branch, then it isn’t useful
   5736      to invoke another transient that displays them for the same branch.
   5737      In that case this command prompts for a branch.
   5738 
   5739    The variables are described in *note Branch Git Variables::.
   5740 
   5741 ‘b b’     (‘magit-checkout’)
   5742 
   5743      Checkout a revision read in the minibuffer and defaulting to the
   5744      branch or arbitrary revision at point.  If the revision is a local
   5745      branch then that becomes the current branch.  If it is something
   5746      else then ‘HEAD’ becomes detached.  Checkout fails if the working
   5747      tree or the staging area contain changes.
   5748 
   5749 ‘b n’     (‘magit-branch-create’)
   5750 
   5751      Create a new branch.  The user is asked for a branch or arbitrary
   5752      revision to use as the starting point of the new branch.  When a
   5753      branch name is provided, then that becomes the upstream branch of
   5754      the new branch.  The name of the new branch is also read in the
   5755      minibuffer.
   5756 
   5757      Also see option ‘magit-branch-prefer-remote-upstream’.
   5758 
   5759 ‘b c’     (‘magit-branch-and-checkout’)
   5760 
   5761      This command creates a new branch like ‘magit-branch-create’, but
   5762      then also checks it out.
   5763 
   5764      Also see option ‘magit-branch-prefer-remote-upstream’.
   5765 
   5766 ‘b l’     (‘magit-branch-checkout’)
   5767 
   5768      This command checks out an existing or new local branch.  It reads
   5769      a branch name from the user offering all local branches and a
   5770      subset of remote branches as candidates.  Remote branches for which
   5771      a local branch by the same name exists are omitted from the list of
   5772      candidates.  The user can also enter a completely new branch name.
   5773 
   5774         • If the user selects an existing local branch, then that is
   5775           checked out.
   5776 
   5777         • If the user selects a remote branch, then it creates and
   5778           checks out a new local branch with the same name, and
   5779           configures the selected remote branch as the push target.
   5780 
   5781         • If the user enters a new branch name, then it creates and
   5782           checks that out, after also reading the starting-point from
   5783           the user.
   5784 
   5785      In the latter two cases the upstream is also set.  Whether it is
   5786      set to the chosen starting point or something else depends on the
   5787      value of ‘magit-branch-adjust-remote-upstream-alist’.
   5788 
   5789 ‘b s’     (‘magit-branch-spinoff’)
   5790 
   5791      This command creates and checks out a new branch starting at and
   5792      tracking the current branch.  That branch in turn is reset to the
   5793      last commit it shares with its upstream.  If the current branch has
   5794      no upstream or no unpushed commits, then the new branch is created
   5795      anyway and the previously current branch is not touched.
   5796 
   5797      This is useful to create a feature branch after work has already
   5798      began on the old branch (likely but not necessarily "master").
   5799 
   5800      If the current branch is a member of the value of option
   5801      ‘magit-branch-prefer-remote-upstream’ (which see), then the current
   5802      branch will be used as the starting point as usual, but the
   5803      upstream of the starting-point may be used as the upstream of the
   5804      new branch, instead of the starting-point itself.
   5805 
   5806      If optional FROM is non-nil, then the source branch is reset to
   5807      ‘FROM~’, instead of to the last commit it shares with its upstream.
   5808      Interactively, FROM is only ever non-nil, if the region selects
   5809      some commits, and among those commits, FROM is the commit that is
   5810      the fewest commits ahead of the source branch.
   5811 
   5812      The commit at the other end of the selection actually does not
   5813      matter, all commits between FROM and ‘HEAD’ are moved to the new
   5814      branch.  If FROM is not reachable from ‘HEAD’ or is reachable from
   5815      the source branch’s upstream, then an error is raised.
   5816 
   5817 ‘b S’     (‘magit-branch-spinout’)
   5818 
   5819      This command behaves like ‘magit-branch-spinoff’, except that it
   5820      does not change the current branch.  If there are any uncommitted
   5821      changes, then it behaves exactly like ‘magit-branch-spinoff’.
   5822 
   5823 ‘b x’     (‘magit-branch-reset’)
   5824 
   5825      This command resets a branch, defaulting to the branch at point, to
   5826      the tip of another branch or any other commit.
   5827 
   5828      When the branch being reset is the current branch, then a hard
   5829      reset is performed.  If there are any uncommitted changes, then the
   5830      user has to confirm the reset because those changes would be lost.
   5831 
   5832      This is useful when you have started work on a feature branch but
   5833      realize it’s all crap and want to start over.
   5834 
   5835      When resetting to another branch and a prefix argument is used,
   5836      then the target branch is set as the upstream of the branch that is
   5837      being reset.
   5838 
   5839 ‘b k’     (‘magit-branch-delete’)
   5840 
   5841      Delete one or multiple branches.  If the region marks multiple
   5842      branches, then offer to delete those.  Otherwise, prompt for a
   5843      single branch to be deleted, defaulting to the branch at point.
   5844 
   5845 ‘b r’     (‘magit-branch-rename’)
   5846 
   5847      Rename a branch.  The branch and the new name are read in the
   5848      minibuffer.  With prefix argument the branch is renamed even if
   5849      that name conflicts with an existing branch.
   5850 
   5851  -- User Option: magit-branch-read-upstream-first
   5852 
   5853      When creating a branch, whether to read the upstream branch before
   5854      the name of the branch that is to be created.  The default is ‘t’,
   5855      and I recommend you leave it at that.
   5856 
   5857  -- User Option: magit-branch-prefer-remote-upstream
   5858 
   5859      This option specifies whether remote upstreams are favored over
   5860      local upstreams when creating new branches.
   5861 
   5862      When a new branch is created, then the branch, commit, or stash at
   5863      point is suggested as the starting point of the new branch, or if
   5864      there is no such revision at point the current branch.  In either
   5865      case the user may choose another starting point.
   5866 
   5867      If the chosen starting point is a branch, then it may also be set
   5868      as the upstream of the new branch, depending on the value of the
   5869      Git variable ‘branch.autoSetupMerge’.  By default this is done for
   5870      remote branches, but not for local branches.
   5871 
   5872      You might prefer to always use some remote branch as upstream.  If
   5873      the chosen starting point is (1) a local branch, (2) whose name
   5874      matches a member of the value of this option, (3) the upstream of
   5875      that local branch is a remote branch with the same name, and (4)
   5876      that remote branch can be fast-forwarded to the local branch, then
   5877      the chosen branch is used as starting point, but its own upstream
   5878      is used as the upstream of the new branch.
   5879 
   5880      Members of this option’s value are treated as branch names that
   5881      have to match exactly unless they contain a character that makes
   5882      them invalid as a branch name.  Recommended characters to use to
   5883      trigger interpretation as a regexp are "*" and "^".  Some other
   5884      characters which you might expect to be invalid, actually are not,
   5885      e.g.  ".+$" are all perfectly valid.  More precisely, if ‘git
   5886      check-ref-format --branch STRING’ exits with a non-zero status,
   5887      then treat STRING as a regexp.
   5888 
   5889      Assuming the chosen branch matches these conditions you would end
   5890      up with with e.g.:
   5891 
   5892           feature --upstream--> origin/master
   5893 
   5894      instead of
   5895 
   5896           feature --upstream--> master --upstream--> origin/master
   5897 
   5898      Which you prefer is a matter of personal preference.  If you do
   5899      prefer the former, then you should add branches such as ‘master’,
   5900      ‘next’, and ‘maint’ to the value of this options.
   5901 
   5902  -- User Option: magit-branch-adjust-remote-upstream-alist
   5903 
   5904      The value of this option is an alist of branches to be used as the
   5905      upstream when branching a remote branch.
   5906 
   5907      When creating a local branch from an ephemeral branch located on a
   5908      remote, e.g.  a feature or hotfix branch, then that remote branch
   5909      should usually not be used as the upstream branch, since the
   5910      push-remote already allows accessing it and having both the
   5911      upstream and the push-remote reference the same related branch
   5912      would be wasteful.  Instead a branch like "maint" or "master"
   5913      should be used as the upstream.
   5914 
   5915      This option allows specifying the branch that should be used as the
   5916      upstream when branching certain remote branches.  The value is an
   5917      alist of the form ‘((UPSTREAM . RULE)...)’.  The first matching
   5918      element is used, the following elements are ignored.
   5919 
   5920      UPSTREAM is the branch to be used as the upstream for branches
   5921      specified by RULE.  It can be a local or a remote branch.
   5922 
   5923      RULE can either be a regular expression, matching branches whose
   5924      upstream should be the one specified by UPSTREAM.  Or it can be a
   5925      list of the only branches that should *not* use UPSTREAM; all other
   5926      branches will.  Matching is done after stripping the remote part of
   5927      the name of the branch that is being branched from.
   5928 
   5929      If you use a finite set of non-ephemeral branches across all your
   5930      repositories, then you might use something like:
   5931 
   5932           (("origin/master" . ("master" "next" "maint")))
   5933 
   5934      Or if the names of all your ephemeral branches contain a slash, at
   5935      least in some repositories, then a good value could be:
   5936 
   5937           (("origin/master" . "/"))
   5938 
   5939      Of course you can also fine-tune:
   5940 
   5941           (("origin/maint" . "\\`hotfix/")
   5942            ("origin/master" . "\\`feature/"))
   5943 
   5944      UPSTREAM can be a local branch:
   5945 
   5946           (("master" . ("master" "next" "maint")))
   5947 
   5948    Because the main branch is no longer almost always named "master" you
   5949 should also account for other common names:
   5950 
   5951      (("main"  . ("main" "master" "next" "maint"))
   5952       ("master" . ("main" "master" "next" "maint")))
   5953 
   5954  -- Command: magit-branch-orphan
   5955 
   5956      This command creates and checks out a new orphan branch with
   5957      contents from a given revision.
   5958 
   5959  -- Command: magit-branch-or-checkout
   5960 
   5961      This command is a hybrid between ‘magit-checkout’ and
   5962      ‘magit-branch-and-checkout’ and is intended as a replacement for
   5963      the former in ‘magit-branch’.
   5964 
   5965      It first asks the user for an existing branch or revision.  If the
   5966      user input actually can be resolved as a branch or revision, then
   5967      it checks that out, just like ‘magit-checkout’ would.
   5968 
   5969      Otherwise it creates and checks out a new branch using the input as
   5970      its name.  Before doing so it reads the starting-point for the new
   5971      branch.  This is similar to what ‘magit-branch-and-checkout’ does.
   5972 
   5973      To use this command instead of ‘magit-checkout’ add this to your
   5974      init file:
   5975 
   5976           (transient-replace-suffix 'magit-branch 'magit-checkout
   5977             '("b" "dwim" magit-branch-or-checkout))
   5978 
   5979 
   5980 File: magit.info,  Node: Branch Git Variables,  Next: Auxiliary Branch Commands,  Prev: Branch Commands,  Up: Branching
   5981 
   5982 6.6.3 Branch Git Variables
   5983 --------------------------
   5984 
   5985 These variables can be set from the transient prefix command
   5986 ‘magit-branch-configure’.  By default they can also be set from
   5987 ‘magit-branch’.  See *note Branch Commands::.
   5988 
   5989  -- Variable: branch.NAME.merge
   5990 
   5991      Together with ‘branch.NAME.remote’ this variable defines the
   5992      upstream branch of the local branch named NAME.  The value of this
   5993      variable is the full reference of the upstream _branch_.
   5994 
   5995  -- Variable: branch.NAME.remote
   5996 
   5997      Together with ‘branch.NAME.merge’ this variable defines the
   5998      upstream branch of the local branch named NAME.  The value of this
   5999      variable is the name of the upstream _remote_.
   6000 
   6001  -- Variable: branch.NAME.rebase
   6002 
   6003      This variable controls whether pulling into the branch named NAME
   6004      is done by rebasing or by merging the fetched branch.
   6005 
   6006         • When ‘true’ then pulling is done by rebasing.
   6007 
   6008         • When ‘false’ then pulling is done by merging.
   6009 
   6010         • When undefined then the value of ‘pull.rebase’ is used.  The
   6011           default of that variable is ‘false’.
   6012 
   6013  -- Variable: branch.NAME.pushRemote
   6014 
   6015      This variable specifies the remote that the branch named NAME is
   6016      usually pushed to.  The value has to be the name of an existing
   6017      remote.
   6018 
   6019      It is not possible to specify the name of _branch_ to push the
   6020      local branch to.  The name of the remote branch is always the same
   6021      as the name of the local branch.
   6022 
   6023      If this variable is undefined but ‘remote.pushDefault’ is defined,
   6024      then the value of the latter is used.  By default
   6025      ‘remote.pushDefault’ is undefined.
   6026 
   6027  -- Variable: branch.NAME.description
   6028 
   6029      This variable can be used to describe the branch named NAME.  That
   6030      description is used e.g.  when turning the branch into a series of
   6031      patches.
   6032 
   6033    The following variables specify defaults which are used if the above
   6034 branch-specific variables are not set.
   6035 
   6036  -- Variable: pull.rebase
   6037 
   6038      This variable specifies whether pulling is done by rebasing or by
   6039      merging.  It can be overwritten using ‘branch.NAME.rebase’.
   6040 
   6041         • When ‘true’ then pulling is done by rebasing.
   6042 
   6043         • When ‘false’ (the default) then pulling is done by merging.
   6044 
   6045      Since it is never a good idea to merge the upstream branch into a
   6046      feature or hotfix branch and most branches are such branches, you
   6047      should consider setting this to ‘true’, and ‘branch.master.rebase’
   6048      to ‘false’.
   6049 
   6050  -- Variable: remote.pushDefault
   6051 
   6052      This variable specifies what remote the local branches are usually
   6053      pushed to.  This can be overwritten per branch using
   6054      ‘branch.NAME.pushRemote’.
   6055 
   6056    The following variables are used during the creation of a branch and
   6057 control whether the various branch-specific variables are automatically
   6058 set at this time.
   6059 
   6060  -- Variable: branch.autoSetupMerge
   6061 
   6062      This variable specifies under what circumstances creating a branch
   6063      NAME should result in the variables ‘branch.NAME.merge’ and
   6064      ‘branch.NAME.remote’ being set according to the starting point used
   6065      to create the branch.  If the starting point isn’t a branch, then
   6066      these variables are never set.
   6067 
   6068         • When ‘always’ then the variables are set regardless of whether
   6069           the starting point is a local or a remote branch.
   6070 
   6071         • When ‘true’ (the default) then the variables are set when the
   6072           starting point is a remote branch, but not when it is a local
   6073           branch.
   6074 
   6075         • When ‘false’ then the variables are never set.
   6076 
   6077  -- Variable: branch.autoSetupRebase
   6078 
   6079      This variable specifies whether creating a branch NAME should
   6080      result in the variable ‘branch.NAME.rebase’ being set to ‘true’.
   6081 
   6082         • When ‘always’ then the variable is set regardless of whether
   6083           the starting point is a local or a remote branch.
   6084 
   6085         • When ‘local’ then the variable are set when the starting point
   6086           is a local branch, but not when it is a remote branch.
   6087 
   6088         • When ‘remote’ then the variable are set when the starting
   6089           point is a remote branch, but not when it is a local branch.
   6090 
   6091         • When ‘never’ (the default) then the variable is never set.
   6092 
   6093    Note that the respective commands always change the repository-local
   6094 values.  If you want to change the global value, which is used when the
   6095 local value is undefined, then you have to do so on the command line,
   6096 e.g.:
   6097 
   6098      git config --global remote.autoSetupMerge always
   6099 
   6100    For more information about these variables you should also see
   6101 
   6102    *note (gitman)git-config::.  Also see *note (gitman)git-branch::.  ,
   6103 *note (gitman)git-checkout::.  and *note Pushing::.
   6104 
   6105  -- User Option: magit-prefer-remote-upstream
   6106 
   6107      This option controls whether commands that read a branch from the
   6108      user and then set it as the upstream branch, offer a local or a
   6109      remote branch as default completion candidate, when they have the
   6110      choice.
   6111 
   6112      This affects all commands that use ‘magit-read-upstream-branch’ or
   6113      ‘magit-read-starting-point’, which includes all commands that
   6114      change the upstream and many which create new branches.
   6115 
   6116 
   6117 File: magit.info,  Node: Auxiliary Branch Commands,  Prev: Branch Git Variables,  Up: Branching
   6118 
   6119 6.6.4 Auxiliary Branch Commands
   6120 -------------------------------
   6121 
   6122 These commands are not available from the transient ‘magit-branch’ by
   6123 default.
   6124 
   6125  -- Command: magit-branch-shelve
   6126 
   6127      This command shelves a branch.  This is done by deleting the
   6128      branch, and creating a new reference "refs/shelved/BRANCH-NAME"
   6129      pointing at the same commit as the branch pointed at.  If the
   6130      deleted branch had a reflog, then that is preserved as the reflog
   6131      of the new reference.
   6132 
   6133      This is useful if you want to move a branch out of sight, but are
   6134      not ready to completely discard it yet.
   6135 
   6136  -- Command: magit-branch-unshelve
   6137 
   6138      This command unshelves a branch that was previously shelved using
   6139      ‘magit-branch-shelve’.  This is done by deleting the reference
   6140      "refs/shelved/BRANCH-NAME" and creating a branch "BRANCH-NAME"
   6141      pointing at the same commit as the deleted reference pointed at.
   6142      If the deleted reference had a reflog, then that is restored as the
   6143      reflog of the branch.
   6144 
   6145 
   6146 File: magit.info,  Node: Merging,  Next: Resolving Conflicts,  Prev: Branching,  Up: Manipulating
   6147 
   6148 6.7 Merging
   6149 ===========
   6150 
   6151 Also see *note (gitman)git-merge::.  For information on how to resolve
   6152 merge conflicts see the next section.
   6153 
   6154 ‘m’     (‘magit-merge’)
   6155 
   6156      This transient prefix command binds the following suffix commands
   6157      along with the appropriate infix arguments and displays them in a
   6158      temporary buffer until a suffix is invoked.
   6159 
   6160    When no merge is in progress, then the transient features the
   6161 following suffix commands.
   6162 
   6163 ‘m m’     (‘magit-merge-plain’)
   6164 
   6165      This command merges another branch or an arbitrary revision into
   6166      the current branch.  The branch or revision to be merged is read in
   6167      the minibuffer and defaults to the branch at point.
   6168 
   6169      Unless there are conflicts or a prefix argument is used, then the
   6170      resulting merge commit uses a generic commit message, and the user
   6171      does not get a chance to inspect or change it before the commit is
   6172      created.  With a prefix argument this does not actually create the
   6173      merge commit, which makes it possible to inspect how conflicts were
   6174      resolved and to adjust the commit message.
   6175 
   6176 ‘m e’     (‘magit-merge-editmsg’)
   6177 
   6178      This command merges another branch or an arbitrary revision into
   6179      the current branch and opens a commit message buffer, so that the
   6180      user can make adjustments.  The commit is not actually created
   6181      until the user finishes with ‘C-c C-c’.
   6182 
   6183 ‘m n’     (‘magit-merge-nocommit’)
   6184 
   6185      This command merges another branch or an arbitrary revision into
   6186      the current branch, but does not actually create the merge commit.
   6187      The user can then further adjust the merge, even when automatic
   6188      conflict resolution succeeded and/or adjust the commit message.
   6189 
   6190 ‘m a’     (‘magit-merge-absorb’)
   6191 
   6192      This command merges another local branch into the current branch
   6193      and then removes the former.
   6194 
   6195      Before the source branch is merged, it is first force pushed to its
   6196      push-remote, provided the respective remote branch already exists.
   6197      This ensures that the respective pull-request (if any) won’t get
   6198      stuck on some obsolete version of the commits that are being
   6199      merged.  Finally, if ‘magit-branch-pull-request’ was used to create
   6200      the merged branch, then the respective remote branch is also
   6201      removed.
   6202 
   6203 ‘m i’     (‘magit-merge-into’)
   6204 
   6205      This command merges the current branch into another local branch
   6206      and then removes the former.  The latter becomes the new current
   6207      branch.
   6208 
   6209      Before the source branch is merged, it is first force pushed to its
   6210      push-remote, provided the respective remote branch already exists.
   6211      This ensures that the respective pull-request (if any) won’t get
   6212      stuck on some obsolete version of the commits that are being
   6213      merged.  Finally, if ‘magit-branch-pull-request’ was used to create
   6214      the merged branch, then the respective remote branch is also
   6215      removed.
   6216 
   6217 ‘m s’     (‘magit-merge-squash’)
   6218 
   6219      This command squashes the changes introduced by another branch or
   6220      an arbitrary revision into the current branch.  This only applies
   6221      the changes made by the squashed commits.  No information is
   6222      preserved that would allow creating an actual merge commit.
   6223      Instead of this command you should probably use a command from the
   6224      apply transient.
   6225 
   6226 ‘m p’     (‘magit-merge-preview’)
   6227 
   6228      This command shows a preview of merging another branch or an
   6229      arbitrary revision into the current branch.
   6230 
   6231    When a merge is in progress, then the transient instead features the
   6232 following suffix commands.
   6233 
   6234 ‘m m’     (‘magit-merge’)
   6235 
   6236      After the user resolved conflicts, this command proceeds with the
   6237      merge.  If some conflicts weren’t resolved, then this command
   6238      fails.
   6239 
   6240 ‘m a’     (‘magit-merge-abort’)
   6241 
   6242      This command aborts the current merge operation.
   6243 
   6244 
   6245 File: magit.info,  Node: Resolving Conflicts,  Next: Rebasing,  Prev: Merging,  Up: Manipulating
   6246 
   6247 6.8 Resolving Conflicts
   6248 =======================
   6249 
   6250 When merging branches (or otherwise combining or changing history)
   6251 conflicts can occur.  If you edited two completely different parts of
   6252 the same file in two branches and then merge one of these branches into
   6253 the other, then Git can resolve that on its own, but if you edit the
   6254 same area of a file, then a human is required to decide how the two
   6255 versions, or "sides of the conflict", are to be combined into one.
   6256 
   6257    Here we can only provide a brief introduction to the subject and
   6258 point you toward some tools that can help.  If you are new to this, then
   6259 please also consult Git’s own documentation as well as other resources.
   6260 
   6261    If a file has conflicts and Git cannot resolve them by itself, then
   6262 it puts both versions into the affected file along with special markers
   6263 whose purpose is to denote the boundaries of the unresolved part of the
   6264 file and between the different versions.  These boundary lines begin
   6265 with the strings consisting of six times the same character, one of ‘<’,
   6266 ‘|’, ‘=’ and ‘>’ and are followed by information about the source of the
   6267 respective versions, e.g.:
   6268 
   6269      <<<<<<< HEAD
   6270      Take the blue pill.
   6271      =======
   6272      Take the red pill.
   6273      >>>>>>> feature
   6274 
   6275    In this case you have chosen to take the red pill on one branch and
   6276 on another you picked the blue pill.  Now that you are merging these two
   6277 diverging branches, Git cannot possibly know which pill you want to
   6278 take.
   6279 
   6280    To resolve that conflict you have to create a version of the affected
   6281 area of the file by keeping only one of the sides, possibly by editing
   6282 it in order to bring in the changes from the other side, remove the
   6283 other versions as well as the markers, and then stage the result.  A
   6284 possible resolution might be:
   6285 
   6286      Take both pills.
   6287 
   6288    Often it is useful to see not only the two sides of the conflict but
   6289 also the "original" version from before the same area of the file was
   6290 modified twice on different branches.  Instruct Git to insert that
   6291 version as well by running this command once:
   6292 
   6293      git config --global merge.conflictStyle diff3
   6294 
   6295    The above conflict might then have looked like this:
   6296 
   6297      <<<<<<< HEAD
   6298      Take the blue pill.
   6299      ||||||| merged common ancestors
   6300      Take either the blue or the red pill, but not both.
   6301      =======
   6302      Take the red pill.
   6303      >>>>>>> feature
   6304 
   6305    If that were the case, then the above conflict resolution would not
   6306 have been correct, which demonstrates why seeing the original version
   6307 alongside the conflicting versions can be useful.
   6308 
   6309    You can perform the conflict resolution completely by hand, but Emacs
   6310 also provides some packages that help in the process: Smerge, Ediff
   6311 (*note (ediff)Top::), and Emerge (*note (emacs)Emerge::).  Magit does
   6312 not provide its own tools for conflict resolution, but it does make
   6313 using Smerge and Ediff more convenient.  (Ediff supersedes Emerge, so
   6314 you probably don’t want to use the latter anyway.)
   6315 
   6316    In the Magit status buffer, files with unresolved conflicts are
   6317 listed in the "Unstaged changes" and/or "Staged changes" sections.  They
   6318 are prefixed with the word "unmerged", which in this context essentially
   6319 is a synonym for "unresolved".
   6320 
   6321    Pressing ‘RET’ while point is on such a file section shows a buffer
   6322 visiting that file, turns on ‘smerge-mode’ in that buffer, and places
   6323 point inside the first area with conflicts.  You should then resolve
   6324 that conflict using regular edit commands and/or Smerge commands.
   6325 
   6326    Unfortunately Smerge does not have a manual, but you can get a list
   6327 of commands and binding ‘C-c ^ C-h’ and press ‘RET’ while point is on a
   6328 command name to read its documentation.
   6329 
   6330    Normally you would edit one version and then tell Smerge to keep only
   6331 that version.  Use ‘C-c ^ m’ (‘smerge-keep-mine’) to keep the ‘HEAD’
   6332 version or ‘C-c ^ o’ (‘smerge-keep-other’) to keep the version that
   6333 follows "|||||||".  Then use ‘C-c ^ n’ to move to the next conflicting
   6334 area in the same file.  Once you are done resolving conflicts, return to
   6335 the Magit status buffer.  The file should now be shown as "modified", no
   6336 longer as "unmerged", because Smerge automatically stages the file when
   6337 you save the buffer after resolving the last conflict.
   6338 
   6339    Magit now wraps the mentioned Smerge commands, allowing you to use
   6340 these key bindings without having to go to the file-visiting buffer.
   6341 Additionally ‘k’ (‘magit-discard’) on a hunk with unresolved conflicts
   6342 asks which side to keep or, if point is on a side, then it keeps it
   6343 without prompting.  Similarly ‘k’ on a unresolved file ask which side to
   6344 keep.
   6345 
   6346    Alternatively you could use Ediff, which uses separate buffers for
   6347 the different versions of the file.  To resolve conflicts in a file
   6348 using Ediff press ‘e’ while point is on such a file in the status
   6349 buffer.
   6350 
   6351    Ediff can be used for other purposes as well.  For more information
   6352 on how to enter Ediff from Magit, see *note Ediffing::.  Explaining how
   6353 to use Ediff is beyond the scope of this manual, instead see *note
   6354 (ediff)Top::.
   6355 
   6356    If you are unsure whether you should Smerge or Ediff, then use the
   6357 former.  It is much easier to understand and use, and except for truly
   6358 complex conflicts, the latter is usually overkill.
   6359 
   6360 
   6361 File: magit.info,  Node: Rebasing,  Next: Cherry Picking,  Prev: Resolving Conflicts,  Up: Manipulating
   6362 
   6363 6.9 Rebasing
   6364 ============
   6365 
   6366 Also see *note (gitman)git-rebase::.  For information on how to resolve
   6367 conflicts that occur during rebases see the preceding section.
   6368 
   6369 ‘r’     (‘magit-rebase’)
   6370 
   6371      This transient prefix command binds the following suffix commands
   6372      along with the appropriate infix arguments and displays them in a
   6373      temporary buffer until a suffix is invoked.
   6374 
   6375    When no rebase is in progress, then the transient features the
   6376 following suffix commands.
   6377 
   6378    Using one of these commands _starts_ a rebase sequence.  Git might
   6379 then stop somewhere along the way, either because you told it to do so,
   6380 or because applying a commit failed due to a conflict.  When that
   6381 happens, then the status buffer shows information about the rebase
   6382 sequence which is in progress in a section similar to a log section.
   6383 See *note Information About In-Progress Rebase::.
   6384 
   6385    For information about the upstream and the push-remote, see *note The
   6386 Two Remotes::.
   6387 
   6388 ‘r p’     (‘magit-rebase-onto-pushremote’)
   6389 
   6390      This command rebases the current branch onto its push-remote.
   6391 
   6392      With a prefix argument or when the push-remote is either not
   6393      configured or unusable, then let the user first configure the
   6394      push-remote.
   6395 
   6396 ‘r u’     (‘magit-rebase-onto-upstream’)
   6397 
   6398      This command rebases the current branch onto its upstream branch.
   6399 
   6400      With a prefix argument or when the upstream is either not
   6401      configured or unusable, then let the user first configure the
   6402      upstream.
   6403 
   6404 ‘r e’     (‘magit-rebase-branch’)
   6405 
   6406      This command rebases the current branch onto a branch read in the
   6407      minibuffer.  All commits that are reachable from head but not from
   6408      the selected branch TARGET are being rebased.
   6409 
   6410 ‘r s’     (‘magit-rebase-subset’)
   6411 
   6412      This command starts a non-interactive rebase sequence to transfer
   6413      commits from START to ‘HEAD’ onto NEWBASE.  START has to be
   6414      selected from a list of recent commits.
   6415 
   6416    By default Magit uses the ‘--autostash’ argument, which causes
   6417 uncommitted changes to be stored in a stash before the rebase begins.
   6418 These changes are restored after the rebase completes and if possible
   6419 the stash is removed.  If the stash does not apply cleanly, then the
   6420 stash is not removed.  In case something goes wrong when resolving the
   6421 conflicts, this allows you to start over.
   6422 
   6423    Even though one of the actions is dedicated to interactive rebases,
   6424 the transient also features the infix argument ‘--interactive’.  This
   6425 can be used to turn one of the other, non-interactive rebase variants
   6426 into an interactive rebase.
   6427 
   6428    For example if you want to clean up a feature branch and at the same
   6429 time rebase it onto ‘master’, then you could use ‘r-iu’.  But we
   6430 recommend that you instead do that in two steps.  First use ‘ri’ to
   6431 cleanup the feature branch, and then in a second step ‘ru’ to rebase it
   6432 onto ‘master’.  That way if things turn out to be more complicated than
   6433 you thought and/or you make a mistake and have to start over, then you
   6434 only have to redo half the work.
   6435 
   6436    Explicitly enabling ‘--interactive’ won’t have an effect on the
   6437 following commands as they always use that argument anyway, even if it
   6438 is not enabled in the transient.
   6439 
   6440 ‘r i’     (‘magit-rebase-interactive’)
   6441 
   6442      This command starts an interactive rebase sequence.
   6443 
   6444 ‘r f’     (‘magit-rebase-autosquash’)
   6445 
   6446      This command combines squash and fixup commits with their intended
   6447      targets.
   6448 
   6449 ‘r m’     (‘magit-rebase-edit-commit’)
   6450 
   6451      This command starts an interactive rebase sequence that lets the
   6452      user edit a single older commit.
   6453 
   6454 ‘r w’     (‘magit-rebase-reword-commit’)
   6455 
   6456      This command starts an interactive rebase sequence that lets the
   6457      user reword a single older commit.
   6458 
   6459 ‘r k’     (‘magit-rebase-remove-commit’)
   6460 
   6461      This command removes a single older commit using rebase.
   6462 
   6463    When a rebase is in progress, then the transient instead features the
   6464 following suffix commands.
   6465 
   6466 ‘r r’     (‘magit-rebase-continue’)
   6467 
   6468      This command restart the current rebasing operation.
   6469 
   6470      In some cases this pops up a commit message buffer for you do edit.
   6471      With a prefix argument the old message is reused as-is.
   6472 
   6473 ‘r s’     (‘magit-rebase-skip’)
   6474 
   6475      This command skips the current commit and restarts the current
   6476      rebase operation.
   6477 
   6478 ‘r e’     (‘magit-rebase-edit’)
   6479 
   6480      This command lets the user edit the todo list of the current rebase
   6481      operation.
   6482 
   6483 ‘r a’     (‘magit-rebase-abort’)
   6484 
   6485      This command aborts the current rebase operation, restoring the
   6486      original branch.
   6487 
   6488 * Menu:
   6489 
   6490 * Editing Rebase Sequences::
   6491 * Information About In-Progress Rebase::
   6492 
   6493 
   6494 File: magit.info,  Node: Editing Rebase Sequences,  Next: Information About In-Progress Rebase,  Up: Rebasing
   6495 
   6496 6.9.1 Editing Rebase Sequences
   6497 ------------------------------
   6498 
   6499 ‘C-c C-c’     (‘with-editor-finish’)
   6500 
   6501      Finish the current editing session by returning with exit code 0.
   6502      Git then uses the rebase instructions it finds in the file.
   6503 
   6504 ‘C-c C-k’     (‘with-editor-cancel’)
   6505 
   6506      Cancel the current editing session by returning with exit code 1.
   6507      Git then forgoes starting the rebase sequence.
   6508 
   6509 ‘RET’     (‘git-rebase-show-commit’)
   6510 
   6511      Show the commit on the current line in another buffer and select
   6512      that buffer.
   6513 
   6514 ‘SPC’     (‘git-rebase-show-or-scroll-up’)
   6515 
   6516      Show the commit on the current line in another buffer without
   6517      selecting that buffer.  If the revision buffer is already visible
   6518      in another window of the current frame, then instead scroll that
   6519      window up.
   6520 
   6521 ‘DEL’     (‘git-rebase-show-or-scroll-down’)
   6522 
   6523      Show the commit on the current line in another buffer without
   6524      selecting that buffer.  If the revision buffer is already visible
   6525      in another window of the current frame, then instead scroll that
   6526      window down.
   6527 
   6528 ‘p’     (‘git-rebase-backward-line’)
   6529 
   6530      Move to previous line.
   6531 
   6532 ‘n’     (‘forward-line’)
   6533 
   6534      Move to next line.
   6535 
   6536 ‘M-p’     (‘git-rebase-move-line-up’)
   6537 
   6538      Move the current commit (or command) up.
   6539 
   6540 ‘M-n’     (‘git-rebase-move-line-down’)
   6541 
   6542      Move the current commit (or command) down.
   6543 
   6544 ‘r’     (‘git-rebase-reword’)
   6545 
   6546      Edit message of commit on current line.
   6547 
   6548 ‘e’     (‘git-rebase-edit’)
   6549 
   6550      Stop at the commit on the current line.
   6551 
   6552 ‘s’     (‘git-rebase-squash’)
   6553 
   6554      Meld commit on current line into previous commit, and edit message.
   6555 
   6556 ‘f’     (‘git-rebase-fixup’)
   6557 
   6558      Meld commit on current line into previous commit, discarding the
   6559      current commit’s message.
   6560 
   6561 ‘k’     (‘git-rebase-kill-line’)
   6562 
   6563      Kill the current action line.
   6564 
   6565 ‘c’     (‘git-rebase-pick’)
   6566 
   6567      Use commit on current line.
   6568 
   6569 ‘x’     (‘git-rebase-exec’)
   6570 
   6571      Insert a shell command to be run after the proceeding commit.
   6572 
   6573      If there already is such a command on the current line, then edit
   6574      that instead.  With a prefix argument insert a new command even
   6575      when there already is one on the current line.  With empty input
   6576      remove the command on the current line, if any.
   6577 
   6578 ‘b’     (‘git-rebase-break’)
   6579 
   6580      Insert a break action before the current line, instructing Git to
   6581      return control to the user.
   6582 
   6583 ‘y’     (‘git-rebase-insert’)
   6584 
   6585      Read an arbitrary commit and insert it below current line.
   6586 
   6587 ‘C-x u’     (‘git-rebase-undo’)
   6588 
   6589      Undo some previous changes.  Like ‘undo’ but works in read-only
   6590      buffers.
   6591 
   6592  -- User Option: git-rebase-auto-advance
   6593 
   6594      Whether to move to next line after changing a line.
   6595 
   6596  -- User Option: git-rebase-show-instructions
   6597 
   6598      Whether to show usage instructions inside the rebase buffer.
   6599 
   6600  -- User Option: git-rebase-confirm-cancel
   6601 
   6602      Whether confirmation is required to cancel.
   6603 
   6604    When a rebase is performed with the ‘--rebase-merges’ option, the
   6605 sequence will include a few other types of actions and the following
   6606 commands become relevant.
   6607 
   6608 ‘l’     (‘git-rebase-label’)
   6609 
   6610      This commands inserts a label action or edits the one at point.
   6611 
   6612 ‘t’     (‘git-rebase-reset’)
   6613 
   6614      This command inserts a reset action or edits the one at point.  The
   6615      prompt will offer the labels that are currently present in the
   6616      buffer.
   6617 
   6618 ‘MM’     (‘git-rebase-merge’)
   6619 
   6620      The command inserts a merge action or edits the one at point.  The
   6621      prompt will offer the labels that are currently present in the
   6622      buffer.  Specifying a message to reuse via ‘-c’ or ‘-C’ is not
   6623      supported; an editor will always be invoked for the merge.
   6624 
   6625 ‘Mt’     (‘git-rebase-merge-toggle-editmsg’)
   6626 
   6627      This command toggles between the ‘-C’ and ‘-c’ options of the merge
   6628      action at point.  These options both specify a commit whose message
   6629      should be reused.  The lower-case variant instructs Git to invoke
   6630      the editor when creating the merge, allowing the user to edit the
   6631      message.
   6632 
   6633 
   6634 File: magit.info,  Node: Information About In-Progress Rebase,  Prev: Editing Rebase Sequences,  Up: Rebasing
   6635 
   6636 6.9.2 Information About In-Progress Rebase
   6637 ------------------------------------------
   6638 
   6639 While a rebase sequence is in progress, the status buffer features a
   6640 section that lists the commits that have already been applied as well as
   6641 the commits that still have to be applied.
   6642 
   6643    The commits are split in two halves.  When rebase stops at a commit,
   6644 either because the user has to deal with a conflict or because s/he
   6645 explicitly requested that rebase stops at that commit, then point is
   6646 placed on the commit that separates the two groups, i.e.  on ‘HEAD’.
   6647 The commits above it have not been applied yet, while the ‘HEAD’ and the
   6648 commits below it have already been applied.  In between these two groups
   6649 of applied and yet-to-be applied commits, there sometimes is a commit
   6650 which has been dropped.
   6651 
   6652    Each commit is prefixed with a word and these words are additionally
   6653 shown in different colors to indicate the status of the commits.
   6654 
   6655    The following colors are used:
   6656 
   6657    • Yellow commits have not been applied yet.
   6658 
   6659    • Gray commits have already been applied.
   6660 
   6661    • The blue commit is the ‘HEAD’ commit.
   6662 
   6663    • The green commit is the commit the rebase sequence stopped at.  If
   6664      this is the same commit as ‘HEAD’ (e.g.  because you haven’t done
   6665      anything yet after rebase stopped at the commit, then this commit
   6666      is shown in blue, not green).  There can only be a green *and* a
   6667      blue commit at the same time, if you create one or more new commits
   6668      after rebase stops at a commit.
   6669 
   6670    • Red commits have been dropped.  They are shown for reference only,
   6671      e.g.  to make it easier to diff.
   6672 
   6673    Of course these colors are subject to the color-theme in use.
   6674 
   6675    The following words are used:
   6676 
   6677    • Commits prefixed with ‘pick’, ‘reword’, ‘edit’, ‘squash’, and
   6678      ‘fixup’ have not been applied yet.  These words have the same
   6679      meaning here as they do in the buffer used to edit the rebase
   6680      sequence.  See *note Editing Rebase Sequences::.  When the
   6681      ‘--rebase-merges’ option was specified, ‘reset’, ‘label’, and
   6682      ‘merge’ lines may also be present.
   6683 
   6684    • Commits prefixed with ‘done’ and ‘onto’ have already been applied.
   6685      It is possible for such a commit to be the ‘HEAD’, in which case it
   6686      is blue.  Otherwise it is grey.
   6687 
   6688         • The commit prefixed with ‘onto’ is the commit on top of which
   6689           all the other commits are being re-applied.  This commit
   6690           itself did not have to be re-applied, it is the commit rebase
   6691           did rewind to before starting to re-apply other commits.
   6692 
   6693         • Commits prefixed with ‘done’ have already been re-applied.
   6694           This includes commits that have been re-applied but also new
   6695           commits that you have created during the rebase.
   6696 
   6697    • All other commits, those not prefixed with any of the above words,
   6698      are in some way related to the commit at which rebase stopped.
   6699 
   6700      To determine whether a commit is related to the stopped-at commit
   6701      their hashes, trees and patch-ids (1) are being compared.  The
   6702      commit message is not used for this purpose.
   6703 
   6704      Generally speaking commits that are related to the stopped-at
   6705      commit can have any of the used colors, though not all color/word
   6706      combinations are possible.
   6707 
   6708      Words used for stopped-at commits are:
   6709 
   6710         • When a commit is prefixed with ‘void’, then that indicates
   6711           that Magit knows for sure that all the changes in that commit
   6712           have been applied using several new commits.  This commit is
   6713           no longer reachable from ‘HEAD’, and it also isn’t one of the
   6714           commits that will be applied when resuming the session.
   6715 
   6716         • When a commit is prefixed with ‘join’, then that indicates
   6717           that the rebase sequence stopped at that commit due to a
   6718           conflict - you now have to join (merge) the changes with what
   6719           has already been applied.  In a sense this is the commit
   6720           rebase stopped at, but while its effect is already in the
   6721           index and in the worktree (with conflict markers), the commit
   6722           itself has not actually been applied yet (it isn’t the
   6723           ‘HEAD’).  So it is shown in yellow, like the other commits
   6724           that still have to be applied.
   6725 
   6726         • When a commit is prefixed with ‘stop’ or a _blue_ or _green_
   6727           ‘same’, then that indicates that rebase stopped at this
   6728           commit, that it is still applied or has been applied again,
   6729           and that at least its patch-id is unchanged.
   6730 
   6731              • When a commit is prefixed with ‘stop’, then that
   6732                indicates that rebase stopped at that commit because you
   6733                requested that earlier, and its patch-id is unchanged.
   6734                It might even still be the exact same commit.
   6735 
   6736              • When a commit is prefixed with a _blue_ or _green_
   6737                ‘same’, then that indicates that while its tree or hash
   6738                changed, its patch-id did not.  If it is blue, then it is
   6739                the ‘HEAD’ commit (as always for blue).  When it is
   6740                green, then it no longer is ‘HEAD’ because other commit
   6741                have been created since (but before continuing the
   6742                rebase).
   6743 
   6744         • When a commit is prefixed with ‘goal’, a _yellow_ ‘same,’ or
   6745           ‘work’, then that indicates that rebase applied that commit
   6746           but that you then reset ‘HEAD’ to an earlier commit (likely to
   6747           split it up into multiple commits), and that there are some
   6748           uncommitted changes remaining which likely (but not
   6749           necessarily) originate from that commit.
   6750 
   6751              • When a commit is prefixed with ‘goal’, then that
   6752                indicates that it is still possible to create a new
   6753                commit with the exact same tree (the "goal") without
   6754                manually editing any files, by committing the index, or
   6755                by staging all changes and then committing that.  This is
   6756                the case when the original tree still exists in the index
   6757                or worktree in untainted form.
   6758 
   6759              • When a commit is prefixed with a yellow ‘same’, then that
   6760                indicates that it is no longer possible to create a
   6761                commit with the exact same tree, but that it is still
   6762                possible to create a commit with the same patch-id.  This
   6763                would be the case if you created a new commit with other
   6764                changes, but the changes from the original commit still
   6765                exist in the index or working tree in untainted form.
   6766 
   6767              • When a commit is prefixed with ‘work’, then that
   6768                indicates that you reset ‘HEAD’ to an earlier commit, and
   6769                that there are some staged and/or unstaged changes
   6770                (likely, but not necessarily) originating from that
   6771                commit.  However it is no longer possible to create a new
   6772                commit with the same tree or at least the same patch-id
   6773                because you have already made other changes.
   6774 
   6775         • When a commit is prefixed with ‘poof’ or ‘gone’, then that
   6776           indicates that rebase applied that commit but that you then
   6777           reset ‘HEAD’ to an earlier commit (likely to split it up into
   6778           multiple commits), and that there are no uncommitted changes.
   6779 
   6780              • When a commit is prefixed with ‘poof’, then that
   6781                indicates that it is no longer reachable from ‘HEAD’, but
   6782                that it has been replaced with one or more commits, which
   6783                together have the exact same effect.
   6784 
   6785              • When a commit is prefixed with ‘gone’, then that
   6786                indicates that it is no longer reachable from ‘HEAD’ and
   6787                that we also cannot determine whether its changes are
   6788                still in effect in one or more new commits.  They might
   6789                be, but if so, then there must also be other changes
   6790                which makes it impossible to know for sure.
   6791 
   6792    Do not worry if you do not fully understand the above.  That’s okay,
   6793 you will acquire a good enough understanding through practice.
   6794 
   6795    For other sequence operations such as cherry-picking, a similar
   6796 section is displayed, but they lack some of the features described
   6797 above, due to limitations in the git commands used to implement them.
   6798 Most importantly these sequences only support "picking" a commit but not
   6799 other actions such as "rewording", and they do not keep track of the
   6800 commits which have already been applied.
   6801 
   6802    ---------- Footnotes ----------
   6803 
   6804    (1) The patch-id is a hash of the _changes_ introduced by a commit.
   6805 It differs from the hash of the commit itself, which is a hash of the
   6806 result of applying that change (i.e.  the resulting trees and blobs) as
   6807 well as author and committer information, the commit message, and the
   6808 hashes of the parents of the commit.  The patch-id hash on the other
   6809 hand is created only from the added and removed lines, even line numbers
   6810 and whitespace changes are ignored when calculating this hash.  The
   6811 patch-ids of two commits can be used to answer the question "Do these
   6812 commits make the same change?".
   6813 
   6814 
   6815 File: magit.info,  Node: Cherry Picking,  Next: Resetting,  Prev: Rebasing,  Up: Manipulating
   6816 
   6817 6.10 Cherry Picking
   6818 ===================
   6819 
   6820 Also see *note (gitman)git-cherry-pick::.
   6821 
   6822 ‘A’     (‘magit-cherry-pick’)
   6823 
   6824      This transient prefix command binds the following suffix commands
   6825      along with the appropriate infix arguments and displays them in a
   6826      temporary buffer until a suffix is invoked.
   6827 
   6828    When no cherry-pick or revert is in progress, then the transient
   6829 features the following suffix commands.
   6830 
   6831 ‘A A’     (‘magit-cherry-copy’)
   6832 
   6833      This command copies COMMITS from another branch onto the current
   6834      branch.  If the region selects multiple commits, then those are
   6835      copied, without prompting.  Otherwise the user is prompted for a
   6836      commit or range, defaulting to the commit at point.
   6837 
   6838 ‘A a’     (‘magit-cherry-apply’)
   6839 
   6840      This command applies the changes in COMMITS from another branch
   6841      onto the current branch.  If the region selects multiple commits,
   6842      then those are used, without prompting.  Otherwise the user is
   6843      prompted for a commit or range, defaulting to the commit at point.
   6844 
   6845      This command also has a top-level binding, which can be invoked
   6846      without using the transient by typing ‘a’ at the top-level.
   6847 
   6848    The following commands not only apply some commits to some branch,
   6849 but also remove them from some other branch.  The removal is performed
   6850 using either ‘git-update-ref’ or if necessary ‘git-rebase’.  Both
   6851 applying commits as well as removing them using ‘git-rebase’ can lead to
   6852 conflicts.  If that happens, then these commands abort and you not only
   6853 have to resolve the conflicts but also finish the process the same way
   6854 you would have to if these commands didn’t exist at all.
   6855 
   6856 ‘A h’     (‘magit-cherry-harvest’)
   6857 
   6858      This command moves the selected COMMITS that must be located on
   6859      another BRANCH onto the current branch instead, removing them from
   6860      the former.  When this command succeeds, then the same branch is
   6861      current as before.
   6862 
   6863      Applying the commits on the current branch or removing them from
   6864      the other branch can lead to conflicts.  When that happens, then
   6865      this command stops and you have to resolve the conflicts and then
   6866      finish the process manually.
   6867 
   6868 ‘A d’     (‘magit-cherry-donate’)
   6869 
   6870      This command moves the selected COMMITS from the current branch
   6871      onto another existing BRANCH, removing them from the former.  When
   6872      this command succeeds, then the same branch is current as before.
   6873 
   6874      Applying the commits on the other branch or removing them from the
   6875      current branch can lead to conflicts.  When that happens, then this
   6876      command stops and you have to resolve the conflicts and then finish
   6877      the process manually.
   6878 
   6879 ‘A n’     (‘magit-cherry-spinout’)
   6880 
   6881      This command moves the selected COMMITS from the current branch
   6882      onto a new branch BRANCH, removing them from the former.  When this
   6883      command succeeds, then the same branch is current as before.
   6884 
   6885      Applying the commits on the other branch or removing them from the
   6886      current branch can lead to conflicts.  When that happens, then this
   6887      command stops and you have to resolve the conflicts and then finish
   6888      the process manually.
   6889 
   6890 ‘A s’     (‘magit-cherry-spinoff’)
   6891 
   6892      This command moves the selected COMMITS from the current branch
   6893      onto a new branch BRANCH, removing them from the former.  When this
   6894      command succeeds, then the new branch is checked out.
   6895 
   6896      Applying the commits on the other branch or removing them from the
   6897      current branch can lead to conflicts.  When that happens, then this
   6898      command stops and you have to resolve the conflicts and then finish
   6899      the process manually.
   6900 
   6901    When a cherry-pick or revert is in progress, then the transient
   6902 instead features the following suffix commands.
   6903 
   6904 ‘A A’     (‘magit-sequence-continue’)
   6905 
   6906      Resume the current cherry-pick or revert sequence.
   6907 
   6908 ‘A s’     (‘magit-sequence-skip’)
   6909 
   6910      Skip the stopped at commit during a cherry-pick or revert sequence.
   6911 
   6912 ‘A a’     (‘magit-sequence-abort’)
   6913 
   6914      Abort the current cherry-pick or revert sequence.  This discards
   6915      all changes made since the sequence started.
   6916 
   6917 * Menu:
   6918 
   6919 * Reverting::
   6920 
   6921 
   6922 File: magit.info,  Node: Reverting,  Up: Cherry Picking
   6923 
   6924 6.10.1 Reverting
   6925 ----------------
   6926 
   6927 ‘V’     (‘magit-revert’)
   6928 
   6929      This transient prefix command binds the following suffix commands
   6930      along with the appropriate infix arguments and displays them in a
   6931      temporary buffer until a suffix is invoked.
   6932 
   6933    When no cherry-pick or revert is in progress, then the transient
   6934 features the following suffix commands.
   6935 
   6936 ‘V V’     (‘magit-revert-and-commit’)
   6937 
   6938      Revert a commit by creating a new commit.  Prompt for a commit,
   6939      defaulting to the commit at point.  If the region selects multiple
   6940      commits, then revert all of them, without prompting.
   6941 
   6942 ‘V v’     (‘magit-revert-no-commit’)
   6943 
   6944      Revert a commit by applying it in reverse to the working tree.
   6945      Prompt for a commit, defaulting to the commit at point.  If the
   6946      region selects multiple commits, then revert all of them, without
   6947      prompting.
   6948 
   6949    When a cherry-pick or revert is in progress, then the transient
   6950 instead features the following suffix commands.
   6951 
   6952 ‘V A’     (‘magit-sequence-continue’)
   6953 
   6954      Resume the current cherry-pick or revert sequence.
   6955 
   6956 ‘V s’     (‘magit-sequence-skip’)
   6957 
   6958      Skip the stopped at commit during a cherry-pick or revert sequence.
   6959 
   6960 ‘V a’     (‘magit-sequence-abort’)
   6961 
   6962      Abort the current cherry-pick or revert sequence.  This discards
   6963      all changes made since the sequence started.
   6964 
   6965 
   6966 File: magit.info,  Node: Resetting,  Next: Stashing,  Prev: Cherry Picking,  Up: Manipulating
   6967 
   6968 6.11 Resetting
   6969 ==============
   6970 
   6971 Also see *note (gitman)git-reset::.
   6972 
   6973 ‘x’     (‘magit-reset-quickly’)
   6974 
   6975      Reset the ‘HEAD’ and index to some commit read from the user and
   6976      defaulting to the commit at point, and possibly also reset the
   6977      working tree.  With a prefix argument reset the working tree
   6978      otherwise don’t.
   6979 
   6980 ‘X m’     (‘magit-reset-mixed’)
   6981 
   6982      Reset the ‘HEAD’ and index to some commit read from the user and
   6983      defaulting to the commit at point.  The working tree is kept as-is.
   6984 
   6985 ‘X s’     (‘magit-reset-soft’)
   6986 
   6987      Reset the ‘HEAD’ to some commit read from the user and defaulting
   6988      to the commit at point.  The index and the working tree are kept
   6989      as-is.
   6990 
   6991 ‘X h’     (‘magit-reset-hard’)
   6992 
   6993      Reset the ‘HEAD’, index, and working tree to some commit read from
   6994      the user and defaulting to the commit at point.
   6995 
   6996 ‘X k’     (‘magit-reset-keep’)
   6997 
   6998      Reset the ‘HEAD’, index, and working tree to some commit read from
   6999      the user and defaulting to the commit at point.  Uncommitted
   7000      changes are kept as-is.
   7001 
   7002 ‘X i’     (‘magit-reset-index’)
   7003 
   7004      Reset the index to some commit read from the user and defaulting to
   7005      the commit at point.  Keep the ‘HEAD’ and working tree as-is, so if
   7006      the commit refers to the ‘HEAD’, then this effectively unstages all
   7007      changes.
   7008 
   7009 ‘X w’     (‘magit-reset-worktree’)
   7010 
   7011      Reset the working tree to some commit read from the user and
   7012      defaulting to the commit at point.  Keep the ‘HEAD’ and index
   7013      as-is.
   7014 
   7015 ‘X f’     (‘magit-file-checkout’)
   7016 
   7017      Update file in the working tree and index to the contents from a
   7018      revision.  Both the revision and file are read from the user.
   7019 
   7020 
   7021 File: magit.info,  Node: Stashing,  Prev: Resetting,  Up: Manipulating
   7022 
   7023 6.12 Stashing
   7024 =============
   7025 
   7026 Also see *note (gitman)git-stash::.
   7027 
   7028 ‘z’     (‘magit-stash’)
   7029 
   7030      This transient prefix command binds the following suffix commands
   7031      along with the appropriate infix arguments and displays them in a
   7032      temporary buffer until a suffix is invoked.
   7033 
   7034 ‘z z’     (‘magit-stash-both’)
   7035 
   7036      Create a stash of the index and working tree.  Untracked files are
   7037      included according to infix arguments.  One prefix argument is
   7038      equivalent to ‘--include-untracked’ while two prefix arguments are
   7039      equivalent to ‘--all’.
   7040 
   7041 ‘z i’     (‘magit-stash-index’)
   7042 
   7043      Create a stash of the index only.  Unstaged and untracked changes
   7044      are not stashed.
   7045 
   7046 ‘z w’     (‘magit-stash-worktree’)
   7047 
   7048      Create a stash of unstaged changes in the working tree.  Untracked
   7049      files are included according to infix arguments.  One prefix
   7050      argument is equivalent to ‘--include-untracked’ while two prefix
   7051      arguments are equivalent to ‘--all’.
   7052 
   7053 ‘z x’     (‘magit-stash-keep-index’)
   7054 
   7055      Create a stash of the index and working tree, keeping index intact.
   7056      Untracked files are included according to infix arguments.  One
   7057      prefix argument is equivalent to ‘--include-untracked’ while two
   7058      prefix arguments are equivalent to ‘--all’.
   7059 
   7060 ‘z Z’     (‘magit-snapshot-both’)
   7061 
   7062      Create a snapshot of the index and working tree.  Untracked files
   7063      are included according to infix arguments.  One prefix argument is
   7064      equivalent to ‘--include-untracked’ while two prefix arguments are
   7065      equivalent to ‘--all’.
   7066 
   7067 ‘z I’     (‘magit-snapshot-index’)
   7068 
   7069      Create a snapshot of the index only.  Unstaged and untracked
   7070      changes are not stashed.
   7071 
   7072 ‘z W’     (‘magit-snapshot-worktree’)
   7073 
   7074      Create a snapshot of unstaged changes in the working tree.
   7075      Untracked files are included according to infix arguments.  One
   7076      prefix argument is equivalent to ‘--include-untracked’ while two
   7077      prefix arguments are equivalent to ‘--all’-.
   7078 
   7079 ‘z a’     (‘magit-stash-apply’)
   7080 
   7081      Apply a stash to the working tree.  Try to preserve the stash
   7082      index.  If that fails because there are staged changes, apply
   7083      without preserving the stash index.
   7084 
   7085 ‘z p’     (‘magit-stash-pop’)
   7086 
   7087      Apply a stash to the working tree and remove it from stash list.
   7088      Try to preserve the stash index.  If that fails because there are
   7089      staged changes, apply without preserving the stash index and forgo
   7090      removing the stash.
   7091 
   7092 ‘z k’     (‘magit-stash-drop’)
   7093 
   7094      Remove a stash from the stash list.  When the region is active,
   7095      offer to drop all contained stashes.
   7096 
   7097 ‘z v’     (‘magit-stash-show’)
   7098 
   7099      Show all diffs of a stash in a buffer.
   7100 
   7101 ‘z b’     (‘magit-stash-branch’)
   7102 
   7103      Create and checkout a new BRANCH from STASH.  The branch starts at
   7104      the commit that was current when the stash was created.
   7105 
   7106 ‘z B’     (‘magit-stash-branch-here’)
   7107 
   7108      Create and checkout a new BRANCH using ‘magit-branch’ with the
   7109      current branch or ‘HEAD’ as the starting-point.  Then apply STASH,
   7110      dropping it if it applies cleanly.
   7111 
   7112 ‘z f’     (‘magit-stash-format-patch’)
   7113 
   7114      Create a patch from STASH.
   7115 
   7116 ‘k’     (‘magit-stash-clear’)
   7117 
   7118      Remove all stashes saved in REF’s reflog by deleting REF.
   7119 
   7120 ‘z l’     (‘magit-stash-list’)
   7121 
   7122      List all stashes in a buffer.
   7123 
   7124  -- User Option: magit-stashes-margin
   7125 
   7126      This option specifies whether the margin is initially shown in
   7127      stashes buffers and how it is formatted.
   7128 
   7129      The value has the form ‘(INIT STYLE WIDTH AUTHOR AUTHOR-WIDTH)’.
   7130 
   7131         • If INIT is non-nil, then the margin is shown initially.
   7132 
   7133         • STYLE controls how to format the author or committer date.  It
   7134           can be one of ‘age’ (to show the age of the commit),
   7135           ‘age-abbreviated’ (to abbreviate the time unit to a
   7136           character), or a string (suitable for ‘format-time-string’) to
   7137           show the actual date.  Option
   7138           ‘magit-log-margin-show-committer-date’ controls which date is
   7139           being displayed.
   7140 
   7141         • WIDTH controls the width of the margin.  This exists for
   7142           forward compatibility and currently the value should not be
   7143           changed.
   7144 
   7145         • AUTHOR controls whether the name of the author is also shown
   7146           by default.
   7147 
   7148         • AUTHOR-WIDTH has to be an integer.  When the name of the
   7149           author is shown, then this specifies how much space is used to
   7150           do so.
   7151 
   7152 
   7153 File: magit.info,  Node: Transferring,  Next: Miscellaneous,  Prev: Manipulating,  Up: Top
   7154 
   7155 7 Transferring
   7156 **************
   7157 
   7158 * Menu:
   7159 
   7160 * Remotes::
   7161 * Fetching::
   7162 * Pulling::
   7163 * Pushing::
   7164 * Plain Patches::
   7165 * Maildir Patches::
   7166 
   7167 
   7168 File: magit.info,  Node: Remotes,  Next: Fetching,  Up: Transferring
   7169 
   7170 7.1 Remotes
   7171 ===========
   7172 
   7173 * Menu:
   7174 
   7175 * Remote Commands::
   7176 * Remote Git Variables::
   7177 
   7178 
   7179 File: magit.info,  Node: Remote Commands,  Next: Remote Git Variables,  Up: Remotes
   7180 
   7181 7.1.1 Remote Commands
   7182 ---------------------
   7183 
   7184 The transient prefix command ‘magit-remote’ is used to add remotes and
   7185 to make changes to existing remotes.  This command only deals with
   7186 remotes themselves, not with branches or the transfer of commits.  Those
   7187 features are available from separate transient commands.
   7188 
   7189    Also see *note (gitman)git-remote::.
   7190 
   7191 ‘M’     (‘magit-remote’)
   7192 
   7193      This transient prefix command binds the following suffix commands
   7194      and displays them in a temporary buffer until a suffix is invoked.
   7195 
   7196      By default it also binds and displays the values of some
   7197      remote-related Git variables and allows changing their values.
   7198 
   7199  -- User Option: magit-remote-direct-configure
   7200 
   7201      This option controls whether remote-related Git variables are
   7202      accessible directly from the transient ‘magit-remote’.
   7203 
   7204      If ‘t’ (the default) and a local branch is checked out, then
   7205      ‘magit-remote’ features the variables for the upstream remote of
   7206      that branch, or if ‘HEAD’ is detached, for ‘origin’, provided that
   7207      exists.
   7208 
   7209      If ‘nil’, then ‘magit-remote-configure’ has to be used to do so.
   7210 
   7211 ‘M C’     (‘magit-remote-configure’)
   7212 
   7213      This transient prefix command binds commands that set the value of
   7214      remote-related variables and displays them in a temporary buffer
   7215      until the transient is exited.
   7216 
   7217      With a prefix argument, this command always prompts for a remote.
   7218 
   7219      Without a prefix argument this depends on whether it was invoked as
   7220      a suffix of ‘magit-remote’ and on the
   7221      ‘magit-remote-direct-configure’ option.  If ‘magit-remote’ already
   7222      displays the variables for the upstream, then it does not make
   7223      sense to invoke another transient that displays them for the same
   7224      remote.  In that case this command prompts for a remote.
   7225 
   7226    The variables are described in *note Remote Git Variables::.
   7227 
   7228 ‘M a’     (‘magit-remote-add’)
   7229 
   7230      This command add a remote and fetches it.  The remote name and url
   7231      are read in the minibuffer.
   7232 
   7233 ‘M r’     (‘magit-remote-rename’)
   7234 
   7235      This command renames a remote.  Both the old and the new names are
   7236      read in the minibuffer.
   7237 
   7238 ‘M u’     (‘magit-remote-set-url’)
   7239 
   7240      This command changes the url of a remote.  Both the remote and the
   7241      new url are read in the minibuffer.
   7242 
   7243 ‘M k’     (‘magit-remote-remove’)
   7244 
   7245      This command deletes a remote, read in the minibuffer.
   7246 
   7247 ‘M p’     (‘magit-remote-prune’)
   7248 
   7249      This command removes stale remote-tracking branches for a remote
   7250      read in the minibuffer.
   7251 
   7252 ‘M P’     (‘magit-remote-prune-refspecs’)
   7253 
   7254      This command removes stale refspecs for a remote read in the
   7255      minibuffer.
   7256 
   7257      A refspec is stale if there no longer exists at least one branch on
   7258      the remote that would be fetched due to that refspec.  A stale
   7259      refspec is problematic because its existence causes Git to refuse
   7260      to fetch according to the remaining non-stale refspecs.
   7261 
   7262      If only stale refspecs remain, then this command offers to either
   7263      delete the remote or to replace the stale refspecs with the default
   7264      refspec ("+refs/heads/*:refs/remotes/REMOTE/*").
   7265 
   7266      This command also removes the remote-tracking branches that were
   7267      created due to the now stale refspecs.  Other stale branches are
   7268      not removed.
   7269 
   7270  -- User Option: magit-remote-add-set-remote.pushDefault
   7271 
   7272      This option controls whether the user is asked whether they want to
   7273      set ‘remote.pushDefault’ after adding a remote.
   7274 
   7275      If ‘ask’, then users is always ask.  If ‘ask-if-unset’, then the
   7276      user is only if the variable isn’t set already.  If ‘nil’, then the
   7277      user isn’t asked and the variable isn’t set.  If the value is a
   7278      string, then the variable is set without the user being asked,
   7279      provided that the name of the added remote is equal to that string
   7280      and the variable isn’t already set.
   7281 
   7282 
   7283 File: magit.info,  Node: Remote Git Variables,  Prev: Remote Commands,  Up: Remotes
   7284 
   7285 7.1.2 Remote Git Variables
   7286 --------------------------
   7287 
   7288 These variables can be set from the transient prefix command
   7289 ‘magit-remote-configure’.  By default they can also be set from
   7290 ‘magit-remote’.  See *note Remote Commands::.
   7291 
   7292  -- Variable: remote.NAME.url
   7293 
   7294      This variable specifies the url of the remote named NAME.  It can
   7295      have multiple values.
   7296 
   7297  -- Variable: remote.NAME.fetch
   7298 
   7299      The refspec used when fetching from the remote named NAME.  It can
   7300      have multiple values.
   7301 
   7302  -- Variable: remote.NAME.pushurl
   7303 
   7304      This variable specifies the url used for fetching from the remote
   7305      named NAME.  If it is not specified, then ‘remote.NAME.url’ is used
   7306      instead.  It can have multiple values.
   7307 
   7308  -- Variable: remote.NAME.push
   7309 
   7310      The refspec used when pushing to the remote named NAME.  It can
   7311      have multiple values.
   7312 
   7313  -- Variable: remote.NAME.tagOpts
   7314 
   7315      This variable specifies what tags are fetched by default.  If the
   7316      value is ‘--no-tags’ then no tags are fetched.  If the value is
   7317      ‘--tags’, then all tags are fetched.  If this variable has no
   7318      value, then only tags are fetched that are reachable from fetched
   7319      branches.
   7320 
   7321 
   7322 File: magit.info,  Node: Fetching,  Next: Pulling,  Prev: Remotes,  Up: Transferring
   7323 
   7324 7.2 Fetching
   7325 ============
   7326 
   7327 Also see *note (gitman)git-fetch::.  For information about the upstream
   7328 and the push-remote, see *note The Two Remotes::.
   7329 
   7330 ‘f’     (‘magit-fetch’)
   7331 
   7332      This transient prefix command binds the following suffix commands
   7333      along with the appropriate infix arguments and displays them in a
   7334      temporary buffer until a suffix is invoked.
   7335 
   7336 ‘f p’     (‘magit-fetch-from-pushremote’)
   7337 
   7338      This command fetches from the current push-remote.
   7339 
   7340      With a prefix argument or when the push-remote is either not
   7341      configured or unusable, then let the user first configure the
   7342      push-remote.
   7343 
   7344 ‘f u’     (‘magit-fetch-from-upstream’)
   7345 
   7346      This command fetch from the upstream of the current branch.
   7347 
   7348      If the upstream is configured for the current branch and names an
   7349      existing remote, then use that.  Otherwise try to use another
   7350      remote: If only a single remote is configured, then use that.
   7351      Otherwise if a remote named "origin" exists, then use that.
   7352 
   7353      If no remote can be determined, then this command is not available
   7354      from the ‘magit-fetch’ transient prefix and invoking it directly
   7355      results in an error.
   7356 
   7357 ‘f e’     (‘magit-fetch-other’)
   7358 
   7359      This command fetch from a repository read from the minibuffer.
   7360 
   7361 ‘f o’     (‘magit-fetch-branch’)
   7362 
   7363      This command fetches a branch from a remote, both of which are read
   7364      from the minibuffer.
   7365 
   7366 ‘f r’     (‘magit-fetch-refspec’)
   7367 
   7368      This command fetches from a remote using an explicit refspec, both
   7369      of which are read from the minibuffer.
   7370 
   7371 ‘f a’     (‘magit-fetch-all’)
   7372 
   7373      This command fetches from all remotes.
   7374 
   7375 ‘f m’     (‘magit-submodule-fetch’)
   7376 
   7377      This command fetches all submodules.  With a prefix argument it
   7378      fetches all remotes of all submodules.
   7379 
   7380  -- User Option: magit-pull-or-fetch
   7381 
   7382      By default fetch and pull commands are available from separate
   7383      transient prefix command.  Setting this to ‘t’ adds some (but not
   7384      all) of the above suffix commands to the ‘magit-pull’ transient.
   7385 
   7386      If you do that, then you might also want to change the key binding
   7387      for these prefix commands, e.g.:
   7388 
   7389           (setq magit-pull-or-fetch t)
   7390           (define-key magit-mode-map "f" 'magit-pull) ; was magit-fetch
   7391           (define-key magit-mode-map "F" nil)         ; was magit-pull
   7392 
   7393 
   7394 File: magit.info,  Node: Pulling,  Next: Pushing,  Prev: Fetching,  Up: Transferring
   7395 
   7396 7.3 Pulling
   7397 ===========
   7398 
   7399 Also see *note (gitman)git-pull::.  For information about the upstream
   7400 and the push-remote, see *note The Two Remotes::.
   7401 
   7402 ‘F’     (‘magit-pull’)
   7403 
   7404      This transient prefix command binds the following suffix commands
   7405      and displays them in a temporary buffer until a suffix is invoked.
   7406 
   7407 ‘F p’     (‘magit-pull-from-pushremote’)
   7408 
   7409      This command pulls from the push-remote of the current branch.
   7410 
   7411      With a prefix argument or when the push-remote is either not
   7412      configured or unusable, then let the user first configure the
   7413      push-remote.
   7414 
   7415 ‘F u’     (‘magit-pull-from-upstream’)
   7416 
   7417      This command pulls from the upstream of the current branch.
   7418 
   7419      With a prefix argument or when the upstream is either not
   7420      configured or unusable, then let the user first configure the
   7421      upstream.
   7422 
   7423 ‘F e’     (‘magit-pull-branch’)
   7424 
   7425      This command pulls from a branch read in the minibuffer.
   7426 
   7427 
   7428 File: magit.info,  Node: Pushing,  Next: Plain Patches,  Prev: Pulling,  Up: Transferring
   7429 
   7430 7.4 Pushing
   7431 ===========
   7432 
   7433 Also see *note (gitman)git-push::.  For information about the upstream
   7434 and the push-remote, see *note The Two Remotes::.
   7435 
   7436 ‘P’     (‘magit-push’)
   7437 
   7438      This transient prefix command binds the following suffix commands
   7439      along with the appropriate infix arguments and displays them in a
   7440      temporary buffer until a suffix is invoked.
   7441 
   7442 ‘P p’     (‘magit-push-current-to-pushremote’)
   7443 
   7444      This command pushes the current branch to its push-remote.
   7445 
   7446      With a prefix argument or when the push-remote is either not
   7447      configured or unusable, then let the user first configure the
   7448      push-remote.
   7449 
   7450 ‘P u’     (‘magit-push-current-to-upstream’)
   7451 
   7452      This command pushes the current branch to its upstream branch.
   7453 
   7454      With a prefix argument or when the upstream is either not
   7455      configured or unusable, then let the user first configure the
   7456      upstream.
   7457 
   7458 ‘P e’     (‘magit-push-current’)
   7459 
   7460      This command pushes the current branch to a branch read in the
   7461      minibuffer.
   7462 
   7463 ‘P o’     (‘magit-push-other’)
   7464 
   7465      This command pushes an arbitrary branch or commit somewhere.  Both
   7466      the source and the target are read in the minibuffer.
   7467 
   7468 ‘P r’     (‘magit-push-refspecs’)
   7469 
   7470      This command pushes one or multiple refspecs to a remote, both of
   7471      which are read in the minibuffer.
   7472 
   7473      To use multiple refspecs, separate them with commas.  Completion is
   7474      only available for the part before the colon, or when no colon is
   7475      used.
   7476 
   7477 ‘P m’     (‘magit-push-matching’)
   7478 
   7479      This command pushes all matching branches to another repository.
   7480 
   7481      If only one remote exists, then push to that.  Otherwise prompt for
   7482      a remote, offering the remote configured for the current branch as
   7483      default.
   7484 
   7485 ‘P t’     (‘magit-push-tags’)
   7486 
   7487      This command pushes all tags to another repository.
   7488 
   7489      If only one remote exists, then push to that.  Otherwise prompt for
   7490      a remote, offering the remote configured for the current branch as
   7491      default.
   7492 
   7493 ‘P T’     (‘magit-push-tag’)
   7494 
   7495      This command pushes a tag to another repository.
   7496 
   7497    One of the infix arguments, ‘--force-with-lease’, deserves a word of
   7498 caution.  It is passed without a value, which means "permit a force push
   7499 as long as the remote-tracking branches match their counterparts on the
   7500 remote end".  If you’ve set up a tool to do automatic fetches (Magit
   7501 itself does not provide such functionality), using ‘--force-with-lease’
   7502 can be dangerous because you don’t actually control or know the state of
   7503 the remote-tracking refs.  In that case, you should consider setting
   7504 ‘push.useForceIfIncludes’ to ‘true’ (available since Git 2.30).
   7505 
   7506    Two more push commands exist, which by default are not available from
   7507 the push transient.  See their doc-strings for instructions on how to
   7508 add them to the transient.
   7509 
   7510  -- Command: magit-push-implicitly args
   7511 
   7512      This command pushes somewhere without using an explicit refspec.
   7513 
   7514      This command simply runs ‘git push -v [ARGS]’.  ARGS are the infix
   7515      arguments.  No explicit refspec arguments are used.  Instead the
   7516      behavior depends on at least these Git variables: ‘push.default’,
   7517      ‘remote.pushDefault’, ‘branch.<branch>.pushRemote’,
   7518      ‘branch.<branch>.remote’, ‘branch.<branch>.merge’, and
   7519      ‘remote.<remote>.push’.
   7520 
   7521      If you add this suffix to a transient prefix without explicitly
   7522      specifying the description, then an attempt is made to predict what
   7523      this command will do.  For example:
   7524 
   7525           (transient-insert-suffix 'magit-push \"p\"
   7526             '(\"i\" magit-push-implicitly))"
   7527 
   7528  -- Command: magit-push-to-remote remote args
   7529 
   7530      This command pushes to the remote REMOTE without using an explicit
   7531      refspec.  The remote is read in the minibuffer.
   7532 
   7533      This command simply runs ‘git push -v [ARGS] REMOTE’.  ARGS are the
   7534      infix arguments.  No refspec arguments are used.  Instead the
   7535      behavior depends on at least these Git variables: ‘push.default’,
   7536      ‘remote.pushDefault’, ‘branch.<branch>.pushRemote’,
   7537      ‘branch.<branch>.remote’, ‘branch.<branch>.merge’, and
   7538      ‘remote.<remote>.push’.
   7539 
   7540 
   7541 File: magit.info,  Node: Plain Patches,  Next: Maildir Patches,  Prev: Pushing,  Up: Transferring
   7542 
   7543 7.5 Plain Patches
   7544 =================
   7545 
   7546 ‘W’     (‘magit-patch’)
   7547 
   7548      This transient prefix command binds the following suffix commands
   7549      along with the appropriate infix arguments and displays them in a
   7550      temporary buffer until a suffix is invoked.
   7551 
   7552 ‘W c’     (‘magit-patch-create’)
   7553 
   7554      This command creates patches for a set commits.  If the region
   7555      marks several commits, then it creates patches for all of them.
   7556      Otherwise it functions as a transient prefix command, which
   7557      features several infix arguments and binds itself as a suffix
   7558      command.  When this command is invoked as a suffix of itself, then
   7559      it creates a patch using the specified infix arguments.
   7560 
   7561 ‘w a’     (‘magit-patch-apply’)
   7562 
   7563      This command applies a patch.  This is a transient prefix command,
   7564      which features several infix arguments and binds itself as a suffix
   7565      command.  When this command is invoked as a suffix of itself, then
   7566      it applies a patch using the specified infix arguments.
   7567 
   7568 ‘W s’     (‘magit-patch-save’)
   7569 
   7570      This command creates a patch from the current diff.
   7571 
   7572      Inside ‘magit-diff-mode’ or ‘magit-revision-mode’ buffers, ‘C-x
   7573      C-w’ is also bound to this command.
   7574 
   7575    It is also possible to save a plain patch file by using ‘C-x C-w’
   7576 inside a ‘magit-diff-mode’ or ‘magit-revision-mode’ buffer.
   7577 
   7578 
   7579 File: magit.info,  Node: Maildir Patches,  Prev: Plain Patches,  Up: Transferring
   7580 
   7581 7.6 Maildir Patches
   7582 ===================
   7583 
   7584 Also see *note (gitman)git-am::.  and *note (gitman)git-apply::.
   7585 
   7586 ‘w’     (‘magit-am’)
   7587 
   7588      This transient prefix command binds the following suffix commands
   7589      along with the appropriate infix arguments and displays them in a
   7590      temporary buffer until a suffix is invoked.
   7591 
   7592 ‘w w’     (‘magit-am-apply-patches’)
   7593 
   7594      This command applies one or more patches.  If the region marks
   7595      files, then those are applied as patches.  Otherwise this command
   7596      reads a file-name in the minibuffer, defaulting to the file at
   7597      point.
   7598 
   7599 ‘w m’     (‘magit-am-apply-maildir’)
   7600 
   7601      This command applies patches from a maildir.
   7602 
   7603 ‘w a’     (‘magit-patch-apply’)
   7604 
   7605      This command applies a plain patch.  For a longer description see
   7606      *note Plain Patches::.  This command is only available from the
   7607      ‘magit-am’ transient for historic reasons.
   7608 
   7609    When an "am" operation is in progress, then the transient instead
   7610 features the following suffix commands.
   7611 
   7612 ‘w w’     (‘magit-am-continue’)
   7613 
   7614      This command resumes the current patch applying sequence.
   7615 
   7616 ‘w s’     (‘magit-am-skip’)
   7617 
   7618      This command skips the stopped at patch during a patch applying
   7619      sequence.
   7620 
   7621 ‘w a’     (‘magit-am-abort’)
   7622 
   7623      This command aborts the current patch applying sequence.  This
   7624      discards all changes made since the sequence started.
   7625 
   7626 
   7627 File: magit.info,  Node: Miscellaneous,  Next: Customizing,  Prev: Transferring,  Up: Top
   7628 
   7629 8 Miscellaneous
   7630 ***************
   7631 
   7632 * Menu:
   7633 
   7634 * Tagging::
   7635 * Notes::
   7636 * Submodules::
   7637 * Subtree::
   7638 * Worktree::
   7639 * Bundle::
   7640 * Common Commands::
   7641 * Wip Modes::
   7642 * Commands for Buffers Visiting Files::
   7643 * Minor Mode for Buffers Visiting Blobs::
   7644 
   7645 
   7646 File: magit.info,  Node: Tagging,  Next: Notes,  Up: Miscellaneous
   7647 
   7648 8.1 Tagging
   7649 ===========
   7650 
   7651 Also see *note (gitman)git-tag::.
   7652 
   7653 ‘t’     (‘magit-tag’)
   7654 
   7655      This transient prefix command binds the following suffix commands
   7656      along with the appropriate infix arguments and displays them in a
   7657      temporary buffer until a suffix is invoked.
   7658 
   7659 ‘t t’     (‘magit-tag-create’)
   7660 
   7661      This command creates a new tag with the given NAME at REV.  With a
   7662      prefix argument it creates an annotated tag.
   7663 
   7664 ‘t r’     (‘magit-tag-release’)
   7665 
   7666      This commands creates a release tag.  It assumes that release tags
   7667      match ‘magit-release-tag-regexp’.
   7668 
   7669      First it prompts for the name of the new tag using the highest
   7670      existing tag as initial input and leaving it to the user to
   7671      increment the desired part of the version string.  If you use
   7672      unconventional release tags or version numbers (e.g.,
   7673      ‘v1.2.3-custom.1’), you can set the ‘magit-release-tag-regexp’ and
   7674      ‘magit-tag-version-regexp-alist’ variables.
   7675 
   7676      If ‘--annotate’ is enabled then it prompts for the message of the
   7677      new tag.  The proposed tag message is based on the message of the
   7678      highest tag, provided that that contains the corresponding version
   7679      string and substituting the new version string for that.  Otherwise
   7680      it proposes something like "Foo-Bar 1.2.3", given, for example, a
   7681      TAG "v1.2.3" and a repository located at something like
   7682      "/path/to/foo-bar".
   7683 
   7684 ‘t k’     (‘magit-tag-delete’)
   7685 
   7686      This command deletes one or more tags.  If the region marks
   7687      multiple tags (and nothing else), then it offers to delete those.
   7688      Otherwise, it prompts for a single tag to be deleted, defaulting to
   7689      the tag at point.
   7690 
   7691 ‘t p’     (‘magit-tag-prune’)
   7692 
   7693      This command offers to delete tags missing locally from REMOTE, and
   7694      vice versa.
   7695 
   7696 
   7697 File: magit.info,  Node: Notes,  Next: Submodules,  Prev: Tagging,  Up: Miscellaneous
   7698 
   7699 8.2 Notes
   7700 =========
   7701 
   7702 Also see *note (gitman)git-notes::.
   7703 
   7704 ‘T’     (‘magit-notes’)
   7705 
   7706      This transient prefix command binds the following suffix commands
   7707      along with the appropriate infix arguments and displays them in a
   7708      temporary buffer until a suffix is invoked.
   7709 
   7710 ‘T T’     (‘magit-notes-edit’)
   7711 
   7712      Edit the note attached to a commit, defaulting to the commit at
   7713      point.
   7714 
   7715      By default use the value of Git variable ‘core.notesRef’ or
   7716      "refs/notes/commits" if that is undefined.
   7717 
   7718 ‘T r’     (‘magit-notes-remove’)
   7719 
   7720      Remove the note attached to a commit, defaulting to the commit at
   7721      point.
   7722 
   7723      By default use the value of Git variable ‘core.notesRef’ or
   7724      "refs/notes/commits" if that is undefined.
   7725 
   7726 ‘T p’     (‘magit-notes-prune’)
   7727 
   7728      Remove notes about unreachable commits.
   7729 
   7730    It is possible to merge one note ref into another.  That may result
   7731 in conflicts which have to resolved in the temporary worktree
   7732 ".git/NOTES_MERGE_WORKTREE".
   7733 
   7734 ‘T m’     (‘magit-notes-merge’)
   7735 
   7736      Merge the notes of a ref read from the user into the current notes
   7737      ref.  The current notes ref is the value of Git variable
   7738      ‘core.notesRef’ or "refs/notes/commits" if that is undefined.
   7739 
   7740    When a notes merge is in progress then the transient features the
   7741 following suffix commands, instead of those listed above.
   7742 
   7743 ‘T c’     (‘magit-notes-merge-commit’)
   7744 
   7745      Commit the current notes ref merge, after manually resolving
   7746      conflicts.
   7747 
   7748 ‘T a’     (‘magit-notes-merge-abort’)
   7749 
   7750      Abort the current notes ref merge.
   7751 
   7752    The following variables control what notes reference ‘magit-notes-*’,
   7753 ‘git notes’ and ‘git show’ act on and display.  Both the local and
   7754 global values are displayed and can be modified.
   7755 
   7756  -- Variable: core.notesRef
   7757 
   7758      This variable specifies the notes ref that is displayed by default
   7759      and which commands act on by default.
   7760 
   7761  -- Variable: notes.displayRef
   7762 
   7763      This variable specifies additional notes ref to be displayed in
   7764      addition to the ref specified by ‘core.notesRef’.  It can have
   7765      multiple values and may end with ‘*’ to display all refs in the
   7766      ‘refs/notes/’ namespace (or ‘**’ if some names contain slashes).
   7767 
   7768 
   7769 File: magit.info,  Node: Submodules,  Next: Subtree,  Prev: Notes,  Up: Miscellaneous
   7770 
   7771 8.3 Submodules
   7772 ==============
   7773 
   7774 Also see *note (gitman)git-submodule::.
   7775 
   7776 * Menu:
   7777 
   7778 * Listing Submodules::
   7779 * Submodule Transient::
   7780 
   7781 
   7782 File: magit.info,  Node: Listing Submodules,  Next: Submodule Transient,  Up: Submodules
   7783 
   7784 8.3.1 Listing Submodules
   7785 ------------------------
   7786 
   7787 The command ‘magit-list-submodules’ displays a list of the current
   7788 repository’s submodules in a separate buffer.  It’s also possible to
   7789 display information about submodules directly in the status buffer of
   7790 the super-repository by adding ‘magit-insert-modules’ to the hook
   7791 ‘magit-status-sections-hook’ as described in *note Status Module
   7792 Sections::.
   7793 
   7794  -- Command: magit-list-submodules
   7795 
   7796      This command displays a list of the current repository’s submodules
   7797      in a separate buffer.
   7798 
   7799      It can be invoked by pressing ‘RET’ on the section titled
   7800      "Modules".
   7801 
   7802  -- User Option: magit-submodule-list-columns
   7803 
   7804      This option controls what columns are displayed by the command
   7805      ‘magit-list-submodules’ and how they are displayed.
   7806 
   7807      Each element has the form ‘(HEADER WIDTH FORMAT PROPS)’.
   7808 
   7809      HEADER is the string displayed in the header.  WIDTH is the width
   7810      of the column.  FORMAT is a function that is called with one
   7811      argument, the repository identification (usually its basename), and
   7812      with ‘default-directory’ bound to the toplevel of its working tree.
   7813      It has to return a string to be inserted or nil.  PROPS is an alist
   7814      that supports the keys ‘:right-align’ and ‘:pad-right’.
   7815 
   7816 
   7817 File: magit.info,  Node: Submodule Transient,  Prev: Listing Submodules,  Up: Submodules
   7818 
   7819 8.3.2 Submodule Transient
   7820 -------------------------
   7821 
   7822 ‘o’     (‘magit-submodule’)
   7823 
   7824      This transient prefix command binds the following suffix commands
   7825      along with the appropriate infix arguments and displays them in a
   7826      temporary buffer until a suffix is invoked.
   7827 
   7828    Some of the below commands default to act on the modules that are
   7829 selected using the region.  For brevity their description talk about
   7830 "the selected modules", but if no modules are selected, then they act on
   7831 the current module instead, or if point isn’t on a module, then the read
   7832 a single module to act on.  With a prefix argument these commands ignore
   7833 the selection and the current module and instead act on all suitable
   7834 modules.
   7835 
   7836 ‘o a’     (‘magit-submodule-add’)
   7837 
   7838      This commands adds the repository at URL as a module.  Optional
   7839      PATH is the path to the module relative to the root of the
   7840      super-project.  If it is nil then the path is determined based on
   7841      URL.
   7842 
   7843 ‘o r’     (‘magit-submodule-register’)
   7844 
   7845      This command registers the selected modules by copying their urls
   7846      from ".gitmodules" to "$GIT_DIR/config".  These values can then be
   7847      edited before running ‘magit-submodule-populate’.  If you don’t
   7848      need to edit any urls, then use the latter directly.
   7849 
   7850 ‘o p’     (‘magit-submodule-populate’)
   7851 
   7852      This command creates the working directory or directories of the
   7853      selected modules, checking out the recorded commits.
   7854 
   7855 ‘o u’     (‘magit-submodule-update’)
   7856 
   7857      This command updates the selected modules checking out the recorded
   7858      commits.
   7859 
   7860 ‘o s’     (‘magit-submodule-synchronize’)
   7861 
   7862      This command synchronizes the urls of the selected modules, copying
   7863      the values from ".gitmodules" to the ".git/config" of the
   7864      super-project as well those of the modules.
   7865 
   7866 ‘o d’     (‘magit-submodule-unpopulate’)
   7867 
   7868      This command removes the working directory of the selected modules.
   7869 
   7870 ‘o l’     (‘magit-list-submodules’)
   7871 
   7872      This command displays a list of the current repository’s modules.
   7873 
   7874 ‘o f’     (‘magit-fetch-modules’)
   7875 
   7876      This command fetches all modules.
   7877 
   7878      Option ‘magit-fetch-modules-jobs’ controls how many submodules are
   7879      being fetched in parallel.  Also fetch the super-repository,
   7880      because ‘git fetch’ does not support not doing that.  With a prefix
   7881      argument fetch all remotes.
   7882 
   7883 
   7884 File: magit.info,  Node: Subtree,  Next: Worktree,  Prev: Submodules,  Up: Miscellaneous
   7885 
   7886 8.4 Subtree
   7887 ===========
   7888 
   7889 Also see *note (gitman)git-subtree::.
   7890 
   7891 ‘O’     (‘magit-subtree’)
   7892 
   7893      This transient prefix command binds the two sub-transients; one for
   7894      importing a subtree and one for exporting a subtree.
   7895 
   7896 ‘O i’     (‘magit-subtree-import’)
   7897 
   7898      This transient prefix command binds the following suffix commands
   7899      along with the appropriate infix arguments and displays them in a
   7900      temporary buffer until a suffix is invoked.
   7901 
   7902      The suffixes of this command import subtrees.
   7903 
   7904      If the ‘--prefix’ argument is set, then the suffix commands use
   7905      that prefix without prompting the user.  If it is unset, then they
   7906      read the prefix in the minibuffer.
   7907 
   7908 ‘O i a’     (‘magit-subtree-add’)
   7909 
   7910      This command adds COMMIT from REPOSITORY as a new subtree at
   7911      PREFIX.
   7912 
   7913 ‘O i c’     (‘magit-subtree-add-commit’)
   7914 
   7915      This command add COMMIT as a new subtree at PREFIX.
   7916 
   7917 ‘O i m’     (‘magit-subtree-merge’)
   7918 
   7919      This command merges COMMIT into the PREFIX subtree.
   7920 
   7921 ‘O i f’     (‘magit-subtree-pull’)
   7922 
   7923      This command pulls COMMIT from REPOSITORY into the PREFIX subtree.
   7924 
   7925 ‘O e’     (‘magit-subtree-export’)
   7926 
   7927      This transient prefix command binds the following suffix commands
   7928      along with the appropriate infix arguments and displays them in a
   7929      temporary buffer until a suffix is invoked.
   7930 
   7931      The suffixes of this command export subtrees.
   7932 
   7933      If the ‘--prefix’ argument is set, then the suffix commands use
   7934      that prefix without prompting the user.  If it is unset, then they
   7935      read the prefix in the minibuffer.
   7936 
   7937 ‘O e p’     (‘magit-subtree-push’)
   7938 
   7939      This command extract the history of the subtree PREFIX and pushes
   7940      it to REF on REPOSITORY.
   7941 
   7942 ‘O e s’     (‘magit-subtree-split’)
   7943 
   7944      This command extracts the history of the subtree PREFIX.
   7945 
   7946 
   7947 File: magit.info,  Node: Worktree,  Next: Bundle,  Prev: Subtree,  Up: Miscellaneous
   7948 
   7949 8.5 Worktree
   7950 ============
   7951 
   7952 Also see *note (gitman)git-worktree::.
   7953 
   7954 ‘Z’     (‘magit-worktree’)
   7955 
   7956      This transient prefix command binds the following suffix commands
   7957      and displays them in a temporary buffer until a suffix is invoked.
   7958 
   7959 ‘Z b’     (‘magit-worktree-checkout’)
   7960 
   7961      Checkout BRANCH in a new worktree at PATH.
   7962 
   7963 ‘Z c’     (‘magit-worktree-branch’)
   7964 
   7965      Create a new BRANCH and check it out in a new worktree at PATH.
   7966 
   7967 ‘Z m’     (‘magit-worktree-move’)
   7968 
   7969      Move an existing worktree to a new PATH.
   7970 
   7971 ‘Z k’     (‘magit-worktree-delete’)
   7972 
   7973      Delete a worktree, defaulting to the worktree at point.  The
   7974      primary worktree cannot be deleted.
   7975 
   7976 ‘Z g’     (‘magit-worktree-status’)
   7977 
   7978      Show the status for the worktree at point.
   7979 
   7980      If there is no worktree at point, then read one in the minibuffer.
   7981      If the worktree at point is the one whose status is already being
   7982      displayed in the current buffer, then show it in Dired instead.
   7983 
   7984 
   7985 File: magit.info,  Node: Bundle,  Next: Common Commands,  Prev: Worktree,  Up: Miscellaneous
   7986 
   7987 8.6 Bundle
   7988 ==========
   7989 
   7990 Also see *note (gitman)git-bundle::.
   7991 
   7992  -- Command: magit-bundle
   7993 
   7994      This transient prefix command binds several suffix commands for
   7995      running ‘git bundle’ subcommands and displays them in a temporary
   7996      buffer until a suffix is invoked.
   7997 
   7998 
   7999 File: magit.info,  Node: Common Commands,  Next: Wip Modes,  Prev: Bundle,  Up: Miscellaneous
   8000 
   8001 8.7 Common Commands
   8002 ===================
   8003 
   8004  -- Command: magit-switch-to-repository-buffer
   8005  -- Command: magit-switch-to-repository-buffer-other-window
   8006  -- Command: magit-switch-to-repository-buffer-other-frame
   8007  -- Command: magit-display-repository-buffer
   8008 
   8009      These commands read any existing Magit buffer that belongs to the
   8010      current repository from the user and then switch to the selected
   8011      buffer (without refreshing it).
   8012 
   8013      The last variant uses ‘magit-display-buffer’ to do so and thus
   8014      respects ‘magit-display-buffer-function’.
   8015 
   8016    These are some of the commands that can be used in all buffers whose
   8017 major-modes derive from ‘magit-mode’.  There are other common commands
   8018 beside the ones below, but these didn’t fit well anywhere else.
   8019 
   8020 ‘C-w’     (‘magit-copy-section-value’)
   8021 
   8022      This command saves the value of the current section to the
   8023      ‘kill-ring’, and, provided that the current section is a commit,
   8024      branch, or tag section, it also pushes the (referenced) revision to
   8025      the ‘magit-revision-stack’.
   8026 
   8027      When the current section is a branch or a tag, and a prefix
   8028      argument is used, then it saves the revision at its tip to the
   8029      ‘kill-ring’ instead of the reference name.
   8030 
   8031      When the region is active, this command saves that to the
   8032      ‘kill-ring’, like ‘kill-ring-save’ would, instead of behaving as
   8033      described above.  If a prefix argument is used and the region is
   8034      within a hunk, then it strips the diff marker column and keeps only
   8035      either the added or removed lines, depending on the sign of the
   8036      prefix argument.
   8037 
   8038 ‘M-w’     (‘magit-copy-buffer-revision’)
   8039 
   8040      This command saves the revision being displayed in the current
   8041      buffer to the ‘kill-ring’ and also pushes it to the
   8042      ‘magit-revision-stack’.  It is mainly intended for use in
   8043      ‘magit-revision-mode’ buffers, the only buffers where it is always
   8044      unambiguous exactly which revision should be saved.
   8045 
   8046      Most other Magit buffers usually show more than one revision, in
   8047      some way or another, so this command has to select one of them, and
   8048      that choice might not always be the one you think would have been
   8049      the best pick.
   8050 
   8051    Outside of Magit ‘M-w’ and ‘C-w’ are usually bound to
   8052 ‘kill-ring-save’ and ‘kill-region’, and these commands would also be
   8053 useful in Magit buffers.  Therefore when the region is active, then both
   8054 of these commands behave like ‘kill-ring-save’ instead of as described
   8055 above.
   8056 
   8057 
   8058 File: magit.info,  Node: Wip Modes,  Next: Commands for Buffers Visiting Files,  Prev: Common Commands,  Up: Miscellaneous
   8059 
   8060 8.8 Wip Modes
   8061 =============
   8062 
   8063 Git keeps *committed* changes around long enough for users to recover
   8064 changes they have accidentally deleted.  It does so by not garbage
   8065 collecting any committed but no longer referenced objects for a certain
   8066 period of time, by default 30 days.
   8067 
   8068    But Git does *not* keep track of *uncommitted* changes in the working
   8069 tree and not even the index (the staging area).  Because Magit makes it
   8070 so convenient to modify uncommitted changes, it also makes it easy to
   8071 shoot yourself in the foot in the process.
   8072 
   8073    For that reason Magit provides a global mode that saves *tracked*
   8074 files to work-in-progress references after or before certain actions.
   8075 (At present untracked files are never saved and for technical reasons
   8076 nothing is saved before the first commit has been created).
   8077 
   8078    Two separate work-in-progress references are used to track the state
   8079 of the index and of the working tree: ‘refs/wip/index/<branchref>’ and
   8080 ‘refs/wip/wtree/<branchref>’, where ‘<branchref>’ is the full ref of the
   8081 current branch, e.g.  ‘refs/heads/master’.  When the ‘HEAD’ is detached
   8082 then ‘HEAD’ is used in place of ‘<branchref>’.
   8083 
   8084    Checking out another branch (or detaching ‘HEAD’) causes the use of
   8085 different wip refs for subsequent changes.
   8086 
   8087  -- User Option: magit-wip-mode
   8088 
   8089      When this mode is enabled, then uncommitted changes are committed
   8090      to dedicated work-in-progress refs whenever appropriate (i.e.  when
   8091      dataloss would be a possibility otherwise).
   8092 
   8093      Setting this variable directly does not take effect; either use the
   8094      Custom interface to do so or call the respective mode function.
   8095 
   8096      For historic reasons this mode is implemented on top of four other
   8097      ‘magit-wip-*’ modes, which can also be used individually, if you
   8098      want finer control over when the wip refs are updated; but that is
   8099      discouraged.  See *note Legacy Wip Modes::.
   8100 
   8101    To view the log for a branch and its wip refs use the commands
   8102 ‘magit-wip-log’ and ‘magit-wip-log-current’.  You should use ‘--graph’
   8103 when using these commands.
   8104 
   8105  -- Command: magit-wip-log
   8106 
   8107      This command shows the log for a branch and its wip refs.  With a
   8108      negative prefix argument only the worktree wip ref is shown.
   8109 
   8110      The absolute numeric value of the prefix argument controls how many
   8111      "branches" of each wip ref are shown.  This is only relevant if the
   8112      value of ‘magit-wip-merge-branch’ is ‘nil’.
   8113 
   8114  -- Command: magit-wip-log-current
   8115 
   8116      This command shows the log for the current branch and its wip refs.
   8117      With a negative prefix argument only the worktree wip ref is shown.
   8118 
   8119      The absolute numeric value of the prefix argument controls how many
   8120      "branches" of each wip ref are shown.  This is only relevant if the
   8121      value of ‘magit-wip-merge-branch’ is ‘nil’.
   8122 
   8123 ‘X w’     (‘magit-reset-worktree’)
   8124 
   8125      This command resets the working tree to some commit read from the
   8126      user and defaulting to the commit at point, while keeping the
   8127      ‘HEAD’ and index as-is.
   8128 
   8129      This can be used to restore files to the state committed to a wip
   8130      ref.  Note that this will discard any unstaged changes that might
   8131      have existed before invoking this command (but of course only after
   8132      committing that to the working tree wip ref).
   8133 
   8134    Note that even if you enable ‘magit-wip-mode’ this won’t give you
   8135 perfect protection.  The most likely scenario for losing changes despite
   8136 the use of ‘magit-wip-mode’ is making a change outside Emacs and then
   8137 destroying it also outside Emacs.  In some such a scenario, Magit, being
   8138 an Emacs package, didn’t get the opportunity to keep you from shooting
   8139 yourself in the foot.
   8140 
   8141    When you are unsure whether Magit did commit a change to the wip
   8142 refs, then you can explicitly request that all changes to all tracked
   8143 files are being committed.
   8144 
   8145 ‘M-x magit-wip-commit’     (‘magit-wip-commit’)
   8146 
   8147      This command commits all changes to all tracked files to the index
   8148      and working tree work-in-progress refs.  Like the modes described
   8149      above, it does not commit untracked files, but it does check all
   8150      tracked files for changes.  Use this command when you suspect that
   8151      the modes might have overlooked a change made outside Emacs/Magit.
   8152 
   8153  -- User Option: magit-wip-namespace
   8154 
   8155      The namespace used for work-in-progress refs.  It has to end with a
   8156      slash.  The wip refs are named ‘<namespace>index/<branchref>’ and
   8157      ‘<namespace>wtree/<branchref>’.  When snapshots are created while
   8158      the ‘HEAD’ is detached then ‘HEAD’ is used in place of
   8159      ‘<branchref>’.
   8160 
   8161  -- User Option: magit-wip-mode-lighter
   8162 
   8163      Mode-line lighter for ‘magit-wip--mode’.
   8164 
   8165 * Menu:
   8166 
   8167 * Wip Graph::
   8168 * Legacy Wip Modes::
   8169 
   8170 
   8171 File: magit.info,  Node: Wip Graph,  Next: Legacy Wip Modes,  Up: Wip Modes
   8172 
   8173 8.8.1 Wip Graph
   8174 ---------------
   8175 
   8176  -- User Option: magit-wip-merge-branch
   8177 
   8178      This option controls whether the current branch is merged into the
   8179      wip refs after a new commit was created on the branch.
   8180 
   8181      If non-nil and the current branch has new commits, then it is
   8182      merged into the wip ref before creating a new wip commit.  This
   8183      makes it easier to inspect wip history and the wip commits are
   8184      never garbage collected.
   8185 
   8186      If nil and the current branch has new commits, then the wip ref is
   8187      reset to the tip of the branch before creating a new wip commit.
   8188      With this setting wip commits are eventually garbage collected.
   8189 
   8190    When ‘magit-wip-merge-branch’ is ‘t’, then the history looks like
   8191 this:
   8192 
   8193        *--*--*--*--*--*       refs/wip/index/refs/heads/master
   8194       /     /     /
   8195      A-----B-----C            refs/heads/master
   8196 
   8197    When ‘magit-wip-merge-branch’ is ‘nil’, then creating a commit on the
   8198 real branch and then making a change causes the wip refs to be recreated
   8199 to fork from the new commit.  But the old commits on the wip refs are
   8200 not lost.  They are still available from the reflog.  To make it easier
   8201 to see when the fork point of a wip ref was changed, an additional
   8202 commit with the message "restart autosaving" is created on it (‘xxO’
   8203 commits below are such boundary commits).
   8204 
   8205    Starting with
   8206 
   8207            BI0---BI1    refs/wip/index/refs/heads/master
   8208           /
   8209      A---B              refs/heads/master
   8210           \
   8211            BW0---BW1    refs/wip/wtree/refs/heads/master
   8212 
   8213    and committing the staged changes and editing and saving a file would
   8214 result in
   8215 
   8216            BI0---BI1        refs/wip/index/refs/heads/master
   8217           /
   8218      A---B---C              refs/heads/master
   8219           \   \
   8220            \   CW0---CW1    refs/wip/wtree/refs/heads/master
   8221             \
   8222              BW0---BW1      refs/wip/wtree/refs/heads/master@{2}
   8223 
   8224    The fork-point of the index wip ref is not changed until some change
   8225 is being staged.  Likewise just checking out a branch or creating a
   8226 commit does not change the fork-point of the working tree wip ref.  The
   8227 fork-points are not adjusted until there actually is a change that
   8228 should be committed to the respective wip ref.
   8229 
   8230 
   8231 File: magit.info,  Node: Legacy Wip Modes,  Prev: Wip Graph,  Up: Wip Modes
   8232 
   8233 8.8.2 Legacy Wip Modes
   8234 ----------------------
   8235 
   8236 It is recommended that you use the mode ‘magit-wip-mode’ (which see) and
   8237 ignore the existence of the following modes, which are preserved for
   8238 historic reasons.
   8239 
   8240    Setting the following variables directly does not take effect; either
   8241 use the Custom interface to do so or call the respective mode functions.
   8242 
   8243  -- User Option: magit-wip-after-save-mode
   8244 
   8245      When this mode is enabled, then saving a buffer that visits a file
   8246      tracked in a Git repository causes its current state to be
   8247      committed to the working tree wip ref for the current branch.
   8248 
   8249  -- User Option: magit-wip-after-apply-mode
   8250 
   8251      When this mode is enabled, then applying (i.e.  staging, unstaging,
   8252      discarding, reversing, and regularly applying) a change to a file
   8253      tracked in a Git repository causes its current state to be
   8254      committed to the index and/or working tree wip refs for the current
   8255      branch.
   8256 
   8257    If you only ever edit files using Emacs and only ever interact with
   8258 Git using Magit, then the above two modes should be enough to protect
   8259 each and every change from accidental loss.  In practice nobody does
   8260 that.  Two additional modes exists that do commit to the wip refs before
   8261 making changes that could cause the loss of earlier changes.
   8262 
   8263  -- User Option: magit-wip-before-change-mode
   8264 
   8265      When this mode is enabled, then certain commands commit the
   8266      existing changes to the files they are about to make changes to.
   8267 
   8268  -- User Option: magit-wip-initial-backup-mode
   8269 
   8270      When this mode is enabled, then the current version of a file is
   8271      committed to the worktree wip ref before the buffer visiting that
   8272      file is saved for the first time since the buffer was created.
   8273 
   8274      This backs up the same version of the file that ‘backup-buffer’
   8275      would save.  While ‘backup-buffer’ uses a backup file, this mode
   8276      uses the same worktree wip ref as used by the other Magit Wip
   8277      modes.  Like ‘backup-buffer’, it only does this once; unless you
   8278      kill the buffer and visit the file again only one backup will be
   8279      created per Emacs session.
   8280 
   8281      This mode ignores the variables that affect ‘backup-buffer’ and can
   8282      be used along-side that function, which is recommended because it
   8283      only backs up files that are tracked in a Git repository.
   8284 
   8285  -- User Option: magit-wip-after-save-local-mode-lighter
   8286 
   8287      Mode-line lighter for ‘magit-wip-after-save-local-mode’.
   8288 
   8289  -- User Option: magit-wip-after-apply-mode-lighter
   8290 
   8291      Mode-line lighter for ‘magit-wip-after-apply-mode’.
   8292 
   8293  -- User Option: magit-wip-before-change-mode-lighter
   8294 
   8295      Mode-line lighter for ‘magit-wip-before-change-mode’.
   8296 
   8297  -- User Option: magit-wip-initial-backup-mode-lighter
   8298 
   8299      Mode-line lighter for ‘magit-wip-initial-backup-mode’.
   8300 
   8301 
   8302 File: magit.info,  Node: Commands for Buffers Visiting Files,  Next: Minor Mode for Buffers Visiting Blobs,  Prev: Wip Modes,  Up: Miscellaneous
   8303 
   8304 8.9 Commands for Buffers Visiting Files
   8305 =======================================
   8306 
   8307 Magit defines a few global key bindings unless the user sets
   8308 ‘magit-define-global-key-bindings’ to ‘nil’.  This includes binding ‘C-c
   8309 M-g’ to ‘magit-file-dispatch’.  ‘C-c g’ would be a much better binding
   8310 but the ‘C-c <letter>’ namespace is reserved for users, meaning that
   8311 packages are not allowed to use it.  If you want to use ‘C-c g’, then
   8312 you have to add that binding yourself.  Also see *note Default
   8313 Bindings:: and *note (elisp)Key Binding Conventions::.
   8314 
   8315    If you want a better binding, you have to add it yourself:
   8316 
   8317      (global-set-key (kbd "C-c g") 'magit-file-dispatch)
   8318 
   8319    The key bindings shown below assume that you have not improved the
   8320 binding for ‘magit-file-dispatch’.
   8321 
   8322 ‘C-c M-g’     (‘magit-file-dispatch’)
   8323 
   8324      This transient prefix command binds the following suffix commands
   8325      and displays them in a temporary buffer until a suffix is invoked.
   8326 
   8327      When invoked in a buffer that does not visit a file, then it falls
   8328      back to regular ‘magit-dispatch’.
   8329 
   8330 ‘C-c M-g s’     (‘magit-stage-file’)
   8331 
   8332      Stage all changes to the file being visited in the current buffer.
   8333 
   8334 ‘C-c M-g u’     (‘magit-unstage-file’)
   8335 
   8336      Unstage all changes to the file being visited in the current
   8337      buffer.
   8338 
   8339 ‘C-c M-g c’     (‘magit-commit’)
   8340 
   8341      This transient prefix command binds the following suffix commands
   8342      along with the appropriate infix arguments and displays them in a
   8343      temporary buffer until a suffix is invoked.  See *note Initiating a
   8344      Commit::.
   8345 
   8346 ‘C-c M-g D’     (‘magit-diff’)
   8347 
   8348      This transient prefix command binds several diff suffix commands
   8349      and infix arguments and displays them in a temporary buffer until a
   8350      suffix is invoked.  See *note Diffing::.
   8351 
   8352      This is the same command that ‘d’ is bound to in Magit buffers.  If
   8353      this command is invoked from a file-visiting buffer, then the
   8354      initial value of the option (‘--’) that limits the diff to certain
   8355      file(s) is set to the visited file.
   8356 
   8357 ‘C-c M-g d’     (‘magit-diff-buffer-file’)
   8358 
   8359      This command shows the diff for the file of blob that the current
   8360      buffer visits.
   8361 
   8362  -- User Option: magit-diff-buffer-file-locked
   8363 
   8364      This option controls whether ‘magit-diff-buffer-file’ uses a
   8365      dedicated buffer.  See *note Modes and Buffers::.
   8366 
   8367 ‘C-c M-g L’     (‘magit-log’)
   8368 
   8369      This transient prefix command binds several log suffix commands and
   8370      infix arguments and displays them in a temporary buffer until a
   8371      suffix is invoked.  See *note Logging::.
   8372 
   8373      This is the same command that ‘l’ is bound to in Magit buffers.  If
   8374      this command is invoked from a file-visiting buffer, then the
   8375      initial value of the option (‘--’) that limits the log to certain
   8376      file(s) is set to the visited file.
   8377 
   8378 ‘C-c M-g l’     (‘magit-log-buffer-file’)
   8379 
   8380      This command shows the log for the file of blob that the current
   8381      buffer visits.  Renames are followed when a prefix argument is used
   8382      or when ‘--follow’ is an active log argument.  When the region is
   8383      active, the log is restricted to the selected line range.
   8384 
   8385 ‘C-c M-g t’     (‘magit-log-trace-definition’)
   8386 
   8387      This command shows the log for the definition at point.
   8388 
   8389  -- User Option: magit-log-buffer-file-locked
   8390 
   8391      This option controls whether ‘magit-log-buffer-file’ uses a
   8392      dedicated buffer.  See *note Modes and Buffers::.
   8393 
   8394 ‘C-c M-g B’     (‘magit-blame’)
   8395 
   8396      This transient prefix command binds all blaming suffix commands
   8397      along with the appropriate infix arguments and displays them in a
   8398      temporary buffer until a suffix is invoked.
   8399 
   8400      For more information about this and the following commands also see
   8401      *note Blaming::.
   8402 
   8403    In addition to the ‘magit-blame’ sub-transient, the dispatch
   8404 transient also binds several blaming suffix commands directly.  See
   8405 *note Blaming:: for information about those commands and bindings.
   8406 
   8407 ‘C-c M-g e’     (‘magit-edit-line-commit’)
   8408 
   8409      This command makes the commit editable that added the current line.
   8410 
   8411      With a prefix argument it makes the commit editable that removes
   8412      the line, if any.  The commit is determined using ‘git blame’ and
   8413      made editable using ‘git rebase --interactive’ if it is reachable
   8414      from ‘HEAD’, or by checking out the commit (or a branch that points
   8415      at it) otherwise.
   8416 
   8417 ‘C-c M-g p’     (‘magit-blob-previous’)
   8418 
   8419      Visit the previous blob which modified the current file.
   8420 
   8421    There are a few additional commands that operate on a single file but
   8422 are not enabled in the file transient command by default:
   8423 
   8424  -- Command: magit-file-rename
   8425 
   8426      This command renames a file read from the user.
   8427 
   8428  -- Command: magit-file-delete
   8429 
   8430      This command deletes a file read from the user.
   8431 
   8432  -- Command: magit-file-untrack
   8433 
   8434      This command untracks a file read from the user.
   8435 
   8436  -- Command: magit-file-checkout
   8437 
   8438      This command updates a file in the working tree and index to the
   8439      contents from a revision.  Both the revision and file are read from
   8440      the user.
   8441 
   8442    To enable them invoke the transient (‘C-c M-g’), enter "edit mode"
   8443 (‘C-x l’), set the "transient level" (‘C-x l’ again), enter ‘5’, and
   8444 leave edit mode (‘C-g’).  Also see *note (transient)Enabling and
   8445 Disabling Suffixes::.
   8446 
   8447 
   8448 File: magit.info,  Node: Minor Mode for Buffers Visiting Blobs,  Prev: Commands for Buffers Visiting Files,  Up: Miscellaneous
   8449 
   8450 8.10 Minor Mode for Buffers Visiting Blobs
   8451 ==========================================
   8452 
   8453 The ‘magit-blob-mode’ enables certain Magit features in blob-visiting
   8454 buffers.  Such buffers can be created using ‘magit-find-file’ and some
   8455 of the commands mentioned below, which also take care of turning on this
   8456 minor mode.  Currently this mode only establishes a few key bindings,
   8457 but this might be extended.
   8458 
   8459 ‘p’     (‘magit-blob-previous’)
   8460 
   8461      Visit the previous blob which modified the current file.
   8462 
   8463 ‘n’     (‘magit-blob-next’)
   8464 
   8465      Visit the next blob which modified the current file.
   8466 
   8467 ‘q’     (‘magit-kill-this-buffer’)
   8468 
   8469      Kill the current buffer.
   8470 
   8471 
   8472 File: magit.info,  Node: Customizing,  Next: Plumbing,  Prev: Miscellaneous,  Up: Top
   8473 
   8474 9 Customizing
   8475 *************
   8476 
   8477 Both Git and Emacs are highly customizable.  Magit is both a Git
   8478 porcelain as well as an Emacs package, so it makes sense to customize it
   8479 using both Git variables as well as Emacs options.  However this
   8480 flexibility doesn’t come without problems, including but not limited to
   8481 the following.
   8482 
   8483    • Some Git variables automatically have an effect in Magit without
   8484      requiring any explicit support.  Sometimes that is desirable - in
   8485      other cases, it breaks Magit.
   8486 
   8487      When a certain Git setting breaks Magit but you want to keep using
   8488      that setting on the command line, then that can be accomplished by
   8489      overriding the value for Magit only by appending something like
   8490      ‘("-c" "some.variable=compatible-value")’ to
   8491      ‘magit-git-global-arguments’.
   8492 
   8493    • Certain settings like ‘fetch.prune=true’ are respected by Magit
   8494      commands (because they simply call the respective Git command) but
   8495      their value is not reflected in the respective transient buffers.
   8496      In this case the ‘--prune’ argument in ‘magit-fetch’ might be
   8497      active or inactive, but that doesn’t keep the Git variable from
   8498      being honored by the suffix commands anyway.  So pruning might
   8499      happen despite the ‘--prune’ arguments being displayed in a way
   8500      that seems to indicate that no pruning will happen.
   8501 
   8502    I intend to address these and similar issues in a future release.
   8503 
   8504 * Menu:
   8505 
   8506 * Per-Repository Configuration::
   8507 * Essential Settings::
   8508 
   8509 
   8510 File: magit.info,  Node: Per-Repository Configuration,  Next: Essential Settings,  Up: Customizing
   8511 
   8512 9.1 Per-Repository Configuration
   8513 ================================
   8514 
   8515 Magit can be configured on a per-repository level using both Git
   8516 variables as well as Emacs options.
   8517 
   8518    To set a Git variable for one repository only, simply set it in
   8519 ‘/path/to/repo/.git/config’ instead of ‘$HOME/.gitconfig’ or
   8520 ‘/etc/gitconfig’.  See *note (gitman)git-config::.
   8521 
   8522    Similarly, Emacs options can be set for one repository only by
   8523 editing ‘/path/to/repo/.dir-locals.el’.  See *note (emacs)Directory
   8524 Variables::.  For example to disable automatic refreshes of
   8525 file-visiting buffers in just one huge repository use this:
   8526 
   8527    • ‘/path/to/huge/repo/.dir-locals.el’
   8528 
   8529           ((nil . ((magit-refresh-buffers . nil))))
   8530 
   8531    It might only be costly to insert certain information into Magit
   8532 buffers for repositories that are exceptionally large, in which case you
   8533 can disable the respective section inserters just for that repository:
   8534 
   8535    • ‘/path/to/tag/invested/repo/.dir-locals.el’
   8536 
   8537           ((magit-status-mode
   8538             . ((eval . (magit-disable-section-inserter 'magit-insert-tags-header)))))
   8539 
   8540  -- Function: magit-disable-section-inserter fn
   8541 
   8542      This function disables the section inserter FN in the current
   8543      repository.  It is only intended for use in ‘.dir-locals.el’ and
   8544      ‘.dir-locals-2.el’.
   8545 
   8546    If you want to apply the same settings to several, but not all,
   8547 repositories then keeping the repository-local config files in sync
   8548 would quickly become annoying.  To avoid that you can create config
   8549 files for certain classes of repositories (e.g.  "huge repositories")
   8550 and then include those files in the per-repository config files.  For
   8551 example:
   8552 
   8553    • ‘/path/to/huge/repo/.git/config’
   8554 
   8555           [include]
   8556                   path = /path/to/huge-gitconfig
   8557 
   8558    • ‘/path/to/huge-gitconfig’
   8559 
   8560           [status]
   8561                   showUntrackedFiles = no
   8562 
   8563    • ‘$HOME/.emacs.d/init.el’
   8564 
   8565           (dir-locals-set-class-variables 'huge-git-repository
   8566              '((nil . ((magit-refresh-buffers . nil)))))
   8567 
   8568           (dir-locals-set-directory-class
   8569              "/path/to/huge/repo/" 'huge-git-repository)
   8570 
   8571 
   8572 File: magit.info,  Node: Essential Settings,  Prev: Per-Repository Configuration,  Up: Customizing
   8573 
   8574 9.2 Essential Settings
   8575 ======================
   8576 
   8577 The next two sections list and discuss several variables that many users
   8578 might want to customize, for safety and/or performance reasons.
   8579 
   8580 * Menu:
   8581 
   8582 * Safety::
   8583 * Performance::
   8584 * Default Bindings::
   8585 
   8586 
   8587 File: magit.info,  Node: Safety,  Next: Performance,  Up: Essential Settings
   8588 
   8589 9.2.1 Safety
   8590 ------------
   8591 
   8592 This section discusses various variables that you might want to change
   8593 (or *not* change) for safety reasons.
   8594 
   8595    Git keeps *committed* changes around long enough for users to recover
   8596 changes they have accidentally been deleted.  It does not do the same
   8597 for *uncommitted* changes in the working tree and not even the index
   8598 (the staging area).  Because Magit makes it so easy to modify
   8599 uncommitted changes, it also makes it easy to shoot yourself in the foot
   8600 in the process.  For that reason Magit provides three global modes that
   8601 save *tracked* files to work-in-progress references after or before
   8602 certain actions.  See *note Wip Modes::.
   8603 
   8604    These modes are not enabled by default because of performance
   8605 concerns.  Instead a lot of potentially destructive commands require
   8606 confirmation every time they are used.  In many cases this can be
   8607 disabled by adding a symbol to ‘magit-no-confirm’ (see *note Completion
   8608 and Confirmation::).  If you enable the various wip modes then you
   8609 should add ‘safe-with-wip’ to this list.
   8610 
   8611    Similarly it isn’t necessary to require confirmation before moving a
   8612 file to the system trash - if you trashed a file by mistake then you can
   8613 recover it from there.  Option ‘magit-delete-by-moving-to-trash’
   8614 controls whether the system trash is used, which is the case by default.
   8615 Nevertheless, ‘trash’ isn’t a member of ‘magit-no-confirm’ - you might
   8616 want to change that.
   8617 
   8618    By default buffers visiting files are automatically reverted when the
   8619 visited file changes on disk.  This isn’t as risky as it might seem, but
   8620 to make an informed decision you should see *note Risk of Reverting
   8621 Automatically::.
   8622 
   8623 
   8624 File: magit.info,  Node: Performance,  Next: Default Bindings,  Prev: Safety,  Up: Essential Settings
   8625 
   8626 9.2.2 Performance
   8627 -----------------
   8628 
   8629 After Magit has run ‘git’ for side-effects, it also refreshes the
   8630 current Magit buffer and the respective status buffer.  This is
   8631 necessary because otherwise outdated information might be displayed
   8632 without the user noticing.  Magit buffers are updated by recreating
   8633 their content from scratch, which makes updating simpler and less
   8634 error-prone, but also more costly.  Keeping it simple and just
   8635 re-creating everything from scratch is an old design decision and
   8636 departing from that will require major refactoring.
   8637 
   8638    I plan to do that in time for the next major release.  I also intend
   8639 to create logs and diffs asynchronously, which should also help a lot
   8640 but also requires major refactoring.
   8641 
   8642    Meanwhile you can tell Magit to only automatically refresh the
   8643 current Magit buffer, but not the status buffer.  If you do that, then
   8644 the status buffer is only refreshed automatically if it is the current
   8645 buffer.
   8646 
   8647      (setq magit-refresh-status-buffer nil)
   8648 
   8649    You should also check whether any third-party packages have added
   8650 anything to ‘magit-refresh-buffer-hook’, ‘magit-status-refresh-hook’,
   8651 ‘magit-pre-refresh-hook’, and ‘magit-post-refresh-hook’.  If so, then
   8652 check whether those additions impact performance significantly.
   8653 
   8654    Magit can be told to refresh buffers verbosely using ‘M-x
   8655 magit-toggle-verbose-refresh’.  Enabling this helps figuring out which
   8656 sections are bottlenecks.  The additional output can be found in the
   8657 ‘*Messages*’ buffer.
   8658 
   8659    Magit also reverts buffers for visited files located inside the
   8660 current repository when the visited file changes on disk.  That is
   8661 implemented on top of ‘auto-revert-mode’ from the built-in library
   8662 ‘autorevert’.  To figure out whether that impacts performance, check
   8663 whether performance is significantly worse, when many buffers exist
   8664 and/or when some buffers visit files using TRAMP.  If so, then this
   8665 should help.
   8666 
   8667      (setq auto-revert-buffer-list-filter
   8668            'magit-auto-revert-repository-buffer-p)
   8669 
   8670    For alternative approaches see *note Automatic Reverting of
   8671 File-Visiting Buffers::.
   8672 
   8673    If you have enabled any features that are disabled by default, then
   8674 you should check whether they impact performance significantly.  It’s
   8675 likely that they were not enabled by default because it is known that
   8676 they reduce performance at least in large repositories.
   8677 
   8678    If performance is only slow inside certain unusually large
   8679 repositories, then you might want to disable certain features on a
   8680 per-repository or per-repository-class basis only.  See *note
   8681 Per-Repository Configuration::.  For example it takes a long time to
   8682 determine the next and current tag in repository with exceptional
   8683 numbers of tags.  It would therefore be a good idea to disable
   8684 ‘magit-insert-tags-headers’, as explained at the mentioned node.
   8685 
   8686 * Menu:
   8687 
   8688 * Microsoft Windows Performance::
   8689 * MacOS Performance::
   8690 
   8691 Log Performance
   8692 ...............
   8693 
   8694 When showing logs, Magit limits the number of commits initially shown in
   8695 the hope that this avoids unnecessary work.  When using ‘--graph’ is
   8696 used, then this unfortunately does not have the desired effect for large
   8697 histories.  Junio, Git’s maintainer, said on the git mailing list
   8698 (<http://www.spinics.net/lists/git/msg232230.html>): "‘--graph’ wants to
   8699 compute the whole history and the max-count only affects the output
   8700 phase after ‘--graph’ does its computation".
   8701 
   8702    In other words, it’s not that Git is slow at outputting the
   8703 differences, or that Magit is slow at parsing the output - the problem
   8704 is that Git first goes outside and has a smoke.
   8705 
   8706    We actually work around this issue by limiting the number of commits
   8707 not only by using ‘-<N>’ but by also using a range.  But unfortunately
   8708 that’s not always possible.
   8709 
   8710    When more than a few thousand commits are shown, then the use of
   8711 ‘--graph’ can slow things down.
   8712 
   8713    Using ‘--color --graph’ is even slower.  Magit uses code that is part
   8714 of Emacs to turn control characters into faces.  That code is pretty
   8715 slow and this is quite noticeable when showing a log with many branches
   8716 and merges.  For that reason ‘--color’ is not enabled by default
   8717 anymore.  Consider leaving it at that.
   8718 
   8719 Diff Performance
   8720 ................
   8721 
   8722 If diffs are slow, then consider turning off some optional diff features
   8723 by setting all or some of the following variables to ‘nil’:
   8724 ‘magit-diff-highlight-indentation’, ‘magit-diff-highlight-trailing’,
   8725 ‘magit-diff-paint-whitespace’, ‘magit-diff-highlight-hunk-body’, and
   8726 ‘magit-diff-refine-hunk’.
   8727 
   8728    When showing a commit instead of some arbitrary diff, then some
   8729 additional information is displayed.  Calculating this information can
   8730 be quite expensive given certain circumstances.  If looking at a commit
   8731 using ‘magit-revision-mode’ takes considerably more time than looking at
   8732 the same commit in ‘magit-diff-mode’, then consider setting
   8733 ‘magit-revision-insert-related-refs’ to ‘nil’.
   8734 
   8735    When you are often confronted with diffs that contain deleted files,
   8736 then you might want to enable the ‘--irreversible-delete’ argument.  If
   8737 you do that then diffs still show that a file was deleted but without
   8738 also showing the complete deleted content of the file.  This argument is
   8739 not available by default, see *note (transient)Enabling and Disabling
   8740 Suffixes::.  Once you have done that you should enable it and save that
   8741 setting, see *note (transient)Saving Values::.  You should do this in
   8742 both the diff (‘d’) and the diff refresh (‘D’) transient popups.
   8743 
   8744 Refs Buffer Performance
   8745 .......................
   8746 
   8747 When refreshing the "references buffer" is slow, then that’s usually
   8748 because several hundred refs are being displayed.  The best way to
   8749 address that is to display fewer refs, obviously.
   8750 
   8751    If you are not, or only mildly, interested in seeing the list of
   8752 tags, then start by not displaying them:
   8753 
   8754      (remove-hook 'magit-refs-sections-hook 'magit-insert-tags)
   8755 
   8756    Then you should also make sure that the listed remote branches
   8757 actually all exist.  You can do so by pruning branches which no longer
   8758 exist using ‘f-pa’.
   8759 
   8760 Committing Performance
   8761 ......................
   8762 
   8763 When you initiate a commit, then Magit by default automatically shows a
   8764 diff of the changes you are about to commit.  For large commits this can
   8765 take a long time, which is especially distracting when you are
   8766 committing large amounts of generated data which you don’t actually
   8767 intend to inspect before committing.  This behavior can be turned off
   8768 using:
   8769 
   8770      (remove-hook 'server-switch-hook 'magit-commit-diff)
   8771 
   8772    Then you can type ‘C-c C-d’ to show the diff when you actually want
   8773 to see it, but only then.  Alternatively you can leave the hook alone
   8774 and just type ‘C-g’ in those cases when it takes too long to generate
   8775 the diff.  If you do that, then you will end up with a broken diff
   8776 buffer, but doing it this way has the advantage that you usually get to
   8777 see the diff, which is useful because it increases the odds that you
   8778 spot potential issues.
   8779 
   8780 
   8781 File: magit.info,  Node: Microsoft Windows Performance,  Next: MacOS Performance,  Up: Performance
   8782 
   8783 Microsoft Windows Performance
   8784 .............................
   8785 
   8786 In order to update the status buffer, ‘git’ has to be run a few dozen
   8787 times.  That is problematic on Microsoft Windows, because that operating
   8788 system is exceptionally slow at starting processes.  Sadly this is an
   8789 issue that can only be fixed by Microsoft itself, and they don’t appear
   8790 to be particularly interested in doing so.
   8791 
   8792    Beside the subprocess issue, there are also other Windows-specific
   8793 performance issues.  Some of these have workarounds.  The maintainers of
   8794 "Git for Windows" try to improve performance on Windows.  Always use the
   8795 latest release in order to benefit from the latest performance tweaks.
   8796 Magit too tries to work around some Windows-specific issues.
   8797 
   8798    According to some sources, setting the following Git variables can
   8799 also help.
   8800 
   8801      git config --global core.preloadindex true   # default since v2.1
   8802      git config --global core.fscache true        # default since v2.8
   8803      git config --global gc.auto 256
   8804 
   8805    You should also check whether an anti-virus program is affecting
   8806 performance.
   8807 
   8808 
   8809 File: magit.info,  Node: MacOS Performance,  Prev: Microsoft Windows Performance,  Up: Performance
   8810 
   8811 MacOS Performance
   8812 .................
   8813 
   8814 Before Emacs 26.1 child processes were created using ‘fork’ on macOS.
   8815 That needlessly copied GUI resources, which is expensive.  The result
   8816 was that forking took about 30 times as long on Darwin than on Linux,
   8817 and because Magit starts many ‘git’ processes that made quite a
   8818 difference.
   8819 
   8820    So make sure that you are using at least Emacs 26.1, in which case
   8821 the faster ‘vfork’ will be used.  (The creation of child processes still
   8822 takes about twice as long on Darwin compared to Linux.)  See (1) for
   8823 more information.
   8824 
   8825    ---------- Footnotes ----------
   8826 
   8827    (1) 
   8828 <https://lists.gnu.org/archive/html/bug-gnu-emacs/2017-04/msg00201.html>
   8829 
   8830 
   8831 File: magit.info,  Node: Default Bindings,  Prev: Performance,  Up: Essential Settings
   8832 
   8833 9.2.3 Default Bindings
   8834 ----------------------
   8835 
   8836  -- User Option: magit-define-global-key-bindings
   8837 
   8838      This option controls whether some Magit commands are automatically
   8839      bound in the global keymap even before Magit is used for the first
   8840      time in the current session.
   8841 
   8842      If this variable is non-nil, which it is by default, then the
   8843      following bindings may be added to the global keymap.
   8844 
   8845      ‘C-x g’     ‘magit-status’
   8846      ‘C-x M-g’   ‘magit-dispatch’
   8847      ‘C-c M-g’   ‘magit-file-dispatch’
   8848 
   8849      These bindings may be added when ‘after-init-hook’ is run.  Each
   8850      binding is added if and only if at that time no other key is bound
   8851      to the same command and no other command is bound to the same key.
   8852      In other words we try to avoid adding bindings that are
   8853      unnecessary, as well as bindings that conflict with other bindings.
   8854 
   8855      Adding the above bindings is delayed until ‘after-init-hook’ is
   8856      called to allow users to set the variable anywhere in their init
   8857      file (without having to make sure to do so before ‘magit’ is loaded
   8858      or autoloaded) and to increase the likelihood that all the
   8859      potentially conflicting user bindings have already been added.
   8860 
   8861      To set this variable use either ‘setq’ or the Custom interface.  Do
   8862      not use the function ‘customize-set-variable’ because doing that
   8863      would cause Magit to be loaded immediately when that form is
   8864      evaluated (this differs from ‘custom-set-variables’, which doesn’t
   8865      load the libraries that define the customized variables).
   8866 
   8867      Setting this variable to nil has no effect if that is done after
   8868      the key bindings have already been added.
   8869 
   8870      We recommend that you bind ‘C-c g’ instead of ‘C-c M-g’ to
   8871      ‘magit-file-dispatch’.  The former is a much better binding but the
   8872      ‘C-c <letter>’ namespace is strictly reserved for users; preventing
   8873      Magit from using it by default.
   8874 
   8875           (global-set-key (kbd "C-c g") 'magit-file-dispatch)
   8876 
   8877      Also see *note Commands for Buffers Visiting Files:: and *note
   8878      (elisp)Key Binding Conventions::.
   8879 
   8880 
   8881 File: magit.info,  Node: Plumbing,  Next: FAQ,  Prev: Customizing,  Up: Top
   8882 
   8883 10 Plumbing
   8884 ***********
   8885 
   8886 The following sections describe how to use several of Magit’s core
   8887 abstractions to extend Magit itself or implement a separate extension.
   8888 
   8889    A few of the low-level features used by Magit have been factored out
   8890 into separate libraries/packages, so that they can be used by other
   8891 packages, without having to depend on Magit.  See *note
   8892 (with-editor)Top:: for information about ‘with-editor’.  ‘transient’
   8893 doesn’t have a manual yet.
   8894 
   8895    If you are trying to find an unused key that you can bind to a
   8896 command provided by your own Magit extension, then checkout
   8897 <https://github.com/magit/magit/wiki/Plugin-Dispatch-Key-Registry>.
   8898 
   8899 * Menu:
   8900 
   8901 * Calling Git::
   8902 * Section Plumbing::
   8903 * Refreshing Buffers::
   8904 * Conventions::
   8905 
   8906 
   8907 File: magit.info,  Node: Calling Git,  Next: Section Plumbing,  Up: Plumbing
   8908 
   8909 10.1 Calling Git
   8910 ================
   8911 
   8912 Magit provides many specialized functions for calling Git.  All of these
   8913 functions are defined in either ‘magit-git.el’ or ‘magit-process.el’ and
   8914 have one of the prefixes ‘magit-run-’, ‘magit-call-’, ‘magit-start-’, or
   8915 ‘magit-git-’ (which is also used for other things).
   8916 
   8917    All of these functions accept an indefinite number of arguments,
   8918 which are strings that specify command line arguments for Git (or in
   8919 some cases an arbitrary executable).  These arguments are flattened
   8920 before being passed on to the executable; so instead of strings they can
   8921 also be lists of strings and arguments that are ‘nil’ are silently
   8922 dropped.  Some of these functions also require a single mandatory
   8923 argument before these command line arguments.
   8924 
   8925    Roughly speaking, these functions run Git either to get some value or
   8926 for side-effects.  The functions that return a value are useful to
   8927 collect the information necessary to populate a Magit buffer, while the
   8928 others are used to implement Magit commands.
   8929 
   8930    The functions in the value-only group always run synchronously, and
   8931 they never trigger a refresh.  The function in the side-effect group can
   8932 be further divided into subgroups depending on whether they run Git
   8933 synchronously or asynchronously, and depending on whether they trigger a
   8934 refresh when the executable has finished.
   8935 
   8936 * Menu:
   8937 
   8938 * Getting a Value from Git::
   8939 * Calling Git for Effect::
   8940 
   8941 
   8942 File: magit.info,  Node: Getting a Value from Git,  Next: Calling Git for Effect,  Up: Calling Git
   8943 
   8944 10.1.1 Getting a Value from Git
   8945 -------------------------------
   8946 
   8947 These functions run Git in order to get a value, an exit status, or
   8948 output.  Of course you could also use them to run Git commands that have
   8949 side-effects, but that should be avoided.
   8950 
   8951  -- Function: magit-git-exit-code &rest args
   8952 
   8953      Executes git with ARGS and returns its exit code.
   8954 
   8955  -- Function: magit-git-success &rest args
   8956 
   8957      Executes git with ARGS and returns ‘t’ if the exit code is ‘0’,
   8958      ‘nil’ otherwise.
   8959 
   8960  -- Function: magit-git-failure &rest args
   8961 
   8962      Executes git with ARGS and returns ‘t’ if the exit code is ‘1’,
   8963      ‘nil’ otherwise.
   8964 
   8965  -- Function: magit-git-true &rest args
   8966 
   8967      Executes git with ARGS and returns ‘t’ if the first line printed by
   8968      git is the string "true", ‘nil’ otherwise.
   8969 
   8970  -- Function: magit-git-false &rest args
   8971 
   8972      Executes git with ARGS and returns ‘t’ if the first line printed by
   8973      git is the string "false", ‘nil’ otherwise.
   8974 
   8975  -- Function: magit-git-insert &rest args
   8976 
   8977      Executes git with ARGS and inserts its output at point.
   8978 
   8979  -- Function: magit-git-string &rest args
   8980 
   8981      Executes git with ARGS and returns the first line of its output.
   8982      If there is no output or if it begins with a newline character,
   8983      then this returns ‘nil’.
   8984 
   8985  -- Function: magit-git-lines &rest args
   8986 
   8987      Executes git with ARGS and returns its output as a list of lines.
   8988      Empty lines anywhere in the output are omitted.
   8989 
   8990  -- Function: magit-git-items &rest args
   8991 
   8992      Executes git with ARGS and returns its null-separated output as a
   8993      list.  Empty items anywhere in the output are omitted.
   8994 
   8995      If the value of option ‘magit-git-debug’ is non-nil and git exits
   8996      with a non-zero exit status, then warn about that in the echo area
   8997      and add a section containing git’s standard error in the current
   8998      repository’s process buffer.
   8999 
   9000  -- Function: magit-process-git destination &rest args
   9001 
   9002      Calls Git synchronously in a separate process, returning its exit
   9003      code.  DESTINATION specifies how to handle the output, like for
   9004      ‘call-process’, except that file handlers are supported.  Enables
   9005      Cygwin’s "noglob" option during the call and ensures unix eol
   9006      conversion.
   9007 
   9008  -- Function: magit-process-file process &optional infile buffer display
   9009           &rest args
   9010 
   9011      Processes files synchronously in a separate process.  Identical to
   9012      ‘process-file’ but temporarily enables Cygwin’s "noglob" option
   9013      during the call and ensures unix eol conversion.
   9014 
   9015    If an error occurs when using one of the above functions, then that
   9016 is usually due to a bug, i.e.  using an argument which is not actually
   9017 supported.  Such errors are usually not reported, but when they occur we
   9018 need to be able to debug them.
   9019 
   9020  -- User Option: magit-git-debug
   9021 
   9022      Whether to report errors that occur when using ‘magit-git-insert’,
   9023      ‘magit-git-string’, ‘magit-git-lines’, or ‘magit-git-items’.  This
   9024      does not actually raise an error.  Instead a message is shown in
   9025      the echo area, and git’s standard error is insert into a new
   9026      section in the current repository’s process buffer.
   9027 
   9028  -- Function: magit-git-str &rest args
   9029 
   9030      This is a variant of ‘magit-git-string’ that ignores the option
   9031      ‘magit-git-debug’.  It is mainly intended to be used while handling
   9032      errors in functions that do respect that option.  Using such a
   9033      function while handing an error could cause yet another error and
   9034      therefore lead to an infinite recursion.  You probably won’t ever
   9035      need to use this function.
   9036 
   9037 
   9038 File: magit.info,  Node: Calling Git for Effect,  Prev: Getting a Value from Git,  Up: Calling Git
   9039 
   9040 10.1.2 Calling Git for Effect
   9041 -----------------------------
   9042 
   9043 These functions are used to run git to produce some effect.  Most Magit
   9044 commands that actually run git do so by using such a function.
   9045 
   9046    Because we do not need to consume git’s output when using these
   9047 functions, their output is instead logged into a per-repository buffer,
   9048 which can be shown using ‘$’ from a Magit buffer or ‘M-x magit-process’
   9049 elsewhere.
   9050 
   9051    These functions can have an effect in two distinct ways.  Firstly,
   9052 running git may change something, i.e.  create or push a new commit.
   9053 Secondly, that change may require that Magit buffers are refreshed to
   9054 reflect the changed state of the repository.  But refreshing isn’t
   9055 always desirable, so only some of these functions do perform such a
   9056 refresh after git has returned.
   9057 
   9058    Sometimes it is useful to run git asynchronously.  For example, when
   9059 the user has just initiated a push, then there is no reason to make her
   9060 wait until that has completed.  In other cases it makes sense to wait
   9061 for git to complete before letting the user do something else.  For
   9062 example after staging a change it is useful to wait until after the
   9063 refresh because that also automatically moves to the next change.
   9064 
   9065  -- Function: magit-call-git &rest args
   9066 
   9067      Calls git synchronously with ARGS.
   9068 
   9069  -- Function: magit-call-process program &rest args
   9070 
   9071      Calls PROGRAM synchronously with ARGS.
   9072 
   9073  -- Function: magit-run-git &rest args
   9074 
   9075      Calls git synchronously with ARGS and then refreshes.
   9076 
   9077  -- Function: magit-run-git-with-input &rest args
   9078 
   9079      Calls git synchronously with ARGS and sends it the content of the
   9080      current buffer on standard input.
   9081 
   9082      If the current buffer’s ‘default-directory’ is on a remote
   9083      filesystem, this function actually runs git asynchronously.  But
   9084      then it waits for the process to return, so the function itself is
   9085      synchronous.
   9086 
   9087  -- Function: magit-git &rest args
   9088 
   9089      Calls git synchronously with ARGS for side-effects only.  This
   9090      function does not refresh the buffer.
   9091 
   9092  -- Function: magit-git-wash washer &rest args
   9093 
   9094      Execute Git with ARGS, inserting washed output at point.  Actually
   9095      first insert the raw output at point.  If there is no output call
   9096      ‘magit-cancel-section’.  Otherwise temporarily narrow the buffer to
   9097      the inserted text, move to its beginning, and then call function
   9098      WASHER with ARGS as its sole argument.
   9099 
   9100    And now for the asynchronous variants.
   9101 
   9102  -- Function: magit-run-git-async &rest args
   9103 
   9104      Start Git, prepare for refresh, and return the process object.
   9105      ARGS is flattened and then used as arguments to Git.
   9106 
   9107      Display the command line arguments in the echo area.
   9108 
   9109      After Git returns some buffers are refreshed: the buffer that was
   9110      current when this function was called (if it is a Magit buffer and
   9111      still alive), as well as the respective Magit status buffer.
   9112      Unmodified buffers visiting files that are tracked in the current
   9113      repository are reverted if ‘magit-revert-buffers’ is non-nil.
   9114 
   9115  -- Function: magit-run-git-with-editor &rest args
   9116 
   9117      Export GIT_EDITOR and start Git.  Also prepare for refresh and
   9118      return the process object.  ARGS is flattened and then used as
   9119      arguments to Git.
   9120 
   9121      Display the command line arguments in the echo area.
   9122 
   9123      After Git returns some buffers are refreshed: the buffer that was
   9124      current when this function was called (if it is a Magit buffer and
   9125      still alive), as well as the respective Magit status buffer.
   9126 
   9127  -- Function: magit-start-git input &rest args
   9128 
   9129      Start Git, prepare for refresh, and return the process object.
   9130 
   9131      If INPUT is non-nil, it has to be a buffer or the name of an
   9132      existing buffer.  The buffer content becomes the processes standard
   9133      input.
   9134 
   9135      Option ‘magit-git-executable’ specifies the Git executable and
   9136      option ‘magit-git-global-arguments’ specifies constant arguments.
   9137      The remaining arguments ARGS specify arguments to Git.  They are
   9138      flattened before use.
   9139 
   9140      After Git returns, some buffers are refreshed: the buffer that was
   9141      current when this function was called (if it is a Magit buffer and
   9142      still alive), as well as the respective Magit status buffer.
   9143      Unmodified buffers visiting files that are tracked in the current
   9144      repository are reverted if ‘magit-revert-buffers’ is non-nil.
   9145 
   9146  -- Function: magit-start-process &rest args
   9147 
   9148      Start PROGRAM, prepare for refresh, and return the process object.
   9149 
   9150      If optional argument INPUT is non-nil, it has to be a buffer or the
   9151      name of an existing buffer.  The buffer content becomes the
   9152      processes standard input.
   9153 
   9154      The process is started using ‘start-file-process’ and then setup to
   9155      use the sentinel ‘magit-process-sentinel’ and the filter
   9156      ‘magit-process-filter’.  Information required by these functions is
   9157      stored in the process object.  When this function returns the
   9158      process has not started to run yet so it is possible to override
   9159      the sentinel and filter.
   9160 
   9161      After the process returns, ‘magit-process-sentinel’ refreshes the
   9162      buffer that was current when ‘magit-start-process’ was called (if
   9163      it is a Magit buffer and still alive), as well as the respective
   9164      Magit status buffer.  Unmodified buffers visiting files that are
   9165      tracked in the current repository are reverted if
   9166      ‘magit-revert-buffers’ is non-nil.
   9167 
   9168  -- Variable: magit-this-process
   9169 
   9170      The child process which is about to start.  This can be used to
   9171      change the filter and sentinel.
   9172 
   9173  -- Variable: magit-process-raise-error
   9174 
   9175      When this is non-nil, then ‘magit-process-sentinel’ raises an error
   9176      if git exits with a non-zero exit status.  For debugging purposes.
   9177 
   9178 
   9179 File: magit.info,  Node: Section Plumbing,  Next: Refreshing Buffers,  Prev: Calling Git,  Up: Plumbing
   9180 
   9181 10.2 Section Plumbing
   9182 =====================
   9183 
   9184 * Menu:
   9185 
   9186 * Creating Sections::
   9187 * Section Selection::
   9188 * Matching Sections::
   9189 
   9190 
   9191 File: magit.info,  Node: Creating Sections,  Next: Section Selection,  Up: Section Plumbing
   9192 
   9193 10.2.1 Creating Sections
   9194 ------------------------
   9195 
   9196  -- Macro: magit-insert-section &rest args
   9197 
   9198      Insert a section at point.
   9199 
   9200      TYPE is the section type, a symbol.  Many commands that act on the
   9201      current section behave differently depending on that type.  Also if
   9202      a variable ‘magit-TYPE-section-map’ exists, then use that as the
   9203      text-property ‘keymap’ of all text belonging to the section (but
   9204      this may be overwritten in subsections).  TYPE can also have the
   9205      form ‘(eval FORM)’ in which case FORM is evaluated at runtime.
   9206 
   9207      Optional VALUE is the value of the section, usually a string that
   9208      is required when acting on the section.
   9209 
   9210      When optional HIDE is non-nil collapse the section body by default,
   9211      i.e.  when first creating the section, but not when refreshing the
   9212      buffer.  Otherwise, expand it by default.  This can be overwritten
   9213      using ‘magit-section-set-visibility-hook’.  When a section is
   9214      recreated during a refresh, then the visibility of predecessor is
   9215      inherited and HIDE is ignored (but the hook is still honored).
   9216 
   9217      BODY is any number of forms that actually insert the section’s
   9218      heading and body.  Optional NAME, if specified, has to be a symbol,
   9219      which is then bound to the struct of the section being inserted.
   9220 
   9221      Before BODY is evaluated the ‘start’ of the section object is set
   9222      to the value of ‘point’ and after BODY was evaluated its ‘end’ is
   9223      set to the new value of ‘point’; BODY is responsible for moving
   9224      ‘point’ forward.
   9225 
   9226      If it turns out inside BODY that the section is empty, then
   9227      ‘magit-cancel-section’ can be used to abort and remove all traces
   9228      of the partially inserted section.  This can happen when creating a
   9229      section by washing Git’s output and Git didn’t actually output
   9230      anything this time around.
   9231 
   9232  -- Function: magit-insert-heading &rest args
   9233 
   9234      Insert the heading for the section currently being inserted.
   9235 
   9236      This function should only be used inside ‘magit-insert-section’.
   9237 
   9238      When called without any arguments, then just set the ‘content’ slot
   9239      of the object representing the section being inserted to a marker
   9240      at ‘point’.  The section should only contain a single line when
   9241      this function is used like this.
   9242 
   9243      When called with arguments ARGS, which have to be strings, then
   9244      insert those strings at point.  The section should not contain any
   9245      text before this happens and afterwards it should again only
   9246      contain a single line.  If the ‘face’ property is set anywhere
   9247      inside any of these strings, then insert all of them unchanged.
   9248      Otherwise use the ‘magit-section-heading’ face for all inserted
   9249      text.
   9250 
   9251      The ‘content’ property of the section struct is the end of the
   9252      heading (which lasts from ‘start’ to ‘content’) and the beginning
   9253      of the body (which lasts from ‘content’ to ‘end’).  If the value of
   9254      ‘content’ is nil, then the section has no heading and its body
   9255      cannot be collapsed.  If a section does have a heading then its
   9256      height must be exactly one line, including a trailing newline
   9257      character.  This isn’t enforced; you are responsible for getting it
   9258      right.  The only exception is that this function does insert a
   9259      newline character if necessary.
   9260 
   9261  -- Function: magit-cancel-section
   9262 
   9263      Cancel the section currently being inserted.  This exits the
   9264      innermost call to ‘magit-insert-section’ and removes all traces of
   9265      what has already happened inside that call.
   9266 
   9267  -- Function: magit-define-section-jumper sym title &optional value
   9268 
   9269      Define an interactive function to go to section SYM.  TITLE is the
   9270      displayed title of the section.
   9271 
   9272 
   9273 File: magit.info,  Node: Section Selection,  Next: Matching Sections,  Prev: Creating Sections,  Up: Section Plumbing
   9274 
   9275 10.2.2 Section Selection
   9276 ------------------------
   9277 
   9278  -- Function: magit-current-section
   9279 
   9280      Return the section at point.
   9281 
   9282  -- Function: magit-region-sections &optional condition multiple
   9283 
   9284      Return a list of the selected sections.
   9285 
   9286      When the region is active and constitutes a valid section
   9287      selection, then return a list of all selected sections.  This is
   9288      the case when the region begins in the heading of a section and
   9289      ends in the heading of the same section or in that of a sibling
   9290      section.  If optional MULTIPLE is non-nil, then the region cannot
   9291      begin and end in the same section.
   9292 
   9293      When the selection is not valid, then return nil.  In this case,
   9294      most commands that can act on the selected sections will instead
   9295      act on the section at point.
   9296 
   9297      When the region looks like it would in any other buffer then the
   9298      selection is invalid.  When the selection is valid then the region
   9299      uses the ‘magit-section-highlight’ face.  This does not apply to
   9300      diffs where things get a bit more complicated, but even here if the
   9301      region looks like it usually does, then that’s not a valid
   9302      selection as far as this function is concerned.
   9303 
   9304      If optional CONDITION is non-nil, then the selection not only has
   9305      to be valid; all selected sections additionally have to match
   9306      CONDITION, or nil is returned.  See ‘magit-section-match’ for the
   9307      forms CONDITION can take.
   9308 
   9309  -- Function: magit-region-values &optional condition multiple
   9310 
   9311      Return a list of the values of the selected sections.
   9312 
   9313      Return the values that themselves would be returned by
   9314      ‘magit-region-sections’ (which see).
   9315 
   9316 
   9317 File: magit.info,  Node: Matching Sections,  Prev: Section Selection,  Up: Section Plumbing
   9318 
   9319 10.2.3 Matching Sections
   9320 ------------------------
   9321 
   9322 ‘M-x magit-describe-section-briefly’     (‘magit-describe-section-briefly’)
   9323 
   9324      Show information about the section at point.  This command is
   9325      intended for debugging purposes.
   9326 
   9327  -- Function: magit-section-ident section
   9328 
   9329      Return an unique identifier for SECTION.  The return value has the
   9330      form ‘((TYPE . VALUE)...)’.
   9331 
   9332  -- Function: magit-get-section ident &optional root
   9333 
   9334      Return the section identified by IDENT.  IDENT has to be a list as
   9335      returned by ‘magit-section-ident’.
   9336 
   9337  -- Function: magit-section-match condition &optional section
   9338 
   9339      Return ‘t’ if SECTION matches CONDITION.  SECTION defaults to the
   9340      section at point.  If SECTION is not specified and there also is no
   9341      section at point, then return ‘nil’.
   9342 
   9343      CONDITION can take the following forms:
   9344         • ‘(CONDITION...)’
   9345 
   9346           matches if any of the CONDITIONs matches.
   9347 
   9348         • ‘[CLASS...]’
   9349 
   9350           matches if the section’s class is the same as the first CLASS
   9351           or a subclass of that; the section’s parent class matches the
   9352           second CLASS; and so on.
   9353 
   9354         • ‘[* CLASS...]’
   9355 
   9356           matches sections that match ‘[CLASS...]’ and also recursively
   9357           all their child sections.
   9358 
   9359         • ‘CLASS’
   9360 
   9361           matches if the section’s class is the same as CLASS or a
   9362           subclass of that; regardless of the classes of the parent
   9363           sections.
   9364 
   9365      Each CLASS should be a class symbol, identifying a class that
   9366      derives from ‘magit-section’.  For backward compatibility CLASS can
   9367      also be a "type symbol".  A section matches such a symbol if the
   9368      value of its ‘type’ slot is ‘eq’.  If a type symbol has an entry in
   9369      ‘magit--section-type-alist’, then a section also matches that type
   9370      if its class is a subclass of the class that corresponds to the
   9371      type as per that alist.
   9372 
   9373      Note that it is not necessary to specify the complete section
   9374      lineage as printed by ‘magit-describe-section-briefly’, unless of
   9375      course you want to be that precise.
   9376 
   9377  -- Function: magit-section-value-if condition &optional section
   9378 
   9379      If the section at point matches CONDITION, then return its value.
   9380 
   9381      If optional SECTION is non-nil then test whether that matches
   9382      instead.  If there is no section at point and SECTION is nil, then
   9383      return nil.  If the section does not match, then return nil.
   9384 
   9385      See ‘magit-section-match’ for the forms CONDITION can take.
   9386 
   9387  -- Function: magit-section-case &rest clauses
   9388 
   9389      Choose among clauses on the type of the section at point.
   9390 
   9391      Each clause looks like (CONDITION BODY...).  The type of the
   9392      section is compared against each CONDITION; the BODY forms of the
   9393      first match are evaluated sequentially and the value of the last
   9394      form is returned.  Inside BODY the symbol ‘it’ is bound to the
   9395      section at point.  If no clause succeeds or if there is no section
   9396      at point return nil.
   9397 
   9398      See ‘magit-section-match’ for the forms CONDITION can take.
   9399      Additionally a CONDITION of t is allowed in the final clause and
   9400      matches if no other CONDITION match, even if there is no section at
   9401      point.
   9402 
   9403  -- Variable: magit-root-section
   9404 
   9405      The root section in the current buffer.  All other sections are
   9406      descendants of this section.  The value of this variable is set by
   9407      ‘magit-insert-section’ and you should never modify it.
   9408 
   9409    For diff related sections a few additional tools exist.
   9410 
   9411  -- Function: magit-diff-type &optional section
   9412 
   9413      Return the diff type of SECTION.
   9414 
   9415      The returned type is one of the symbols ‘staged’, ‘unstaged’,
   9416      ‘committed’, or ‘undefined’.  This type serves a similar purpose as
   9417      the general type common to all sections (which is stored in the
   9418      ‘type’ slot of the corresponding ‘magit-section’ struct) but takes
   9419      additional information into account.  When the SECTION isn’t
   9420      related to diffs and the buffer containing it also isn’t a
   9421      diff-only buffer, then return nil.
   9422 
   9423      Currently the type can also be one of ‘tracked’ and ‘untracked’,
   9424      but these values are not handled explicitly in every place they
   9425      should be.  A possible fix could be to just return nil here.
   9426 
   9427      The section has to be a ‘diff’ or ‘hunk’ section, or a section
   9428      whose children are of type ‘diff’.  If optional SECTION is nil,
   9429      return the diff type for the current section.  In buffers whose
   9430      major mode is ‘magit-diff-mode’ SECTION is ignored and the type is
   9431      determined using other means.  In ‘magit-revision-mode’ buffers the
   9432      type is always ‘committed’.
   9433 
   9434  -- Function: magit-diff-scope &optional section strict
   9435 
   9436      Return the diff scope of SECTION or the selected section(s).
   9437 
   9438      A diff’s "scope" describes what part of a diff is selected, it is a
   9439      symbol, one of ‘region’, ‘hunk’, ‘hunks’, ‘file’, ‘files’, or
   9440      ‘list’.  Do not confuse this with the diff "type", as returned by
   9441      ‘magit-diff-type’.
   9442 
   9443      If optional SECTION is non-nil, then return the scope of that,
   9444      ignoring the sections selected by the region.  Otherwise return the
   9445      scope of the current section, or if the region is active and
   9446      selects a valid group of diff related sections, the type of these
   9447      sections, i.e.  ‘hunks’ or ‘files’.  If SECTION (or if the current
   9448      section that is nil) is a ‘hunk’ section and the region starts and
   9449      ends inside the body of a that section, then the type is ‘region’.
   9450 
   9451      If optional STRICT is non-nil then return nil if the diff type of
   9452      the section at point is ‘untracked’ or the section at point is not
   9453      actually a ‘diff’ but a ‘diffstat’ section.
   9454 
   9455 
   9456 File: magit.info,  Node: Refreshing Buffers,  Next: Conventions,  Prev: Section Plumbing,  Up: Plumbing
   9457 
   9458 10.3 Refreshing Buffers
   9459 =======================
   9460 
   9461 All commands that create a new Magit buffer or change what is being
   9462 displayed in an existing buffer do so by calling ‘magit-mode-setup’.
   9463 Among other things, that function sets the buffer local values of
   9464 ‘default-directory’ (to the top-level of the repository),
   9465 ‘magit-refresh-function’, and ‘magit-refresh-args’.
   9466 
   9467    Buffers are refreshed by calling the function that is the local value
   9468 of ‘magit-refresh-function’ (a function named ‘magit-*-refresh-buffer’,
   9469 where ‘*’ may be something like ‘diff’) with the value of
   9470 ‘magit-refresh-args’ as arguments.
   9471 
   9472  -- Macro: magit-mode-setup buffer switch-func mode refresh-func
   9473           &optional refresh-args
   9474 
   9475      This function displays and selects BUFFER, turns on MODE, and
   9476      refreshes a first time.
   9477 
   9478      This function displays and optionally selects BUFFER by calling
   9479      ‘magit-mode-display-buffer’ with BUFFER, MODE and SWITCH-FUNC as
   9480      arguments.  Then it sets the local value of
   9481      ‘magit-refresh-function’ to REFRESH-FUNC and that of
   9482      ‘magit-refresh-args’ to REFRESH-ARGS.  Finally it creates the
   9483      buffer content by calling REFRESH-FUNC with REFRESH-ARGS as
   9484      arguments.
   9485 
   9486      All arguments are evaluated before switching to BUFFER.
   9487 
   9488  -- Function: magit-mode-display-buffer buffer mode &optional
   9489           switch-function
   9490 
   9491      This function display BUFFER in some window and select it.  BUFFER
   9492      may be a buffer or a string, the name of a buffer.  The buffer is
   9493      returned.
   9494 
   9495      Unless BUFFER is already displayed in the selected frame, store the
   9496      previous window configuration as a buffer local value, so that it
   9497      can later be restored by ‘magit-mode-bury-buffer’.
   9498 
   9499      The buffer is displayed and selected using SWITCH-FUNCTION.  If
   9500      that is ‘nil’ then ‘pop-to-buffer’ is used if the current buffer’s
   9501      major mode derives from ‘magit-mode’.  Otherwise ‘switch-to-buffer’
   9502      is used.
   9503 
   9504  -- Variable: magit-refresh-function
   9505 
   9506      The value of this buffer-local variable is the function used to
   9507      refresh the current buffer.  It is called with ‘magit-refresh-args’
   9508      as arguments.
   9509 
   9510  -- Variable: magit-refresh-args
   9511 
   9512      The list of arguments used by ‘magit-refresh-function’ to refresh
   9513      the current buffer.  ‘magit-refresh-function’ is called with these
   9514      arguments.
   9515 
   9516      The value is usually set using ‘magit-mode-setup’, but in some
   9517      cases it’s also useful to provide commands that can change the
   9518      value.  For example, the ‘magit-diff-refresh’ transient can be used
   9519      to change any of the arguments used to display the diff, without
   9520      having to specify again which differences should be shown, but
   9521      ‘magit-diff-more-context’, ‘magit-diff-less-context’ and
   9522      ‘magit-diff-default-context’ change just the ‘-U<N>’ argument.  In
   9523      both case this is done by changing the value of this variable and
   9524      then calling this ‘magit-refresh-function’.
   9525 
   9526 
   9527 File: magit.info,  Node: Conventions,  Prev: Refreshing Buffers,  Up: Plumbing
   9528 
   9529 10.4 Conventions
   9530 ================
   9531 
   9532 Also see *note Completion and Confirmation::.
   9533 
   9534 * Menu:
   9535 
   9536 * Theming Faces::
   9537 
   9538 
   9539 File: magit.info,  Node: Theming Faces,  Up: Conventions
   9540 
   9541 10.4.1 Theming Faces
   9542 --------------------
   9543 
   9544 The default theme uses blue for local branches, green for remote
   9545 branches, and goldenrod (brownish yellow) for tags.  When creating a new
   9546 theme, you should probably follow that example.  If your theme already
   9547 uses other colors, then stick to that.
   9548 
   9549    In older releases these reference faces used to have a background
   9550 color and a box around them.  The basic default faces no longer do so,
   9551 to make Magit buffers much less noisy, and you should follow that
   9552 example at least with regards to boxes.  (Boxes were used in the past to
   9553 work around a conflict between the highlighting overlay and text
   9554 property backgrounds.  That’s no longer necessary because highlighting
   9555 no longer causes other background colors to disappear.)  Alternatively
   9556 you can keep the background color and/or box, but then have to take
   9557 special care to adjust ‘magit-branch-current’ accordingly.  By default
   9558 it looks mostly like ‘magit-branch-local’, but with a box (by default
   9559 the former is the only face that uses a box, exactly so that it sticks
   9560 out).  If the former also uses a box, then you have to make sure that it
   9561 differs in some other way from the latter.
   9562 
   9563    The most difficult faces to theme are those related to diffs,
   9564 headings, highlighting, and the region.  There are faces that fall into
   9565 all four groups - expect to spend some time getting this right.
   9566 
   9567    The ‘region’ face in the default theme, in both the light and dark
   9568 variants, as well as in many other themes, distributed with Emacs or by
   9569 third-parties, is very ugly.  It is common to use a background color
   9570 that really sticks out, which is ugly but if that were the only problem
   9571 then it would be acceptable.  Unfortunately many themes also set the
   9572 foreground color, which ensures that all text within the region is
   9573 readable.  Without doing that there might be cases where some foreground
   9574 color is too close to the region background color to still be readable.
   9575 But it also means that text within the region loses all syntax
   9576 highlighting.
   9577 
   9578    I consider the work that went into getting the ‘region’ face right to
   9579 be a good indicator for the general quality of a theme.  My
   9580 recommendation for the ‘region’ face is this: use a background color
   9581 slightly different from the background color of the ‘default’ face, and
   9582 do not set the foreground color at all.  So for a light theme you might
   9583 use a light (possibly tinted) gray as the background color of ‘default’
   9584 and a somewhat darker gray for the background of ‘region’.  That should
   9585 usually be enough to not collide with the foreground color of any other
   9586 face.  But if some other faces also set a light gray as background
   9587 color, then you should also make sure it doesn’t collide with those (in
   9588 some cases it might be acceptable though).
   9589 
   9590    Magit only uses the ‘region’ face when the region is "invalid" by its
   9591 own definition.  In a Magit buffer the region is used to either select
   9592 multiple sibling sections, so that commands which support it act on all
   9593 of these sections instead of just the current section, or to select
   9594 lines within a single hunk section.  In all other cases, the section is
   9595 considered invalid and Magit won’t act on it.  But such invalid sections
   9596 happen, either because the user has not moved point enough yet to make
   9597 it valid or because she wants to use a non-magit command to act on the
   9598 region, e.g.  ‘kill-region’.
   9599 
   9600    So using the regular ‘region’ face for invalid sections is a feature.
   9601 It tells the user that Magit won’t be able to act on it.  It’s
   9602 acceptable if that face looks a bit odd and even (but less so) if it
   9603 collides with the background colors of section headings and other things
   9604 that have a background color.
   9605 
   9606    Magit highlights the current section.  If a section has subsections,
   9607 then all of them are highlighted.  This is done using faces that have
   9608 "highlight" in their names.  For most sections,
   9609 ‘magit-section-highlight’ is used for both the body and the heading.
   9610 Like the ‘region’ face, it should only set the background color to
   9611 something similar to that of ‘default’.  The highlight background color
   9612 must be different from both the ‘region’ background color and the
   9613 ‘default’ background color.
   9614 
   9615    For diff related sections Magit uses various faces to highlight
   9616 different parts of the selected section(s).  Note that hunk headings,
   9617 unlike all other section headings, by default have a background color,
   9618 because it is useful to have very visible separators between hunks.
   9619 That face ‘magit-diff-hunk-heading’, should be different from both
   9620 ‘magit-diff-hunk-heading-highlight’ and ‘magit-section-highlight’, as
   9621 well as from ‘magit-diff-context’ and ‘magit-diff-context-highlight’.
   9622 By default we do that by changing the foreground color.  Changing the
   9623 background color would lead to complications, and there are already
   9624 enough we cannot get around.  (Also note that it is generally a good
   9625 idea for section headings to always be bold, but only for sections that
   9626 have subsections).
   9627 
   9628    When there is a valid region selecting diff-related sibling sections,
   9629 i.e.  multiple files or hunks, then the bodies of all these sections use
   9630 the respective highlight faces, but additionally the headings instead
   9631 use one of the faces ‘magit-diff-file-heading-selection’ or
   9632 ‘magit-diff-hunk-heading-selection’.  These faces have to be different
   9633 from the regular highlight variants to provide explicit visual
   9634 indication that the region is active.
   9635 
   9636    When theming diff related faces, start by setting the option
   9637 ‘magit-diff-refine-hunk’ to ‘all’.  You might personally prefer to only
   9638 refine the current hunk or not use hunk refinement at all, but some of
   9639 the users of your theme want all hunks to be refined, so you have to
   9640 cater to that.
   9641 
   9642    (Also turn on ‘magit-diff-highlight-indentation’,
   9643 ‘magit-diff-highlight-trailing’, and ‘magit-diff-paint-whitespace’; and
   9644 insert some whitespace errors into the code you use for testing.)
   9645 
   9646    For e.g.  "added lines" you have to adjust three faces:
   9647 ‘magit-diff-added’, ‘magit-diff-added-highlight’, and
   9648 ‘smerge-refined-added’.  Make sure that the latter works well with both
   9649 of the former, as well as ‘smerge-other’ and ‘diff-added’.  Then do the
   9650 same for the removed lines, context lines, lines added by us, and lines
   9651 added by them.  Also make sure the respective added, removed, and
   9652 context faces use approximately the same saturation for both the
   9653 highlighted and unhighlighted variants.  Also make sure the file and
   9654 diff headings work nicely with context lines (e.g.  make them look
   9655 different).  Line faces should set both the foreground and the
   9656 background color.  For example, for added lines use two different
   9657 greens.
   9658 
   9659    It’s best if the foreground color of both the highlighted and the
   9660 unhighlighted variants are the same, so you will need to have to find a
   9661 color that works well on the highlight and unhighlighted background, the
   9662 refine background, and the highlight context background.  When there is
   9663 an hunk internal region, then the added- and removed-lines background
   9664 color is used only within that region.  Outside the region the
   9665 highlighted context background color is used.  This makes it easier to
   9666 see what is being staged.  With an hunk internal region the hunk heading
   9667 is shown using ‘magit-diff-hunk-heading-selection’, and so are the thin
   9668 lines that are added around the lines that fall within the region.  The
   9669 background color of that has to be distinct enough from the various
   9670 other involved background colors.
   9671 
   9672    Nobody said this would be easy.  If your theme restricts itself to a
   9673 certain set of colors, then you should make an exception here.
   9674 Otherwise it would be impossible to make the diffs look good in each and
   9675 every variation.  Actually you might want to just stick to the default
   9676 definitions for these faces.  You have been warned.  Also please note
   9677 that if you do not get this right, this will in some cases look to users
   9678 like bugs in Magit - so please do it right or not at all.
   9679 
   9680 
   9681 File: magit.info,  Node: FAQ,  Next: Debugging Tools,  Prev: Plumbing,  Up: Top
   9682 
   9683 Appendix A FAQ
   9684 **************
   9685 
   9686 The next two nodes lists frequently asked questions.  For a list of
   9687 frequently *and recently* asked questions, i.e.  questions that haven’t
   9688 made it into the manual yet, see
   9689 <https://github.com/magit/magit/wiki/FAQ>.
   9690 
   9691    Please also use the *note Debugging Tools::.
   9692 
   9693 * Menu:
   9694 
   9695 * FAQ - How to ...?::
   9696 * FAQ - Issues and Errors::
   9697 
   9698 
   9699 File: magit.info,  Node: FAQ - How to ...?,  Next: FAQ - Issues and Errors,  Up: FAQ
   9700 
   9701 A.1 FAQ - How to ...?
   9702 =====================
   9703 
   9704 * Menu:
   9705 
   9706 * How to pronounce Magit?::
   9707 * How to show git's output?::
   9708 * How to install the gitman info manual?::
   9709 * How to show diffs for gpg-encrypted files?::
   9710 * How does branching and pushing work?::
   9711 * Can Magit be used as ediff-version-control-package?::
   9712 * Should I disable VC?::
   9713 
   9714 
   9715 File: magit.info,  Node: How to pronounce Magit?,  Next: How to show git's output?,  Up: FAQ - How to ...?
   9716 
   9717 A.1.1 How to pronounce Magit?
   9718 -----------------------------
   9719 
   9720 Either ‘mu[m's] git’ or ‘magi{c => t}’ is fine.
   9721 
   9722    The slogan is "It’s Magit!  The magical Git client", so it makes
   9723 sense to pronounce Magit like magic, while taking into account that C
   9724 and T do not sound the same.
   9725 
   9726    The German "Magie" is not pronounced the same as the English "magic",
   9727 so if you speak German then you can use the above rational to justify
   9728 using the former pronunciation; ‘Mag{ie => it}’.
   9729 
   9730    You can also choose to use the former pronunciation just because you
   9731 like it better.
   9732 
   9733    Also see <https://magit.vc/assets/videos/magic.mp4>.  Also see
   9734 <https://emacs.stackexchange.com/questions/13696>.
   9735 
   9736 
   9737 File: magit.info,  Node: How to show git's output?,  Next: How to install the gitman info manual?,  Prev: How to pronounce Magit?,  Up: FAQ - How to ...?
   9738 
   9739 A.1.2 How to show git’s output?
   9740 -------------------------------
   9741 
   9742 To show the output of recently run git commands, press ‘$’ (or, if that
   9743 isn’t available, ‘M-x magit-process-buffer’).  This will show a buffer
   9744 containing a section per git invocation; as always press ‘TAB’ to expand
   9745 or collapse them.
   9746 
   9747    By default, git’s output is only inserted into the process buffer if
   9748 it is run for side-effects.  When the output is consumed in some way,
   9749 also inserting it into the process buffer would be too expensive.  For
   9750 debugging purposes, it’s possible to do so anyway by setting
   9751 ‘magit-git-debug’ to ‘t’.
   9752 
   9753 
   9754 File: magit.info,  Node: How to install the gitman info manual?,  Next: How to show diffs for gpg-encrypted files?,  Prev: How to show git's output?,  Up: FAQ - How to ...?
   9755 
   9756 A.1.3 How to install the gitman info manual?
   9757 --------------------------------------------
   9758 
   9759 Git’s manpages can be exported as an info manual called ‘gitman’.
   9760 Magit’s own info manual links to nodes in that manual instead of the
   9761 actual manpages because Info doesn’t support linking to manpages.
   9762 
   9763    Unfortunately some distributions do not install the ‘gitman’ manual
   9764 by default and you will have to install a separate documentation package
   9765 to get it.
   9766 
   9767    Magit patches Info adding the ability to visit links to the ‘gitman’
   9768 Info manual by instead viewing the respective manpage.  If you prefer
   9769 that approach, then set the value of ‘magit-view-git-manual-method’ to
   9770 one of the supported packages ‘man’ or ‘woman’, e.g.:
   9771 
   9772      (setq magit-view-git-manual-method 'man)
   9773 
   9774 
   9775 File: magit.info,  Node: How to show diffs for gpg-encrypted files?,  Next: How does branching and pushing work?,  Prev: How to install the gitman info manual?,  Up: FAQ - How to ...?
   9776 
   9777 A.1.4 How to show diffs for gpg-encrypted files?
   9778 ------------------------------------------------
   9779 
   9780 Git supports showing diffs for encrypted files, but has to be told to do
   9781 so.  Since Magit just uses Git to get the diffs, configuring Git also
   9782 affects the diffs displayed inside Magit.
   9783 
   9784      git config --global diff.gpg.textconv "gpg --no-tty --decrypt"
   9785      echo "*.gpg filter=gpg diff=gpg" > .gitattributes
   9786 
   9787 
   9788 File: magit.info,  Node: How does branching and pushing work?,  Next: Can Magit be used as ediff-version-control-package?,  Prev: How to show diffs for gpg-encrypted files?,  Up: FAQ - How to ...?
   9789 
   9790 A.1.5 How does branching and pushing work?
   9791 ------------------------------------------
   9792 
   9793 Please see *note Branching:: and
   9794 <http://emacsair.me/2016/01/18/magit-2.4>
   9795 
   9796 
   9797 File: magit.info,  Node: Can Magit be used as ediff-version-control-package?,  Next: Should I disable VC?,  Prev: How does branching and pushing work?,  Up: FAQ - How to ...?
   9798 
   9799 A.1.6 Can Magit be used as ‘ediff-version-control-package’?
   9800 -----------------------------------------------------------
   9801 
   9802 No, it cannot.  For that to work the functions ‘ediff-magit-internal’
   9803 and ‘ediff-magit-merge-internal’ would have to be implemented, and they
   9804 are not.  These two functions are only used by the three commands
   9805 ‘ediff-revision’, ‘ediff-merge-revisions-with-ancestor’, and
   9806 ‘ediff-merge-revisions’.
   9807 
   9808    These commands only delegate the task of populating buffers with
   9809 certain revisions to the "internal" functions.  The equally important
   9810 task of determining which revisions are to be compared/merged is not
   9811 delegated.  Instead this is done without any support whatsoever from the
   9812 version control package/system - meaning that the user has to enter the
   9813 revisions explicitly.  Instead of implementing ‘ediff-magit-internal’ we
   9814 provide ‘magit-ediff-compare’, which handles both tasks like it is 2005.
   9815 
   9816    The other commands ‘ediff-merge-revisions’ and
   9817 ‘ediff-merge-revisions-with-ancestor’ are normally not what you want
   9818 when using a modern version control system like Git.  Instead of letting
   9819 the user resolve only those conflicts which Git could not resolve on its
   9820 own, they throw away all work done by Git and then expect the user to
   9821 manually merge all conflicts, including those that had already been
   9822 resolved.  That made sense back in the days when version control systems
   9823 couldn’t merge (or so I have been told), but not anymore.  Once in a
   9824 blue moon you might actually want to see all conflicts, in which case
   9825 you *can* use these commands, which then use ‘ediff-vc-merge-internal’.
   9826 So we don’t actually have to implement ‘ediff-magit-merge-internal’.
   9827 Instead we provide the more useful command ‘magit-ediff-resolve’ which
   9828 only shows yet-to-be resolved conflicts.
   9829 
   9830 
   9831 File: magit.info,  Node: Should I disable VC?,  Prev: Can Magit be used as ediff-version-control-package?,  Up: FAQ - How to ...?
   9832 
   9833 A.1.7 Should I disable VC?
   9834 --------------------------
   9835 
   9836 If you don’t use VC (the built-in version control interface) then you
   9837 might be tempted to disable it, not least because we used to recommend
   9838 that you do that.
   9839 
   9840    We no longer recommend that you disable VC.  Doing so would break
   9841 useful third-party packages (such as ‘diff-hl’), which depend on VC
   9842 being enabled.
   9843 
   9844    If you choose to disable VC anyway, then you can do so by changing
   9845 the value of ‘vc-handled-backends’.
   9846 
   9847 
   9848 File: magit.info,  Node: FAQ - Issues and Errors,  Prev: FAQ - How to ...?,  Up: FAQ
   9849 
   9850 A.2 FAQ - Issues and Errors
   9851 ===========================
   9852 
   9853 * Menu:
   9854 
   9855 * Magit is slow::
   9856 * I changed several thousand files at once and now Magit is unusable::
   9857 * I am having problems committing::
   9858 * I am using MS Windows and cannot push with Magit::
   9859 * I am using OS X and SOMETHING works in shell, but not in Magit: I am using OS X and SOMETHING works in shell but not in Magit.
   9860 * Expanding a file to show the diff causes it to disappear::
   9861 * Point is wrong in the COMMIT_EDITMSG buffer::
   9862 * The mode-line information isn't always up-to-date::
   9863 * A branch and tag sharing the same name breaks SOMETHING::
   9864 * My Git hooks work on the command-line but not inside Magit::
   9865 * git-commit-mode isn't used when committing from the command-line::
   9866 * Point ends up inside invisible text when jumping to a file-visiting buffer::
   9867 * I am unable to stage when using Tramp from MS Windows::
   9868 * I am no longer able to save popup defaults::
   9869 
   9870 
   9871 File: magit.info,  Node: Magit is slow,  Next: I changed several thousand files at once and now Magit is unusable,  Up: FAQ - Issues and Errors
   9872 
   9873 A.2.1 Magit is slow
   9874 -------------------
   9875 
   9876 See *note Performance::.
   9877 
   9878 
   9879 File: magit.info,  Node: I changed several thousand files at once and now Magit is unusable,  Next: I am having problems committing,  Prev: Magit is slow,  Up: FAQ - Issues and Errors
   9880 
   9881 A.2.2 I changed several thousand files at once and now Magit is unusable
   9882 ------------------------------------------------------------------------
   9883 
   9884 Magit is *currently* not expected to work under such conditions.  It
   9885 sure would be nice if it did, and v2.5 will hopefully be a big step into
   9886 that direction.  But it might take until v3.1 to accomplish fully
   9887 satisfactory performance, because that requires some heavy refactoring.
   9888 
   9889    But for now we recommend you use the command line to complete this
   9890 one commit.  Also see *note Performance::.
   9891 
   9892 
   9893 File: magit.info,  Node: I am having problems committing,  Next: I am using MS Windows and cannot push with Magit,  Prev: I changed several thousand files at once and now Magit is unusable,  Up: FAQ - Issues and Errors
   9894 
   9895 A.2.3 I am having problems committing
   9896 -------------------------------------
   9897 
   9898 That likely means that Magit is having problems finding an appropriate
   9899 emacsclient executable.  See *note (with-editor)Configuring
   9900 With-Editor:: and *note (with-editor)Debugging::.
   9901 
   9902 
   9903 File: magit.info,  Node: I am using MS Windows and cannot push with Magit,  Next: I am using OS X and SOMETHING works in shell but not in Magit,  Prev: I am having problems committing,  Up: FAQ - Issues and Errors
   9904 
   9905 A.2.4 I am using MS Windows and cannot push with Magit
   9906 ------------------------------------------------------
   9907 
   9908 It’s almost certain that Magit is only incidental to this issue.  It is
   9909 much more likely that this is a configuration issue, even if you can
   9910 push on the command line.
   9911 
   9912    Detailed setup instructions can be found at
   9913 <https://github.com/magit/magit/wiki/Pushing-with-Magit-from-Windows>.
   9914 
   9915 
   9916 File: magit.info,  Node: I am using OS X and SOMETHING works in shell but not in Magit,  Next: Expanding a file to show the diff causes it to disappear,  Prev: I am using MS Windows and cannot push with Magit,  Up: FAQ - Issues and Errors
   9917 
   9918 A.2.5 I am using OS X and SOMETHING works in shell, but not in Magit
   9919 --------------------------------------------------------------------
   9920 
   9921 This usually occurs because Emacs doesn’t have the same environment
   9922 variables as your shell.  Try installing and configuring
   9923 <https://github.com/purcell/exec-path-from-shell>.  By default it
   9924 synchronizes ‘$PATH’, which helps Magit find the same ‘git’ as the one
   9925 you are using on the shell.
   9926 
   9927    If SOMETHING is "passphrase caching with gpg-agent for commit and/or
   9928 tag signing", then you’ll also need to synchronize ‘$GPG_AGENT_INFO’.
   9929 
   9930 
   9931 File: magit.info,  Node: Expanding a file to show the diff causes it to disappear,  Next: Point is wrong in the COMMIT_EDITMSG buffer,  Prev: I am using OS X and SOMETHING works in shell but not in Magit,  Up: FAQ - Issues and Errors
   9932 
   9933 A.2.6 Expanding a file to show the diff causes it to disappear
   9934 --------------------------------------------------------------
   9935 
   9936 This is probably caused by a change of a ‘diff.*’ Git variable.  You
   9937 probably set that variable for a reason, and should therefore only undo
   9938 that setting in Magit by customizing ‘magit-git-global-arguments’.
   9939 
   9940 
   9941 File: magit.info,  Node: Point is wrong in the COMMIT_EDITMSG buffer,  Next: The mode-line information isn't always up-to-date,  Prev: Expanding a file to show the diff causes it to disappear,  Up: FAQ - Issues and Errors
   9942 
   9943 A.2.7 Point is wrong in the ‘COMMIT_EDITMSG’ buffer
   9944 ---------------------------------------------------
   9945 
   9946 Neither Magit nor ‘git-commit‘ fiddle with point in the buffer used to
   9947 write commit messages, so something else must be doing it.
   9948 
   9949    You have probably globally enabled a mode which does restore point in
   9950 file-visiting buffers.  It might be a bit surprising, but when you write
   9951 a commit message, then you are actually editing a file.
   9952 
   9953    So you have to figure out which package is doing.  ‘saveplace’,
   9954 ‘pointback’, and ‘session’ are likely candidates.  These snippets might
   9955 help:
   9956 
   9957      (setq session-name-disable-regexp "\\(?:\\`'\\.git/[A-Z_]+\\'\\)")
   9958 
   9959      (with-eval-after-load 'pointback
   9960        (lambda ()
   9961          (when (or git-commit-mode git-rebase-mode)
   9962            (pointback-mode -1))))
   9963 
   9964 
   9965 File: magit.info,  Node: The mode-line information isn't always up-to-date,  Next: A branch and tag sharing the same name breaks SOMETHING,  Prev: Point is wrong in the COMMIT_EDITMSG buffer,  Up: FAQ - Issues and Errors
   9966 
   9967 A.2.8 The mode-line information isn’t always up-to-date
   9968 -------------------------------------------------------
   9969 
   9970 Magit is not responsible for the version control information that is
   9971 being displayed in the mode-line and looks something like ‘Git-master’.
   9972 The built-in "Version Control" package, also known as "VC", updates that
   9973 information, and can be told to do so more often:
   9974 
   9975      (setq auto-revert-check-vc-info t)
   9976 
   9977    But doing so isn’t good for performance.  For more (overly
   9978 optimistic) information see *note (emacs)VC Mode Line::.
   9979 
   9980    If you don’t really care about seeing this information in the
   9981 mode-line, but just don’t want to see _incorrect_ information, then
   9982 consider simply not displaying it in the mode-line:
   9983 
   9984      (setq-default mode-line-format
   9985                    (delete '(vc-mode vc-mode) mode-line-format))
   9986 
   9987 
   9988 File: magit.info,  Node: A branch and tag sharing the same name breaks SOMETHING,  Next: My Git hooks work on the command-line but not inside Magit,  Prev: The mode-line information isn't always up-to-date,  Up: FAQ - Issues and Errors
   9989 
   9990 A.2.9 A branch and tag sharing the same name breaks SOMETHING
   9991 -------------------------------------------------------------
   9992 
   9993 Or more generally, ambiguous refnames break SOMETHING.
   9994 
   9995    Magit assumes that refs are named non-ambiguously across the
   9996 "refs/heads/", "refs/tags/", and "refs/remotes/" namespaces (i.e., all
   9997 the names remain unique when those prefixes are stripped).  We consider
   9998 ambiguous refnames unsupported and recommend that you use a
   9999 non-ambiguous naming scheme.  However, if you do work with a repository
  10000 that has ambiguous refnames, please report any issues you encounter so
  10001 that we can investigate whether there is a simple fix.
  10002 
  10003 
  10004 File: magit.info,  Node: My Git hooks work on the command-line but not inside Magit,  Next: git-commit-mode isn't used when committing from the command-line,  Prev: A branch and tag sharing the same name breaks SOMETHING,  Up: FAQ - Issues and Errors
  10005 
  10006 A.2.10 My Git hooks work on the command-line but not inside Magit
  10007 -----------------------------------------------------------------
  10008 
  10009 When Magit calls ‘git’ it adds a few global arguments including
  10010 ‘--literal-pathspecs’ and the ‘git’ process started by Magit then passes
  10011 that setting on to other ‘git’ process it starts itself.  It does so by
  10012 setting the environment variable ‘GIT_LITERAL_PATHSPECS’, not by calling
  10013 subprocesses with the ‘--literal-pathspecs’ argument.  You can therefore
  10014 override this setting in hook scripts using ‘unset
  10015 GIT_LITERAL_PATHSPECS’.
  10016 
  10017 
  10018 File: magit.info,  Node: git-commit-mode isn't used when committing from the command-line,  Next: Point ends up inside invisible text when jumping to a file-visiting buffer,  Prev: My Git hooks work on the command-line but not inside Magit,  Up: FAQ - Issues and Errors
  10019 
  10020 A.2.11 ‘git-commit-mode’ isn’t used when committing from the command-line
  10021 -------------------------------------------------------------------------
  10022 
  10023 The reason for this is that ‘git-commit.el’ has not been loaded yet
  10024 and/or that the server has not been started yet.  These things have
  10025 always already been taken care of when you commit from Magit because in
  10026 order to do so, Magit has to be loaded and doing that involves loading
  10027 ‘git-commit’ and starting the server.
  10028 
  10029    If you want to commit from the command-line, then you have to take
  10030 care of these things yourself.  Your ‘init.el’ file should contain:
  10031 
  10032      (require 'git-commit)
  10033      (server-mode)
  10034 
  10035    Instead of ‘(require ’git-commit)‘ you may also use:
  10036 
  10037      (load "/path/to/magit-autoloads.el")
  10038 
  10039    You might want to do that because loading ‘git-commit’ causes large
  10040 parts of Magit to be loaded.
  10041 
  10042    There are also some variations of ‘(server-mode)’ that you might want
  10043 to try.  Personally I use:
  10044 
  10045      (use-package server
  10046        :config (or (server-running-p) (server-mode)))
  10047 
  10048    Now you can use:
  10049 
  10050      $ emacs&
  10051      $ EDITOR=emacsclient git commit
  10052 
  10053    However you cannot use:
  10054 
  10055      $ killall emacs
  10056      $ EDITOR="emacsclient --alternate-editor emacs" git commit
  10057 
  10058    This will actually end up using ‘emacs’, not ‘emacsclient’.  If you
  10059 do this, then you can still edit the commit message but
  10060 ‘git-commit-mode’ won’t be used and you have to exit ‘emacs’ to finish
  10061 the process.
  10062 
  10063    Tautology ahead.  If you want to be able to use ‘emacsclient’ to
  10064 connect to a running ‘emacs’ instance, even though no ‘emacs’ instance
  10065 is running, then you cannot use ‘emacsclient’ directly.
  10066 
  10067    Instead you have to create a script that does something like this:
  10068 
  10069    Try to use ‘emacsclient’ (without using ‘--alternate-editor’).  If
  10070 that succeeds, do nothing else.  Otherwise start ‘emacs &’ (and
  10071 ‘init.el’ must call ‘server-start’) and try to use ‘emacsclient’ again.
  10072 
  10073 
  10074 File: magit.info,  Node: Point ends up inside invisible text when jumping to a file-visiting buffer,  Next: I am unable to stage when using Tramp from MS Windows,  Prev: git-commit-mode isn't used when committing from the command-line,  Up: FAQ - Issues and Errors
  10075 
  10076 A.2.12 Point ends up inside invisible text when jumping to a file-visiting buffer
  10077 ---------------------------------------------------------------------------------
  10078 
  10079 This can happen when you type ‘RET’ on a hunk to visit the respective
  10080 file at the respective position.  One solution to this problem is to use
  10081 ‘global-reveal-mode’.  It makes sure that text around point is always
  10082 visible.  If that is too drastic for your taste, then you may instead
  10083 use ‘magit-diff-visit-file-hook’ to reveal the text, possibly using
  10084 ‘reveal-post-command’ or for Org buffers ‘org-reveal’.
  10085 
  10086 
  10087 File: magit.info,  Node: I am unable to stage when using Tramp from MS Windows,  Next: I am no longer able to save popup defaults,  Prev: Point ends up inside invisible text when jumping to a file-visiting buffer,  Up: FAQ - Issues and Errors
  10088 
  10089 A.2.13 I am unable to stage when using Tramp from MS Windows
  10090 ------------------------------------------------------------
  10091 
  10092 Magit may be unable to stage (or otherwise apply) individual hunks when
  10093 you are connected to remote machine using Tramp and the local machine
  10094 uses MS Windows.
  10095 
  10096    There appears to be a problem with ‘process-send-eof’ in this
  10097 scenario, as mentioned at the end of ‘tramp-tests.el’.  I have contacted
  10098 the Tramp maintainer about this.  For now this unfortunately means that
  10099 it just doesn’t work and we cannot do anything about it.  If you have
  10100 more information, then please comment on
  10101 <https://github.com/magit/magit/issues/3624>.
  10102 
  10103 
  10104 File: magit.info,  Node: I am no longer able to save popup defaults,  Prev: I am unable to stage when using Tramp from MS Windows,  Up: FAQ - Issues and Errors
  10105 
  10106 A.2.14 I am no longer able to save popup defaults
  10107 -------------------------------------------------
  10108 
  10109 Magit used to use Magit-Popup to implement the transient popup menus.
  10110 Now it used Transient instead, which is Magit-Popup’s successor.
  10111 
  10112    In the older Magit-Popup menus, it was possible to save user settings
  10113 (e.g.  setting the gpg signing key for commits) by using ‘C-c C-c’ in
  10114 the popup buffer.  This would dismiss the popup, but save the settings
  10115 as the defaults for future popups.
  10116 
  10117    When switching to Transient menus, this functionality is now
  10118 available via ‘C-x C-s’ instead; the ‘C-x’ prefix has other options as
  10119 well when using Transient, which will be displayed when it is typed.
  10120 See <https://magit.vc/manual/transient/Saving-Values.html#Saving-Values>
  10121 for more details.
  10122 
  10123 
  10124 File: magit.info,  Node: Debugging Tools,  Next: Keystroke Index,  Prev: FAQ,  Up: Top
  10125 
  10126 B Debugging Tools
  10127 *****************
  10128 
  10129 Magit and its dependencies provide a few debugging tools, and we
  10130 appreciate it very much if you use those tools before reporting an
  10131 issue.  Please include all relevant output when reporting an issue.
  10132 
  10133 ‘M-x magit-version’     (‘magit-version’)
  10134 
  10135      This command shows the currently used versions of Magit, Git, and
  10136      Emacs in the echo area.  Non-interactively this just returns the
  10137      Magit version.
  10138 
  10139 ‘M-x magit-emacs-Q-command’     (‘magit-emacs-Q-command’)
  10140 
  10141      This command shows a debugging shell command in the echo area and
  10142      adds it to the kill ring.  Paste that command into a shell and run
  10143      it.
  10144 
  10145      This shell command starts ‘emacs’ with only ‘magit’ and its
  10146      dependencies loaded.  Neither your configuration nor other
  10147      installed packages are loaded.  This makes it easier to determine
  10148      whether some issue lays with Magit or something else.
  10149 
  10150      If you run Magit from its Git repository, then you should be able
  10151      to use ‘make emacs-Q’ instead of the output of this command.
  10152 
  10153 ‘M-x magit-toggle-verbose-refresh’     (‘magit-toggle-verbose-refresh’)
  10154 
  10155      This command toggles whether Magit refreshes buffers verbosely.
  10156      Enabling this helps figuring out which sections are bottlenecks.
  10157      The additional output can be found in the ‘*Messages*’ buffer.
  10158 
  10159 ‘M-x magit-debug-git-executable’     (‘magit-debug-git-executable’)
  10160 
  10161      This command displays a buffer containing information about the
  10162      available and used ‘git’ executable(s), and can be useful when
  10163      investigating ‘exec-path’ issues.
  10164 
  10165      Also see *note Git Executable::.
  10166 
  10167 ‘M-x with-editor-debug’     (‘with-editor-debug’)
  10168 
  10169      This command displays a buffer containing information about the
  10170      available and used ‘emacsclient’ executable(s), and can be useful
  10171      when investigating why Magit (or rather ‘with-editor’) cannot find
  10172      an appropriate ‘emacsclient’ executable.
  10173 
  10174      Also see *note (with-editor)Debugging::.
  10175 
  10176    Please also see the *note FAQ::.
  10177 
  10178 
  10179 File: magit.info,  Node: Keystroke Index,  Next: Command Index,  Prev: Debugging Tools,  Up: Top
  10180 
  10181 Appendix C Keystroke Index
  10182 **************************
  10183 
  10184 
  10185 * Menu:
  10186 
  10187 * !:                                     Running Git Manually.
  10188                                                               (line  12)
  10189 * ! !:                                   Running Git Manually.
  10190                                                               (line  17)
  10191 * ! a:                                   Running Git Manually.
  10192                                                               (line  59)
  10193 * ! b:                                   Running Git Manually.
  10194                                                               (line  63)
  10195 * ! g:                                   Running Git Manually.
  10196                                                               (line  67)
  10197 * ! k:                                   Running Git Manually.
  10198                                                               (line  55)
  10199 * ! p:                                   Running Git Manually.
  10200                                                               (line  26)
  10201 * ! s:                                   Running Git Manually.
  10202                                                               (line  36)
  10203 * ! S:                                   Running Git Manually.
  10204                                                               (line  41)
  10205 * $:                                     Viewing Git Output.  (line  16)
  10206 * +:                                     Log Buffer.          (line  72)
  10207 * + <1>:                                 Refreshing Diffs.    (line  69)
  10208 * -:                                     Log Buffer.          (line  76)
  10209 * - <1>:                                 Refreshing Diffs.    (line  65)
  10210 * 0:                                     Refreshing Diffs.    (line  73)
  10211 * 1:                                     Section Visibility.  (line  26)
  10212 * 2:                                     Section Visibility.  (line  27)
  10213 * 3:                                     Section Visibility.  (line  28)
  10214 * 4:                                     Section Visibility.  (line  29)
  10215 * ::                                     Running Git Manually.
  10216                                                               (line  25)
  10217 * =:                                     Log Buffer.          (line  66)
  10218 * ^:                                     Section Movement.    (line  31)
  10219 * a:                                     Applying.            (line  33)
  10220 * A:                                     Cherry Picking.      (line   8)
  10221 * A A:                                   Cherry Picking.      (line  17)
  10222 * A a:                                   Cherry Picking.      (line  24)
  10223 * A A <1>:                               Cherry Picking.      (line  90)
  10224 * A a <1>:                               Cherry Picking.      (line  98)
  10225 * A d:                                   Cherry Picking.      (line  54)
  10226 * A h:                                   Cherry Picking.      (line  42)
  10227 * A n:                                   Cherry Picking.      (line  65)
  10228 * A s:                                   Cherry Picking.      (line  76)
  10229 * A s <1>:                               Cherry Picking.      (line  94)
  10230 * B:                                     Bisecting.           (line   8)
  10231 * b:                                     Blaming.             (line 102)
  10232 * b <1>:                                 Branch Commands.     (line  12)
  10233 * b <2>:                                 Editing Rebase Sequences.
  10234                                                               (line  85)
  10235 * B B:                                   Bisecting.           (line  16)
  10236 * B b:                                   Bisecting.           (line  34)
  10237 * b b:                                   Branch Commands.     (line  49)
  10238 * b C:                                   Branch Commands.     (line  29)
  10239 * b c:                                   Branch Commands.     (line  67)
  10240 * B g:                                   Bisecting.           (line  39)
  10241 * B k:                                   Bisecting.           (line  51)
  10242 * b k:                                   Branch Commands.     (line 147)
  10243 * b l:                                   Branch Commands.     (line  74)
  10244 * B m:                                   Bisecting.           (line  44)
  10245 * b n:                                   Branch Commands.     (line  57)
  10246 * B r:                                   Bisecting.           (line  57)
  10247 * b r:                                   Branch Commands.     (line 153)
  10248 * B s:                                   Bisecting.           (line  27)
  10249 * b s:                                   Branch Commands.     (line  97)
  10250 * b S:                                   Branch Commands.     (line 125)
  10251 * b x:                                   Branch Commands.     (line 131)
  10252 * c:                                     Blaming.             (line 135)
  10253 * C:                                     Cloning Repository.  (line  20)
  10254 * c <1>:                                 Initiating a Commit. (line   8)
  10255 * c <2>:                                 Editing Rebase Sequences.
  10256                                                               (line  72)
  10257 * c a:                                   Initiating a Commit. (line  19)
  10258 * c A:                                   Initiating a Commit. (line  67)
  10259 * C b:                                   Cloning Repository.  (line  41)
  10260 * C C:                                   Cloning Repository.  (line  29)
  10261 * c c:                                   Initiating a Commit. (line  14)
  10262 * C d:                                   Cloning Repository.  (line  54)
  10263 * C e:                                   Cloning Repository.  (line  61)
  10264 * c e:                                   Initiating a Commit. (line  23)
  10265 * c f:                                   Initiating a Commit. (line  43)
  10266 * c F:                                   Initiating a Commit. (line  51)
  10267 * C m:                                   Cloning Repository.  (line  46)
  10268 * C s:                                   Cloning Repository.  (line  34)
  10269 * c s:                                   Initiating a Commit. (line  55)
  10270 * c S:                                   Initiating a Commit. (line  63)
  10271 * c w:                                   Initiating a Commit. (line  33)
  10272 * C-<return>:                            Visiting Files and Blobs from a Diff.
  10273                                                               (line  51)
  10274 * C-<tab>:                               Section Visibility.  (line  13)
  10275 * C-c C-a:                               Commit Pseudo Headers.
  10276                                                               (line  17)
  10277 * C-c C-b:                               Log Buffer.          (line  21)
  10278 * C-c C-b <1>:                           Refreshing Diffs.    (line  91)
  10279 * C-c C-c:                               Transient Commands.  (line  18)
  10280 * C-c C-c <1>:                           Select from Log.     (line  20)
  10281 * C-c C-c <2>:                           Editing Commit Messages.
  10282                                                               (line  17)
  10283 * C-c C-c <3>:                           Editing Rebase Sequences.
  10284                                                               (line   6)
  10285 * C-c C-d:                               Refreshing Diffs.    (line  81)
  10286 * C-c C-d <1>:                           Editing Commit Messages.
  10287                                                               (line  58)
  10288 * C-c C-e:                               Commands Available in Diffs.
  10289                                                               (line  25)
  10290 * C-c C-f:                               Log Buffer.          (line  25)
  10291 * C-c C-f <1>:                           Refreshing Diffs.    (line  95)
  10292 * C-c C-i:                               Commit Pseudo Headers.
  10293                                                               (line  13)
  10294 * C-c C-k:                               Select from Log.     (line  26)
  10295 * C-c C-k <1>:                           Editing Commit Messages.
  10296                                                               (line  22)
  10297 * C-c C-k <2>:                           Editing Rebase Sequences.
  10298                                                               (line  11)
  10299 * C-c C-n:                               Log Buffer.          (line  29)
  10300 * C-c C-o:                               Commit Pseudo Headers.
  10301                                                               (line  33)
  10302 * C-c C-p:                               Commit Pseudo Headers.
  10303                                                               (line  37)
  10304 * C-c C-r:                               Commit Pseudo Headers.
  10305                                                               (line  21)
  10306 * C-c C-s:                               Commit Pseudo Headers.
  10307                                                               (line  25)
  10308 * C-c C-t:                               Commands Available in Diffs.
  10309                                                               (line  14)
  10310 * C-c C-t <1>:                           Commit Pseudo Headers.
  10311                                                               (line  29)
  10312 * C-c C-w:                               Using the Revision Stack.
  10313                                                               (line   6)
  10314 * C-c M-g:                               Commands for Buffers Visiting Files.
  10315                                                               (line  21)
  10316 * C-c M-g B:                             Blaming.             (line  18)
  10317 * C-c M-g b:                             Blaming.             (line  29)
  10318 * C-c M-g B <1>:                         Commands for Buffers Visiting Files.
  10319                                                               (line  93)
  10320 * C-c M-g B b:                           Blaming.             (line  30)
  10321 * C-c M-g B e:                           Blaming.             (line  64)
  10322 * C-c M-g B f:                           Blaming.             (line  55)
  10323 * C-c M-g B r:                           Blaming.             (line  46)
  10324 * C-c M-g c:                             Commands for Buffers Visiting Files.
  10325                                                               (line  38)
  10326 * C-c M-g D:                             Commands for Buffers Visiting Files.
  10327                                                               (line  45)
  10328 * C-c M-g d:                             Commands for Buffers Visiting Files.
  10329                                                               (line  56)
  10330 * C-c M-g e:                             Blaming.             (line  63)
  10331 * C-c M-g e <1>:                         Commands for Buffers Visiting Files.
  10332                                                               (line 106)
  10333 * C-c M-g f:                             Blaming.             (line  54)
  10334 * C-c M-g L:                             Commands for Buffers Visiting Files.
  10335                                                               (line  66)
  10336 * C-c M-g l:                             Commands for Buffers Visiting Files.
  10337                                                               (line  77)
  10338 * C-c M-g p:                             Commands for Buffers Visiting Files.
  10339                                                               (line 116)
  10340 * C-c M-g r:                             Blaming.             (line  45)
  10341 * C-c M-g s:                             Commands for Buffers Visiting Files.
  10342                                                               (line  29)
  10343 * C-c M-g t:                             Commands for Buffers Visiting Files.
  10344                                                               (line  84)
  10345 * C-c M-g u:                             Commands for Buffers Visiting Files.
  10346                                                               (line  33)
  10347 * C-c M-i:                               Commit Pseudo Headers.
  10348                                                               (line  42)
  10349 * C-c M-s:                               Editing Commit Messages.
  10350                                                               (line  34)
  10351 * C-w:                                   Common Commands.     (line  22)
  10352 * C-x g:                                 Status Buffer.       (line  22)
  10353 * C-x u:                                 Editing Rebase Sequences.
  10354                                                               (line  94)
  10355 * d:                                     Diffing.             (line  21)
  10356 * D:                                     Refreshing Diffs.    (line  11)
  10357 * d c:                                   Diffing.             (line  69)
  10358 * d d:                                   Diffing.             (line  27)
  10359 * D f:                                   Refreshing Diffs.    (line  46)
  10360 * D F:                                   Refreshing Diffs.    (line  51)
  10361 * D g:                                   Refreshing Diffs.    (line  17)
  10362 * d p:                                   Diffing.             (line  61)
  10363 * d r:                                   Diffing.             (line  31)
  10364 * D r:                                   Refreshing Diffs.    (line  41)
  10365 * d s:                                   Diffing.             (line  51)
  10366 * D s:                                   Refreshing Diffs.    (line  22)
  10367 * d t:                                   Diffing.             (line  74)
  10368 * D t:                                   Refreshing Diffs.    (line  37)
  10369 * d u:                                   Diffing.             (line  57)
  10370 * d w:                                   Diffing.             (line  45)
  10371 * D w:                                   Refreshing Diffs.    (line  29)
  10372 * DEL:                                   Log Buffer.          (line  56)
  10373 * DEL <1>:                               Commands Available in Diffs.
  10374                                                               (line  60)
  10375 * DEL <2>:                               Blaming.             (line  89)
  10376 * DEL <3>:                               Editing Rebase Sequences.
  10377                                                               (line  28)
  10378 * e:                                     Ediffing.            (line   9)
  10379 * E:                                     Ediffing.            (line  21)
  10380 * e <1>:                                 Editing Rebase Sequences.
  10381                                                               (line  55)
  10382 * E c:                                   Ediffing.            (line  65)
  10383 * E i:                                   Ediffing.            (line  57)
  10384 * E m:                                   Ediffing.            (line  35)
  10385 * E r:                                   Ediffing.            (line  26)
  10386 * E s:                                   Ediffing.            (line  48)
  10387 * E u:                                   Ediffing.            (line  53)
  10388 * E w:                                   Ediffing.            (line  61)
  10389 * E z:                                   Ediffing.            (line  69)
  10390 * f:                                     Editing Rebase Sequences.
  10391                                                               (line  63)
  10392 * f <1>:                                 Fetching.            (line   9)
  10393 * F:                                     Pulling.             (line   9)
  10394 * f a:                                   Fetching.            (line  50)
  10395 * f C:                                   Branch Commands.     (line  30)
  10396 * F C:                                   Branch Commands.     (line  31)
  10397 * f e:                                   Fetching.            (line  36)
  10398 * F e:                                   Pulling.             (line  30)
  10399 * f m:                                   Fetching.            (line  54)
  10400 * f o:                                   Fetching.            (line  40)
  10401 * f p:                                   Fetching.            (line  15)
  10402 * F p:                                   Pulling.             (line  14)
  10403 * f r:                                   Fetching.            (line  45)
  10404 * f u:                                   Fetching.            (line  23)
  10405 * F u:                                   Pulling.             (line  22)
  10406 * g:                                     Automatic Refreshing of Magit Buffers.
  10407                                                               (line  25)
  10408 * G:                                     Automatic Refreshing of Magit Buffers.
  10409                                                               (line  34)
  10410 * H:                                     Section Types and Values.
  10411                                                               (line  13)
  10412 * I:                                     Creating Repository. (line   6)
  10413 * j:                                     Log Buffer.          (line  35)
  10414 * j <1>:                                 Commands Available in Diffs.
  10415                                                               (line  45)
  10416 * k:                                     Viewing Git Output.  (line  24)
  10417 * k <1>:                                 Applying.            (line  40)
  10418 * k <2>:                                 Editing Rebase Sequences.
  10419                                                               (line  68)
  10420 * k <3>:                                 Stashing.            (line  96)
  10421 * l:                                     Logging.             (line  29)
  10422 * L:                                     Refreshing Logs.     (line  11)
  10423 * L <1>:                                 Log Buffer.          (line   6)
  10424 * L <2>:                                 Log Margin.          (line  57)
  10425 * l <1>:                                 Editing Rebase Sequences.
  10426                                                               (line 115)
  10427 * l a:                                   Logging.             (line  60)
  10428 * l b:                                   Logging.             (line  56)
  10429 * L d:                                   Log Margin.          (line  74)
  10430 * L g:                                   Refreshing Logs.     (line  17)
  10431 * l h:                                   Logging.             (line  48)
  10432 * l H:                                   Reflog.              (line  19)
  10433 * l l:                                   Logging.             (line  35)
  10434 * l L:                                   Logging.             (line  52)
  10435 * L L:                                   Log Margin.          (line  66)
  10436 * L l:                                   Log Margin.          (line  70)
  10437 * l o:                                   Logging.             (line  41)
  10438 * l O:                                   Reflog.              (line  15)
  10439 * l r:                                   Reflog.              (line  11)
  10440 * L s:                                   Refreshing Logs.     (line  22)
  10441 * L t:                                   Refreshing Logs.     (line  37)
  10442 * L w:                                   Refreshing Logs.     (line  29)
  10443 * m:                                     Merging.             (line   9)
  10444 * M:                                     Remote Commands.     (line  13)
  10445 * m a:                                   Merging.             (line  45)
  10446 * m a <1>:                               Merging.             (line  95)
  10447 * M a:                                   Remote Commands.     (line  50)
  10448 * M C:                                   Remote Commands.     (line  33)
  10449 * m e:                                   Merging.             (line  31)
  10450 * m i:                                   Merging.             (line  58)
  10451 * M k:                                   Remote Commands.     (line  65)
  10452 * m m:                                   Merging.             (line  18)
  10453 * m m <1>:                               Merging.             (line  89)
  10454 * m n:                                   Merging.             (line  38)
  10455 * m p:                                   Merging.             (line  81)
  10456 * M p:                                   Remote Commands.     (line  69)
  10457 * M P:                                   Remote Commands.     (line  74)
  10458 * M r:                                   Remote Commands.     (line  55)
  10459 * m s:                                   Merging.             (line  72)
  10460 * M u:                                   Remote Commands.     (line  60)
  10461 * M-1:                                   Section Visibility.  (line  33)
  10462 * M-2:                                   Section Visibility.  (line  34)
  10463 * M-3:                                   Section Visibility.  (line  35)
  10464 * M-4:                                   Section Visibility.  (line  36)
  10465 * M-<tab>:                               Section Visibility.  (line  17)
  10466 * M-n:                                   Section Movement.    (line  26)
  10467 * M-n <1>:                               Editing Commit Messages.
  10468                                                               (line  44)
  10469 * M-n <2>:                               Editing Rebase Sequences.
  10470                                                               (line  47)
  10471 * M-p:                                   Section Movement.    (line  20)
  10472 * M-p <1>:                               Editing Commit Messages.
  10473                                                               (line  38)
  10474 * M-p <2>:                               Editing Rebase Sequences.
  10475                                                               (line  43)
  10476 * M-w:                                   Blaming.             (line 127)
  10477 * M-w <1>:                               Common Commands.     (line  40)
  10478 * M-x magit-debug-git-executable:        Git Executable.      (line  56)
  10479 * M-x magit-debug-git-executable <1>:    Debugging Tools.     (line  36)
  10480 * M-x magit-describe-section-briefly:    Matching Sections.   (line   6)
  10481 * M-x magit-emacs-Q-command:             Debugging Tools.     (line  16)
  10482 * M-x magit-reset-index:                 Staging and Unstaging.
  10483                                                               (line  87)
  10484 * M-x magit-reverse-in-index:            Staging and Unstaging.
  10485                                                               (line  62)
  10486 * M-x magit-stage-file:                  Staging from File-Visiting Buffers.
  10487                                                               (line  10)
  10488 * M-x magit-toggle-buffer-lock:          Modes and Buffers.   (line  17)
  10489 * M-x magit-toggle-verbose-refresh:      Debugging Tools.     (line  30)
  10490 * M-x magit-unstage-file:                Staging from File-Visiting Buffers.
  10491                                                               (line  18)
  10492 * M-x magit-version:                     Git Executable.      (line  61)
  10493 * M-x magit-version <1>:                 Debugging Tools.     (line  10)
  10494 * M-x magit-wip-commit:                  Wip Modes.           (line  88)
  10495 * M-x with-editor-debug:                 Debugging Tools.     (line  44)
  10496 * MM:                                    Editing Rebase Sequences.
  10497                                                               (line 125)
  10498 * Mt:                                    Editing Rebase Sequences.
  10499                                                               (line 132)
  10500 * n:                                     Section Movement.    (line  16)
  10501 * n <1>:                                 Blaming.             (line 106)
  10502 * N:                                     Blaming.             (line 110)
  10503 * n <2>:                                 Editing Rebase Sequences.
  10504                                                               (line  39)
  10505 * n <3>:                                 Minor Mode for Buffers Visiting Blobs.
  10506                                                               (line  16)
  10507 * o:                                     Submodule Transient. (line   6)
  10508 * O:                                     Subtree.             (line   8)
  10509 * o a:                                   Submodule Transient. (line  20)
  10510 * o d:                                   Submodule Transient. (line  50)
  10511 * O e:                                   Subtree.             (line  42)
  10512 * O e p:                                 Subtree.             (line  54)
  10513 * O e s:                                 Subtree.             (line  59)
  10514 * o f:                                   Submodule Transient. (line  58)
  10515 * O i:                                   Subtree.             (line  13)
  10516 * O i a:                                 Subtree.             (line  25)
  10517 * O i c:                                 Subtree.             (line  30)
  10518 * O i f:                                 Subtree.             (line  38)
  10519 * O i m:                                 Subtree.             (line  34)
  10520 * o l:                                   Submodule Transient. (line  54)
  10521 * o p:                                   Submodule Transient. (line  34)
  10522 * o r:                                   Submodule Transient. (line  27)
  10523 * o s:                                   Submodule Transient. (line  44)
  10524 * o u:                                   Submodule Transient. (line  39)
  10525 * p:                                     Section Movement.    (line  10)
  10526 * p <1>:                                 Blaming.             (line 114)
  10527 * P:                                     Blaming.             (line 118)
  10528 * p <2>:                                 Editing Rebase Sequences.
  10529                                                               (line  35)
  10530 * P <1>:                                 Pushing.             (line   9)
  10531 * p <3>:                                 Minor Mode for Buffers Visiting Blobs.
  10532                                                               (line  12)
  10533 * P C:                                   Branch Commands.     (line  32)
  10534 * P e:                                   Pushing.             (line  31)
  10535 * P m:                                   Pushing.             (line  50)
  10536 * P o:                                   Pushing.             (line  36)
  10537 * P p:                                   Pushing.             (line  15)
  10538 * P r:                                   Pushing.             (line  41)
  10539 * P t:                                   Pushing.             (line  58)
  10540 * P T:                                   Pushing.             (line  66)
  10541 * P u:                                   Pushing.             (line  23)
  10542 * q:                                     Quitting Windows.    (line   6)
  10543 * q <1>:                                 Log Buffer.          (line  14)
  10544 * q <2>:                                 Blaming.             (line 122)
  10545 * q <3>:                                 Minor Mode for Buffers Visiting Blobs.
  10546                                                               (line  20)
  10547 * r:                                     Rebasing.            (line   9)
  10548 * r <1>:                                 Editing Rebase Sequences.
  10549                                                               (line  51)
  10550 * r a:                                   Rebasing.            (line 123)
  10551 * r e:                                   Rebasing.            (line  44)
  10552 * r e <1>:                               Rebasing.            (line 118)
  10553 * r f:                                   Rebasing.            (line  84)
  10554 * r i:                                   Rebasing.            (line  80)
  10555 * r k:                                   Rebasing.            (line  99)
  10556 * r m:                                   Rebasing.            (line  89)
  10557 * r p:                                   Rebasing.            (line  28)
  10558 * r r:                                   Rebasing.            (line 106)
  10559 * r s:                                   Rebasing.            (line  50)
  10560 * r s <1>:                               Rebasing.            (line 113)
  10561 * r u:                                   Rebasing.            (line  36)
  10562 * r w:                                   Rebasing.            (line  94)
  10563 * RET:                                   References Buffer.   (line 185)
  10564 * RET <1>:                               Visiting Files and Blobs from a Diff.
  10565                                                               (line   8)
  10566 * RET <2>:                               Blaming.             (line  75)
  10567 * RET <3>:                               Editing Rebase Sequences.
  10568                                                               (line  16)
  10569 * s:                                     Staging and Unstaging.
  10570                                                               (line  28)
  10571 * S:                                     Staging and Unstaging.
  10572                                                               (line  36)
  10573 * s <1>:                                 Editing Rebase Sequences.
  10574                                                               (line  59)
  10575 * S-<tab>:                               Section Visibility.  (line  22)
  10576 * SPC:                                   Log Buffer.          (line  46)
  10577 * SPC <1>:                               Commands Available in Diffs.
  10578                                                               (line  56)
  10579 * SPC <2>:                               Blaming.             (line  79)
  10580 * SPC <3>:                               Editing Rebase Sequences.
  10581                                                               (line  21)
  10582 * t:                                     Editing Rebase Sequences.
  10583                                                               (line 119)
  10584 * t <1>:                                 Tagging.             (line   8)
  10585 * T:                                     Notes.               (line   8)
  10586 * T a:                                   Notes.               (line  52)
  10587 * T c:                                   Notes.               (line  47)
  10588 * t k:                                   Tagging.             (line  39)
  10589 * T m:                                   Notes.               (line  38)
  10590 * t p:                                   Tagging.             (line  46)
  10591 * T p:                                   Notes.               (line  30)
  10592 * t r:                                   Tagging.             (line  19)
  10593 * T r:                                   Notes.               (line  22)
  10594 * t t:                                   Tagging.             (line  14)
  10595 * T T:                                   Notes.               (line  14)
  10596 * TAB:                                   Section Visibility.  (line   9)
  10597 * u:                                     Staging and Unstaging.
  10598                                                               (line  43)
  10599 * U:                                     Staging and Unstaging.
  10600                                                               (line  52)
  10601 * v:                                     Applying.            (line  48)
  10602 * V:                                     Reverting.           (line   6)
  10603 * V A:                                   Reverting.           (line  31)
  10604 * V a:                                   Reverting.           (line  39)
  10605 * V s:                                   Reverting.           (line  35)
  10606 * V V:                                   Reverting.           (line  15)
  10607 * V v:                                   Reverting.           (line  21)
  10608 * W:                                     Plain Patches.       (line   6)
  10609 * w:                                     Maildir Patches.     (line   8)
  10610 * w a:                                   Plain Patches.       (line  21)
  10611 * w a <1>:                               Maildir Patches.     (line  25)
  10612 * w a <2>:                               Maildir Patches.     (line  43)
  10613 * W c:                                   Plain Patches.       (line  12)
  10614 * w m:                                   Maildir Patches.     (line  21)
  10615 * W s:                                   Plain Patches.       (line  28)
  10616 * w s:                                   Maildir Patches.     (line  38)
  10617 * w w:                                   Maildir Patches.     (line  14)
  10618 * w w <1>:                               Maildir Patches.     (line  34)
  10619 * x:                                     Editing Rebase Sequences.
  10620                                                               (line  76)
  10621 * x <1>:                                 Resetting.           (line   8)
  10622 * X f:                                   Resetting.           (line  50)
  10623 * X h:                                   Resetting.           (line  26)
  10624 * X i:                                   Resetting.           (line  37)
  10625 * X k:                                   Resetting.           (line  31)
  10626 * X m:                                   Resetting.           (line  15)
  10627 * X s:                                   Resetting.           (line  20)
  10628 * X w:                                   Resetting.           (line  44)
  10629 * X w <1>:                               Wip Modes.           (line  66)
  10630 * Y:                                     Cherries.            (line  17)
  10631 * y:                                     References Buffer.   (line   6)
  10632 * y <1>:                                 Editing Rebase Sequences.
  10633                                                               (line  90)
  10634 * y c:                                   References Buffer.   (line  26)
  10635 * y o:                                   References Buffer.   (line  32)
  10636 * y r:                                   References Buffer.   (line  37)
  10637 * y y:                                   References Buffer.   (line  21)
  10638 * z:                                     Stashing.            (line   8)
  10639 * Z:                                     Worktree.            (line   8)
  10640 * z a:                                   Stashing.            (line  59)
  10641 * z b:                                   Stashing.            (line  81)
  10642 * z B:                                   Stashing.            (line  86)
  10643 * Z b:                                   Worktree.            (line  13)
  10644 * Z c:                                   Worktree.            (line  17)
  10645 * z f:                                   Stashing.            (line  92)
  10646 * Z g:                                   Worktree.            (line  30)
  10647 * z i:                                   Stashing.            (line  21)
  10648 * z I:                                   Stashing.            (line  47)
  10649 * z k:                                   Stashing.            (line  72)
  10650 * Z k:                                   Worktree.            (line  25)
  10651 * z l:                                   Stashing.            (line 100)
  10652 * Z m:                                   Worktree.            (line  21)
  10653 * z p:                                   Stashing.            (line  65)
  10654 * z v:                                   Stashing.            (line  77)
  10655 * z w:                                   Stashing.            (line  26)
  10656 * z W:                                   Stashing.            (line  52)
  10657 * z x:                                   Stashing.            (line  33)
  10658 * z z:                                   Stashing.            (line  14)
  10659 * z Z:                                   Stashing.            (line  40)
  10660 
  10661 
  10662 File: magit.info,  Node: Command Index,  Next: Function Index,  Prev: Keystroke Index,  Up: Top
  10663 
  10664 Appendix D Command Index
  10665 ************************
  10666 
  10667 
  10668 * Menu:
  10669 
  10670 * forward-line:                          Editing Rebase Sequences.
  10671                                                               (line  39)
  10672 * git-commit-ack:                        Commit Pseudo Headers.
  10673                                                               (line  17)
  10674 * git-commit-cc:                         Commit Pseudo Headers.
  10675                                                               (line  33)
  10676 * git-commit-insert-pseudo-header:       Commit Pseudo Headers.
  10677                                                               (line  13)
  10678 * git-commit-next-message:               Editing Commit Messages.
  10679                                                               (line  44)
  10680 * git-commit-prev-message:               Editing Commit Messages.
  10681                                                               (line  38)
  10682 * git-commit-reported:                   Commit Pseudo Headers.
  10683                                                               (line  37)
  10684 * git-commit-review:                     Commit Pseudo Headers.
  10685                                                               (line  21)
  10686 * git-commit-save-message:               Editing Commit Messages.
  10687                                                               (line  34)
  10688 * git-commit-signoff:                    Commit Pseudo Headers.
  10689                                                               (line  25)
  10690 * git-commit-suggested:                  Commit Pseudo Headers.
  10691                                                               (line  42)
  10692 * git-commit-test:                       Commit Pseudo Headers.
  10693                                                               (line  29)
  10694 * git-rebase-backward-line:              Editing Rebase Sequences.
  10695                                                               (line  35)
  10696 * git-rebase-break:                      Editing Rebase Sequences.
  10697                                                               (line  85)
  10698 * git-rebase-edit:                       Editing Rebase Sequences.
  10699                                                               (line  55)
  10700 * git-rebase-exec:                       Editing Rebase Sequences.
  10701                                                               (line  76)
  10702 * git-rebase-fixup:                      Editing Rebase Sequences.
  10703                                                               (line  63)
  10704 * git-rebase-insert:                     Editing Rebase Sequences.
  10705                                                               (line  90)
  10706 * git-rebase-kill-line:                  Editing Rebase Sequences.
  10707                                                               (line  68)
  10708 * git-rebase-label:                      Editing Rebase Sequences.
  10709                                                               (line 115)
  10710 * git-rebase-merge:                      Editing Rebase Sequences.
  10711                                                               (line 125)
  10712 * git-rebase-merge-toggle-editmsg:       Editing Rebase Sequences.
  10713                                                               (line 132)
  10714 * git-rebase-move-line-down:             Editing Rebase Sequences.
  10715                                                               (line  47)
  10716 * git-rebase-move-line-up:               Editing Rebase Sequences.
  10717                                                               (line  43)
  10718 * git-rebase-pick:                       Editing Rebase Sequences.
  10719                                                               (line  72)
  10720 * git-rebase-reset:                      Editing Rebase Sequences.
  10721                                                               (line 119)
  10722 * git-rebase-reword:                     Editing Rebase Sequences.
  10723                                                               (line  51)
  10724 * git-rebase-show-commit:                Editing Rebase Sequences.
  10725                                                               (line  16)
  10726 * git-rebase-show-or-scroll-down:        Editing Rebase Sequences.
  10727                                                               (line  28)
  10728 * git-rebase-show-or-scroll-up:          Editing Rebase Sequences.
  10729                                                               (line  21)
  10730 * git-rebase-squash:                     Editing Rebase Sequences.
  10731                                                               (line  59)
  10732 * git-rebase-undo:                       Editing Rebase Sequences.
  10733                                                               (line  94)
  10734 * ido-enter-magit-status:                Status Buffer.       (line  99)
  10735 * magit-am:                              Maildir Patches.     (line   8)
  10736 * magit-am-abort:                        Maildir Patches.     (line  43)
  10737 * magit-am-apply-maildir:                Maildir Patches.     (line  21)
  10738 * magit-am-apply-patches:                Maildir Patches.     (line  14)
  10739 * magit-am-continue:                     Maildir Patches.     (line  34)
  10740 * magit-am-skip:                         Maildir Patches.     (line  38)
  10741 * magit-apply:                           Applying.            (line  33)
  10742 * magit-bisect:                          Bisecting.           (line   8)
  10743 * magit-bisect-bad:                      Bisecting.           (line  34)
  10744 * magit-bisect-good:                     Bisecting.           (line  39)
  10745 * magit-bisect-mark:                     Bisecting.           (line  44)
  10746 * magit-bisect-reset:                    Bisecting.           (line  57)
  10747 * magit-bisect-run:                      Bisecting.           (line  27)
  10748 * magit-bisect-skip:                     Bisecting.           (line  51)
  10749 * magit-bisect-start:                    Bisecting.           (line  16)
  10750 * magit-blame:                           Blaming.             (line  18)
  10751 * magit-blame <1>:                       Blaming.             (line 102)
  10752 * magit-blame <2>:                       Commands for Buffers Visiting Files.
  10753                                                               (line  93)
  10754 * magit-blame-addition:                  Blaming.             (line  29)
  10755 * magit-blame-addition <1>:              Blaming.             (line  30)
  10756 * magit-blame-copy-hash:                 Blaming.             (line 127)
  10757 * magit-blame-cycle-style:               Blaming.             (line 135)
  10758 * magit-blame-echo:                      Blaming.             (line  63)
  10759 * magit-blame-echo <1>:                  Blaming.             (line  64)
  10760 * magit-blame-next-chunk:                Blaming.             (line 106)
  10761 * magit-blame-next-chunk-same-commit:    Blaming.             (line 110)
  10762 * magit-blame-previous-chunk:            Blaming.             (line 114)
  10763 * magit-blame-previous-chunk-same-commit: Blaming.            (line 118)
  10764 * magit-blame-quit:                      Blaming.             (line 122)
  10765 * magit-blame-removal:                   Blaming.             (line  45)
  10766 * magit-blame-removal <1>:               Blaming.             (line  46)
  10767 * magit-blame-reverse:                   Blaming.             (line  54)
  10768 * magit-blame-reverse <1>:               Blaming.             (line  55)
  10769 * magit-blob-next:                       Minor Mode for Buffers Visiting Blobs.
  10770                                                               (line  16)
  10771 * magit-blob-previous:                   Commands for Buffers Visiting Files.
  10772                                                               (line 116)
  10773 * magit-blob-previous <1>:               Minor Mode for Buffers Visiting Blobs.
  10774                                                               (line  12)
  10775 * magit-branch:                          Branch Commands.     (line  12)
  10776 * magit-branch-and-checkout:             Branch Commands.     (line  67)
  10777 * magit-branch-checkout:                 Branch Commands.     (line  74)
  10778 * magit-branch-configure:                Branch Commands.     (line  29)
  10779 * magit-branch-configure <1>:            Branch Commands.     (line  30)
  10780 * magit-branch-configure <2>:            Branch Commands.     (line  31)
  10781 * magit-branch-configure <3>:            Branch Commands.     (line  32)
  10782 * magit-branch-create:                   Branch Commands.     (line  57)
  10783 * magit-branch-delete:                   Branch Commands.     (line 147)
  10784 * magit-branch-or-checkout:              Branch Commands.     (line 267)
  10785 * magit-branch-orphan:                   Branch Commands.     (line 262)
  10786 * magit-branch-rename:                   Branch Commands.     (line 153)
  10787 * magit-branch-reset:                    Branch Commands.     (line 131)
  10788 * magit-branch-shelve:                   Auxiliary Branch Commands.
  10789                                                               (line   9)
  10790 * magit-branch-spinoff:                  Branch Commands.     (line  97)
  10791 * magit-branch-spinout:                  Branch Commands.     (line 125)
  10792 * magit-branch-unshelve:                 Auxiliary Branch Commands.
  10793                                                               (line  20)
  10794 * magit-bundle:                          Bundle.              (line   8)
  10795 * magit-checkout:                        Branch Commands.     (line  49)
  10796 * magit-cherry:                          Cherries.            (line  17)
  10797 * magit-cherry-apply:                    Cherry Picking.      (line  24)
  10798 * magit-cherry-copy:                     Cherry Picking.      (line  17)
  10799 * magit-cherry-donate:                   Cherry Picking.      (line  54)
  10800 * magit-cherry-harvest:                  Cherry Picking.      (line  42)
  10801 * magit-cherry-pick:                     Cherry Picking.      (line   8)
  10802 * magit-cherry-spinoff:                  Cherry Picking.      (line  76)
  10803 * magit-cherry-spinout:                  Cherry Picking.      (line  65)
  10804 * magit-clone:                           Cloning Repository.  (line  20)
  10805 * magit-clone-bare:                      Cloning Repository.  (line  41)
  10806 * magit-clone-mirror:                    Cloning Repository.  (line  46)
  10807 * magit-clone-regular:                   Cloning Repository.  (line  29)
  10808 * magit-clone-shallow:                   Cloning Repository.  (line  34)
  10809 * magit-clone-shallow-exclude:           Cloning Repository.  (line  61)
  10810 * magit-clone-shallow-since:             Cloning Repository.  (line  54)
  10811 * magit-commit:                          Initiating a Commit. (line   8)
  10812 * magit-commit <1>:                      Commands for Buffers Visiting Files.
  10813                                                               (line  38)
  10814 * magit-commit-amend:                    Initiating a Commit. (line  19)
  10815 * magit-commit-augment:                  Initiating a Commit. (line  67)
  10816 * magit-commit-create:                   Initiating a Commit. (line  14)
  10817 * magit-commit-extend:                   Initiating a Commit. (line  23)
  10818 * magit-commit-fixup:                    Initiating a Commit. (line  43)
  10819 * magit-commit-instant-fixup:            Initiating a Commit. (line  51)
  10820 * magit-commit-instant-squash:           Initiating a Commit. (line  63)
  10821 * magit-commit-reword:                   Initiating a Commit. (line  33)
  10822 * magit-commit-squash:                   Initiating a Commit. (line  55)
  10823 * magit-copy-buffer-revision:            Common Commands.     (line  40)
  10824 * magit-copy-section-value:              Common Commands.     (line  22)
  10825 * magit-cycle-margin-style:              Log Margin.          (line  70)
  10826 * magit-debug-git-executable:            Git Executable.      (line  56)
  10827 * magit-debug-git-executable <1>:        Debugging Tools.     (line  36)
  10828 * magit-describe-section:                Section Types and Values.
  10829                                                               (line  13)
  10830 * magit-describe-section-briefly:        Section Types and Values.
  10831                                                               (line  18)
  10832 * magit-describe-section-briefly <1>:    Matching Sections.   (line   6)
  10833 * magit-diff:                            Diffing.             (line  21)
  10834 * magit-diff <1>:                        Commands for Buffers Visiting Files.
  10835                                                               (line  45)
  10836 * magit-diff-buffer-file:                Commands for Buffers Visiting Files.
  10837                                                               (line  56)
  10838 * magit-diff-default-context:            Refreshing Diffs.    (line  73)
  10839 * magit-diff-dwim:                       Diffing.             (line  27)
  10840 * magit-diff-edit-hunk-commit:           Commands Available in Diffs.
  10841                                                               (line  25)
  10842 * magit-diff-flip-revs:                  Refreshing Diffs.    (line  46)
  10843 * magit-diff-less-context:               Refreshing Diffs.    (line  65)
  10844 * magit-diff-more-context:               Refreshing Diffs.    (line  69)
  10845 * magit-diff-paths:                      Diffing.             (line  61)
  10846 * magit-diff-range:                      Diffing.             (line  31)
  10847 * magit-diff-refresh:                    Refreshing Diffs.    (line  11)
  10848 * magit-diff-refresh <1>:                Refreshing Diffs.    (line  17)
  10849 * magit-diff-save-default-arguments:     Refreshing Diffs.    (line  29)
  10850 * magit-diff-set-default-arguments:      Refreshing Diffs.    (line  22)
  10851 * magit-diff-show-or-scroll-down:        Log Buffer.          (line  56)
  10852 * magit-diff-show-or-scroll-down <1>:    Blaming.             (line  89)
  10853 * magit-diff-show-or-scroll-up:          Log Buffer.          (line  46)
  10854 * magit-diff-show-or-scroll-up <1>:      Blaming.             (line  79)
  10855 * magit-diff-staged:                     Diffing.             (line  51)
  10856 * magit-diff-switch-range-type:          Refreshing Diffs.    (line  41)
  10857 * magit-diff-toggle-file-filter:         Refreshing Diffs.    (line  51)
  10858 * magit-diff-toggle-refine-hunk:         Refreshing Diffs.    (line  37)
  10859 * magit-diff-trace-definition:           Commands Available in Diffs.
  10860                                                               (line  14)
  10861 * magit-diff-unstaged:                   Diffing.             (line  57)
  10862 * magit-diff-visit-file:                 Visiting Files and Blobs from a Diff.
  10863                                                               (line   8)
  10864 * magit-diff-visit-file-other-frame:     Visiting Files and Blobs from a Diff.
  10865                                                               (line  74)
  10866 * magit-diff-visit-file-other-window:    Visiting Files and Blobs from a Diff.
  10867                                                               (line  73)
  10868 * magit-diff-visit-file-worktree:        Visiting Files and Blobs from a Diff.
  10869                                                               (line  51)
  10870 * magit-diff-visit-worktree-file-other-frame: Visiting Files and Blobs from a Diff.
  10871                                                               (line  76)
  10872 * magit-diff-visit-worktree-file-other-window: Visiting Files and Blobs from a Diff.
  10873                                                               (line  75)
  10874 * magit-diff-while-committing:           Refreshing Diffs.    (line  81)
  10875 * magit-diff-while-committing <1>:       Editing Commit Messages.
  10876                                                               (line  58)
  10877 * magit-diff-working-tree:               Diffing.             (line  45)
  10878 * magit-discard:                         Applying.            (line  40)
  10879 * magit-dispatch:                        Transient Commands.  (line  18)
  10880 * magit-display-repository-buffer:       Common Commands.     (line   9)
  10881 * magit-ediff:                           Ediffing.            (line  21)
  10882 * magit-ediff-compare:                   Ediffing.            (line  26)
  10883 * magit-ediff-dwim:                      Ediffing.            (line   9)
  10884 * magit-ediff-resolve:                   Ediffing.            (line  35)
  10885 * magit-ediff-show-commit:               Ediffing.            (line  65)
  10886 * magit-ediff-show-staged:               Ediffing.            (line  57)
  10887 * magit-ediff-show-stash:                Ediffing.            (line  69)
  10888 * magit-ediff-show-unstaged:             Ediffing.            (line  53)
  10889 * magit-ediff-show-working-tree:         Ediffing.            (line  61)
  10890 * magit-ediff-stage:                     Ediffing.            (line  48)
  10891 * magit-edit-line-commit:                Commands for Buffers Visiting Files.
  10892                                                               (line 106)
  10893 * magit-emacs-Q-command:                 Debugging Tools.     (line  16)
  10894 * magit-fetch:                           Fetching.            (line   9)
  10895 * magit-fetch-all:                       Fetching.            (line  50)
  10896 * magit-fetch-branch:                    Fetching.            (line  40)
  10897 * magit-fetch-from-pushremote:           Fetching.            (line  15)
  10898 * magit-fetch-from-upstream:             Fetching.            (line  23)
  10899 * magit-fetch-modules:                   Submodule Transient. (line  58)
  10900 * magit-fetch-other:                     Fetching.            (line  36)
  10901 * magit-fetch-refspec:                   Fetching.            (line  45)
  10902 * magit-file-checkout:                   Resetting.           (line  50)
  10903 * magit-file-checkout <1>:               Commands for Buffers Visiting Files.
  10904                                                               (line 135)
  10905 * magit-file-delete:                     Commands for Buffers Visiting Files.
  10906                                                               (line 127)
  10907 * magit-file-dispatch:                   Commands for Buffers Visiting Files.
  10908                                                               (line  21)
  10909 * magit-file-rename:                     Commands for Buffers Visiting Files.
  10910                                                               (line 123)
  10911 * magit-file-untrack:                    Commands for Buffers Visiting Files.
  10912                                                               (line 131)
  10913 * magit-find-file:                       General-Purpose Visit Commands.
  10914                                                               (line   9)
  10915 * magit-find-file-other-frame:           General-Purpose Visit Commands.
  10916                                                               (line  21)
  10917 * magit-find-file-other-window:          General-Purpose Visit Commands.
  10918                                                               (line  15)
  10919 * magit-git-command:                     Running Git Manually.
  10920                                                               (line  25)
  10921 * magit-git-command <1>:                 Running Git Manually.
  10922                                                               (line  26)
  10923 * magit-git-command-topdir:              Running Git Manually.
  10924                                                               (line  17)
  10925 * magit-go-backward:                     Log Buffer.          (line  21)
  10926 * magit-go-backward <1>:                 Refreshing Diffs.    (line  91)
  10927 * magit-go-forward:                      Log Buffer.          (line  25)
  10928 * magit-go-forward <1>:                  Refreshing Diffs.    (line  95)
  10929 * magit-init:                            Creating Repository. (line   6)
  10930 * magit-jump-to-diffstat-or-diff:        Commands Available in Diffs.
  10931                                                               (line  45)
  10932 * magit-kill-this-buffer:                Minor Mode for Buffers Visiting Blobs.
  10933                                                               (line  20)
  10934 * magit-list-repositories:               Repository List.     (line   6)
  10935 * magit-list-submodules:                 Listing Submodules.  (line  13)
  10936 * magit-list-submodules <1>:             Submodule Transient. (line  54)
  10937 * magit-log:                             Logging.             (line  29)
  10938 * magit-log <1>:                         Commands for Buffers Visiting Files.
  10939                                                               (line  66)
  10940 * magit-log-all:                         Logging.             (line  60)
  10941 * magit-log-all-branches:                Logging.             (line  56)
  10942 * magit-log-branches:                    Logging.             (line  52)
  10943 * magit-log-buffer-file:                 Commands for Buffers Visiting Files.
  10944                                                               (line  77)
  10945 * magit-log-bury-buffer:                 Log Buffer.          (line  14)
  10946 * magit-log-current:                     Logging.             (line  35)
  10947 * magit-log-double-commit-limit:         Log Buffer.          (line  72)
  10948 * magit-log-half-commit-limit:           Log Buffer.          (line  76)
  10949 * magit-log-head:                        Logging.             (line  48)
  10950 * magit-log-move-to-parent:              Log Buffer.          (line  29)
  10951 * magit-log-move-to-revision:            Log Buffer.          (line  35)
  10952 * magit-log-other:                       Logging.             (line  41)
  10953 * magit-log-refresh:                     Refreshing Logs.     (line  11)
  10954 * magit-log-refresh <1>:                 Refreshing Logs.     (line  17)
  10955 * magit-log-refresh <2>:                 Log Buffer.          (line   6)
  10956 * magit-log-save-default-arguments:      Refreshing Logs.     (line  29)
  10957 * magit-log-select-pick:                 Select from Log.     (line  20)
  10958 * magit-log-select-quit:                 Select from Log.     (line  26)
  10959 * magit-log-set-default-arguments:       Refreshing Logs.     (line  22)
  10960 * magit-log-toggle-commit-limit:         Log Buffer.          (line  66)
  10961 * magit-log-trace-definition:            Commands for Buffers Visiting Files.
  10962                                                               (line  84)
  10963 * magit-margin-settings:                 Log Margin.          (line  57)
  10964 * magit-merge:                           Merging.             (line   9)
  10965 * magit-merge <1>:                       Merging.             (line  89)
  10966 * magit-merge-abort:                     Merging.             (line  95)
  10967 * magit-merge-absorb:                    Merging.             (line  45)
  10968 * magit-merge-editmsg:                   Merging.             (line  31)
  10969 * magit-merge-into:                      Merging.             (line  58)
  10970 * magit-merge-nocommit:                  Merging.             (line  38)
  10971 * magit-merge-plain:                     Merging.             (line  18)
  10972 * magit-merge-preview:                   Merging.             (line  81)
  10973 * magit-merge-squash:                    Merging.             (line  72)
  10974 * magit-mode-bury-buffer:                Quitting Windows.    (line   6)
  10975 * magit-notes:                           Notes.               (line   8)
  10976 * magit-notes-edit:                      Notes.               (line  14)
  10977 * magit-notes-merge:                     Notes.               (line  38)
  10978 * magit-notes-merge-abort:               Notes.               (line  52)
  10979 * magit-notes-merge-commit:              Notes.               (line  47)
  10980 * magit-notes-prune:                     Notes.               (line  30)
  10981 * magit-notes-remove:                    Notes.               (line  22)
  10982 * magit-patch:                           Plain Patches.       (line   6)
  10983 * magit-patch-apply:                     Plain Patches.       (line  21)
  10984 * magit-patch-apply <1>:                 Maildir Patches.     (line  25)
  10985 * magit-patch-create:                    Plain Patches.       (line  12)
  10986 * magit-patch-save:                      Plain Patches.       (line  28)
  10987 * magit-pop-revision-stack:              Using the Revision Stack.
  10988                                                               (line   6)
  10989 * magit-process:                         Viewing Git Output.  (line  16)
  10990 * magit-process-kill:                    Viewing Git Output.  (line  24)
  10991 * magit-pull:                            Pulling.             (line   9)
  10992 * magit-pull-branch:                     Pulling.             (line  30)
  10993 * magit-pull-from-pushremote:            Pulling.             (line  14)
  10994 * magit-pull-from-upstream:              Pulling.             (line  22)
  10995 * magit-push:                            Pushing.             (line   9)
  10996 * magit-push-current:                    Pushing.             (line  31)
  10997 * magit-push-current-to-pushremote:      Pushing.             (line  15)
  10998 * magit-push-current-to-upstream:        Pushing.             (line  23)
  10999 * magit-push-implicitly args:            Pushing.             (line  83)
  11000 * magit-push-matching:                   Pushing.             (line  50)
  11001 * magit-push-other:                      Pushing.             (line  36)
  11002 * magit-push-refspecs:                   Pushing.             (line  41)
  11003 * magit-push-tag:                        Pushing.             (line  66)
  11004 * magit-push-tags:                       Pushing.             (line  58)
  11005 * magit-push-to-remote remote args:      Pushing.             (line 101)
  11006 * magit-rebase:                          Rebasing.            (line   9)
  11007 * magit-rebase-abort:                    Rebasing.            (line 123)
  11008 * magit-rebase-autosquash:               Rebasing.            (line  84)
  11009 * magit-rebase-branch:                   Rebasing.            (line  44)
  11010 * magit-rebase-continue:                 Rebasing.            (line 106)
  11011 * magit-rebase-edit:                     Rebasing.            (line 118)
  11012 * magit-rebase-edit-commit:              Rebasing.            (line  89)
  11013 * magit-rebase-interactive:              Rebasing.            (line  80)
  11014 * magit-rebase-onto-pushremote:          Rebasing.            (line  28)
  11015 * magit-rebase-onto-upstream:            Rebasing.            (line  36)
  11016 * magit-rebase-remove-commit:            Rebasing.            (line  99)
  11017 * magit-rebase-reword-commit:            Rebasing.            (line  94)
  11018 * magit-rebase-skip:                     Rebasing.            (line 113)
  11019 * magit-rebase-subset:                   Rebasing.            (line  50)
  11020 * magit-reflog-current:                  Reflog.              (line  11)
  11021 * magit-reflog-head:                     Reflog.              (line  19)
  11022 * magit-reflog-other:                    Reflog.              (line  15)
  11023 * magit-refresh:                         Automatic Refreshing of Magit Buffers.
  11024                                                               (line  25)
  11025 * magit-refresh-all:                     Automatic Refreshing of Magit Buffers.
  11026                                                               (line  34)
  11027 * magit-refs-set-show-commit-count:      References Buffer.   (line  37)
  11028 * magit-remote:                          Remote Commands.     (line  13)
  11029 * magit-remote-add:                      Remote Commands.     (line  50)
  11030 * magit-remote-configure:                Remote Commands.     (line  33)
  11031 * magit-remote-prune:                    Remote Commands.     (line  69)
  11032 * magit-remote-prune-refspecs:           Remote Commands.     (line  74)
  11033 * magit-remote-remove:                   Remote Commands.     (line  65)
  11034 * magit-remote-rename:                   Remote Commands.     (line  55)
  11035 * magit-remote-set-url:                  Remote Commands.     (line  60)
  11036 * magit-reset-hard:                      Resetting.           (line  26)
  11037 * magit-reset-index:                     Staging and Unstaging.
  11038                                                               (line  87)
  11039 * magit-reset-index <1>:                 Resetting.           (line  37)
  11040 * magit-reset-keep:                      Resetting.           (line  31)
  11041 * magit-reset-mixed:                     Resetting.           (line  15)
  11042 * magit-reset-quickly:                   Resetting.           (line   8)
  11043 * magit-reset-soft:                      Resetting.           (line  20)
  11044 * magit-reset-worktree:                  Resetting.           (line  44)
  11045 * magit-reset-worktree <1>:              Wip Modes.           (line  66)
  11046 * magit-reverse:                         Applying.            (line  48)
  11047 * magit-reverse-in-index:                Staging and Unstaging.
  11048                                                               (line  62)
  11049 * magit-revert:                          Reverting.           (line   6)
  11050 * magit-revert-and-commit:               Reverting.           (line  15)
  11051 * magit-revert-no-commit:                Reverting.           (line  21)
  11052 * magit-run:                             Running Git Manually.
  11053                                                               (line  12)
  11054 * magit-run-git-gui:                     Running Git Manually.
  11055                                                               (line  67)
  11056 * magit-run-gitk:                        Running Git Manually.
  11057                                                               (line  55)
  11058 * magit-run-gitk-all:                    Running Git Manually.
  11059                                                               (line  59)
  11060 * magit-run-gitk-branches:               Running Git Manually.
  11061                                                               (line  63)
  11062 * magit-section-backward:                Section Movement.    (line  10)
  11063 * magit-section-backward-siblings:       Section Movement.    (line  20)
  11064 * magit-section-cycle:                   Section Visibility.  (line  13)
  11065 * magit-section-cycle-diffs:             Section Visibility.  (line  17)
  11066 * magit-section-cycle-global:            Section Visibility.  (line  22)
  11067 * magit-section-forward:                 Section Movement.    (line  16)
  11068 * magit-section-forward-siblings:        Section Movement.    (line  26)
  11069 * magit-section-hide:                    Section Visibility.  (line  49)
  11070 * magit-section-hide-children:           Section Visibility.  (line  64)
  11071 * magit-section-show:                    Section Visibility.  (line  45)
  11072 * magit-section-show-children:           Section Visibility.  (line  58)
  11073 * magit-section-show-headings:           Section Visibility.  (line  53)
  11074 * magit-section-show-level-1:            Section Visibility.  (line  26)
  11075 * magit-section-show-level-1-all:        Section Visibility.  (line  33)
  11076 * magit-section-show-level-2:            Section Visibility.  (line  27)
  11077 * magit-section-show-level-2-all:        Section Visibility.  (line  34)
  11078 * magit-section-show-level-3:            Section Visibility.  (line  28)
  11079 * magit-section-show-level-3-all:        Section Visibility.  (line  35)
  11080 * magit-section-show-level-4:            Section Visibility.  (line  29)
  11081 * magit-section-show-level-4-all:        Section Visibility.  (line  36)
  11082 * magit-section-toggle:                  Section Visibility.  (line   9)
  11083 * magit-section-toggle-children:         Section Visibility.  (line  68)
  11084 * magit-section-up:                      Section Movement.    (line  31)
  11085 * magit-sequence-abort:                  Cherry Picking.      (line  98)
  11086 * magit-sequence-abort <1>:              Reverting.           (line  39)
  11087 * magit-sequence-continue:               Cherry Picking.      (line  90)
  11088 * magit-sequence-continue <1>:           Reverting.           (line  31)
  11089 * magit-sequence-skip:                   Cherry Picking.      (line  94)
  11090 * magit-sequence-skip <1>:               Reverting.           (line  35)
  11091 * magit-shell-command:                   Running Git Manually.
  11092                                                               (line  41)
  11093 * magit-shell-command-topdir:            Running Git Manually.
  11094                                                               (line  36)
  11095 * magit-show-commit:                     Diffing.             (line  69)
  11096 * magit-show-commit <1>:                 Blaming.             (line  75)
  11097 * magit-show-refs:                       References Buffer.   (line   6)
  11098 * magit-show-refs-current:               References Buffer.   (line  26)
  11099 * magit-show-refs-head:                  References Buffer.   (line  21)
  11100 * magit-show-refs-other:                 References Buffer.   (line  32)
  11101 * magit-snapshot-both:                   Stashing.            (line  40)
  11102 * magit-snapshot-index:                  Stashing.            (line  47)
  11103 * magit-snapshot-worktree:               Stashing.            (line  52)
  11104 * magit-stage:                           Staging and Unstaging.
  11105                                                               (line  28)
  11106 * magit-stage-file:                      Staging from File-Visiting Buffers.
  11107                                                               (line  10)
  11108 * magit-stage-file <1>:                  Commands for Buffers Visiting Files.
  11109                                                               (line  29)
  11110 * magit-stage-modified:                  Staging and Unstaging.
  11111                                                               (line  36)
  11112 * magit-stash:                           Stashing.            (line   8)
  11113 * magit-stash-apply:                     Stashing.            (line  59)
  11114 * magit-stash-both:                      Stashing.            (line  14)
  11115 * magit-stash-branch:                    Stashing.            (line  81)
  11116 * magit-stash-branch-here:               Stashing.            (line  86)
  11117 * magit-stash-clear:                     Stashing.            (line  96)
  11118 * magit-stash-drop:                      Stashing.            (line  72)
  11119 * magit-stash-format-patch:              Stashing.            (line  92)
  11120 * magit-stash-index:                     Stashing.            (line  21)
  11121 * magit-stash-keep-index:                Stashing.            (line  33)
  11122 * magit-stash-list:                      Stashing.            (line 100)
  11123 * magit-stash-pop:                       Stashing.            (line  65)
  11124 * magit-stash-show:                      Diffing.             (line  74)
  11125 * magit-stash-show <1>:                  Stashing.            (line  77)
  11126 * magit-stash-worktree:                  Stashing.            (line  26)
  11127 * magit-status:                          Status Buffer.       (line  22)
  11128 * magit-status-quick:                    Status Buffer.       (line  72)
  11129 * magit-submodule:                       Submodule Transient. (line   6)
  11130 * magit-submodule-add:                   Submodule Transient. (line  20)
  11131 * magit-submodule-fetch:                 Fetching.            (line  54)
  11132 * magit-submodule-populate:              Submodule Transient. (line  34)
  11133 * magit-submodule-register:              Submodule Transient. (line  27)
  11134 * magit-submodule-synchronize:           Submodule Transient. (line  44)
  11135 * magit-submodule-unpopulate:            Submodule Transient. (line  50)
  11136 * magit-submodule-update:                Submodule Transient. (line  39)
  11137 * magit-subtree:                         Subtree.             (line   8)
  11138 * magit-subtree-add:                     Subtree.             (line  25)
  11139 * magit-subtree-add-commit:              Subtree.             (line  30)
  11140 * magit-subtree-export:                  Subtree.             (line  42)
  11141 * magit-subtree-import:                  Subtree.             (line  13)
  11142 * magit-subtree-merge:                   Subtree.             (line  34)
  11143 * magit-subtree-pull:                    Subtree.             (line  38)
  11144 * magit-subtree-push:                    Subtree.             (line  54)
  11145 * magit-subtree-split:                   Subtree.             (line  59)
  11146 * magit-switch-to-repository-buffer:     Common Commands.     (line   6)
  11147 * magit-switch-to-repository-buffer-other-frame: Common Commands.
  11148                                                               (line   8)
  11149 * magit-switch-to-repository-buffer-other-window: Common Commands.
  11150                                                               (line   7)
  11151 * magit-tag:                             Tagging.             (line   8)
  11152 * magit-tag-create:                      Tagging.             (line  14)
  11153 * magit-tag-delete:                      Tagging.             (line  39)
  11154 * magit-tag-prune:                       Tagging.             (line  46)
  11155 * magit-tag-release:                     Tagging.             (line  19)
  11156 * magit-toggle-buffer-lock:              Modes and Buffers.   (line  17)
  11157 * magit-toggle-margin:                   Refreshing Logs.     (line  37)
  11158 * magit-toggle-margin <1>:               Log Margin.          (line  66)
  11159 * magit-toggle-margin-details:           Log Margin.          (line  74)
  11160 * magit-toggle-verbose-refresh:          Debugging Tools.     (line  30)
  11161 * magit-unstage:                         Staging and Unstaging.
  11162                                                               (line  43)
  11163 * magit-unstage-all:                     Staging and Unstaging.
  11164                                                               (line  52)
  11165 * magit-unstage-file:                    Staging from File-Visiting Buffers.
  11166                                                               (line  18)
  11167 * magit-unstage-file <1>:                Commands for Buffers Visiting Files.
  11168                                                               (line  33)
  11169 * magit-version:                         Git Executable.      (line  61)
  11170 * magit-version <1>:                     Debugging Tools.     (line  10)
  11171 * magit-visit-ref:                       References Buffer.   (line 185)
  11172 * magit-wip-commit:                      Wip Modes.           (line  88)
  11173 * magit-wip-log:                         Wip Modes.           (line  48)
  11174 * magit-wip-log-current:                 Wip Modes.           (line  57)
  11175 * magit-worktree:                        Worktree.            (line   8)
  11176 * magit-worktree-branch:                 Worktree.            (line  17)
  11177 * magit-worktree-checkout:               Worktree.            (line  13)
  11178 * magit-worktree-delete:                 Worktree.            (line  25)
  11179 * magit-worktree-move:                   Worktree.            (line  21)
  11180 * magit-worktree-status:                 Worktree.            (line  30)
  11181 * scroll-down:                           Commands Available in Diffs.
  11182                                                               (line  60)
  11183 * scroll-up:                             Commands Available in Diffs.
  11184                                                               (line  56)
  11185 * with-editor-cancel:                    Editing Commit Messages.
  11186                                                               (line  22)
  11187 * with-editor-cancel <1>:                Editing Rebase Sequences.
  11188                                                               (line  11)
  11189 * with-editor-debug:                     Debugging Tools.     (line  44)
  11190 * with-editor-finish:                    Editing Commit Messages.
  11191                                                               (line  17)
  11192 * with-editor-finish <1>:                Editing Rebase Sequences.
  11193                                                               (line   6)
  11194 
  11195 
  11196 File: magit.info,  Node: Function Index,  Next: Variable Index,  Prev: Command Index,  Up: Top
  11197 
  11198 Appendix E Function Index
  11199 *************************
  11200 
  11201 
  11202 * Menu:
  11203 
  11204 * bug-reference-mode:                    Commit Mode and Hooks.
  11205                                                               (line  56)
  11206 * git-commit-check-style-conventions:    Commit Message Conventions.
  11207                                                               (line  40)
  11208 * git-commit-propertize-diff:            Commit Mode and Hooks.
  11209                                                               (line  47)
  11210 * git-commit-save-message:               Commit Mode and Hooks.
  11211                                                               (line  28)
  11212 * git-commit-setup-changelog-support:    Commit Mode and Hooks.
  11213                                                               (line  32)
  11214 * git-commit-turn-on-auto-fill:          Commit Mode and Hooks.
  11215                                                               (line  37)
  11216 * git-commit-turn-on-flyspell:           Commit Mode and Hooks.
  11217                                                               (line  42)
  11218 * ido-enter-magit-status:                Status Buffer.       (line  99)
  11219 * magit-add-section-hook:                Section Hooks.       (line  20)
  11220 * magit-after-save-refresh-status:       Automatic Refreshing of Magit Buffers.
  11221                                                               (line  59)
  11222 * magit-branch-or-checkout:              Branch Commands.     (line 267)
  11223 * magit-branch-orphan:                   Branch Commands.     (line 262)
  11224 * magit-branch-shelve:                   Auxiliary Branch Commands.
  11225                                                               (line   9)
  11226 * magit-branch-unshelve:                 Auxiliary Branch Commands.
  11227                                                               (line  20)
  11228 * magit-builtin-completing-read:         Support for Completion Frameworks.
  11229                                                               (line  42)
  11230 * magit-bundle:                          Bundle.              (line   8)
  11231 * magit-call-git:                        Calling Git for Effect.
  11232                                                               (line  28)
  11233 * magit-call-process:                    Calling Git for Effect.
  11234                                                               (line  32)
  11235 * magit-cancel-section:                  Creating Sections.   (line  71)
  11236 * magit-completing-read:                 Support for Completion Frameworks.
  11237                                                               (line  60)
  11238 * magit-current-section:                 Section Selection.   (line   6)
  11239 * magit-define-section-jumper:           Creating Sections.   (line  77)
  11240 * magit-describe-section-briefly:        Section Types and Values.
  11241                                                               (line  18)
  11242 * magit-diff-scope:                      Matching Sections.   (line 118)
  11243 * magit-diff-type:                       Matching Sections.   (line  95)
  11244 * magit-diff-visit-file-other-frame:     Visiting Files and Blobs from a Diff.
  11245                                                               (line  74)
  11246 * magit-diff-visit-file-other-window:    Visiting Files and Blobs from a Diff.
  11247                                                               (line  73)
  11248 * magit-diff-visit-worktree-file-other-frame: Visiting Files and Blobs from a Diff.
  11249                                                               (line  76)
  11250 * magit-diff-visit-worktree-file-other-window: Visiting Files and Blobs from a Diff.
  11251                                                               (line  75)
  11252 * magit-disable-section-inserter:        Per-Repository Configuration.
  11253                                                               (line  31)
  11254 * magit-display-buffer:                  Switching Buffers.   (line   6)
  11255 * magit-display-buffer-fullcolumn-most-v1: Switching Buffers. (line  75)
  11256 * magit-display-buffer-fullframe-status-topleft-v1: Switching Buffers.
  11257                                                               (line  65)
  11258 * magit-display-buffer-fullframe-status-v1: Switching Buffers.
  11259                                                               (line  59)
  11260 * magit-display-buffer-same-window-except-diff-v1: Switching Buffers.
  11261                                                               (line  53)
  11262 * magit-display-buffer-traditional:      Switching Buffers.   (line  45)
  11263 * magit-display-repository-buffer:       Common Commands.     (line   9)
  11264 * magit-file-checkout:                   Commands for Buffers Visiting Files.
  11265                                                               (line 135)
  11266 * magit-file-delete:                     Commands for Buffers Visiting Files.
  11267                                                               (line 127)
  11268 * magit-file-rename:                     Commands for Buffers Visiting Files.
  11269                                                               (line 123)
  11270 * magit-file-untrack:                    Commands for Buffers Visiting Files.
  11271                                                               (line 131)
  11272 * magit-find-file:                       General-Purpose Visit Commands.
  11273                                                               (line   9)
  11274 * magit-find-file-other-frame:           General-Purpose Visit Commands.
  11275                                                               (line  21)
  11276 * magit-find-file-other-window:          General-Purpose Visit Commands.
  11277                                                               (line  15)
  11278 * magit-generate-buffer-name-default-function: Naming Buffers.
  11279                                                               (line  17)
  11280 * magit-get-section:                     Matching Sections.   (line  16)
  11281 * magit-git:                             Calling Git for Effect.
  11282                                                               (line  50)
  11283 * magit-git-exit-code:                   Getting a Value from Git.
  11284                                                               (line  10)
  11285 * magit-git-failure:                     Getting a Value from Git.
  11286                                                               (line  19)
  11287 * magit-git-false:                       Getting a Value from Git.
  11288                                                               (line  29)
  11289 * magit-git-insert:                      Getting a Value from Git.
  11290                                                               (line  34)
  11291 * magit-git-items:                       Getting a Value from Git.
  11292                                                               (line  49)
  11293 * magit-git-lines:                       Getting a Value from Git.
  11294                                                               (line  44)
  11295 * magit-git-str:                         Getting a Value from Git.
  11296                                                               (line  87)
  11297 * magit-git-string:                      Getting a Value from Git.
  11298                                                               (line  38)
  11299 * magit-git-success:                     Getting a Value from Git.
  11300                                                               (line  14)
  11301 * magit-git-true:                        Getting a Value from Git.
  11302                                                               (line  24)
  11303 * magit-git-wash:                        Calling Git for Effect.
  11304                                                               (line  55)
  11305 * magit-hunk-set-window-start:           Section Movement.    (line  51)
  11306 * magit-ido-completing-read:             Support for Completion Frameworks.
  11307                                                               (line  48)
  11308 * magit-insert-am-sequence:              Status Sections.     (line  28)
  11309 * magit-insert-assumed-unchanged-files:  Status Sections.     (line 117)
  11310 * magit-insert-bisect-log:               Status Sections.     (line  46)
  11311 * magit-insert-bisect-output:            Status Sections.     (line  38)
  11312 * magit-insert-bisect-rest:              Status Sections.     (line  42)
  11313 * magit-insert-diff-filter-header:       Status Header Sections.
  11314                                                               (line  38)
  11315 * magit-insert-error-header:             Status Header Sections.
  11316                                                               (line  28)
  11317 * magit-insert-head-branch-header:       Status Header Sections.
  11318                                                               (line  42)
  11319 * magit-insert-heading:                  Creating Sections.   (line  42)
  11320 * magit-insert-ignored-files:            Status Sections.     (line 100)
  11321 * magit-insert-local-branches:           References Sections. (line  17)
  11322 * magit-insert-merge-log:                Status Sections.     (line  18)
  11323 * magit-insert-modules:                  Status Module Sections.
  11324                                                               (line  12)
  11325 * magit-insert-modules-overview:         Status Module Sections.
  11326                                                               (line  33)
  11327 * magit-insert-modules-unpulled-from-pushremote: Status Module Sections.
  11328                                                               (line  50)
  11329 * magit-insert-modules-unpulled-from-upstream: Status Module Sections.
  11330                                                               (line  44)
  11331 * magit-insert-modules-unpushed-to-pushremote: Status Module Sections.
  11332                                                               (line  62)
  11333 * magit-insert-modules-unpushed-to-upstream: Status Module Sections.
  11334                                                               (line  56)
  11335 * magit-insert-push-branch-header:       Status Header Sections.
  11336                                                               (line  51)
  11337 * magit-insert-rebase-sequence:          Status Sections.     (line  23)
  11338 * magit-insert-recent-commits:           Status Sections.     (line 131)
  11339 * magit-insert-remote-branches:          References Sections. (line  21)
  11340 * magit-insert-remote-header:            Status Header Sections.
  11341                                                               (line  67)
  11342 * magit-insert-repo-header:              Status Header Sections.
  11343                                                               (line  63)
  11344 * magit-insert-section:                  Creating Sections.   (line   6)
  11345 * magit-insert-sequencer-sequence:       Status Sections.     (line  33)
  11346 * magit-insert-skip-worktree-files:      Status Sections.     (line 110)
  11347 * magit-insert-staged-changes:           Status Sections.     (line  63)
  11348 * magit-insert-stashes:                  Status Sections.     (line  67)
  11349 * magit-insert-status-headers:           Status Header Sections.
  11350                                                               (line  12)
  11351 * magit-insert-tags:                     References Sections. (line  25)
  11352 * magit-insert-tags-header:              Status Header Sections.
  11353                                                               (line  56)
  11354 * magit-insert-tracked-files:            Status Sections.     (line  96)
  11355 * magit-insert-unpulled-cherries:        Status Sections.     (line 142)
  11356 * magit-insert-unpulled-from-pushremote: Status Sections.     (line  79)
  11357 * magit-insert-unpulled-from-upstream:   Status Sections.     (line  74)
  11358 * magit-insert-unpulled-or-recent-commits: Status Sections.   (line 124)
  11359 * magit-insert-unpushed-cherries:        Status Sections.     (line 149)
  11360 * magit-insert-unpushed-to-pushremote:   Status Sections.     (line  89)
  11361 * magit-insert-unpushed-to-upstream:     Status Sections.     (line  84)
  11362 * magit-insert-unstaged-changes:         Status Sections.     (line  59)
  11363 * magit-insert-untracked-files:          Status Sections.     (line  50)
  11364 * magit-insert-upstream-branch-header:   Status Header Sections.
  11365                                                               (line  46)
  11366 * magit-insert-user-header:              Status Header Sections.
  11367                                                               (line  75)
  11368 * magit-list-repositories:               Repository List.     (line   6)
  11369 * magit-list-submodules:                 Listing Submodules.  (line  13)
  11370 * magit-log-maybe-show-more-commits:     Section Movement.    (line  66)
  11371 * magit-log-maybe-update-blob-buffer:    Section Movement.    (line  82)
  11372 * magit-log-maybe-update-revision-buffer: Section Movement.   (line  74)
  11373 * magit-maybe-set-dedicated:             Switching Buffers.   (line 100)
  11374 * magit-mode-display-buffer:             Refreshing Buffers.  (line  33)
  11375 * magit-mode-quit-window:                Quitting Windows.    (line  34)
  11376 * magit-mode-setup:                      Refreshing Buffers.  (line  17)
  11377 * magit-process-file:                    Getting a Value from Git.
  11378                                                               (line  67)
  11379 * magit-process-git:                     Getting a Value from Git.
  11380                                                               (line  59)
  11381 * magit-push-implicitly:                 Pushing.             (line  83)
  11382 * magit-push-to-remote:                  Pushing.             (line 101)
  11383 * magit-region-sections:                 Section Selection.   (line  10)
  11384 * magit-region-values:                   Section Selection.   (line  37)
  11385 * magit-repolist-column-branch:          Repository List.     (line  50)
  11386 * magit-repolist-column-branches:        Repository List.     (line  59)
  11387 * magit-repolist-column-flag:            Repository List.     (line  67)
  11388 * magit-repolist-column-ident:           Repository List.     (line  36)
  11389 * magit-repolist-column-path:            Repository List.     (line  41)
  11390 * magit-repolist-column-stashes:         Repository List.     (line  63)
  11391 * magit-repolist-column-unpulled-from-pushremote: Repository List.
  11392                                                               (line  87)
  11393 * magit-repolist-column-unpulled-from-upstream: Repository List.
  11394                                                               (line  82)
  11395 * magit-repolist-column-unpushed-to-pushremote: Repository List.
  11396                                                               (line  97)
  11397 * magit-repolist-column-unpushed-to-upstream: Repository List.
  11398                                                               (line  92)
  11399 * magit-repolist-column-upstream:        Repository List.     (line  54)
  11400 * magit-repolist-column-version:         Repository List.     (line  45)
  11401 * magit-restore-window-configuration:    Quitting Windows.    (line  23)
  11402 * magit-run-git:                         Calling Git for Effect.
  11403                                                               (line  36)
  11404 * magit-run-git-async:                   Calling Git for Effect.
  11405                                                               (line  65)
  11406 * magit-run-git-with-editor:             Calling Git for Effect.
  11407                                                               (line  78)
  11408 * magit-run-git-with-input:              Calling Git for Effect.
  11409                                                               (line  40)
  11410 * magit-save-window-configuration:       Switching Buffers.   (line  89)
  11411 * magit-section-case:                    Matching Sections.   (line  71)
  11412 * magit-section-hide:                    Section Visibility.  (line  49)
  11413 * magit-section-hide-children:           Section Visibility.  (line  64)
  11414 * magit-section-ident:                   Matching Sections.   (line  11)
  11415 * magit-section-match:                   Matching Sections.   (line  21)
  11416 * magit-section-set-window-start:        Section Movement.    (line  59)
  11417 * magit-section-show:                    Section Visibility.  (line  45)
  11418 * magit-section-show-children:           Section Visibility.  (line  58)
  11419 * magit-section-show-headings:           Section Visibility.  (line  53)
  11420 * magit-section-toggle-children:         Section Visibility.  (line  68)
  11421 * magit-section-value-if:                Matching Sections.   (line  61)
  11422 * magit-start-git:                       Calling Git for Effect.
  11423                                                               (line  90)
  11424 * magit-start-process:                   Calling Git for Effect.
  11425                                                               (line 109)
  11426 * magit-stashes-maybe-update-stash-buffer: Section Movement.  (line 106)
  11427 * magit-status-maybe-update-blob-buffer: Section Movement.    (line 100)
  11428 * magit-status-maybe-update-revision-buffer: Section Movement.
  11429                                                               (line  88)
  11430 * magit-status-maybe-update-stash-buffer: Section Movement.   (line  94)
  11431 * magit-status-quick:                    Status Buffer.       (line  72)
  11432 * magit-switch-to-repository-buffer:     Common Commands.     (line   6)
  11433 * magit-switch-to-repository-buffer-other-frame: Common Commands.
  11434                                                               (line   8)
  11435 * magit-switch-to-repository-buffer-other-window: Common Commands.
  11436                                                               (line   7)
  11437 * magit-wip-log:                         Wip Modes.           (line  48)
  11438 * magit-wip-log-current:                 Wip Modes.           (line  57)
  11439 * with-editor-usage-message:             Commit Mode and Hooks.
  11440                                                               (line  60)
  11441 
  11442 
  11443 File: magit.info,  Node: Variable Index,  Prev: Function Index,  Up: Top
  11444 
  11445 Appendix F Variable Index
  11446 *************************
  11447 
  11448 
  11449 * Menu:
  11450 
  11451 * auto-revert-buffer-list-filter:        Automatic Reverting of File-Visiting Buffers.
  11452                                                               (line  81)
  11453 * auto-revert-interval:                  Automatic Reverting of File-Visiting Buffers.
  11454                                                               (line  76)
  11455 * auto-revert-mode:                      Automatic Reverting of File-Visiting Buffers.
  11456                                                               (line  62)
  11457 * auto-revert-stop-on-user-input:        Automatic Reverting of File-Visiting Buffers.
  11458                                                               (line  71)
  11459 * auto-revert-use-notify:                Automatic Reverting of File-Visiting Buffers.
  11460                                                               (line  49)
  11461 * auto-revert-verbose:                   Automatic Reverting of File-Visiting Buffers.
  11462                                                               (line 103)
  11463 * branch.autoSetupMerge:                 Branch Git Variables.
  11464                                                               (line  81)
  11465 * branch.autoSetupRebase:                Branch Git Variables.
  11466                                                               (line  98)
  11467 * branch.NAME.description:               Branch Git Variables.
  11468                                                               (line  48)
  11469 * branch.NAME.merge:                     Branch Git Variables.
  11470                                                               (line  10)
  11471 * branch.NAME.pushRemote:                Branch Git Variables.
  11472                                                               (line  34)
  11473 * branch.NAME.rebase:                    Branch Git Variables.
  11474                                                               (line  22)
  11475 * branch.NAME.remote:                    Branch Git Variables.
  11476                                                               (line  16)
  11477 * core.notesRef:                         Notes.               (line  60)
  11478 * git-commit-fill-column:                Commit Message Conventions.
  11479                                                               (line  19)
  11480 * git-commit-finish-query-functions:     Commit Message Conventions.
  11481                                                               (line  24)
  11482 * git-commit-known-pseudo-headers:       Commit Pseudo Headers.
  11483                                                               (line   9)
  11484 * git-commit-major-mode:                 Commit Mode and Hooks.
  11485                                                               (line  12)
  11486 * git-commit-setup-hook:                 Commit Mode and Hooks.
  11487                                                               (line  22)
  11488 * git-commit-setup-hook <1>:             Commit Mode and Hooks.
  11489                                                               (line  64)
  11490 * git-commit-style-convention-checks:    Commit Message Conventions.
  11491                                                               (line  46)
  11492 * git-commit-summary-max-length:         Commit Message Conventions.
  11493                                                               (line  13)
  11494 * git-rebase-auto-advance:               Editing Rebase Sequences.
  11495                                                               (line  99)
  11496 * git-rebase-confirm-cancel:             Editing Rebase Sequences.
  11497                                                               (line 107)
  11498 * git-rebase-show-instructions:          Editing Rebase Sequences.
  11499                                                               (line 103)
  11500 * global-auto-revert-mode:               Automatic Reverting of File-Visiting Buffers.
  11501                                                               (line  22)
  11502 * magit-auto-revert-immediately:         Automatic Reverting of File-Visiting Buffers.
  11503                                                               (line  32)
  11504 * magit-auto-revert-mode:                Automatic Reverting of File-Visiting Buffers.
  11505                                                               (line  17)
  11506 * magit-auto-revert-tracked-only:        Automatic Reverting of File-Visiting Buffers.
  11507                                                               (line  55)
  11508 * magit-bisect-show-graph:               Bisecting.           (line  65)
  11509 * magit-blame-disable-modes:             Blaming.             (line 165)
  11510 * magit-blame-echo-style:                Blaming.             (line 148)
  11511 * magit-blame-goto-chunk-hook:           Blaming.             (line 171)
  11512 * magit-blame-read-only:                 Blaming.             (line 160)
  11513 * magit-blame-styles:                    Blaming.             (line 143)
  11514 * magit-blame-time-format:               Blaming.             (line 155)
  11515 * magit-branch-adjust-remote-upstream-alist: Branch Commands. (line 210)
  11516 * magit-branch-direct-configure:         Branch Commands.     (line  20)
  11517 * magit-branch-prefer-remote-upstream:   Branch Commands.     (line 165)
  11518 * magit-branch-read-upstream-first:      Branch Commands.     (line 159)
  11519 * magit-buffer-name-format:              Naming Buffers.      (line  27)
  11520 * magit-bury-buffer-function:            Quitting Windows.    (line  14)
  11521 * magit-cherry-margin:                   Cherries.            (line  22)
  11522 * magit-clone-always-transient:          Cloning Repository.  (line  12)
  11523 * magit-clone-default-directory:         Cloning Repository.  (line  90)
  11524 * magit-clone-name-alist:                Cloning Repository.  (line 103)
  11525 * magit-clone-set-remote-head:           Cloning Repository.  (line  68)
  11526 * magit-clone-set-remote.pushDefault:    Cloning Repository.  (line  78)
  11527 * magit-clone-url-format:                Cloning Repository.  (line 124)
  11528 * magit-commit-ask-to-stage:             Initiating a Commit. (line  75)
  11529 * magit-commit-diff-inhibit-same-window: Initiating a Commit. (line 113)
  11530 * magit-commit-extend-override-date:     Initiating a Commit. (line  84)
  11531 * magit-commit-reword-override-date:     Initiating a Commit. (line  88)
  11532 * magit-commit-show-diff:                Initiating a Commit. (line  80)
  11533 * magit-commit-squash-confirm:           Initiating a Commit. (line  92)
  11534 * magit-completing-read-function:        Support for Completion Frameworks.
  11535                                                               (line  27)
  11536 * magit-define-global-key-bindings:      Default Bindings.    (line   6)
  11537 * magit-diff-adjust-tab-width:           Diff Options.        (line  21)
  11538 * magit-diff-buffer-file-locked:         Commands for Buffers Visiting Files.
  11539                                                               (line  61)
  11540 * magit-diff-extra-stat-arguments:       Diff Options.        (line 128)
  11541 * magit-diff-hide-trailing-cr-characters: Diff Options.       (line  90)
  11542 * magit-diff-highlight-hunk-region-functions: Diff Options.   (line  94)
  11543 * magit-diff-highlight-indentation:      Diff Options.        (line  75)
  11544 * magit-diff-highlight-trailing:         Diff Options.        (line  70)
  11545 * magit-diff-paint-whitespace:           Diff Options.        (line  43)
  11546 * magit-diff-paint-whitespace-lines:     Diff Options.        (line  60)
  11547 * magit-diff-refine-hunk:                Diff Options.        (line   6)
  11548 * magit-diff-refine-ignore-whitespace:   Diff Options.        (line  16)
  11549 * magit-diff-unmarked-lines-keep-foreground: Diff Options.    (line 120)
  11550 * magit-diff-visit-previous-blob:        Visiting Files and Blobs from a Diff.
  11551                                                               (line  39)
  11552 * magit-direct-use-buffer-arguments:     Transient Arguments and Buffer Variables.
  11553                                                               (line  73)
  11554 * magit-display-buffer-function:         Switching Buffers.   (line  27)
  11555 * magit-display-buffer-noselect:         Switching Buffers.   (line  18)
  11556 * magit-dwim-selection:                  Completion and Confirmation.
  11557                                                               (line  42)
  11558 * magit-ediff-dwim-show-on-hunks:        Ediffing.            (line  73)
  11559 * magit-ediff-quit-hook:                 Ediffing.            (line  88)
  11560 * magit-ediff-show-stash-with-index:     Ediffing.            (line  81)
  11561 * magit-generate-buffer-name-function:   Naming Buffers.      (line   6)
  11562 * magit-git-debug:                       Viewing Git Output.  (line  28)
  11563 * magit-git-debug <1>:                   Getting a Value from Git.
  11564                                                               (line  79)
  11565 * magit-git-executable:                  Git Executable.      (line  26)
  11566 * magit-git-global-arguments:            Global Git Arguments.
  11567                                                               (line   6)
  11568 * magit-keep-region-overlay:             The Selection.       (line  52)
  11569 * magit-list-refs-sortby:                Additional Completion Options.
  11570                                                               (line   6)
  11571 * magit-log-auto-more:                   Log Buffer.          (line  80)
  11572 * magit-log-buffer-file-locked:          Commands for Buffers Visiting Files.
  11573                                                               (line  88)
  11574 * magit-log-margin:                      Log Margin.          (line  12)
  11575 * magit-log-margin-show-committer-date:  Log Margin.          (line  49)
  11576 * magit-log-section-commit-count:        Status Sections.     (line 136)
  11577 * magit-log-select-margin:               Select from Log.     (line  30)
  11578 * magit-log-show-refname-after-summary:  Log Buffer.          (line  86)
  11579 * magit-log-trace-definition-function:   Commands Available in Diffs.
  11580                                                               (line  18)
  11581 * magit-module-sections-hook:            Status Module Sections.
  11582                                                               (line  20)
  11583 * magit-module-sections-nested:          Status Module Sections.
  11584                                                               (line  24)
  11585 * magit-no-confirm:                      Action Confirmation. (line  18)
  11586 * magit-pop-revision-stack-format:       Using the Revision Stack.
  11587                                                               (line  35)
  11588 * magit-post-commit-hook:                Initiating a Commit. (line 101)
  11589 * magit-post-display-buffer-hook:        Switching Buffers.   (line  95)
  11590 * magit-pre-display-buffer-hook:         Switching Buffers.   (line  84)
  11591 * magit-prefer-remote-upstream:          Branch Git Variables.
  11592                                                               (line 126)
  11593 * magit-prefix-use-buffer-arguments:     Transient Arguments and Buffer Variables.
  11594                                                               (line  64)
  11595 * magit-process-extreme-logging:         Viewing Git Output.  (line  47)
  11596 * magit-process-raise-error:             Calling Git for Effect.
  11597                                                               (line 136)
  11598 * magit-pull-or-fetch:                   Fetching.            (line  59)
  11599 * magit-reflog-margin:                   Reflog.              (line  23)
  11600 * magit-refresh-args:                    Refreshing Buffers.  (line  55)
  11601 * magit-refresh-buffer-hook:             Automatic Refreshing of Magit Buffers.
  11602                                                               (line  43)
  11603 * magit-refresh-function:                Refreshing Buffers.  (line  49)
  11604 * magit-refresh-status-buffer:           Automatic Refreshing of Magit Buffers.
  11605                                                               (line  49)
  11606 * magit-refs-filter-alist:               References Buffer.   (line 163)
  11607 * magit-refs-focus-column-width:         References Buffer.   (line  86)
  11608 * magit-refs-margin:                     References Buffer.   (line 101)
  11609 * magit-refs-margin-for-tags:            References Buffer.   (line 129)
  11610 * magit-refs-pad-commit-counts:          References Buffer.   (line  53)
  11611 * magit-refs-primary-column-width:       References Buffer.   (line  73)
  11612 * magit-refs-sections-hook:              References Sections. (line  13)
  11613 * magit-refs-show-commit-count:          References Buffer.   (line  41)
  11614 * magit-refs-show-remote-prefix:         References Buffer.   (line  66)
  11615 * magit-remote-add-set-remote.pushDefault: Remote Commands.   (line  92)
  11616 * magit-remote-direct-configure:         Remote Commands.     (line  21)
  11617 * magit-remote-git-executable:           Git Executable.      (line  33)
  11618 * magit-repolist-columns:                Repository List.     (line  14)
  11619 * magit-repository-directories:          Status Buffer.       (line  58)
  11620 * magit-revision-filter-files-on-follow: Revision Buffer.     (line  64)
  11621 * magit-revision-insert-related-refs:    Revision Buffer.     (line   6)
  11622 * magit-revision-show-gravatars:         Revision Buffer.     (line  19)
  11623 * magit-revision-use-hash-sections:      Revision Buffer.     (line  36)
  11624 * magit-root-section:                    Matching Sections.   (line  87)
  11625 * magit-save-repository-buffers:         Automatic Saving of File-Visiting Buffers.
  11626                                                               (line  13)
  11627 * magit-section-cache-visibility:        Section Visibility.  (line  95)
  11628 * magit-section-initial-visibility-alist: Section Visibility. (line  78)
  11629 * magit-section-movement-hook:           Section Movement.    (line  46)
  11630 * magit-section-set-visibility-hook:     Section Visibility.  (line 106)
  11631 * magit-section-show-child-count:        Section Options.     (line   9)
  11632 * magit-section-visibility-indicator:    Section Visibility.  (line 124)
  11633 * magit-shell-command-verbose-prompt:    Running Git Manually.
  11634                                                               (line  48)
  11635 * magit-stashes-margin:                  Stashing.            (line 104)
  11636 * magit-status-headers-hook:             Status Header Sections.
  11637                                                               (line  18)
  11638 * magit-status-margin:                   Status Options.      (line  10)
  11639 * magit-status-refresh-hook:             Status Options.      (line   6)
  11640 * magit-status-sections-hook:            Status Sections.     (line  10)
  11641 * magit-submodule-list-columns:          Listing Submodules.  (line  21)
  11642 * magit-this-process:                    Calling Git for Effect.
  11643                                                               (line 131)
  11644 * magit-uniquify-buffer-names:           Naming Buffers.      (line  74)
  11645 * magit-unstage-committed:               Staging and Unstaging.
  11646                                                               (line  56)
  11647 * magit-update-other-window-delay:       Section Movement.    (line 112)
  11648 * magit-visit-ref-behavior:              References Buffer.   (line 196)
  11649 * magit-wip-after-apply-mode:            Legacy Wip Modes.    (line  19)
  11650 * magit-wip-after-apply-mode-lighter:    Legacy Wip Modes.    (line  59)
  11651 * magit-wip-after-save-local-mode-lighter: Legacy Wip Modes.  (line  55)
  11652 * magit-wip-after-save-mode:             Legacy Wip Modes.    (line  13)
  11653 * magit-wip-before-change-mode:          Legacy Wip Modes.    (line  33)
  11654 * magit-wip-before-change-mode-lighter:  Legacy Wip Modes.    (line  63)
  11655 * magit-wip-initial-backup-mode:         Legacy Wip Modes.    (line  38)
  11656 * magit-wip-initial-backup-mode-lighter: Legacy Wip Modes.    (line  67)
  11657 * magit-wip-merge-branch:                Wip Graph.           (line   6)
  11658 * magit-wip-mode:                        Wip Modes.           (line  30)
  11659 * magit-wip-mode-lighter:                Wip Modes.           (line 104)
  11660 * magit-wip-namespace:                   Wip Modes.           (line  96)
  11661 * notes.displayRef:                      Notes.               (line  65)
  11662 * pull.rebase:                           Branch Git Variables.
  11663                                                               (line  57)
  11664 * remote.NAME.fetch:                     Remote Git Variables.
  11665                                                               (line  15)
  11666 * remote.NAME.push:                      Remote Git Variables.
  11667                                                               (line  26)
  11668 * remote.NAME.pushurl:                   Remote Git Variables.
  11669                                                               (line  20)
  11670 * remote.NAME.tagOpts:                   Remote Git Variables.
  11671                                                               (line  31)
  11672 * remote.NAME.url:                       Remote Git Variables.
  11673                                                               (line  10)
  11674 * remote.pushDefault:                    Branch Git Variables.
  11675                                                               (line  71)
  11676 
  11677 
  11678 
  11679 Tag Table:
  11680 Node: Top754
  11681 Node: Introduction6599
  11682 Node: Installation11322
  11683 Node: Installing from Melpa11652
  11684 Node: Installing from the Git Repository12725
  11685 Node: Post-Installation Tasks15457
  11686 Node: Getting Started16742
  11687 Node: Interface Concepts21982
  11688 Node: Modes and Buffers22343
  11689 Node: Switching Buffers24092
  11690 Node: Naming Buffers28843
  11691 Node: Quitting Windows32150
  11692 Node: Automatic Refreshing of Magit Buffers33896
  11693 Node: Automatic Saving of File-Visiting Buffers36790
  11694 Node: Automatic Reverting of File-Visiting Buffers37975
  11695 Node: Risk of Reverting Automatically42970
  11696 Node: Sections45352
  11697 Node: Section Movement46278
  11698 Node: Section Visibility51188
  11699 Node: Section Hooks57265
  11700 Node: Section Types and Values59672
  11701 Node: Section Options61093
  11702 Node: Transient Commands61565
  11703 Node: Transient Arguments and Buffer Variables62802
  11704 Node: Completion Confirmation and the Selection69818
  11705 Node: Action Confirmation70262
  11706 Node: Completion and Confirmation78115
  11707 Node: The Selection81301
  11708 Node: The hunk-internal region84200
  11709 Node: Support for Completion Frameworks85289
  11710 Node: Additional Completion Options90196
  11711 Node: Running Git90795
  11712 Node: Viewing Git Output91068
  11713 Node: Git Process Status93174
  11714 Node: Running Git Manually94139
  11715 Node: Git Executable96647
  11716 Node: Global Git Arguments99724
  11717 Node: Inspecting100530
  11718 Node: Status Buffer101687
  11719 Node: Status Sections106705
  11720 Node: Status Header Sections112257
  11721 Node: Status Module Sections114887
  11722 Node: Status Options117392
  11723 Node: Repository List118861
  11724 Node: Logging122203
  11725 Node: Refreshing Logs124764
  11726 Node: Log Buffer126210
  11727 Node: Log Margin130463
  11728 Node: Select from Log133642
  11729 Node: Reflog135867
  11730 Node: Cherries137524
  11731 Node: Diffing139372
  11732 Node: Refreshing Diffs142451
  11733 Node: Commands Available in Diffs146030
  11734 Node: Diff Options148566
  11735 Node: Revision Buffer154047
  11736 Node: Ediffing157377
  11737 Node: References Buffer161025
  11738 Node: References Sections171670
  11739 Node: Bisecting172531
  11740 Node: Visiting Files and Blobs174883
  11741 Node: General-Purpose Visit Commands175353
  11742 Node: Visiting Files and Blobs from a Diff176309
  11743 Node: Blaming179768
  11744 Node: Manipulating186109
  11745 Node: Creating Repository186451
  11746 Node: Cloning Repository186993
  11747 Node: Staging and Unstaging192398
  11748 Node: Staging from File-Visiting Buffers196481
  11749 Node: Applying197649
  11750 Node: Committing199737
  11751 Node: Initiating a Commit200320
  11752 Node: Editing Commit Messages205566
  11753 Node: Using the Revision Stack208369
  11754 Node: Commit Pseudo Headers211420
  11755 Node: Commit Mode and Hooks212756
  11756 Node: Commit Message Conventions215694
  11757 Node: Branching217822
  11758 Node: The Two Remotes218048
  11759 Node: Branch Commands220701
  11760 Node: Branch Git Variables233412
  11761 Node: Auxiliary Branch Commands238803
  11762 Node: Merging239921
  11763 Node: Resolving Conflicts243929
  11764 Node: Rebasing249300
  11765 Node: Editing Rebase Sequences254159
  11766 Node: Information About In-Progress Rebase258487
  11767 Ref: Information About In-Progress Rebase-Footnote-1267369
  11768 Node: Cherry Picking267965
  11769 Node: Reverting272296
  11770 Node: Resetting273745
  11771 Node: Stashing275611
  11772 Node: Transferring280312
  11773 Node: Remotes280534
  11774 Node: Remote Commands280686
  11775 Node: Remote Git Variables284767
  11776 Node: Fetching286046
  11777 Node: Pulling288533
  11778 Node: Pushing289579
  11779 Node: Plain Patches293917
  11780 Node: Maildir Patches295408
  11781 Node: Miscellaneous296922
  11782 Node: Tagging297247
  11783 Node: Notes299165
  11784 Node: Submodules301537
  11785 Node: Listing Submodules301755
  11786 Node: Submodule Transient303161
  11787 Node: Subtree305683
  11788 Node: Worktree307659
  11789 Node: Bundle308755
  11790 Node: Common Commands309123
  11791 Node: Wip Modes311762
  11792 Node: Wip Graph316693
  11793 Node: Legacy Wip Modes319007
  11794 Node: Commands for Buffers Visiting Files321902
  11795 Node: Minor Mode for Buffers Visiting Blobs327524
  11796 Node: Customizing328337
  11797 Node: Per-Repository Configuration329933
  11798 Node: Essential Settings332188
  11799 Node: Safety332533
  11800 Node: Performance334294
  11801 Ref: Log Performance337323
  11802 Ref: Diff Performance338633
  11803 Ref: Refs Buffer Performance339974
  11804 Ref: Committing Performance340549
  11805 Node: Microsoft Windows Performance341462
  11806 Node: MacOS Performance342653
  11807 Ref: MacOS Performance-Footnote-1343358
  11808 Node: Default Bindings343440
  11809 Node: Plumbing345682
  11810 Node: Calling Git346511
  11811 Node: Getting a Value from Git348036
  11812 Node: Calling Git for Effect351777
  11813 Node: Section Plumbing357683
  11814 Node: Creating Sections357911
  11815 Node: Section Selection361811
  11816 Node: Matching Sections363610
  11817 Node: Refreshing Buffers369583
  11818 Node: Conventions372731
  11819 Node: Theming Faces372923
  11820 Node: FAQ381038
  11821 Node: FAQ - How to ...?381480
  11822 Node: How to pronounce Magit?381893
  11823 Node: How to show git's output?382695
  11824 Node: How to install the gitman info manual?383481
  11825 Node: How to show diffs for gpg-encrypted files?384451
  11826 Node: How does branching and pushing work?385047
  11827 Node: Can Magit be used as ediff-version-control-package?385410
  11828 Node: Should I disable VC?387428
  11829 Node: FAQ - Issues and Errors388046
  11830 Node: Magit is slow389047
  11831 Node: I changed several thousand files at once and now Magit is unusable389261
  11832 Node: I am having problems committing389990
  11833 Node: I am using MS Windows and cannot push with Magit390471
  11834 Node: I am using OS X and SOMETHING works in shell but not in Magit391088
  11835 Node: Expanding a file to show the diff causes it to disappear391919
  11836 Node: Point is wrong in the COMMIT_EDITMSG buffer392500
  11837 Node: The mode-line information isn't always up-to-date393546
  11838 Node: A branch and tag sharing the same name breaks SOMETHING394609
  11839 Node: My Git hooks work on the command-line but not inside Magit395495
  11840 Node: git-commit-mode isn't used when committing from the command-line396341
  11841 Node: Point ends up inside invisible text when jumping to a file-visiting buffer398612
  11842 Node: I am unable to stage when using Tramp from MS Windows399472
  11843 Node: I am no longer able to save popup defaults400379
  11844 Node: Debugging Tools401339
  11845 Node: Keystroke Index403518
  11846 Node: Command Index437906
  11847 Node: Function Index476038
  11848 Node: Variable Index493162
  11849 
  11850 End Tag Table
  11851 
  11852 
  11853 Local Variables:
  11854 coding: utf-8
  11855 End: