我是 OCaml 的新手,我按照教程设置了开发环境。然后我用 dune 和 OCaml尝试了helloworld示例,但遇到了以下错误:
$ dune init exe helloworld
Success: initialized executable component named helloworld
$ dune build
Error: I cannot find the root of the current workspace/project.
If you would like to create a new dune project, you can type:
dune init project NAME
Otherwise, please make sure to run dune inside an existing project or
workspace. For more information about how dune identifies the root of the
current workspace/project, please refer to
https://dune.readthedocs.io/en/stable/usage.html#finding-the-root
目录结构:
.
├── _build
│ └── log
├── dune
└── helloworld.ml
沙丘:3.0.2
ocaml:4.11.1