NixOS: Difference between revisions
imported>Ixxie Added imperative section. |
imported>Ixxie |
||
| Line 69: | Line 69: | ||
In addition to declarative system configuration, NixOS offers imperative commands to manage ''user specific'' package management. These operations are managed by the <code>nix-env</code> command line tool. The following is a summary of some common operations that can be performed with it: | In addition to declarative system configuration, NixOS offers imperative commands to manage ''user specific'' package management. These operations are managed by the <code>nix-env</code> command line tool. The following is a summary of some common operations that can be performed with it: | ||
{| | |||
|''Searching for packages'' | |||
|<code>nix-env -qaP '.*packagename.*'</code> | |||
|- | |||
|''Installing a package'' | |||
|<code>nix-env -i packagename</code> | |||
|- | |||
|''List installed packages'' | |||
|<code>nix-env -q</code> | |||
|- | |||
|''Uninstall packages'' | |||
|<code>nix-env -e packagename</code> | |||
|- | |||
|''Upgrade packages'' | |||
|<code>nix-env -u</code> | |||
|} | |||
=== Channels === | === Channels === | ||