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

checks: fix sw_vers parameter for macOSVersion (--productVersion, not -productVersion)

This commit is contained in:
tarc 2025-01-30 12:46:25 -03:00
parent 349a74c66c
commit f1cf8c4f5a

View file

@ -9,7 +9,7 @@ let
cfg = config.system.checks;
macOSVersion = ''
IFS=. read -ra osVersion <<<"$(sw_vers --productVersion)"
IFS=. read -ra osVersion <<<"$(sw_vers -productVersion)"
if (( osVersion[0] < 11 || (osVersion[0] == 11 && osVersion[1] < 3) )); then
printf >&2 '\e[1;31merror: macOS version is less than 11.3, aborting activation\e[0m\n'
printf >&2 'Nixpkgs 25.05 requires macOS Big Sur 11.3 or newer, and 25.11 will\n'