Merge pull request #59 from folliehiyuki/extra-env

Implement extraEnv option
This commit is contained in:
Zhaofeng Li
2025-03-03 13:12:08 -07:00
committed by GitHub
+3 -1
View File
@@ -129,7 +129,9 @@ let
'' + lib.optionalString (prefix.taps ? "homebrew/homebrew-core") ''
# Disable API to use pinned homebrew-core
export HOMEBREW_NO_INSTALL_FROM_API=1
'' + (builtins.readFile ./brew.tail.sh));
'' + (lib.optionalString (cfg.extraEnv != {})
(lib.concatLines (lib.mapAttrsToList (name: value: "export ${name}=${lib.escapeShellArg value}") cfg.extraEnv)))
+ (builtins.readFile ./brew.tail.sh));
in pkgs.substituteAll {
name = "brew";
src = template;