| 1 |
$ mkdir bin |
| 2 |
$ ln -s $(which ocaml_index) bin/ocaml-index |
| 3 |
$ export PATH=bin:$PATH |
| 4 |
|
| 5 |
$ dune exec ./main.exe |
| 6 |
1564242 |
| 7 |
|
| 8 |
The @check alias does not build indexes: |
| 9 |
(it might at some point if the process becomes fast-enough) |
| 10 |
|
| 11 |
$ dune build @check |
| 12 |
|
| 13 |
$ find . -name '*.ocaml-index' | sort |
| 14 |
|
| 15 |
The @ocaml-index indexes the entire workspace, including librairies that might |
| 16 |
not be directly used and thus usually not built by @check: |
| 17 |
|
| 18 |
$ dune build @ocaml-index |
| 19 |
|
| 20 |
$ find . -name '*.ocaml-index' | sort |
| 21 |
./_build/default/.main.eobjs/cctx.ocaml-index |
| 22 |
./_build/default/implicit-lib/.imp_lib.objs/cctx.ocaml-index |
| 23 |
./_build/default/lib/.otherlib.objs/cctx.ocaml-index |
| 24 |
./_build/default/private-module/.pmodlib.objs/cctx.ocaml-index |
| 25 |
./_build/default/sub-project/.subprojectlib.objs/cctx.ocaml-index |
| 26 |
./_build/default/vendor/otherproject/.private_lib.objs/cctx.ocaml-index |
| 27 |
./_build/default/vendor/otherproject/.vendored_lib.objs/cctx.ocaml-index |
| 28 |
|
| 29 |
|
| 30 |
$ FILE=$PWD/main.ml |
| 31 |
$ printf "(4:File%d:%s)" ${#FILE} $FILE | dune ocaml-merlin | |
| 32 |
> sed -E "s/[[:digit:]]+:/\?:/g" | tr '(' '\n' | grep ":INDEX?" |
| 33 |
?:INDEX?:$TESTCASE_ROOT/_build/default/.main.eobjs/cctx.ocaml-index) |
| 34 |
?:INDEX?:$TESTCASE_ROOT/_build/default/implicit-lib/.imp_lib.objs/cctx.ocaml-index) |
| 35 |
?:INDEX?:$TESTCASE_ROOT/_build/default/lib/.otherlib.objs/cctx.ocaml-index) |
| 36 |
?:INDEX?:$TESTCASE_ROOT/_build/default/private-module/.pmodlib.objs/cctx.ocaml-index) |
| 37 |
?:INDEX?:$TESTCASE_ROOT/_build/default/sub-project/.subprojectlib.objs/cctx.ocaml-index) |
| 38 |
?:INDEX?:$TESTCASE_ROOT/_build/default/vendor/otherproject/.private_lib.objs/cctx.ocaml-index) |
| 39 |
?:INDEX?:$TESTCASE_ROOT/_build/default/vendor/otherproject/.vendored_lib.objs/cctx.ocaml-index) |