about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--flake.nix2
-rwxr-xr-xrebuild.sh1
2 files changed, 2 insertions, 1 deletions
diff --git a/flake.nix b/flake.nix
index 4a22725..76a2c0d 100644
--- a/flake.nix
+++ b/flake.nix
@@ -1,5 +1,5 @@
 {
-	description = "Nixos config flake"
+	description = "Nixos config flake";
 
 	inputs = {
 		nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
diff --git a/rebuild.sh b/rebuild.sh
index c38145e..2e2dfdd 100755
--- a/rebuild.sh
+++ b/rebuild.sh
@@ -36,6 +36,7 @@ echo "NixOS Rebuilding..."
 
 # Rebuild, output simplified errors, log trackebacks
 sudo nixos-rebuild switch --flake $DIR 2>&1 | tee nixos-switch.log
+cat nixos-switch.log | grep --color error && exit 1
 
 # Get current generation metadata
 current=$(nixos-rebuild list-generations | grep current)