User:Penguin/Doom Emacs

From Gentoo Wiki
Jump to:navigation Jump to:search

This guide assumes you know how to install both emacs and doom emacs already. This guide is purely for gentoo-specific enhancements.

Using Packages from Portage in Doom Emacs

Doom emacs uses groups or clusters of packages via init.el called modules. These modules are intended to simplify package installation and setup based on use case. For example, in the :lang section of ~/.config/doom/packages.el, you’ll find a variety of different language modules with options for each module, much like use flags! This can be incredibly convenient because it means you don’t have to hunt down the 30 or so plugins that may be required to get support for your languange.

On a seemingly unrelated note, gentoo actually provides loads of emacs plugins on the official repos through portage. Since it is generally better to use your distro’s packages vs. other sources’ packages, we’ll need to instruct doom emacs to use our system packages rather than the melpa provided packages. I’ll be using app-emacs/spacemacs-theme as an example. To do this, one should use the following:

Install the package

   emerge -a app-emacs/spacemacs-theme

Tell Doom Emacs to use the package provided by portage

   (package! spacemacs-theme :built-in 'prefer)

Reload your config and you should be good to go.