Rebuild sudo nixos-rebuild switch --flake . --upgrade-all Clean nix store nix-store --gc --print-roots | egrep -v "^(/nix/var|/run/\w+-system|\{memory|/proc)"