From def1e23be848848400d1d097d4f044e3c401f9dd Mon Sep 17 00:00:00 2001 From: Weijia Wang <9713184+wegank@users.noreply.github.com> Date: Sun, 14 Apr 2024 23:02:32 +0200 Subject: treewide: remove lib.mdDoc --- modules/time/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/time') diff --git a/modules/time/default.nix b/modules/time/default.nix index d3fa34d..28724a5 100644 --- a/modules/time/default.nix +++ b/modules/time/default.nix @@ -23,7 +23,7 @@ in type = types.nullOr types.str; default = null; example = "America/New_York"; - description = lib.mdDoc '' + description = '' The time zone used when displaying times and dates. See or run {command}`sudo systemsetup -listtimezones` for a comprehensive list of possible values for this setting. -- cgit v1.2.3 From 6ff3a49ceb1c98e96452542a6feadacc477eedff Mon Sep 17 00:00:00 2001 From: zowoq <59103226+zowoq@users.noreply.github.com> Date: Tue, 5 Nov 2024 11:11:14 +1000 Subject: time: shellcheck fix https://www.shellcheck.net/wiki/SC2143 --- modules/time/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/time') diff --git a/modules/time/default.nix b/modules/time/default.nix index 28724a5..01c4703 100644 --- a/modules/time/default.nix +++ b/modules/time/default.nix @@ -7,7 +7,7 @@ let cfg = config.time; timeZone = optionalString (cfg.timeZone != null) '' - if [ -z $(systemsetup -listtimezones | grep "^ ${cfg.timeZone}$") ]; then + if ! systemsetup -listtimezones | grep -q "^ ${cfg.timeZone}$"; then echo "${cfg.timeZone} is not a valid timezone. The command 'listtimezones' will show a list of valid time zones." >&2 false fi -- cgit v1.2.3