Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Tag each uploaded beta with version and current build number. It's pretty sweet.
lane :beta do
ensure_git_status_clean
latestBuildNumber = bump_build_number
# Git tag must not already exist. If it does, check if we forgot to bump version or
# delete previous tag on remote.
git_tag_name = "v#{version}(#{latestBuildNumber})"
UI.crash!("Git tag #{git_tag_name} already exists.") if git_tag_exists(tag: git_tag_name)
build_app(scheme: "Volante")
upload_to_testflight(skip_waiting_for_build_processing: true)
# Create a git tag,
add_git_tag(tag: git_tag_name)
push_git_tags
increment_build_number(build_number: 0, xcodeproj: "Volante.xcodeproj")
end
def bump_build_number
latestBuildNumber = latest_testflight_build_number(
version: version,
initial_build_number: 0
)
return increment_build_number(
build_number: latestBuildNumber + 1,
xcodeproj: "Volante.xcodeproj"
)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.