dune utop some executable

785 views Asked by At

For an single file executable, how can I load it in dune utop ?

Precisely, on a project with a library in a directory lib and a corresponding dune file, I can launch dune utop lib then open Lib.MyModule and this will load the file MyModule.ml.

What would be the equivalent for a project with no subdirectory, and the following files at its root, a dune file

(executable
  (name auth)
  (libraries ezjsonm cryptokit))

and a file auth.ml

let hi = "value"

where I would like to load the values from that file in dune utop

1

There are 1 answers

0
Louis Roché On BEST ANSWER

This is not supported by dune currently. You need to have a lib to use dune utop. It is a bit unfortunate.