2020-04-24 23:36:52 +00:00
|
|
|
{ config, lib, ... }:
|
|
|
|
{
|
|
|
|
meta = {
|
2024-09-19 14:19:46 +00:00
|
|
|
maintainers = lib.teams.freedesktop.members;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
options = {
|
2024-09-19 14:19:46 +00:00
|
|
|
xdg.menus.enable = lib.mkOption {
|
|
|
|
type = lib.types.bool;
|
2020-04-24 23:36:52 +00:00
|
|
|
default = true;
|
2024-04-21 15:54:59 +00:00
|
|
|
description = ''
|
2020-04-24 23:36:52 +00:00
|
|
|
Whether to install files to support the
|
2022-08-12 12:06:08 +00:00
|
|
|
[XDG Desktop Menu specification](https://specifications.freedesktop.org/menu-spec/menu-spec-latest.html).
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
config = lib.mkIf config.xdg.menus.enable {
|
2020-04-24 23:36:52 +00:00
|
|
|
environment.pathsToLink = [
|
|
|
|
"/share/applications"
|
|
|
|
"/share/desktop-directories"
|
|
|
|
"/etc/xdg/menus"
|
|
|
|
"/etc/xdg/menus/applications-merged"
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|