Adding programs to PATH: Difference between revisions
Add initial version of guide page for adding packages to PATH. Tags: Mobile edit Mobile web edit Visual edit |
m Clarify udev paragraph Tags: Mobile edit Mobile web edit Visual edit |
||
| Line 1: | Line 1: | ||
Here is a collection of methods to add a program to the <code>PATH</code> environment variable with [[Nix (package manager)]] with packages from [[Nixpkgs]]. | Here is a collection of methods to add a program to the <code>PATH</code> environment variable with [[Nix (package manager)]] with packages from [[Nixpkgs]]. | ||
The NixOS method supports installing [[udev]] rules, which may be required for programs interacting with hardware. Services should be enabled and configured with NixOS options rather than by adding them manually to <code>environment.systemPackages</code>. | |||
Here we are using the package <code>hello</code> as an example. Unless stated otherwise, package attribute names (with necessary prefixes like <code>nixpkgs\#</code> or <code>pkgs.</code>) can be repeated to add more packages. | Here we are using the package <code>hello</code> as an example. Unless stated otherwise, package attribute names (with necessary prefixes like <code>nixpkgs\#</code> or <code>pkgs.</code>) can be repeated to add more packages. | ||