From 26a9dc4a6809e8cb620028048c6c1772847b39b7 Mon Sep 17 00:00:00 2001 From: Oguz Kocer Date: Fri, 24 Jul 2026 00:59:17 -0400 Subject: [PATCH 1/4] Let developers pick static release notes during beta promotion Adds static "what's new" options (one for now, `serious`) chosen from a second field in the beta-promotion block step. The picked option's notes are set on the beta release, and the production promote carries them over. Changes: - `STATIC_RELEASE_NOTE_OPTIONS` registry (Fastfile) - Release-notes select field in the beta picker; `promote_to_beta` takes `release_notes_option` (read from Buildkite meta-data by promote-to-beta.sh) - `static_release_notes` attaches the per-locale notes to the beta release - `download_static_release_notes` lane pulls the translations from GlotPress - English source files + seeded en-US metadata Translations are seeded separately via GlotPress; until then promotions attach the committed en-US note and Play falls back to the default language. --- .buildkite/commands/promote-to-beta.sh | 15 ++++- .../release_notes_static/serious.txt | 1 + .../metadata/release_notes_static/serious.txt | 1 + fastlane/Fastfile | 8 +++ .../en-US/release_notes_static/serious.txt | 1 + fastlane/lanes/localization.rb | 55 +++++++++++++++++ fastlane/lanes/promote.rb | 60 +++++++++++++++++-- .../en-US/release_notes_static/serious.txt | 1 + 8 files changed, 133 insertions(+), 9 deletions(-) create mode 100644 WordPress/jetpack_metadata/release_notes_static/serious.txt create mode 100644 WordPress/metadata/release_notes_static/serious.txt create mode 100644 fastlane/jetpack_metadata/android/en-US/release_notes_static/serious.txt create mode 100644 fastlane/metadata/android/en-US/release_notes_static/serious.txt diff --git a/.buildkite/commands/promote-to-beta.sh b/.buildkite/commands/promote-to-beta.sh index 967c59fca058..09756b565222 100755 --- a/.buildkite/commands/promote-to-beta.sh +++ b/.buildkite/commands/promote-to-beta.sh @@ -4,15 +4,24 @@ set -eu # Promotes the build chosen in the preceding block step to the beta track. No build — just gems + secrets. -# `beta_build_to_promote` must stay in sync with PROMOTION_META_DATA_KEY in fastlane/lanes/promote.rb, -# which is the key the gather lane writes the block-step select field under. +# `beta_build_to_promote` must stay in sync with BETA_META_DATA_KEY in fastlane/lanes/promote.rb, +# which is the key the gather lane writes the block-step build select field under. VERSION_CODE="$(buildkite-agent meta-data get "beta_build_to_promote" --default "")" +# `beta_release_notes_option` must stay in sync with BETA_RELEASE_NOTES_META_DATA_KEY in the same file +# (the block step's release-notes select field). +RELEASE_NOTES_OPTION="$(buildkite-agent meta-data get "beta_release_notes_option" --default "")" + if [[ -z "${VERSION_CODE}" ]]; then echo "+++ :x: No build was selected to promote." exit 1 fi +if [[ -z "${RELEASE_NOTES_OPTION}" ]]; then + echo "+++ :x: No release notes option was selected." + exit 1 +fi + echo "--- :rubygems: Setting up Gems" install_gems @@ -20,4 +29,4 @@ echo "--- :closed_lock_with_key: Installing Secrets" bundle exec fastlane run configure_apply echo "--- :rocket: Promoting ${VERSION_CODE} to the beta track" -bundle exec fastlane promote_to_beta version_code:"${VERSION_CODE}" +bundle exec fastlane promote_to_beta version_code:"${VERSION_CODE}" release_notes_option:"${RELEASE_NOTES_OPTION}" diff --git a/WordPress/jetpack_metadata/release_notes_static/serious.txt b/WordPress/jetpack_metadata/release_notes_static/serious.txt new file mode 100644 index 000000000000..8ef5aad0194e --- /dev/null +++ b/WordPress/jetpack_metadata/release_notes_static/serious.txt @@ -0,0 +1 @@ +We're focused on making Jetpack more stable and dependable with every release. This update continues that work with ongoing improvements and fixes. Have feedback or need help? Reach us any time from Help & Support. Thank you for using Jetpack. diff --git a/WordPress/metadata/release_notes_static/serious.txt b/WordPress/metadata/release_notes_static/serious.txt new file mode 100644 index 000000000000..7d232109a07d --- /dev/null +++ b/WordPress/metadata/release_notes_static/serious.txt @@ -0,0 +1 @@ +We're focused on making WordPress more stable and dependable with every release. This update continues that work with ongoing improvements and fixes. Have feedback or need help? Reach us any time from Help & Support. Thank you for using WordPress. diff --git a/fastlane/Fastfile b/fastlane/Fastfile index 7bfb6eaa8ede..fb4c30920d10 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -39,6 +39,14 @@ UPLOAD_TO_PLAY_STORE_JSON_KEY = File.join(Dir.home, '.configure', 'wordpress-and # writes a track release (AAB upload or beta promotion) keeps it in the release's version codes. PLAY_STORE_VERSION_CODES_TO_RETAIN = [1440].freeze +# The "what's new" options shown in the beta-promotion picker. The picked one is set on the beta +# release and carried to production by the promote. `key` names the source file +# (`release_notes_static/.txt`) and the GlotPress string (`release_note_static_`); `label` +# is shown in the picker. Add entries to offer more options. +STATIC_RELEASE_NOTE_OPTIONS = [ + { key: 'serious', label: 'Serious' } +].freeze + PROTOTYPE_BUILD_TYPE = 'Debug' PROJECT_ROOT_FOLDER = File.dirname(File.expand_path(__dir__)) diff --git a/fastlane/jetpack_metadata/android/en-US/release_notes_static/serious.txt b/fastlane/jetpack_metadata/android/en-US/release_notes_static/serious.txt new file mode 100644 index 000000000000..8ef5aad0194e --- /dev/null +++ b/fastlane/jetpack_metadata/android/en-US/release_notes_static/serious.txt @@ -0,0 +1 @@ +We're focused on making Jetpack more stable and dependable with every release. This update continues that work with ongoing improvements and fixes. Have feedback or need help? Reach us any time from Help & Support. Thank you for using Jetpack. diff --git a/fastlane/lanes/localization.rb b/fastlane/lanes/localization.rb index 7528c1ef14a4..5c034a8bdfa3 100644 --- a/fastlane/lanes/localization.rb +++ b/fastlane/lanes/localization.rb @@ -148,6 +148,15 @@ } end + # The beta-promotion picker's "what's new" options. Stable keys (no version suffix) so each is + # translated once, unlike the per-version `release_note_*` keys. + STATIC_RELEASE_NOTE_OPTIONS.each do |option| + files[:"release_note_static_#{option[:key]}"] = { + path: File.join(metadata_folder, 'release_notes_static', "#{option[:key]}.txt"), + comment: 'translators: Generic "what\'s new" text shown in the Play Store. Limit to 500 characters including spaces.' + } + end + update_po_file_for_metadata_localization( po_path: File.join(metadata_folder, 'PlayStoreStrings.po'), sources: files, @@ -267,6 +276,52 @@ end end + # Downloads the translated "what's new" options from GlotPress into the per-locale + # `release_notes_static/