mirror of
https://github.com/davegallant/nix-config
synced 2025-08-06 11:23:40 +00:00
Add make rollback
This commit is contained in:
3
Makefile
3
Makefile
@@ -18,6 +18,9 @@ endif
|
|||||||
switch:
|
switch:
|
||||||
$(SWITCH_CMD)
|
$(SWITCH_CMD)
|
||||||
|
|
||||||
|
rollback:
|
||||||
|
nixos-rebuild --use-remote-sudo switch --rollback -I nixos-config="modules/machines/$(HOSTNAME)/configuration.nix
|
||||||
|
|
||||||
update:
|
update:
|
||||||
nix flake update
|
nix flake update
|
||||||
|
|
||||||
|
@@ -25,6 +25,14 @@ make update
|
|||||||
|
|
||||||
If there are updates, they should be reflected in [flake.lock](./flake.lock).
|
If there are updates, they should be reflected in [flake.lock](./flake.lock).
|
||||||
|
|
||||||
|
## Rollback
|
||||||
|
|
||||||
|
To rollback to the previous generation:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
make rollback
|
||||||
|
```
|
||||||
|
|
||||||
## Pre-commit hooks
|
## Pre-commit hooks
|
||||||
|
|
||||||
Pre-commit hooks are automatically activated when [direnv](https://github.com/direnv/direnv) is installed.
|
Pre-commit hooks are automatically activated when [direnv](https://github.com/direnv/direnv) is installed.
|
||||||
|
Reference in New Issue
Block a user