1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2025-03-28 10:47:19 +00:00

fix: use short hostname as flake attribute name

This commit is contained in:
Łukasz Niemier 2021-07-09 10:12:23 +02:00
parent 007d700e64
commit de4239f97c
No known key found for this signature in database
GPG key ID: 15E70BE89F051D9B

View file

@ -120,9 +120,9 @@ if [ -n "$flake" ]; then
flakeAttr="${BASH_REMATCH[2]}"
fi
if [ -z "$flakeAttr" ]; then
flakeAttr=$(hostname)
flakeAttr=$(hostname -s)
fi
flakeAttr=darwinConfigurations.${flakeAttr%.local}
flakeAttr=darwinConfigurations.${flakeAttr}
fi
if [ -n "$flake" ]; then