Options
The following options are allowed for all nix-env operations, but may not always have an effect.
-
--file/-ffileish
Specifies the Nix expression (designated below as the active Nix expression) used by the--install,--upgrade, and--query --availableoperations to obtain derivations. The default is~/.nix-defexpr.fileish is interpreted the same as with nix-build. See that section for complete details (
nix-build --help), but in summary, a path argument may be one of:{{#include ../fileish-summary.md}}
-
--profile/-ppath
Specifies the profile to be used by those operations that operate on a profile (designated below as the active profile). A profile is a sequence of user environments called generations, one of which is the current generation. -
--dry-run
For the--install,--upgrade,--uninstall,--switch-generation,--delete-generationsand--rollbackoperations, this flag will causenix-envto print what would be done if this flag had not been specified, without actually doing it.--dry-runalso prints out which paths will be substituted (i.e., downloaded) and which paths will be built from source (because no substitute is available). -
--system-filtersystem
By default, operations such as--query --availableshow derivations matching any platform. This option allows you to use derivations for the specified platform system.