diff --git a/docs/best-practices/simplify-nixos-related-commands.md b/docs/best-practices/simplify-nixos-related-commands.md index b4182d0..57af2fe 100644 --- a/docs/best-practices/simplify-nixos-related-commands.md +++ b/docs/best-practices/simplify-nixos-related-commands.md @@ -33,7 +33,7 @@ up: # Update specific input # usage: make upp i=home-manager upp: - nix flake lock --update-input $(i) + nix flake update $(i) history: nix profile history --profile /nix/var/nix/profiles/system diff --git a/docs/nixos-with-flakes/update-the-system.md b/docs/nixos-with-flakes/update-the-system.md index 1e7d516..64b29e7 100644 --- a/docs/nixos-with-flakes/update-the-system.md +++ b/docs/nixos-with-flakes/update-the-system.md @@ -8,7 +8,7 @@ in `/etc/nixos` or any other location where you keep the configuration: nix flake update # Or replace only the specific input, such as home-manager: -nix flake lock --update-input home-manager +nix flake update home-manager # Apply the updates sudo nixos-rebuild switch --flake . diff --git a/docs/zh/best-practices/simplify-nixos-related-commands.md b/docs/zh/best-practices/simplify-nixos-related-commands.md index e246bf8..e867cd2 100644 --- a/docs/zh/best-practices/simplify-nixos-related-commands.md +++ b/docs/zh/best-practices/simplify-nixos-related-commands.md @@ -34,7 +34,7 @@ up: # Update specific input # usage: make upp i=home-manager upp: - nix flake lock --update-input $(i) + nix flake update $(i) history: nix profile history --profile /nix/var/nix/profiles/system diff --git a/docs/zh/nixos-with-flakes/update-the-system.md b/docs/zh/nixos-with-flakes/update-the-system.md index 623ec3b..b23ce33 100644 --- a/docs/zh/nixos-with-flakes/update-the-system.md +++ b/docs/zh/nixos-with-flakes/update-the-system.md @@ -8,7 +8,7 @@ nix flake update # 或者也可以只更新特定的依赖项,比如只更新 home-manager: -nix flake lock --update-input home-manager +nix flake update home-manager # 部署系统 sudo nixos-rebuild switch --flake .