1DUNE-DESCRIBE(1) Dune Manual DUNE-DESCRIBE(1)
2
3
4
6 dune-describe - Describe the workspace.
7
9 dune describe [OPTION]… [STRING]…
10
12 Describe what is in the current workspace in either human or machine
13 readable form. By default, this command output a human readable
14 description of the current workspace. This output is aimed at human and
15 is not suitable for machine processing. In particular, it is not
16 versioned. If you want to interpret the output of this command from a
17 program, you must use the --format option to specify a machine readable
18 format as well as the --lang option to get a stable output.
19
21 STRING
22 What to describe. The syntax of this description is tied to the
23 version passed to --lang. The currently available commands are the
24 following: workspace DIRS (prints a description of the workspace's
25 structure. If some directories DIRS are provided, then only those
26 directories of the workspace are considered.), opam-files (prints
27 information about the Opam files that have been discovered), pp
28 FILE (builds a given FILE and prints the preprocessed output),
29 external-lib-deps (Print out external libraries needed to build the
30 project. It's an approximated set of libraries.).
31
33 --action-stderr-on-success=VAL
34 Same as --action-stdout-on-success but for the standard output for
35 error messages. A good default for large mono-repositories is
36 --action-stdout-on-success=swallow
37 --action-stderr-on-success=must-be-empty. This ensures that a
38 successful build has a "clean" empty output.
39
40 --action-stdout-on-success=VAL
41 Specify how to deal with the standard output of actions when they
42 succeed. Possible values are: print to just print it to Dune's
43 output, swallow to completely ignore it and must-be-empty to
44 enforce that the action printed nothing. With must-be-empty, Dune
45 will consider that the action failed if it printed something to its
46 standard output. The default is print.
47
48 --build-info
49 Show build information.
50
51 --context=CONTEXT (absent=default)
52 Build context to use.
53
54 --error-reporting=VAL (absent=deterministic)
55 Controls when the build errors are reported. early - report errors
56 as soon as they are discovered. deterministic - report errors at
57 the end of the build in a deterministic order. twice - report each
58 error twice: once as soon as the error is discovered and then again
59 at the end of the build, in a deterministic order.
60
61 -f, --force
62 Force actions associated to aliases to be re-executed even if their
63 dependencies haven't changed.
64
65 --file-watcher=VAL (absent=automatic)
66 Mechanism to detect changes in the source. Automatic to make dune
67 run an external program to detect changes. Manual to notify dune
68 that files have changed manually."
69
70 --format=FORMAT (absent=sexp)
71 FORMAT must be either sexp or csexp
72
73 --lang=VERSION (absent=0.1)
74 Behave the same as this version of Dune.
75
76 --passive-watch-mode
77 Similar to [--watch], but only start a build when instructed
78 externally by an RPC.
79
80 --react-to-insignificant-changes
81 react to insignificant file system changes; this is only useful for
82 benchmarking dune
83
84 --sandbox=VAL (absent DUNE_SANDBOX env)
85 Sandboxing mode to use by default. Some actions require a certain
86 sandboxing mode, so they will ignore this setting. The allowed
87 values are: none, symlink, copy, hardlink.
88
89 --sanitize-for-tests
90 Sanitize the absolute paths in workspace items, and the associated
91 UIDs, so that the output is reproducible. For use in dune's
92 internal tests only (for the workspace command only).
93
94 -w, --watch
95 Instead of terminating build after completion, wait continuously
96 for file changes.
97
98 --wait-for-filesystem-clock
99 Dune digest file contents for better incrementally. These digests
100 are themselves cached. In some cases, Dune needs to drop some
101 digest cache entries in order for things to be reliable. This
102 option makes Dune wait for the file system clock to advance so that
103 it doesn't need to drop anything. You should probably not care
104 about this option; it is mostly useful for Dune developers to make
105 Dune tests of the digest cache more reproducible.
106
107 --with-deps
108 Whether the dependencies between modules should be printed (for the
109 workspace command only).
110
111 --with-pps
112 Whether the dependencies towards ppx-rewriters (that are called at
113 compile time) should be taken into account.
114
116 These options are common to all commands.
117
118 --always-show-command-line
119 Always show the full command lines of programs executed by dune
120
121 --auto-promote
122 Automatically promote files. This is similar to running dune
123 promote after the build.
124
125 --build-dir=FILE (absent DUNE_BUILD_DIR env)
126 Specified build directory. _build if unspecified
127
128 --cache=VAL (absent DUNE_CACHE env)
129 Enable or disable Dune cache (either enabled or disabled). Default
130 is `disabled'.
131
132 --cache-check-probability=VAL (absent DUNE_CACHE_CHECK_PROBABILITY env)
133 Check build reproducibility by re-executing randomly chosen rules
134 and comparing their results with those stored in Dune cache. Note:
135 by increasing the probability of such checks you slow down the
136 build. The default probability is zero, i.e. no rules are checked.
137
138 --cache-storage-mode=VAL (absent DUNE_CACHE_STORAGE_MODE env)
139 Dune cache storage mode (one of auto, hardlink or copy). Default is
140 `auto'.
141
142 --config-file=FILE
143 Load this configuration file instead of the default one.
144
145 --debug-artifact-substitution
146 Print debugging info about artifact substitution
147
148 --debug-backtraces
149 Always print exception backtraces.
150
151 --debug-cache=VAL
152 Show debug messages on cache misses for the given cache layers.
153 Value is a comma-separated list of cache layer names. All available
154 cache layers: shared,workspace-local,fs.
155
156 --debug-dependency-path
157 In case of error, print the dependency path from the targets on the
158 command line to the rule that failed.
159
160 --debug-digests
161 Explain why Dune decides to re-digest some files
162
163 --debug-load-dir
164 Print debugging info about directory loading
165
166 --debug-store-digest-preimage
167 Store digest preimage for all computed digests, so that it's
168 possible to reverse them later, for debugging. The digests are
169 stored in the shared cache (see --cache flag) as values, even if
170 cache is otherwise disabled. This should be used only for
171 debugging, since it's slow and it litters the shared cache.
172
173 --default-target=TARGET (absent=@@default)
174 Set the default target that when none is specified to dune build.
175
176 --diff-command=VAL (absent DUNE_DIFF_COMMAND env)
177 Shell command to use to diff files. Use - to disable printing the
178 diff.
179
180 --disable-promotion (absent DUNE_DISABLE_PROMOTION env)
181 Disable all promotion rules
182
183 --display=MODE
184 Control the display mode of Dune. See dune-config(5) for more
185 details. Valid values for this option are One of progress, verbose,
186 short or quiet
187
188 --dump-memo-graph=FILE
189 Dumps the dependency graph to a file after the build is complete
190
191 --dump-memo-graph-format=FORMAT (absent=gexf)
192 File format to be used when dumping dependency graph
193
194 --dump-memo-graph-with-timing
195 With --dump-memo-graph, will re-run each cached node in the Memo
196 graph after building and include the runtime in the output. Since
197 all nodes contain a cached value, this will measure just the
198 runtime of each node
199
200 --help[=FMT] (default=auto)
201 Show this help in format FMT. The value FMT must be one of auto,
202 pager, groff or plain. With auto, the format is pager or plain
203 whenever the TERM env var is dumb or undefined.
204
205 --ignore-promoted-rules
206 Ignore rules with (mode promote), except ones with (only ...). The
207 variable %{ignoring_promoted_rules} in dune files reflects whether
208 this option was passed or not.
209
210 --instrument-with=BACKENDS (absent DUNE_INSTRUMENT_WITH env)
211 "Enable instrumentation by BACKENDS. BACKENDS is a comma-separated
212 list of library names, each one of which must declare an
213 instrumentation backend.
214
215 -j JOBS
216 Run no more than JOBS commands simultaneously.
217
218 --no-buffer
219 Do not buffer the output of commands executed by dune. By default
220 dune buffers the output of subcommands, in order to prevent
221 interleaving when multiple commands are executed in parallel.
222 However, this can be an issue when debugging long running tests.
223 With --no-buffer, commands have direct access to the terminal. Note
224 that as a result their output won't be captured in the log file.
225 You should use this option in conjunction with -j 1, to avoid
226 interleaving. Additionally you should use --verbose as well, to
227 make sure that commands are printed before they are being executed.
228
229 --no-config
230 Do not load the configuration file
231
232 --no-print-directory
233 Suppress "Entering directory" messages
234
235 --only-packages=PACKAGES
236 Ignore stanzas referring to a package that is not in PACKAGES.
237 PACKAGES is a comma-separated list of package names. Note that this
238 has the same effect as deleting the relevant stanzas from dune
239 files. It is mostly meant for releases. During development, it is
240 likely that what you want instead is to build a particular
241 <package>.install target.
242
243 -p PACKAGES, --for-release-of-packages=PACKAGES (required)
244 Shorthand for --release --only-packages PACKAGE. You must use this
245 option in your <package>.opam files, in order to build only what's
246 necessary when your project contains multiple packages as well as
247 getting reproducible builds.
248
249 --print-metrics
250 Print out various performance metrics after every build
251
252 --profile=VAL (absent DUNE_PROFILE env)
253 Select the build profile, for instance dev or release. The default
254 is dev.
255
256 --promote-install-files[=VAL] (default=true)
257 Promote the generated <package>.install files to the source tree
258
259 --release
260 Put dune into a reproducible release mode. This is in fact a
261 shorthand for --root . --ignore-promoted-rules --no-config
262 --profile release --always-show-command-line
263 --promote-install-files --default-target @install
264 --require-dune-project-file. You should use this option for release
265 builds. For instance, you must use this option in your
266 <package>.opam files. Except if you already use -p, as -p implies
267 this option.
268
269 --require-dune-project-file[=VAL] (default=true)
270 Fail if a dune-project file is missing.
271
272 --root=DIR
273 Use this directory as workspace root instead of guessing it. Note
274 that this option doesn't change the interpretation of targets given
275 on the command line. It is only intended for scripts.
276
277 --store-orig-source-dir (absent DUNE_STORE_ORIG_SOURCE_DIR env)
278 Store original source location in dune-package metadata
279
280 --terminal-persistence=MODE
281 Changes how the log of build results are displayed to the console
282 between rebuilds while in --watch mode. Supported modes: preserve,
283 clear-on-rebuild, clear-on-rebuild-and-flush-history.
284
285 --trace-file=FILE
286 Output trace data in catapult format (compatible with
287 chrome://tracing)
288
289 --verbose
290 Same as --display verbose
291
292 --version
293 Show version information.
294
295 --workspace=FILE (absent DUNE_WORKSPACE env)
296 Use this specific workspace file instead of looking it up.
297
298 -x VAL
299 Cross-compile using this toolchain.
300
302 Use `dune COMMAND --help' for help on a single command.
303
305 describe exits with the following status:
306
307 0 on success.
308
309 123 on indiscriminate errors reported on standard error.
310
311 124 on command line parsing errors.
312
313 125 on unexpected internal errors (bugs).
314
316 These environment variables affect the execution of describe:
317
318 DUNE_BUILD_DIR
319 Specified build directory. _build if unspecified
320
321 DUNE_CACHE
322 Enable or disable Dune cache (either enabled or disabled). Default
323 is `disabled'.
324
325 DUNE_CACHE_CHECK_PROBABILITY
326 Check build reproducibility by re-executing randomly chosen rules
327 and comparing their results with those stored in Dune cache. Note:
328 by increasing the probability of such checks you slow down the
329 build. The default probability is zero, i.e. no rules are checked.
330
331 DUNE_CACHE_STORAGE_MODE
332 Dune cache storage mode (one of auto, hardlink or copy). Default is
333 `auto'.
334
335 DUNE_DIFF_COMMAND
336 Shell command to use to diff files. Use - to disable printing the
337 diff.
338
339 DUNE_DISABLE_PROMOTION
340 Disable all promotion rules
341
342 DUNE_INSTRUMENT_WITH
343 "Enable instrumentation by BACKENDS. BACKENDS is a comma-separated
344 list of library names, each one of which must declare an
345 instrumentation backend.
346
347 DUNE_PROFILE
348 Build profile. dev if unspecified or release if -p is set.
349
350 DUNE_SANDBOX
351 Sandboxing mode to use by default. (see --sandbox)
352
353 DUNE_STORE_ORIG_SOURCE_DIR
354 Store original source location in dune-package metadata
355
356 DUNE_WORKSPACE
357 Use this specific workspace file instead of looking it up.
358
360 Check bug reports at https://github.com/ocaml/dune/issues
361
363 dune(1)
364
365
366
367Dune n/a DUNE-DESCRIBE(1)