1OPAM-SHOW(1) Opam Manual OPAM-SHOW(1)
2
3
4
6 opam-show - Display information about specific packages.
7
9 opam show [OPTION]... [PACKAGES]...
10
12 This command displays the information block for the selected
13 package(s).
14
15 The information block consists of the name of the package, the
16 installed version if this package is installed in the currently
17 selected compiler, the list of available (installable) versions, and a
18 complete description.
19
20 opam list can be used to display the list of available packages as well
21 as a short description for each.
22
23 Paths to package definition files or to directories containing package
24 definitions can also be specified, in which case the corresponding
25 metadata will be shown.
26
28 PACKAGES
29 List of package names, with an optional version or constraint, e.g
30 `pkg', `pkg.1.0' or `pkg>=0.5' ; or files or directory names
31 containing package description, with explicit directory (e.g.
32 `./foo.opam' or `.')
33
35 --empty-fields
36 Show fields that are empty. This is implied when --field is given.
37
38 -f FIELDS, --field=FIELDS
39 Only display the values of these fields. Fields can be selected
40 among name, version, package, synopsis, synopsis-or-target,
41 description, <field>:, installed-version, pin, source-hash,
42 opam-file, all-installed-versions, available-versions,
43 all-versions, repository, installed-files, vc-ref, depexts.
44 Multiple fields can be separated with commas, in which case field
45 titles will be printed; the raw value of any opam-file field can be
46 queried by suffixing a colon character (:), e.g. --field=depopts:.
47
48 --file=FILE
49 DEPRECATED: use an explicit path argument as package instead. Get
50 package information from the given FILE instead of from known
51 packages. This implies --raw unless --fields is used. Only raw
52 opam-file fields can be queried.
53
54 --list-files
55 List the files installed by the package. Equivalent to
56 --field=installed-files, and only available for installed packages
57
58 --no-lint
59 Don't output linting warnings or errors when reading from files
60
61 --normalise
62 Print the values of opam fields normalised (no newlines, no
63 implicit brackets)
64
65 --raw
66 Print the raw opam file for this package
67
68 --where
69 Print the location of the opam file used for this package
70
72 These options are common to all commands.
73
74 --best-effort
75 Don't fail if all requested packages can't be installed: try to
76 install as many as possible. Note that not all external solvers may
77 support this option (recent versions of aspcud or mccs should).
78 This is equivalent to setting $OPAMBESTEFFORT environment variable.
79
80 --color=WHEN
81 Colorize the output. WHEN must be one of `always', `never' or
82 `auto'.
83
84 --criteria=CRITERIA
85 Specify user preferences for dependency solving for this run.
86 Overrides both $OPAMCRITERIA and $OPAMUPGRADECRITERIA. For details
87 on the supported language, and the external solvers available, see
88 http://opam.ocaml.org/doc/External_solvers.html. A general guide to
89 using solver preferences can be found at
90 http://www.dicosmo.org/Articles/usercriteria.pdf.
91
92 --cudf=FILENAME
93 Debug option: Save the CUDF requests sent to the solver to
94 FILENAME-<n>.cudf.
95
96 --debug
97 Print debug message to stderr. This is equivalent to setting
98 $OPAMDEBUG to "true".
99
100 --debug-level=LEVEL
101 Like --debug, but allows specifying the debug level (--debug sets
102 it to 1). Equivalent to setting $OPAMDEBUG to a positive integer.
103
104 --git-version
105 Print the git version of opam, if set (i.e. you are using a
106 development version), and exit.
107
108 --help[=FMT] (default=auto)
109 Show this help in format FMT. The value FMT must be one of `auto',
110 `pager', `groff' or `plain'. With `auto', the format is `pager` or
111 `plain' whenever the TERM env var is `dumb' or undefined.
112
113 --ignore-pin-depends
114 Ignore extra pins required by packages that get pinned, either
115 manually through opam pin or through opam install DIR. This is
116 equivalent to setting IGNOREPINDEPENDS=true.
117
118 --json=FILENAME
119 Save the results of the opam run in a computer-readable file. If
120 the filename contains the character `%', it will be replaced by an
121 index that doesn't overwrite an existing file. Similar to setting
122 the $OPAMJSON variable.
123
124 --no-aspcud
125 Deprecated.
126
127 --no-auto-upgrade
128 When configuring or updating a repository that is written for an
129 earlier opam version (1.2), opam internally converts it to the
130 current format. This disables this behaviour. Note that
131 repositories should define their format version in a 'repo' file at
132 their root, or they will be assumed to be in the older format. It
133 is, in any case, preferable to upgrade the repositories manually
134 using opam admin upgrade [--mirror URL] when possible.
135
136 --no-self-upgrade
137 Opam will replace itself with a newer binary found at OPAMROOT/opam
138 if present. This disables this behaviour.
139
140 -q, --quiet
141 Disables --verbose.
142
143 --root=ROOT
144 Use ROOT as the current root path. This is equivalent to setting
145 $OPAMROOT to ROOT.
146
147 --safe, --readonly
148 Make sure nothing will be automatically updated or rewritten.
149 Useful for calling from completion scripts, for example. Will fail
150 whenever such an operation is needed ; also avoids waiting for
151 locks, skips interactive questions and overrides the $OPAMDEBUG
152 variable. This is equivalent to set environment variable $OPAMSAFE.
153
154 --solver=CMD
155 Specify the CUDF solver to use for resolving package installation
156 problems. This is either a predefined solver (this version of opam
157 supports builtin-mccs+lp(), builtin-mccs+glpk, aspcud, mccs,
158 aspcud-old, packup), or a custom command that should contain the
159 variables %{input}%, %{output}%, %{criteria}%, and optionally
160 %{timeout}%. This is equivalent to setting $OPAMEXTERNALSOLVER.
161
162 --strict
163 Fail whenever an error is found in a package definition or a
164 configuration file. The default is to continue silently if
165 possible.
166
167 --switch=SWITCH
168 Use SWITCH as the current compiler switch. This is equivalent to
169 setting $OPAMSWITCH to SWITCH.
170
171 --use-internal-solver
172 Disable any external solver, and use the built-in one (this
173 requires that opam has been compiled with a built-in solver). This
174 is equivalent to setting $OPAMNOASPCUD or $OPAMUSEINTERNALSOLVER.
175
176 -v, --verbose
177 Be more verbose. One -v shows all package commands, repeat to also
178 display commands called internally (e.g. tar, curl, patch etc.)
179 Repeating n times is equivalent to setting $OPAMVERBOSE to "n".
180
181 --version
182 Show version information.
183
184 -w, --working-dir
185 Whenever updating packages that are bound to a local,
186 version-controlled directory, update to the current working state
187 of their source instead of the last committed state, or the ref
188 they are pointing to. This only affects packages explicitly listed
189 on the command-line.It can also be set with $OPAMWORKINGDIR.
190
191 -y, --yes
192 Answer yes to all yes/no questions without prompting. This is
193 equivalent to setting $OPAMYES to "true".
194
196 Opam makes use of the environment variables listed here. Boolean
197 variables should be set to "0", "no", "false" or the empty string to
198 disable, "1", "yes" or "true" to enable.
199
200 OPAMALLPARENS surround all filters with parenthesis
201
202 OPAMAUTOREMOVE see remove option `--auto-remove`
203
204 OPAMBESTEFFORT see option `--best-effort`
205
206 OPAMBESTEFFORTPREFIXCRITERIA sets the string that must be prepended to
207 the criteria when the `--best-effort` option is set, and is expected to
208 maximise the `opam-query` property in the solution
209
210 OPAMCOLOR, when set to always or never, sets a default value for the
211 --color option.
212
213 OPAMCRITERIA specifies user preferences for dependency solving. The
214 default value depends on the solver version, use `config report` to
215 know the current setting. See also option --criteria
216
217 OPAMCUDFFILE file save the cudf graph to file-actions-explicit.dot
218
219 OPAMCURL can be used to select a given 'curl' program. See OPAMFETCH
220 for more options.
221
222 OPAMDEBUG see options `--debug' and `--debug-level'.
223
224 OPAMDOWNLOADJOBS sets the maximum number of simultaneous downloads.
225
226 OPAMDRYRUN see option `--dry-run`
227
228 OPAMEDITOR sets the editor to use for opam file editing, overrides
229 $EDITOR and $VISUAL
230
231 OPAMERRLOGLEN sets the number of log lines printed when a sub-process
232 fails. 0 to print all.
233
234 OPAMEXTERNALSOLVER see option `--solver'.
235
236 OPAMFAKE see option `--fake`
237
238 OPAMFETCH specifies how to download files: either `wget', `curl' or a
239 custom command where variables %{url}%, %{out}%, %{retry}%,
240 %{compress}% and %{checksum}% will be replaced. Overrides the
241 'download-command' value from the main config file.
242
243 OPAMFIXUPCRITERIA same as OPAMUPGRADECRITERIA, but specific to fixup
244
245 OPAMIGNORECONSTRAINTS see install option `--ignore-constraints-on`
246
247 OPAMIGNOREPINDEPENDS see option `--ignore-pin-depends`
248
249 OPAMJOBS sets the maximum number of parallel workers to run.
250
251 OPAMJSON log json output to the given file (use character `%' to index
252 the files)
253
254 OPAMLOCKED see install option `--locked`
255
256 OPAMLOGS logdir sets log directory, default is a temporary directory in
257 /tmp
258
259 OPAMMAKECMD set the system make command to use
260
261 OPAMNOAUTOUPGRADE disables automatic internal upgrade of repositories
262 in an earlier format to the current one, on 'update' or 'init'.
263
264 OPAMKEEPLOGS tells opam to not remove some temporary command logs and
265 some backups. This skips some finalisers and may also help to get more
266 reliable backtraces
267
268 OPAMLOCKRETRIES sets the number of tries after which opam gives up
269 acquiring its lock and fails. <= 0 means infinite wait.
270
271 OPAMMERGEOUT merge process outputs, stderr on stdout
272
273 OPAMNO answer no to any question asked.
274
275 OPAMNOASPCUD Deprecated.
276
277 OPAMNOCHECKSUMS enables option --no-checksums when available.
278
279 OPAMNOSELFUPGRADE see option `--no-self-upgrade'.
280
281 OPAMPINKINDAUTO sets whether version control systems should be detected
282 when pinning to a local path. Enabled by default since 1.3.0.
283
284 OPAMPRECISETRACKING fine grain tracking of directories
285
286 OPAMREQUIRECHECKSUMS Enables option `--require-checksums' when
287 available (e.g. for `opam install`).
288
289 OPAMRETRES sets the number of tries before failing downloads.
290
291 OPAMROOT see option `--root'. This is automatically set by `opam env
292 --root=DIR --set-root'.
293
294 OPAMROOTISOK don't complain when running as root.
295
296 OPAMSAFE see option `--safe'
297
298 OPAMSHOW see option `--show`
299
300 OPAMSKIPUPDATE see option `--skip-updates`
301
302 OPAMSKIPVERSIONCHECKS bypasses some version checks. Unsafe, for
303 compatibility testing only.
304
305 OPAMSOLVERTIMEOUT change the time allowance of the solver. Default is
306 60.0, set to 0 for unlimited. Note that all solvers may not support
307 this option.
308
309 OPAMSTATUSLINE display a dynamic status line showing what's currently
310 going on on the terminal. (one of one of `always', `never' or `auto')
311
312 OPAMSTATS display stats at the end of command
313
314 OPAMSTRICT fail on inconsistencies (file reading, switch import, etc.)
315
316 OPAMSWITCH see option `--switch'. Automatically set by `opam env
317 --switch=SWITCH --set-switch'.
318
319 OPAMUNLOCKBASE see install option `--unlock-base`
320
321 OPAMUPGRADECRITERIA specifies user preferences for dependency solving
322 when performing an upgrade. Overrides OPAMCRITERIA in upgrades if both
323 are set. See also option --criteria
324
325 OPAMUSEINTERNALSOLVER see option `--use-internal-solver'.
326
327 OPAMUSEOPENSSL force openssl use for hash computing
328
329 OPAMUTF8 use UTF8 characters in output (one of one of `always', `never'
330 or `auto'). By default `auto', which is determined from the locale).
331
332 OPAMUTF8MSGS use extended UTF8 characters (camels) in opam messages.
333 Implies OPAMUTF8. This is set by default on OSX only.
334
335 OPAMVALIDATIONHOOK hook if set, uses the `%{hook%}` command to validate
336 an opam repository update
337
338 OPAMVAR_var overrides the contents of the variable var when
339 substituting `%{var}%` strings in `opam` files.
340
341 OPAMVAR_package_var overrides the contents of the variable package:var
342 when substituting `%{package:var}%` strings in `opam` files.
343
344 OPAMVERBOSE see option `--verbose'.
345
346 OPAMWORKINGDIR see option `--working-dir`
347
348 OPAMYES see option `--yes'.
349
351 As an exception to the following, the `exec' command returns 127 if the
352 command was not found or couldn't be executed, and the command's exit
353 value otherwise.
354
355 0 Success, or true for boolean queries.
356
357 1 False. Returned when a boolean return value is expected, e.g. when
358 running with --check, or for queries like opam lint.
359
360 2 Bad command-line arguments, or command-line arguments pointing to
361 an invalid context (e.g. file not following the expected format).
362
363 5 Not found. You requested something (package, version, repository,
364 etc.) that couldn't be found.
365
366 10 Aborted. The operation required confirmation, which wasn't given.
367
368 15 Could not acquire the locks required for the operation.
369
370 20 There is no solution to the user request. This can be caused by
371 asking to install two incompatible packages, for example.
372
373 30 Error in package definition, or other metadata files. Using
374 --strict raises this error more often.
375
376 31 Package script error. Some package operations were unsuccessful.
377 This may be an error in the packages or an incompatibility with
378 your system. This can be a partial error.
379
380 40 Sync error. Could not fetch some remotes from the network. This can
381 be a partial error.
382
383 50 Configuration error. Opam or system configuration doesn't allow
384 operation, and needs fixing.
385
386 60 Solver failure. The solver failed to return a sound answer. It can
387 be due to a broken external solver, or an error in solver
388 configuration.
389
390 99 Internal error. Something went wrong, likely due to a bug in opam
391 itself.
392
393 130 User interrupt. SIGINT was received, generally due to the user
394 pressing Ctrl-C.
395
397 See https://opam.ocaml.org/doc.
398
400 Vincent Bernardoff <vb@luminar.eu.org>
401 Raja Boujbel <raja.boujbel@ocamlpro.com>
402 Roberto Di Cosmo <roberto@dicosmo.org>
403
404 Thomas Gazagnaire <thomas@gazagnaire.org>
405 Louis Gesbert <louis.gesbert@ocamlpro.com>
406 Fabrice Le Fessant <Fabrice.Le_fessant@inria.fr>
407 Anil Madhavapeddy <anil@recoil.org>
408 Guillem Rieu <guillem.rieu@ocamlpro.com>
409 Ralf Treinen <ralf.treinen@pps.jussieu.fr>
410 Frederic Tuong <tuong@users.gforge.inria.fr>
411
413 Check bug reports at https://github.com/ocaml/opam/issues.
414
415
416
417Opam 2.0.6 OPAM-SHOW(1)