Skip to content

Commit 299859f

Browse files
committed
Update test and documentation
Signed-off-by: Ulysse Gérard <[email protected]>
1 parent 8e8fafa commit 299859f

File tree

2 files changed

+13
-8
lines changed
  • doc
  • test/blackbox-tests/test-cases/merlin/dump-dot-merlin.t

2 files changed

+13
-8
lines changed

doc/usage.rst

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -549,7 +549,10 @@ Querying Merlin configuration
549549
Since version 2.8 Dune does not promote ``.merlin`` files to the source
550550
directories any more. Instead these configurations are stored in the `_build`
551551
folder and Merlin communicates directly with Dune to obtain its configuration
552-
via the `ocaml-merlin` subcommand.
552+
via the `ocaml-merlin` subcommand. The Merlin configuration is now stanza
553+
specific allowing finer control. The following commands are not needed for
554+
normal use of Dune and Merlin but can provide insightful informations when
555+
debugging or configuring non-standard projects.
553556

554557
Printing the configuration
555558
--------------------------
@@ -574,14 +577,16 @@ Merlin configuration syntax by running the following command:
574577

575578
::
576579

577-
$ dune ocaml-merlin --dump-dot-merlin > .merlin
580+
$ dune ocaml dump-dot-merlin > .merlin
578581

579582
In that case only one configuration will be printed which is the result of a
580583
coarse merge of the configurations of the various modules present in the current
581584
folder. This folder must be in a Dune workspace and the project must be already
582585
built. Preprocessing directives and other flags will be commented out and must
583-
be un-commented afterward.
586+
be un-commented afterward. This feature does not aim at writing exact or correct
587+
``.merlin`` files, its sole purpose is to lessen the burden of writing the
588+
configuration from scratch.
584589

585-
Both these commands also support an optional argument to specify the target
586-
directory. This directory must be in a Dune workspace and the project must be
587-
already built.
590+
Both these commands also support an optional path to specify the target
591+
directory. This directory must be in a Dune workspace and the project must have
592+
already been built.

test/blackbox-tests/test-cases/merlin/dump-dot-merlin.t/run.t

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
$ dune build
2-
$ dune ocaml-merlin --dump-dot-merlin
2+
$ dune ocaml dump-dot-merlin
33

44
EXCLUDE_QUERY_DIR
55
B $TESTCASE_ROOT/_build/default/.foo.eobjs/byte
66
S $TESTCASE_ROOT
77
# FLG -pp $TESTCASE_ROOT/_build/default/pp/pp.exe
88
# FLG -open Dune__exe -w @[email protected]@30..39@[email protected]@[email protected] -strict-sequence -strict-formats -short-paths -keep-locs
99
10-
$ dune ocaml-merlin --dump-dot-merlin="pp"
10+
$ dune ocaml dump-dot-merlin "pp"
1111

1212
EXCLUDE_QUERY_DIR
1313
B $TESTCASE_ROOT/_build/default/pp/.pp.eobjs/byte

0 commit comments

Comments
 (0)