1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2024-12-14 11:57:34 +00:00
nix-darwin/tests/networking-hostname.nix
2018-01-08 00:31:52 +01:00

14 lines
529 B
Nix

{ config, pkgs, ... }:
{
networking.hostName = "EVE";
test = ''
echo checking hostname in /activate >&2
grep "scutil --set ComputerName 'EVE'" ${config.out}/activate
grep "scutil --set LocalHostName 'EVE'" ${config.out}/activate
grep "scutil --set HostName 'EVE'" ${config.out}/activate
echo checking defaults write in ${config.out}/activate-user >&2
grep "defaults write /Library/Preferences/SystemConfiguration/com.apple.smb.server 'NetBIOSName' -string 'EVE'" ${config.out}/activate-user
'';
}