Build the versions.json register of every release under a prefix
Source: R/release.R
build_versions_json.RdDiscovers each {prefix}/{version}/catalog.json in the bucket and returns
the list release_database.qmd writes as versions.json — one record per
release with version, release_date, tables, total_rows, size_mb,
plus the archive-policy fields: consolidated (parquet kept indefinitely,
from metadata/release_policy.yml) and, when the version's parquet has been
removed by scripts/thin_releases.R, retired ({retired_utc, to, reason}
read from its retired.json). Both the release notebook and the thinning
script call this, so a re-run of the release cannot drop the policy fields.
Usage
build_versions_json(
bucket,
prefix = CC_RELEASE_PREFIX,
consolidated = character(),
current = NULL
)