差異處
這裏顯示兩個版本的差異處。
Both sides previous revision 前次修改 下次修改 | 前次修改 | ||
nix [2017/01/26 02:41] jz |
nix [2017/05/28 19:12] (目前版本) jz |
||
---|---|---|---|
行 17: | 行 17: | ||
===== Install package ===== | ===== Install package ===== | ||
<code bash> | <code bash> | ||
- | nix-env -iA PACKAGE_NAME | + | nix-env -i PACKAGE_NAME |
</code> | </code> | ||
行 23: | 行 23: | ||
<code bash> | <code bash> | ||
nix-env -e PACKAGE_NAME | nix-env -e PACKAGE_NAME | ||
+ | # same as nix-env --uninstall PACKAGE_NAME | ||
+ | </code> | ||
+ | |||
+ | ===== Garbage collection ===== | ||
+ | <code bash> | ||
+ | nix-collect-garbage -d | ||
</code> | </code> | ||
行 34: | 行 40: | ||
vi /etc/nixos/configuration.nix | vi /etc/nixos/configuration.nix | ||
nixos-rebuild switch | nixos-rebuild switch | ||
+ | nix-env --list-generations | ||
</code> | </code> | ||
行 41: | 行 48: | ||
https://nixos.org/wiki/Cheatsheet | https://nixos.org/wiki/Cheatsheet | ||
+ | |||
+ | https://distrowatch.com/dwres.php?resource=package-management |