From 12c41d07abe96c7303428c2b7bb3fe90d9e5b651 Mon Sep 17 00:00:00 2001 From: Dave Gallant Date: Thu, 14 Mar 2024 22:32:45 -0400 Subject: [PATCH] Fix rollbacks --- README.md | 8 +++++++- justfile | 5 ++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index ddd6844..a5d0e0d 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,13 @@ If there are updates, they should be reflected in [flake.lock](./flake.lock). To rollback to the previous generation: ```sh -just rollback +just rollback-linux +``` + +or on macOS: + +```sh +just rollback-mac ``` ## Garbage collection diff --git a/justfile b/justfile index d2a0c56..2ef7d8c 100644 --- a/justfile +++ b/justfile @@ -8,9 +8,12 @@ build-linux: build-mac: darwin-rebuild switch -I nixos-config="machines/$host/configuration.nix" --flake . -rollback: +rollback-linux: nixos-rebuild --use-remote-sudo switch --rollback -I nixos-config="machines/$host/configuration.nix" +rollback-mac: + darwin-rebuild --rollback -I nixos-config="machines/$host/configuration.nix" + update: @./nix-flake-update.sh