Emacs: Difference between revisions
imported>Makefu Created page with "{{Expansion|This article is incomplete.}} For reference use [https://nixos.org/nixos/manual/index.html#module-services-emacs the emacs chapter in the nixos manual]. Categ..." |
imported>Yuu add emacs overlay from nix community |
||
Line 3: | Line 3: | ||
For reference use [https://nixos.org/nixos/manual/index.html#module-services-emacs the emacs chapter in the nixos manual]. | For reference use [https://nixos.org/nixos/manual/index.html#module-services-emacs the emacs chapter in the nixos manual]. | ||
= Installation = | |||
== Emacs overlay == | |||
As of July 2021, the Nix community [https://github.com/nix-community/emacs-overlay/blob/f177e5d14ad2e1edceb63f3ab8aa9748ebe6383c/default.nix#L88 offers five variants of GNU Emacs]: emacsGit, emacsGcc, emacsPgtk, emacsPgtkGcc, and emacsUnstable. For installing one of them, add the following lines to {{ic|/etc/nixos/configuration.nix}} (replace emacsPgtkGcc with the variant of your choice). | |||
<syntaxhighlight lang="nix"> | |||
{ | |||
services.emacs.package = pkgs.emacsPgtkGcc; | |||
nixpkgs.overlays = [ | |||
(import (builtins.fetchGit { | |||
url = "https://github.com/nix-community/emacs-overlay.git"; | |||
ref = "master"; | |||
rev = "bfc8f6edcb7bcf3cf24e4a7199b3f6fed96aaecf"; # change the revision | |||
})) | |||
]; | |||
environment.systemPackages = with pkgs; [ | |||
emacsPgtkGcc | |||
]; | |||
} | |||
</syntaxhighlight> | |||
[[Category:NixOS]] | [[Category:NixOS]] | ||
[[Category:Incomplete]] | [[Category:Incomplete]] |
Revision as of 20:17, 7 July 2021
For reference use the emacs chapter in the nixos manual.
Installation
Emacs overlay
As of July 2021, the Nix community offers five variants of GNU Emacs: emacsGit, emacsGcc, emacsPgtk, emacsPgtkGcc, and emacsUnstable. For installing one of them, add the following lines to /etc/nixos/configuration.nix
(replace emacsPgtkGcc with the variant of your choice).
{
services.emacs.package = pkgs.emacsPgtkGcc;
nixpkgs.overlays = [
(import (builtins.fetchGit {
url = "https://github.com/nix-community/emacs-overlay.git";
ref = "master";
rev = "bfc8f6edcb7bcf3cf24e4a7199b3f6fed96aaecf"; # change the revision
}))
];
environment.systemPackages = with pkgs; [
emacsPgtkGcc
];
}