Skip to content

Commit

Permalink
nixos/documentation: build apropos cache
Browse files Browse the repository at this point in the history
  • Loading branch information
evils committed Mar 25, 2020
1 parent d96bd33 commit 2df61d8
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions nixos/modules/misc/documentation.nix
Expand Up @@ -174,6 +174,13 @@ in
environment.pathsToLink = [ "/share/man" ];
environment.extraOutputsToInstall = [ "man" ] ++ optional cfg.dev.enable "devman";
environment.etc."man.conf".source = "${pkgs.man-db}/etc/man_db.conf";

system.activationScripts.apropos = ''
mkdir -m 0755 -p /var/cache/man
export PATH=${pkgs.lib.makeBinPath [ pkgs.gzip ]}:$PATH
${pkgs.man-db}/bin/mandb > /dev/null
'';

})

(mkIf cfg.info.enable {
Expand Down

0 comments on commit 2df61d8

Please sign in to comment.