~ knotless Search/
↑↓ move↵ open⇧↵ all results
0
0

A release is published only for a version CHANGELOG.md has a section for

Merged chadtmiller.com asked to merge into main from chadtmiller.com/monolith:release/changelog-guard
.knotless/workflows/release.yml+8−3
@@ -12,9 +12,11 @@
# `pds` are built as the Dockerfile builds them, and the image made from the
# binary with no container engine, which this runner's jobs have none of
# (.knotless/image.sh). release-pull.yml keeps a pull open that raises the
# version; once it lands, this publishes it. A package with that version
# published already is left alone, so a run that published one of them
# and failed publishes the other when it runs again.
# version; once it lands, this publishes it. A version CHANGELOG.md has no
# section for is no release (knope writes one for each), so a pull that
# touches Cargo.toml for another reason publishes nothing. A package with
# that version published already is left alone, so a run that published
# one of them and failed publishes the other when it runs again.
#
# RELEASE_PASSWORD is an app password of the owner's, sealed to this runner
# for pushes to main alone. Asked for on another branch, `knotless run
@@ -50,6 +52,9 @@ steps:
echo "$published" > ~/.published
if [ "$published" = " monolith pds" ]; then
touch ~/.done
elif ! grep -q "^## $version " CHANGELOG.md; then
echo "CHANGELOG.md has no section for $version: no release to publish"
[ "$KNOTLESS_RUN_REF" != refs/heads/main ] || touch ~/.done
elif [ "$KNOTLESS_RUN_REF" != refs/heads/main ]; then
echo "on $KNOTLESS_RUN_REF: building $version, publishing nothing"
fi