package opam-ci-check-lint

  1. Overview
  2. Docs
Library to lint opam files submitted to the opam repository

Install

Dune Dependency

Authors

Maintainers

Sources

12810c8cc0b9a02e7b22f660387b76c6e70aa685.tar.gz
md5=ecf9bfdbe72256fbb3f66b359dc277ef
sha512=f8984939d945184ed44ba694b4f8936991c220d5fc4d57120d2f70d6da6972bf441e2bb174e36181a521589d8db5829a7521caa366b2a3b13f3b2501c057aee6

Description

opam-ci-check-lint exposes the lint functionality used in the opam repo CI and opam-ci-check. It can be used in other packages such as opam publishing tools to ensure that the published package opam files are correct.

Tags

opam ci lint

Published: 09 Jun 2025

README

opam-repo-ci

This is an OCurrent pipeline that tests submissions to opam-repository.

To get set up running the service locally for the first time:

  • Obtain a local copy of the opam-repository Git repo.
  • Create the directory capnp-secrets in the root of this project (or wherever you intend to run the service from).
  • (Possibly) increase the limit on the number of open files, by setting ulimit.
mkdir capnp-secrets
ulimit -n 102400

Then you can run the opam-repo-ci-local command via dune:

dune exec -- opam-repo-ci-local \
  --confirm harmless \
  --repo REPO-PATH \
  --branch BRANCH-NAME \
  --capnp-address tcp:127.0.0.1:5001 \
  --verbosity info

If you would just like to lint your submission locally, you can add the --lint-only flag to the command above.

Here REPO-PATH is the relative or absolute path to your copy of opam-repository, and BRANCH-NAME is the name of the branch containing the changes you want to make, relative to the master branch.

Browse to http://localhost:8080 to see the web UI. You can either set the confirm threshold (at the bottom of the web page) to allow all builds to start, or just click on a yellow box and then on the Start now button to start one step manually.

The analysis step will detect which packages have been changed. Then, for each supported platform it will try to install the package. If that succeeds, it will run the package's tests, and in parallel it will find other packages that depend on this one and test them too.

Web UI

The public web front-end is a separate process. It needs a .cap capability file to connect to the engine. If you have the file for the real service, you can use that. If you're testing the engine locally (as shown above), you can use the ./capnp-secrets/opam-repo-ci-admin.cap that it writes out.

dune exec -- opam-repo-ci-web --backend ./capnp-secrets/opam-repo-ci-admin.cap

Then browse to http://localhost:8090/github to see the public UI.

Supported platforms

The list of supported platforms is documented in doc/platforms.md. It can be regenerated by running dune build @doc.

Dependencies (5)

  1. opam-format >= "2.3.0~alpha1"
  2. opam-state >= "2.3.0~alpha1"
  3. sexplib
  4. dune >= "3.16"
  5. ocaml >= "4.14.0"

Dev Dependencies (1)

  1. odoc with-doc

Used by

None

Conflicts

None

OCaml

Innovation. Community. Security.