diff options
Diffstat (limited to 'nixos/modules/services/misc/nixos-manual.nix')
-rw-r--r-- | nixos/modules/services/misc/nixos-manual.nix | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/nixos/modules/services/misc/nixos-manual.nix b/nixos/modules/services/misc/nixos-manual.nix index 1260272b68e..c522868c1d9 100644 --- a/nixos/modules/services/misc/nixos-manual.nix +++ b/nixos/modules/services/misc/nixos-manual.nix @@ -12,8 +12,10 @@ let cfg = config.services.nixosManual; manual = import ../../../doc/manual { - inherit (cfg) revision; inherit pkgs; + revision = + let fn = "${toString pkgs.path}/.git-revision"; + in if pathExists fn then readFile fn else "master"; options = (fixMergeModules baseModules (removeAttrs extraArgs ["config" "options"]) // { modules = [ ]; @@ -75,16 +77,6 @@ in ''; }; - services.nixosManual.revision = mkOption { - default = "local"; - type = types.uniq types.string; - description = '' - Revision of the targeted source file. This value can either be - <literal>"local"</literal>, <literal>"HEAD"</literal> or any - revision number embedded in a string. - ''; - }; - }; |