From 027500a8dae78eae6bd7ad5f14b9f77ecc65440c Mon Sep 17 00:00:00 2001 From: Yueh-Shun Li Date: Sun, 7 Jul 2024 04:20:17 +0800 Subject: [PATCH] voms: format according to Nix RFC 166 Format the code with nixfmt-rfc-style according to Nix RFC 166. Add comment to elaborate the conditional output "etc" and to maipulate the format. --- pkgs/tools/networking/voms/default.nix | 35 ++++++++++++++++---------- 1 file changed, 22 insertions(+), 13 deletions(-) diff --git a/pkgs/tools/networking/voms/default.nix b/pkgs/tools/networking/voms/default.nix index 3f483da1cef5..b878e0b9d13b 100644 --- a/pkgs/tools/networking/voms/default.nix +++ b/pkgs/tools/networking/voms/default.nix @@ -1,21 +1,22 @@ -{ lib -, stdenv -, fetchFromGitHub +{ + lib, + stdenv, + fetchFromGitHub, # Native build inputs -, autoreconfHook -, bison -, flex -, pkg-config + autoreconfHook, + bison, + flex, + pkg-config, # Build inputs -, expat -, gsoap -, openssl -, zlib + expat, + gsoap, + openssl, + zlib, # Configuration overridable with .override # If not null, the builder will # create a new output "etc", move "$out/etc" to "$etc/etc" # and symlink "$out/etc" to externalEtc. -, externalEtc ? "/etc" + externalEtc ? "/etc", }: stdenv.mkDerivation (finalAttrs: { @@ -47,7 +48,15 @@ stdenv.mkDerivation (finalAttrs: { zlib ]; - outputs = [ "bin" "out" "dev" "man" ] + outputs = + [ + "bin" + "out" + "dev" + "man" + ] + # `etc` output for default configurations that can optionally be + # installed to /etc (system-wide) or profile-path>/etc. ++ lib.optional (externalEtc != null) "etc"; preAutoreconf = ''