From 84b8922e82327a638a828fb585e27206c2539edc Mon Sep 17 00:00:00 2001 From: Daniel Nagy Date: Sat, 21 Sep 2024 09:00:00 +0200 Subject: [PATCH] nixos/darkhttpd: remove `with lib;` --- nixos/modules/services/web-servers/darkhttpd.nix | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/nixos/modules/services/web-servers/darkhttpd.nix b/nixos/modules/services/web-servers/darkhttpd.nix index f6b693139a1e..ab647b11de5d 100644 --- a/nixos/modules/services/web-servers/darkhttpd.nix +++ b/nixos/modules/services/web-servers/darkhttpd.nix @@ -1,11 +1,11 @@ { config, lib, pkgs, ... }: -with lib; - let + inherit (lib) mkIf mkOption optional; + inherit (lib.types) path bool listOf str port; cfg = config.services.darkhttpd; - args = concatStringsSep " " ([ + args = lib.concatStringsSep " " ([ cfg.rootDir "--port ${toString cfg.port}" "--addr ${cfg.address}" @@ -14,12 +14,12 @@ let ++ optional config.networking.enableIPv6 "--ipv6"); in { - options.services.darkhttpd = with types; { - enable = mkEnableOption "DarkHTTPd web server"; + options.services.darkhttpd = { + enable = lib.mkEnableOption "DarkHTTPd web server"; port = mkOption { default = 80; - type = types.port; + type = port; description = '' Port to listen on. Pass 0 to let the system choose any free port for you.