1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2025-03-05 16:27:03 +00:00

Merge pull request #1329 from emilazy/push-nlxwnqymuupk

homebrew: use `mas` from Nixpkgs
This commit is contained in:
Emily 2025-02-10 23:20:29 +00:00 committed by GitHub
commit a36049dac5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -708,9 +708,6 @@ in
description = ''
Applications to install from Mac App Store using {command}`mas`.
When this option is used, `"mas"` is automatically added to
[](#opt-homebrew.brews).
Note that you need to be signed into the Mac App Store for {command}`mas` to
successfully install and upgrade applications, and that unfortunately apps removed from this
option will not be uninstalled automatically even if
@ -768,8 +765,7 @@ in
];
homebrew.brews =
optional (cfg.masApps != { }) "mas"
++ optional (cfg.whalebrews != [ ]) "whalebrew";
optional (cfg.whalebrews != [ ]) "whalebrew";
homebrew.brewfile =
"# Created by `nix-darwin`'s `homebrew` module\n\n"
@ -789,7 +785,8 @@ in
# Homebrew Bundle
echo >&2 "Homebrew bundle..."
if [ -f "${cfg.brewPrefix}/brew" ]; then
PATH="${cfg.brewPrefix}":$PATH ${cfg.onActivation.brewBundleCmd}
PATH="${cfg.brewPrefix}:${lib.makeBinPath [ pkgs.mas ]}:$PATH" \
${cfg.onActivation.brewBundleCmd}
else
echo -e "\e[1;31merror: Homebrew is not installed, skipping...\e[0m" >&2
fi