Skip to content

Commit f9b17c1

Browse files
authored
Clean up building (#680)
1 parent c01892a commit f9b17c1

2 files changed

Lines changed: 11 additions & 142 deletions

File tree

FDROID-UPDATE.md

Lines changed: 0 additions & 141 deletions
This file was deleted.

scripts/build_and_sign.sh

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ require_command() {
3939
readonly TAG=$1
4040
readonly REQUESTED_RUN_ID=${2:-}
4141
[[ $TAG =~ ^[0-9]+$ ]] || fail "release tag must be numeric: $TAG"
42+
readonly FASTLANE_CHANGELOG="$ROOT/fastlane/metadata/android/en-US/changelogs/$TAG.txt"
4243

4344
require_command gh
4445
require_command git
@@ -167,6 +168,14 @@ printf 'signing_certificate_sha256=%s\n' "$ACTUAL_CERT_SHA256" \
167168
printf 'workflow_run=%s\n' "$RUN_URL" >> "$OUTPUT_BUILD_INFO"
168169

169170
printf 'Creating draft GitHub release %s...\n' "$TAG"
171+
RELEASE_NOTES='Download the latest version [here](https://github.com/TrackerControl/tracker-control-android/releases/latest/download/TrackerControl-githubRelease-latest.apk).'
172+
if [[ -s $FASTLANE_CHANGELOG ]]; then
173+
printf 'Including Fastlane changelog: %s\n' "$FASTLANE_CHANGELOG"
174+
RELEASE_NOTES+=$'\n\n'
175+
RELEASE_NOTES+=$(<"$FASTLANE_CHANGELOG")
176+
else
177+
printf 'No Fastlane changelog found for %s; using generated release notes only.\n' "$TAG"
178+
fi
170179
gh release create "$TAG" \
171180
"$SIGNED_APK" \
172181
"$SIGNED_SUMS" \
@@ -175,7 +184,8 @@ gh release create "$TAG" \
175184
--verify-tag \
176185
--draft \
177186
--generate-notes \
178-
--title "$TAG"
187+
--notes "$RELEASE_NOTES" \
188+
--title "Version $TAG"
179189

180190
printf '\nSigned APK: %s\n' "$SIGNED_APK"
181191
printf 'A draft release was created. Test the APK, then publish it in GitHub.\n'

0 commit comments

Comments
 (0)