fleetlint Policy for a fleet of repositories
v0.11 (latest)
Getting started

repo/lockfile-committed/cpp

Dependency lockfile is committed

Implements repo/lockfile-committed for cpp.

Severityerror
Tiers1, 2
Stackscpp
Scopeeach
Kindexpr
Sourcelibrary v0.8.0
Selected byfleetlint-recommended@v0.8.0

Requirement

With Conan, conan.lock is tracked; with vcpkg, vcpkg.json sets a builtin-baseline (or vcpkg-configuration.json a registry baseline), which fixes every port version. A build without a package manager needs neither.

Why

Builds are reproducible only when dependency versions are pinned in git.

Check

((!file("conanfile.txt") && !file("conanfile.py")) || "conan.lock" in tracked()) && (!file("vcpkg.json") || text("vcpkg.json").contains("\"builtin-baseline\"")
    || (file("vcpkg-configuration.json") && text("vcpkg-configuration.json").contains("\"baseline\"")))

Fix

Conan: conan lock create . and commit conan.lock; vcpkg: vcpkg x-update-baseline --add-initial-baseline.

Agent instruction (from repo/lockfile-committed): Run the package manager to produce the lockfile, remove any .gitignore entry for it, and commit it.

A finding that names no file points at vcpkg.json, or conan.lock when there is none.

Sources


Generated by fleetlint docs from catalog v0.8.0.