ocaml / ocaml/dune

Command to display current lockdir solution

Open
#12,865 12 comments 0 reactions 1 assignee View on GitHub

@Sudha247 is already working on this.

Since Jun 1, 2026.

package management
Dominant language
OCaml
Stars
1.9k
Forks
500
Avg merge
15h 21m
Merged PRs (30d)
277

Description

Desired Behavior

With dune pkg lock the solution is printed to the console and the lock directory is in the source tree so it is easy for the user to see what is part of the lock dir and which versions of packages are picked.

However, when the solver is run as a rule, it is silent (rightfully so). The downside however is that it is unclear which packages were selected as the lock directory is in an internal location in the build directory.

It would be nice to be able to print the current solution (if there is one).

Example

$ dune describe pkg solution
Solution for dune.lock:
- base-unix.base
- fmt.0.9.0
- ocaml.5.2.0
- ocaml-base-compiler.5.2.0
- ocaml-config.3
- ocamlbuild.0.15.0+dune
- ocamlfind.1.9.6+dune
- topkg.1.0.7

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.