You need Opam, you can install it by following Opam's documentation.
With Opam installed, you can install the dependencies in a new local switch with:
opam switch create . --locked --lock-suffix=dev.locked --with-test --with-doc
Then, build the project with:
dune build
If you update the dependencies in dune-project
run
dune build
to update the opam file, then run (but doesn't really work cf ocaml/opam#5178)
opam reinstall --working-dir --with-doc --with-test .
to sync the dependencies with your switch and finally
opam lock --lock-suffix=dev.locked .
to update the lock file.
After building the project, you can run the main binary that is produced.
dune exec stork
You can run the test compiled executable:
dune test
You can then accept the correction of the cram tests with:
dune promote
The following snippet describes Stork's repository structure.
.
├── .github/
| Contains GitHub specific files such as actions definitions and issue templates.
│
├── bin/
| Source for Stork's binary. This links to the library defined in `lib/`.
│
├── lib/
| Source for Stork's library. Contains Stork's core functionalities.
│
├── test/
| Unit tests and integration tests for Stork.
│
├── dune-project
| Dune file used to mark the root of the project and define project-wide parameters.
| For the documentation of the syntax, see https://dune.readthedocs.io/en/stable/dune-files.html#dune-project
│
├── LICENSE
│
├── README.md
|
├── stork.opam
| Opam package definition.
| To know more about creating and publishing opam packages, see https://opam.ocaml.org/doc/Packaging.html
|
└── stork.opam.dev.locked
Opam lock file, to be used for development only.