-
Notifications
You must be signed in to change notification settings - Fork 413
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[merlin] Add command to dump generic config in dot merlin syntax (#4250)
* Add merging and dot merlin printing to Merlin module * Add test illustrating the new behavior * Make `dump-dot-merlin` a sub command of the ocaml group * Make path optional for --dump-config * Add documentation for `dune ocaml-merlin` commands Signed-off-by: Ulysse Gérard <[email protected]>
- Loading branch information
Showing
18 changed files
with
227 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,5 @@ | ||
val command : unit Cmdliner.Term.t * Cmdliner.Term.info | ||
|
||
module Dump_dot_merlin : sig | ||
val command : unit Cmdliner.Term.t * Cmdliner.Term.info | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
test/blackbox-tests/test-cases/merlin/dump-dot-merlin.t/dune-project
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
(lang dune 2.8) |
2 changes: 2 additions & 0 deletions
2
test/blackbox-tests/test-cases/merlin/dump-dot-merlin.t/p p/dune
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
(executable | ||
(name pp)) |
Empty file.
18 changes: 18 additions & 0 deletions
18
test/blackbox-tests/test-cases/merlin/dump-dot-merlin.t/run.t
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
$ dune build | ||
$ dune ocaml dump-dot-merlin src\ with\ spaces | | ||
> sed 's#'$(opam config var prefix)'#OPAM_PREFIX#' | ||
EXCLUDE_QUERY_DIR | ||
STDLIB OPAM_PREFIX/lib/ocaml | ||
B $TESTCASE_ROOT/_build/default/src with spaces/.foo.eobjs/byte | ||
S $TESTCASE_ROOT/src with spaces | ||
# FLG -pp ''\''$TESTCASE_ROOT/_build/default/p p/pp.exe'\''' | ||
# FLG -open Dune__exe -w @[email protected]@30..39@[email protected]@[email protected] -strict-sequence -strict-formats -short-paths -keep-locs | ||
$ dune ocaml dump-dot-merlin "p p" | | ||
> sed 's#'$(opam config var prefix)'#OPAM_PREFIX#' | ||
EXCLUDE_QUERY_DIR | ||
STDLIB OPAM_PREFIX/lib/ocaml | ||
B $TESTCASE_ROOT/_build/default/p p/.pp.eobjs/byte | ||
S $TESTCASE_ROOT/p p | ||
# FLG -w @[email protected]@30..39@[email protected]@[email protected] -strict-sequence -strict-formats -short-paths -keep-locs | ||
Empty file.
3 changes: 3 additions & 0 deletions
3
test/blackbox-tests/test-cases/merlin/dump-dot-merlin.t/src with spaces/dune
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
(executables (names foo bar) | ||
(preprocess (per_module | ||
((action (run "p p/pp.exe"%{input-file})) bar)))) |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters