blob: b6b6d048564e4c3e64a8f2f448bc71d4c7551491 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
{ lib, pkgs, config, ... }:
{
options = {
this.gui.enable = lib.mkEnableOption "GUI";
this.gui.extraPackages = lib.mkOption {
type = with lib.types; listOf package;
default = with pkgs; [ xorg.xmodmap xorg.xkbcomp xorg.xdpyinfo xclip ];
};
};
config = lib.mkIf config.this.gui.enable {
services.xserver.enable = true;
services.xserver.displayManager.startx.enable = true;
services.speechd.enable = false;
services.openssh.settings.X11Forwarding = true;
i18n.inputMethod = {
type = "ibus";
ibus.engines = with pkgs.ibus-engines;
(lib.optional
(builtins.elem "jp" config.this.locales.all)
mozc);
};
environment.systemPackages = config.this.gui.extraPackages;
};
}
|