NixOS: Difference between revisions

imported>Ixxie
No edit summary
imported>Ixxie
mNo edit summary
Line 94: Line 94:
====  User Environments ====
====  User Environments ====


In addition to declarative system configuration, NixOS offers the imperative <code>nix-env</code> command which can be used to install packages at the user level. Packages installed using <code>nix-env</code> are only available to the given user, and do not change system state.
In addition to declarative system configuration, NixOS users can utilize Nix's imperative <code>nix-env</code> command to install packages at the user level, without changing the system state. See the [[Nix Package Manager#User Environments| User environments section of the Nix article]] for more information.
 
{| class="wikitable"
|+ Common <code>nix-env</code> Commands
|-
|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 ====