From 3a5c757b01898411faeaa9896b7153c600ee0fd2 Mon Sep 17 00:00:00 2001 From: Rouven Seifert Date: Tue, 16 May 2023 11:49:31 +0200 Subject: [PATCH] fixed nix-env not upgrading generations --- shared/zsh.nix | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/shared/zsh.nix b/shared/zsh.nix index 317ad96..fe9d0b0 100644 --- a/shared/zsh.nix +++ b/shared/zsh.nix @@ -17,7 +17,8 @@ ll = "ls -la"; la = "ls -a"; less = "bat"; - update = "cd /etc/nixos && nix flake update && cat ${../images/another-cat.sixel}"; + # update = "cd /etc/nixos && nix flake update && cat ${../images/another-cat.sixel}"; + update = "cd /etc/nixos && nix flake update"; garbage = "sudo nix-collect-garbage -d && cat ${../images/cat-garbage.sixel}"; }; histSize = 100000; @@ -54,7 +55,8 @@ switch() { OUT_PATH=/tmp/nixos-rebuild-nom-$(date +%s) ${pkgs.nix-output-monitor}/bin/nom build /etc/nixos#nixosConfigurations.${config.networking.hostName}.config.system.build.toplevel -o $OUT_PATH - sudo $OUT_PATH/bin/switch-to-configuration switch + sudo ${pkgs.nix}/bin/nix-env -p /nix/var/nix/profiles/system --set $OUT_PATH + sudo $OUT_PATH/bin/switch-to-configuration switch unlink $OUT_PATH }