#!/usr/bin/env bash # Creates and pushes the tag version- on the published commit (release_rev: @, or its first # non-empty ancestor), with jj only. The tag is lightweight (jj creates no annotated tag): the release notes # are not its message but the file $RELEASE_NOTES_DIR/version-.md committed in the tagged revision, # which forgejo-release.sh reads in the CI as the body of the release. set -euo pipefail . "$(dirname "$0")/common.sh" version=$(current_version) tag="version-$version" notes="$RELEASE_NOTES_DIR/$tag.md" [ -f "$notes" ] || { err "✗ release notes missing: $notes (make release-notes)"; exit 1; } if [ -n "$(jj tag list "exact:$tag" 2>/dev/null)" ]; then err "✗ tag $tag already exists" exit 1 fi rev=$(release_rev) jj tag set "$tag" -r "$rev" jj git push --tag "exact:$tag" ok "✓ Release $tag published"