about summary refs log tree commit diff
path: root/nixpkgs/nixos/modules/config/xdg/icons.nix
blob: 8268a3771a0ea553561bd2af8b1a3154b5ce1b2e (plain) (blame)
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
{ config, lib, ... }:

with lib;
{
  options = {
    xdg.icons.enable = mkOption {
      type = types.bool;
      default = true;
      description = ''
        Whether to install files to support the 
        <link xlink:href="https://specifications.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html">XDG Icon Theme specification</link>.
      '';
    };
  };

  config = mkIf config.xdg.icons.enable {
    environment.pathsToLink = [ 
      "/share/icons" 
      "/share/pixmaps" 
    ];
    
    environment.profileRelativeEnvVars = {
      XCURSOR_PATH = [ "/share/icons" ];
    };
  };

}