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/PlayStoreStrings.po b/WordPress/jetpack_metadata/PlayStoreStrings.po index 8ee92e1f8110..a4665fa475c7 100644 --- a/WordPress/jetpack_metadata/PlayStoreStrings.po +++ b/WordPress/jetpack_metadata/PlayStoreStrings.po @@ -100,3 +100,6 @@ msgid "" "- Removed beta badge from Menus in My Site\n" msgstr "" +msgctxt "release_note_static_serious" +msgid "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." +msgstr "" 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/PlayStoreStrings.po b/WordPress/metadata/PlayStoreStrings.po index 378c25e71c49..d5fc2621ba29 100644 --- a/WordPress/metadata/PlayStoreStrings.po +++ b/WordPress/metadata/PlayStoreStrings.po @@ -154,3 +154,6 @@ msgid "" "- Removed beta badge from Menus in My Site\n" msgstr "" +msgctxt "release_note_static_serious" +msgid "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." +msgstr "" 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/