Fix getting build number in Fastlane

This commit is contained in:
Arkadiusz Fal 2022-08-15 16:55:18 +02:00
parent 3526559859
commit 7607cf24b2

View File

@ -34,6 +34,7 @@ platform :ios do
key_filepath: DEVELOPER_KEY_FILEPATH key_filepath: DEVELOPER_KEY_FILEPATH
) )
build = get_build_number(xcodeproj: "Yattee.xcodeproj")
version = get_version_number( version = get_version_number(
xcodeproj: "Yattee.xcodeproj", xcodeproj: "Yattee.xcodeproj",
target: "Yattee (iOS)" target: "Yattee (iOS)"
@ -41,7 +42,7 @@ platform :ios do
build_app( build_app(
scheme: "Yattee (iOS)", scheme: "Yattee (iOS)",
output_directory: "fastlane/builds/#{version}-#{lane_context[SharedValues::BUILD_NUMBER]}/iOS", output_directory: "fastlane/builds/#{version}-#{build}/iOS",
output_name: "Yattee-#{version}-iOS.ipa", output_name: "Yattee-#{version}-iOS.ipa",
) )
@ -60,6 +61,7 @@ platform :tvos do
key_filepath: DEVELOPER_KEY_FILEPATH key_filepath: DEVELOPER_KEY_FILEPATH
) )
build = get_build_number(xcodeproj: "Yattee.xcodeproj")
version = get_version_number( version = get_version_number(
xcodeproj: "Yattee.xcodeproj", xcodeproj: "Yattee.xcodeproj",
target: "Yattee (tvOS)" target: "Yattee (tvOS)"
@ -67,7 +69,7 @@ platform :tvos do
build_app( build_app(
scheme: "Yattee (tvOS)", scheme: "Yattee (tvOS)",
output_directory: "fastlane/builds/#{version}-#{lane_context[SharedValues::BUILD_NUMBER]}/tvOS", output_directory: "fastlane/builds/#{version}-#{build}/tvOS",
output_name: "Yattee-#{version}-tvOS.ipa", output_name: "Yattee-#{version}-tvOS.ipa",
) )
@ -86,6 +88,7 @@ platform :mac do
key_filepath: DEVELOPER_KEY_FILEPATH key_filepath: DEVELOPER_KEY_FILEPATH
) )
build = get_build_number(xcodeproj: "Yattee.xcodeproj")
version = get_version_number( version = get_version_number(
xcodeproj: "Yattee.xcodeproj", xcodeproj: "Yattee.xcodeproj",
target: "Yattee (macOS)" target: "Yattee (macOS)"
@ -93,7 +96,7 @@ platform :mac do
build_app( build_app(
scheme: "Yattee (macOS)", scheme: "Yattee (macOS)",
output_directory: "fastlane/builds/#{version}-#{lane_context[SharedValues::BUILD_NUMBER]}/macOS", output_directory: "fastlane/builds/#{version}-#{build}/macOS",
output_name: "Yattee-#{version}-macOS.app", output_name: "Yattee-#{version}-macOS.app",
) )