Skip to content

4ever2/dune-ocaml-sample

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sample project in OCaml using Dune

Building

To build the project using Dune you can run

dune build

This will build the project, the compiled files are located in the /_build/default/ directory.

During development, you can use dune watch mode

dune build --watch

This will rebuild the project every time you modify and save a project file.

We can run the executable from the project using

dune exec ex_main

Running tests can be done with the command

dune test

Project structure

The project includes three subparts

  • lib a folder defining a library
  • bin a folder containing an executable that uses the library defined in lib
  • test a folder containing tests of the library defined in lib

Each folder contains a dune file, describing how the project should be built. The dune-project is the main dune file. It specifies metadata about the project.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published