1DUNE(1)                           Dune Manual                          DUNE(1)
2
3
4

NAME

6       dune - composable build system for OCaml
7

SYNOPSIS

9       dune build [--watch]
10       dune runtest [--watch]
11       dune exec NAME
12       dune utop [DIR]
13       dune install
14       dune init project NAME [PATH] [--libs=l1,l2 --ppx=p1,p2 --inline-tests]
15

DESCRIPTION

17       Dune is a build system designed for OCaml projects only. It focuses on
18       providing the user with a consistent experience and takes care of most
19       of the low-level details of OCaml compilation. All you have to do is
20       provide a description of your project and Dune will do the rest.
21
22       The scheme it implements is inspired from the one used inside Jane
23       Street and adapted to the open source world. It has matured over a long
24       time and is used daily by hundreds of developers, which means that it
25       is highly tested and productive.
26

COMMAND ALIASES

28       printenv [OPTION]… [PATH]
29           An alias for env.
30
31       promote [OPTION]… [FILE]…
32           An alias for promotion apply.
33
34       test [OPTION]… [DIR]…
35           An alias for runtest.
36

COMMANDS

38       build [OPTION]… [TARGET]…
39           Build the given targets, or the default ones if none are given.
40
41       cache COMMAND …
42           Manage Dune's shared cache of build artifacts.
43
44       clean [OPTION]…
45           Clean the project.
46
47       coq COMMAND …
48           Command group related to Coq.
49
50       describe [COMMAND] …
51           Describe the workspace.
52
53       diagnostics [OPTION]…
54           Fetch and return errors from the current build.
55
56       exec [OPTION]… PROG [ARGS]…
57           Execute a command in a similar environment as if installation was
58           performed.
59
60       external-lib-deps [OPTION]… [TARGET]…
61           Moved to dune describe external-lib-deps.
62
63       fmt [OPTION]…
64           Format source code.
65
66       format-dune-file [--dune-version=VERSION] [OPTION]… [FILE]
67           Format dune files.
68
69       help [--build-info] [--man-format=FMT] [OPTION]… [TOPIC]
70           Additional Dune help.
71
72       init COMMAND …
73           Command group for initializing Dune components.
74
75       install [OPTION]… [PACKAGE]…
76           Install packages defined in the workspace.
77
78       installed-libraries [OPTION]…
79           Print out libraries installed on the system.
80
81       internal COMMAND …
82
83
84       ocaml COMMAND …
85           Command group related to OCaml.
86
87       ocaml-merlin [OPTION]…
88           Start a merlin configuration server.
89
90       pkg COMMAND …
91           Experimental package management
92
93       promotion COMMAND …
94           Control how changes are propagated back to source code.
95
96       rpc COMMAND …
97           Dune's RPC mechanism. Experimental.
98
99       rules [OPTION]… [TARGET]…
100           Dump rules.
101
102       runtest [OPTION]… [DIR]…
103           Run tests.
104
105       show COMMAND …
106           Command group for showing information about the workspace
107
108       shutdown [OPTION]…
109           Cancel and shutdown any builds in the current workspace.
110
111       subst [--build-info] [OPTION]…
112           Substitute watermarks in source files.
113
114       top [OPTION]… [DIR]
115           Print a list of toplevel directives for including directories and
116           loading cma files.
117
118       uninstall [OPTION]… [PACKAGE]…
119           Uninstall packages defined in the workspace.
120
121       upgrade [OPTION]…
122           Upgrade projects across major Dune versions.
123
124       utop [OPTION]… [DIR] [ARGS]…
125           Load library in utop.
126

COMMON OPTIONS

128       These options are common to all commands.
129
130       --help[=FMT] (default=auto)
131           Show this help in format FMT. The value FMT must be one of auto,
132           pager, groff or plain. With auto, the format is pager or plain
133           whenever the TERM env var is dumb or undefined.
134
135       --version
136           Show version information.
137

MORE HELP

139       Use `dune COMMAND --help' for help on a single command.
140

EXIT STATUS

142       dune exits with the following status:
143
144       0   on success.
145
146       1   if an error happened.
147
148       130 if it was interrupted by a signal.
149

ENVIRONMENT

151       These environment variables affect the execution of dune:
152
153       CLICOLOR
154           If different than 0, ANSI colors are supported and should be used
155           when the program isn’t piped. If equal to 0, don’t output ANSI
156           color escape codes
157
158       CLICOLOR_FORCE
159           If different than 0, ANSI colors should be enabled no matter what.
160

BUGS

162       Check bug reports at https://github.com/ocaml/dune/issues
163

EXAMPLES

165       1.  Initialise a new project named `foo':
166
167             dune init project foo
168
169       2.  Build all targets in the current source tree:
170
171             dune build
172
173       3.  Run the executable named `bar':
174
175             dune exec bar
176
177       4.  Run all tests in the current source tree:
178
179             dune runtest
180
181       5.  Install all components defined in the project:
182
183             dune install
184
185       6.  Remove all build artefacts:
186
187             dune clean
188
189
190
191Dune n/a                                                               DUNE(1)
Impressum