nixos/exwm: add option to specify Emacs package

This allows a custom Emacs package to be used for EXWM (see #99424)

Co-authored-by: Lin Jian <me@linj.tech>

Garklein b7d20dbe f10ada84

Changed files
+5 -1
nixos
modules
services
x11
window-managers
+5 -1
nixos/modules/services/x11/window-managers/exwm.nix
···
${cfg.loadScript}
'';
packages = epkgs: cfg.extraPackages epkgs ++ [ epkgs.exwm ];
-
exwm-emacs = pkgs.emacs.pkgs.withPackages packages;
in
{
···
Emacs lisp code to be run after loading the user's init
file.
'';
};
extraPackages = mkOption {
type = types.functionTo (types.listOf types.package);
···
${cfg.loadScript}
'';
packages = epkgs: cfg.extraPackages epkgs ++ [ epkgs.exwm ];
+
exwm-emacs = cfg.package.pkgs.withPackages packages;
in
{
···
Emacs lisp code to be run after loading the user's init
file.
'';
+
};
+
package = mkPackageOption pkgs "Emacs" {
+
default = "emacs";
+
example = [ "emacs-gtk" ];
};
extraPackages = mkOption {
type = types.functionTo (types.listOf types.package);