From 0ab950c13ee70d98f2b31818db511a615f3b0be6 Mon Sep 17 00:00:00 2001 From: tv Date: Mon, 13 Jul 2015 18:27:16 +0200 Subject: 3 tv.git: allow setting root-{desc,title} --- 3modules/tv/git.nix | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) (limited to '3modules/tv') diff --git a/3modules/tv/git.nix b/3modules/tv/git.nix index e19063fa8..7170d2ebc 100644 --- a/3modules/tv/git.nix +++ b/3modules/tv/git.nix @@ -39,9 +39,6 @@ let type = types.str; default = "/etc/git"; }; - rules = mkOption { - type = types.unspecified; - }; repos = mkOption { type = types.attrsOf (types.submodule ({ options = { @@ -102,6 +99,25 @@ let Repositories. ''; }; + root-desc = mkOption { + type = types.nullOr types.str; + default = null; + description = '' + Text printed below the heading on the repository index page. + Default value: "a fast webinterface for the git dscm". + ''; + }; + root-title = mkOption { + type = types.nullOr types.str; + default = null; + description = '' + Text printed as heading on the repository index page. + Default value: "Git Repository Browser". + ''; + }; + rules = mkOption { + type = types.unspecified; + }; users = mkOption { type = types.unspecified; }; @@ -175,8 +191,8 @@ let enable-log-linecount=1 enable-remote-branches=1 - root-title=public repositories at ${config.networking.hostName} - root-desc=keep calm and engage + ${optionalString (cfg.root-title != null) "root-title=${cfg.root-title}"} + ${optionalString (cfg.root-desc != null) "root-desc=${cfg.root-desc}"} snapshots=0 max-stats=year -- cgit v1.2.3