closure_drift
v1.11.2Before an agent tags a release: does that version label already name different code in the git tags?
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
would_tag Check before tagging
Use BEFORE creating a release tag: would the version that HEAD declares reuse a label that already names other code in the tags? Exit 1 means do not tag; bump the version first. Returns exit 0, 1 or 2 and the JSON report. Exit 2 is not a pass: nothing was decided, and output says why (no label found, a file not read, a tag not compared). Read-only: it runs git reads only, on the local repository, with no network.
| Parameter | Type | Description |
|---|---|---|
repo * | string | path to a local git repository with its tags fetched |
check_versions Measure all version labels
Use to audit the whole tag history: does each version label name exactly one code state? For a single release about to be tagged, use would_tag. With one release only, the answer is not decided (exit 2). Returns exit 0, 1 or 2 and the JSON report. Exit 2 is not a pass: nothing was decided, and output says why (no label found, a file not read, a tag not compared). Read-only: it runs git reads only, on the local repository, with no network.
| Parameter | Type | Description |
|---|---|---|
repo * | string | path to a local git repository with its tags fetched |
published_file | string | a local file with the versions actually released, one per line; tags not on it are not counted as publications |
strict | boolean | answer clean only if every tag scanned was compared (default false) |
explain_label Explain a label in drift
Use after check_versions reports drift: lists, for one label, the paths that differ between the first tag that used it and each other tag that did. For two references you choose, use compare. Returns exit 0, 1 or 2 and the JSON report. Exit 2 is not a pass: nothing was decided, and output says why (no label found, a file not read, a tag not compared). Read-only: it runs git reads only, on the local repository, with no network.
| Parameter | Type | Description |
|---|---|---|
label * | string | a version label reported in drift, as written in the report (e.g. 1.0.0) |
repo * | string | path to a local git repository with its tags fetched |
compare Compare two references
Use to compare any two tags or commits you name: their version labels, closures and the paths that differ. Publication points play no part. Exit 1 when both declare one label and the code differs. Returns exit 0, 1 or 2 and the JSON report. Exit 2 is not a pass: nothing was decided, and output says why (no label found, a file not read, a tag not compared). Read-only: it runs git reads only, on the local repository, with no network.
| Parameter | Type | Description |
|---|---|---|
a * | string | the first tag or commit (the reference side) |
b * | string | the second tag or commit; paths are listed as changed, only in a, only in b |
repo * | string | path to a local git repository with its tags fetched |