Brings the workflows, scripts and fastlane setup up to Agendula's
v1.1.0-beta.1 state:
- beta.yaml: a release/** branch carrying X.Y.Z-beta.N publishes a
Gitea + Codeberg pre-release with the signed APK. Never F-Droid or Play.
- scripts/version_info.sh derives versionCode from versionName for every
workflow and CI step. Clockula has no shipped 1.0.x codes, so it uses one
scheme: X*1000000 + Y*10000 + Z*100 + (beta N, or 99 for stable).
- CI checks the committed versionCode, blocks a beta from reaching main,
enforces the 500-char What's New and validates the store listing.
- Shared publish_gitea_release.sh / publish_codeberg_release.sh /
release_notes.sh replace the inline steps in release.yaml.
- Renovate also runs on every push to main to rebase conflicted PRs.
- jniLibs keepDebugSymbols, which the reproducibility guard now requires.
Fixes a bug present in Agendula too: the Codeberg tag lookups used
/git/refs/tags/{tag}, which matches by prefix, so v1.0.0 would have
"existed" as soon as v1.0.0-beta.1 did. That would have refused every
later beta and skipped the stable release. Both now use /tags/{tag}.
30 lines
1.0 KiB
Bash
Executable File
30 lines
1.0 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Print the forge release notes for VERSION: its `## [VERSION]` section of
|
|
# CHANGELOG.md. A beta (X.Y.Z-beta.N) normally has no section of its own, so it
|
|
# falls back to `## [Unreleased]`, i.e. what the release branch carries so far,
|
|
# under a line saying what a beta is.
|
|
#
|
|
# scripts/release_notes.sh 1.1.0 > release-notes.md
|
|
set -euo pipefail
|
|
cd "$(dirname "$0")/.." # repo root
|
|
|
|
VERSION=${1:?usage: release_notes.sh VERSION}
|
|
|
|
section() {
|
|
awk -v ver="$1" '
|
|
$0 ~ "^## \\[" ver "\\]" { flag = 1; next }
|
|
/^## \[/ { flag = 0 }
|
|
flag' CHANGELOG.md | sed -e '/./,$!d'
|
|
}
|
|
|
|
NOTES=$(section "$VERSION")
|
|
if [[ "$VERSION" == *-beta.* ]]; then
|
|
[ -n "$NOTES" ] || NOTES=$(section Unreleased)
|
|
printf '%s\n\n' "**Beta of ${VERSION%%-*}, for testing.** It updates in place to later betas and to the stable release. Obtainium only offers betas with *Include prereleases* switched on; F-Droid and Play never get them."
|
|
fi
|
|
if [ -n "$NOTES" ]; then
|
|
printf '%s\n' "$NOTES"
|
|
else
|
|
echo "_No changelog entry for ${VERSION} — see CHANGELOG.md._"
|
|
fi
|