doomemacs/modules/tools/magit
Henrik Lissner 037b018cdd
feat: add .doommodule files
These optional dotfiles indicate the root of a module or module
group (:lang), and will later contain module metadata. They will also
serve as an alternative to packages.el and doctor.el, and will aide the
parts of the v3.0 module API concerned with resolving the current module
from a path (`doom-module-from-path`), which currently rely too heavily
on parsing path strings.

For now, however, they're simply placeholders.
2024-09-14 20:47:39 -04:00
..
.doommodule feat: add .doommodule files 2024-09-14 20:47:39 -04:00
autoload.el refactor!(vc-gutter): drop git-gutter for diff-hl 2024-06-22 18:14:04 -04:00
config.el refactor(vc): move git-commit to magit module 2024-09-09 18:08:28 -04:00
packages.el bump: :tools 2024-09-07 19:04:37 -04:00
README.org docs(magit): remove magit-todos from the README 2024-09-07 15:10:11 -04:00

:tools magit

Description   unfold

This module provides Magit, an interface to the Git version control system.

Module flags

+forge
Enable Forge; a porcelain for managing Github issues and PRs from within Emacs. Will take a while on first run to build emacsql-sqlite.

Hacks

  • doom-package:magit has been modified to recognize $XDG_CACHE_HOME/git/credential/socket.
  • doom-package:magit has been modified to invalidate the projectile cache when you check out a new branch or commit.
  • doom-package:magit has been modified to revert repo buffers (e.g. after changing branches) when you later switch to them, rather than all at once.
  • doom-package:forge was modified to defer compilation of emacsql-sqlite until you try to use forge, rather than when magit first loads (which could be as soon as startup).

TODO Changelog

This module does not have a changelog yet.

Installation

Enable this module in your doom! block.

This module requires:

TODO Usage

󱌣 This module's usage documentation is incomplete. Complete it?

Start magit with <leader> g g (M-x magit-status).

If you are new to Magit, see the Getting Started section of its project readme.

TODO Configuration

󱌣 This module's configuration documentation is incomplete. Complete it?

Enable Gravatars

To enable gravatars when viewing commits:

;; in $DOOMDIR/config.el
(after! magit
  (setq magit-revision-show-gravatars '("^Author:     " . "^Commit:     ")))

Enable granular diff-highlights for all hunks

By default, changes are highlighted linewise for all but the selected hunk. This is so for performance reasons. You can enable character-wise highlights for all visible hunks with:

;; in $DOOMDIR/config.el
(after! magit
  (setq magit-diff-refine-hunk 'all))

Troubleshooting

There are no known problems with this module. Report one?

Frequently asked questions

"I recently updated and now I get 'deferred error : (wrong-type-argument sequencep code-reviewauth-token-set\?)' whenever I try to review'"

The previous package "github-review" was replaced with a package that supercedes it called "code-review", which requires a simple change in your authinfo file.

machine api.github.com login yourlogin^github-review password MYTOKENGOESHERE

becomes

machine api.github.com login yourlogin^code-review password MYTOKENGOESHERE

TODO Appendix

󱌣 This module has no appendix yet. Write one?