%title NixOS Quick Tips :nix:dev:ops: %date 2020-10-19 19:05 install a package: `nix-env -i hello` <-- not reproducible and hence not advisable or edit `/etc/nixos/configuration.nix` to ensure system wide install `nixos-rebuild switch` <-- create new generation `nixos-rebuild test` <-- only active while computer on `sudo nixos-rebuild test -I nixpkgs=~/usr/nixpkgs/` ^-- use local repo to build pkgs find out where in the store a binary is: `readlink -f $(which hello)` search packages `nix-env -qaP '.*hello.*'` or `nix search ` search nix package options `nixos-option