Spacemacs

From Gentoo Wiki
Jump to:navigation Jump to:search
Resources

Spacemacs is a sophisticated and polished Emacs set-up focused on ergonomics, mnemonics and consistency.

Installation

Spacemacs is installed simply by replacing the Emacs configuration files with those cloned from the Spacemacs git repository. First install Emacs with the correct USE flags.

Note
The use of Emacs 26.x is advised due to compatibility with Spacemacs layers.

USE flags

Ensure Emacs is built with the xft USE flag[1][2]:

FILE /etc/portage/package.use
app-editors/emacs xft

Emerge Emacs

Install Emacs, or reinstall if USE flags have been changed:

root #emerge --ask app-editors/emacs

Download and install Spacemacs

Spacemacs is installed by cloning a git repository containing Emacs configuration.

First, backup or delete ~/.emacs.d and ~/.emacs, if they already exist:

user $mv ~/.emacs.d ~/.emacs.d.bak-$(date +%FT%T)
user $mv ~/.emacs ~/.emacs.bak-$(date +%FT%T)

If old settings are to be archived, backup ~/.emacsm.

Clone the Spacemacs git repository into ~/.emacs.d:

user $git clone https://github.com/syl20bnr/spacemacs ~/.emacs.d

To finish installing Spacemacs, start Emacs and follow the install prompt at the bottom of the screen:

user $emacs &
Note
Once installation has finished, there may be quite a bit of information from the install logs still showing. The simplest thing, when starting off, may be to close Spacemacs and relaunch by following the next section.

Note: this paragraph may be outdated :- After finishing the first startup process, press ESC -> SPACE -> f -> f -> .spacemacs . The font can be changed under dotspacemacs-default-font and layers can be enabled or disabled under dotspacemacs-configuration-layers among many other options. The settings are written in Lisp.

Usage

Invocation

Because Spacemacs replaces the main Emacs configuration, by default, simply launch Emacs to open Spacemacs:

user $emacs &
Tip
To edit the Spacemacs configuration file, press SPACE -> f -> e -> d, just after launch.

See also

References

  1. Konstantinos Tsardounis. Unable to use Source Code Pro fonts?, Spacemacs GutHub, January 16th, 2018. Retrieved on March 19th, 2019.
  2. Wiki authors. Xft support for GNU Emacs, Gentoo Wiki, July 11th, 2013. Retrieved on March 19th, 2019.