diff options
Diffstat (limited to 'system/modules/emacs.nix')
-rw-r--r-- | system/modules/emacs.nix | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/system/modules/emacs.nix b/system/modules/emacs.nix new file mode 100644 index 000000000000..1cfa2b07452c --- /dev/null +++ b/system/modules/emacs.nix @@ -0,0 +1,23 @@ +{ config, pkgs, lib, ... }: +with lib; +{ + options.programs.emacs.useGit = mkOption { + description = "Use emacs from git"; + type = types.bool; + default = false; + }; + + config = { + nixpkgs.overlays = if config.programs.emacs.useGit then [] else [ + (import (builtins.fetchTarball https://github.com/nix-community/emacs-overlay/archive/master.tar.gz)) + ]; + + environment.systemPackages = with pkgs; [ + (if config.programs.emacs.useGit then emacsGit else emacs) + ripgrep + coreutils + fd + clang + ]; + }; +} |