-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Allow for discriminating between beta and stable when building releases on Buildkite #17893
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
3eeef7f
ea7bdb7
3c593f2
7a94603
f8087cd
ac614d5
a298114
ac42081
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -467,47 +467,6 @@ platform :ios do | |
download_jetpack_localized_app_store_metadata | ||
end | ||
|
||
##################################################################################### | ||
# build_and_upload_beta_release | ||
# ----------------------------------------------------------------------------------- | ||
# This lane builds a beta release of the app and optionally uploads | ||
# it for both internal and external distribution | ||
# ----------------------------------------------------------------------------------- | ||
# Usage: | ||
# bundle exec fastlane build_and_upload_beta_release [skip_confirm:<skip confirm>] | ||
# [create_gh_release:<create release on GH>] | ||
# | ||
# Example: | ||
# bundle exec fastlane build_and_upload_beta_release | ||
# bundle exec fastlane build_and_upload_beta_release skip_confirm:true | ||
# bundle exec fastlane build_and_upload_beta_release create_gh_release:true | ||
##################################################################################### | ||
desc 'Builds and uploads a beta release for distribution' | ||
lane :build_and_upload_beta_release do |options| | ||
build_and_upload_app_center(options) | ||
build_and_upload_app_store_connect(options) | ||
end | ||
|
||
##################################################################################### | ||
# build_and_upload_stable_release | ||
# ----------------------------------------------------------------------------------- | ||
# This lane builds a stable release of the app and optionally uploads | ||
# it for distribution | ||
# ----------------------------------------------------------------------------------- | ||
# Usage: | ||
# bundle exec fastlane build_and_upload_stable_release [skip_confirm:<skip confirm>] | ||
# [create_gh_release:<create release on GH>] | ||
# | ||
# Example: | ||
# bundle exec fastlane build_and_upload_stable_release | ||
# bundle exec fastlane build_and_upload_stable_release skip_confirm:true | ||
# bundle exec fastlane build_and_upload_stable_release create_gh_release:true | ||
##################################################################################### | ||
desc 'Builds and uploads a stable release for distribution' | ||
lane :build_and_upload_stable_release do |options| | ||
build_and_upload_app_store_connect(options) | ||
end | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. These above were just unused lanes from the CircleCI implementation that I noticed while looking around the file. |
||
##################################################################################### | ||
# build_and_upload_app_store_connect | ||
# ----------------------------------------------------------------------------------- | ||
|
@@ -817,12 +776,7 @@ platform :ios do | |
# | ||
##################################################################################### | ||
lane :trigger_beta_build do |options| | ||
buildkite_trigger_build( | ||
buildkite_organization: 'automattic', | ||
buildkite_pipeline: 'wordpress-ios', | ||
branch: options[:branch_to_build], | ||
pipeline_file: 'release-builds.yml' | ||
) | ||
trigger_buildkite_release_build(branch: options[:branch_to_build], beta: true) | ||
end | ||
|
||
##################################################################################### | ||
|
@@ -835,12 +789,7 @@ platform :ios do | |
# | ||
##################################################################################### | ||
lane :trigger_release_build do |options| | ||
buildkite_trigger_build( | ||
buildkite_organization: 'automattic', | ||
buildkite_pipeline: 'wordpress-ios', | ||
branch: options[:branch_to_build], | ||
pipeline_file: 'release-builds.yml' | ||
) | ||
trigger_buildkite_release_build(branch: options[:branch_to_build], beta: false) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I also considered ditching the two lanes for a single one with a |
||
end | ||
|
||
######################################################################## | ||
|
@@ -1019,6 +968,16 @@ def generate_installable_build_number | |
end | ||
end | ||
|
||
def trigger_buildkite_release_build(branch:, beta:) | ||
buildkite_trigger_build( | ||
buildkite_organization: 'automattic', | ||
buildkite_pipeline: 'wordpress-ios', | ||
branch: branch, | ||
environment: { BETA_RELEASE: beta }, | ||
pipeline_file: 'release-builds.yml' | ||
) | ||
end | ||
|
||
# Application-agnostic settings for the `upload_to_app_store` action, also | ||
# known as `deliver`. | ||
UPLOAD_TO_APP_STORE_COMMON_PARAMS = { | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,8 +7,8 @@ group :screenshots, optional: true do | |
end | ||
|
||
# This comment avoids typing to switch to a development version for testing. | ||
# gem 'fastlane-plugin-wpmreleasetoolkit', git: 'git@github.com:wordpress-mobile/release-toolkit', branch: 'trunk' | ||
gem 'fastlane-plugin-wpmreleasetoolkit', '~> 2.3' | ||
gem 'fastlane-plugin-wpmreleasetoolkit', git: 'git@github.com:wordpress-mobile/release-toolkit', branch: 'trunk' | ||
# gem 'fastlane-plugin-wpmreleasetoolkit', '~> 2.3' | ||
Comment on lines
-10
to
+11
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Before merging this (or #17891) we ought to ship a new version of the release toolkit. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. v3.0.0 (wordpress-mobile/release-toolkit#334) is almost ready to go There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Let's land this, then update #17891 to use the new version of the toolkit. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. SGTM 👍 |
||
|
||
gem 'fastlane-plugin-sentry' | ||
gem 'fastlane-plugin-appcenter', '~> 1.8' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The alternative could be to make
$1
required and check for it at the start of the script.This seemed more concise, and I didn't feel we needed refined input validation given these scripts are only meant to run via CI.