Merge pull request #51520 from michaelpj/imp/appstream

nixos: add AppStream module
This commit is contained in:
Jan Tojnar 2018-12-18 00:27:23 +01:00 committed by GitHub
commit aacb244889
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 26 additions and 0 deletions

View file

@ -0,0 +1,25 @@
{ config, lib, ... }:
with lib;
{
options = {
appstream.enable = mkOption {
type = types.bool;
default = true;
description = ''
Whether to install files to support the
<link xlink:href="https://www.freedesktop.org/software/appstream/docs/index.html">AppStream metadata specification</link>.
'';
};
};
config = mkIf config.appstream.enable {
environment.pathsToLink = [
# per component metadata
"/share/metainfo"
# legacy path for above
"/share/appdata"
];
};
}

View file

@ -11,6 +11,7 @@
./config/xdg/icons.nix
./config/xdg/menus.nix
./config/xdg/mime.nix
./config/appstream.nix
./config/gtk/gtk-icon-cache.nix
./config/gnu.nix
./config/i18n.nix