1
0
mirror of https://github.com/nix-community/home-manager synced 2024-06-01 20:43:34 +02:00

manual: add option manual.json.enable

Make it possible to install a JSON file containing the available Home
Manager options.
This commit is contained in:
Alex Ameen 2019-04-13 02:39:14 -05:00 committed by Robert Helgesson
parent 1806e5511e
commit ff602cb906
No known key found for this signature in database
GPG Key ID: 36BDAA14C2797E89

View File

@ -83,13 +83,26 @@ in
Thanks!
'';
};
manual.json.enable = mkOption {
type = types.bool;
default = false;
example = true;
description = ''
Whether to install a JSON formatted list of all Home Manager
options. This can be located at
<filename>&lt;profile directory&gt;/share/doc/home-manager/options.json</filename>,
and may be used for navigating definitions, auto-completing,
and other miscellaneous tasks.
'';
};
};
config = {
home.packages = mkMerge [
(mkIf cfg.html.enable [ helpScript homeManagerManual.manual ])
(mkIf cfg.manpages.enable [ homeManagerManual.manpages ])
(mkIf cfg.json.enable [ homeManagerManual.optionsJSON ])
];
};