2024-07-14 16:04:36 +02:00
|
|
|
#!/bin/sw
|
2024-07-03 15:40:52 +02:00
|
|
|
|
|
|
|
hostname=$(hostname)
|
|
|
|
|
2024-07-04 12:57:40 +02:00
|
|
|
if [[ $hostname == *"desktop"* ]]; then
|
|
|
|
sudo nixos-rebuild switch --flake ~/nix/#desktop
|
2024-07-03 15:40:52 +02:00
|
|
|
elif [[ $hostname == *"laptop"* ]]; then
|
|
|
|
sudo nixos-rebuild switch --flake ~/nix/#laptop
|
|
|
|
else
|
|
|
|
echo "Unable to determine the type of machine."
|
|
|
|
fi
|
|
|
|
|