File: opt-common.md

package info (click to toggle)
nix 2.26.3%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 12,524 kB
  • sloc: cpp: 87,540; sh: 8,864; perl: 649; yacc: 466; xml: 410; javascript: 378; lex: 329; ansic: 215; python: 128; sql: 56; makefile: 33; exp: 5; ruby: 1
file content (38 lines) | stat: -rw-r--r-- 1,564 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# Options

The following options are allowed for all `nix-env` operations, but may not always have an effect.

- `--file` / `-f` *path*

  Specifies the Nix expression (designated below as the *active Nix
  expression*) used by the `--install`, `--upgrade`, and `--query
  --available` operations to obtain derivations. The default is
  `~/.nix-defexpr`.

  If the argument starts with `http://` or `https://`, it is
  interpreted as the URL of a tarball that will be downloaded and
  unpacked to a temporary location. The tarball must include a single
  top-level directory containing at least a file named `default.nix`.

- `--profile` / `-p` *path*

  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-generations` and `--rollback`
  operations, this flag will cause `nix-env` to print what *would* be
  done if this flag had not been specified, without actually doing it.

  `--dry-run` also prints out which paths will be
  [substituted](@docroot@/glossary.md) (i.e., downloaded) and which paths
  will be built from source (because no substitute is available).

- `--system-filter` *system*

  By default, operations such as `--query --available` show derivations matching any platform. This option
  allows you to use derivations for the specified platform *system*.