From 7ac1c1c2036c51447e4d991de70ca05f0c0c0f2e Mon Sep 17 00:00:00 2001 From: Pol Dellaiera Date: Sun, 9 Nov 2025 12:22:43 +0100 Subject: [PATCH 1/3] bash: fix usage of `finalAttrs` pattern Issue introduced in #435033 in 305c5f1f12a8d20953ffbba1628ef0a52620bf7a --- pkgs/shells/bash/5.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/shells/bash/5.nix b/pkgs/shells/bash/5.nix index 0ca4ca768b5d..017edfe2613e 100644 --- a/pkgs/shells/bash/5.nix +++ b/pkgs/shells/bash/5.nix @@ -278,7 +278,7 @@ lib.warnIf (withDocs != null) mainProgram = "bash"; identifiers.cpeParts = let - versionSplit = lib.split "p" version; + versionSplit = lib.split "p" fa.version; in { vendor = "gnu"; From 151aa96218a188a74f2959e84c999bd041ed88a1 Mon Sep 17 00:00:00 2001 From: Pol Dellaiera Date: Wed, 10 Sep 2025 15:52:19 +0200 Subject: [PATCH 2/3] bash: replace `util-linux` with `util-linuxMinimal` --- pkgs/shells/bash/5.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/shells/bash/5.nix b/pkgs/shells/bash/5.nix index 017edfe2613e..243cd9e7fc3a 100644 --- a/pkgs/shells/bash/5.nix +++ b/pkgs/shells/bash/5.nix @@ -5,7 +5,7 @@ fetchurl, updateAutotoolsGnuConfigScriptsHook, bison, - util-linux, + util-linuxMinimal, coreutils, libredirect, glibcLocales, @@ -167,7 +167,7 @@ lib.warnIf (withDocs != null) doCheck = true; nativeCheckInputs = attrs.nativeCheckInputs or [ ] ++ [ - util-linux + util-linuxMinimal libredirect.hook glibcLocales gnused From e6de6e6025dbe56e4470dafc244e03573c6577e7 Mon Sep 17 00:00:00 2001 From: Pol Dellaiera Date: Wed, 10 Sep 2025 15:52:50 +0200 Subject: [PATCH 3/3] bash: minor reformating - Replace `lib.optional` with `lib.optionals` when dealing with lists - Remove `with lib;` from `meta` --- pkgs/shells/bash/5.nix | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pkgs/shells/bash/5.nix b/pkgs/shells/bash/5.nix index 243cd9e7fc3a..015872e3b2f7 100644 --- a/pkgs/shells/bash/5.nix +++ b/pkgs/shells/bash/5.nix @@ -49,7 +49,7 @@ lib.warnIf (withDocs != null) # bionic libc is super weird and has issues with fortify outside of its own libc, check this comment: # https://github.com/NixOS/nixpkgs/pull/192630#discussion_r978985593 # or you can check libc/include/sys/cdefs.h in bionic source code - ++ lib.optional (stdenv.hostPlatform.libc == "bionic") "fortify"; + ++ lib.optionals (stdenv.hostPlatform.libc == "bionic") [ "fortify" ]; outputs = [ "out" @@ -130,9 +130,9 @@ lib.warnIf (withDocs != null) updateAutotoolsGnuConfigScriptsHook bison ] - ++ lib.optional stdenv.hostPlatform.isDarwin stdenv.cc.bintools; + ++ lib.optionals stdenv.hostPlatform.isDarwin [ stdenv.cc.bintools ]; - buildInputs = lib.optional interactive readline; + buildInputs = lib.optionals interactive [ readline ]; enableParallelBuilding = true; @@ -255,7 +255,7 @@ lib.warnIf (withDocs != null) }); }; - meta = with lib; { + meta = { homepage = "https://www.gnu.org/software/bash/"; description = "GNU Bourne-Again Shell, the de facto standard shell on Linux" @@ -270,8 +270,8 @@ lib.warnIf (withDocs != null) interactive use. In addition, most sh scripts can be run by Bash without modification. ''; - license = licenses.gpl3Plus; - platforms = platforms.all; + license = lib.licenses.gpl3Plus; + platforms = lib.platforms.all; # https://github.com/NixOS/nixpkgs/issues/333338 badPlatforms = [ lib.systems.inspect.patterns.isMinGW ]; maintainers = with lib.maintainers; [ infinisil ];