Added rebuild.sh

This commit is contained in:
2022-10-18 11:28:19 +02:00
parent 28a25a3719
commit 99017afeee

12
rebuild.sh Executable file
View File

@@ -0,0 +1,12 @@
#!/usr/bin/env bash
git commit
if [[ $? -ne 0 ]]; then
echo "Git commit not successful, will not rebuild before commit is complete."
exit 1
fi
echo "Copying configurations to etc and rebuilding."
sudo cp /home/adam/nixos-configuration/*.nix /etc/nixos/.
sudo nixos-rebuild switch