Replaced Enterprise with AdHoc
This commit is contained in:
parent
efa00ff67b
commit
2ed2a57d79
|
|
@ -69,8 +69,8 @@ end
|
|||
|
||||
private_lane :addShield do |options|
|
||||
buildNumber = options[:buildNumber]
|
||||
buildDescription = options[:lane_name] # EnterpriseCustomerDev1WithoutSSLPinningRelease
|
||||
.split(/(?=[A-Z])/) # -> ["Enterprise", "Customer", "Dev1", "Without", "S", "S", "L", "Pinning", "Release"]
|
||||
buildDescription = options[:lane_name] # AdHocCustomerDev1WithoutSSLPinningRelease1
|
||||
.split(/(?=[A-Z])/) # -> ["Adhoc", "Customer", "Dev1", "Without", "S", "S", "L", "Pinning", "Release"]
|
||||
.map { |v| v.gsub(/[[:lower:]]+/, "") }[1..2] # -> ["E", "C", "D1", "W", "S", "S", "L", "P", "R"] -> ["C", "D1"]
|
||||
.join # -> "CD1"
|
||||
|
||||
|
|
|
|||
|
|
@ -1,15 +1,15 @@
|
|||
module Touchlane
|
||||
class ConfigurationType
|
||||
DEVELOPMENT = "development"
|
||||
ENTERPRISE = "enterprise"
|
||||
ADHOC = "adhoc"
|
||||
APP_STORE = "appstore"
|
||||
|
||||
DEVELOPMENT_PREFIX = "Standard"
|
||||
ENTERPRISE_PREFIX = "Enterprise"
|
||||
ADHOC_PREFIX = "AdHoc"
|
||||
APP_STORE_PREFIX = "AppStore"
|
||||
|
||||
private_constant :DEVELOPMENT, :ENTERPRISE, :APP_STORE
|
||||
private_constant :DEVELOPMENT_PREFIX, :ENTERPRISE_PREFIX, :APP_STORE_PREFIX
|
||||
private_constant :DEVELOPMENT, :ADHOC, :APP_STORE
|
||||
private_constant :DEVELOPMENT_PREFIX, :ADHOC_PREFIX, :APP_STORE_PREFIX
|
||||
|
||||
def initialize(type)
|
||||
@type = type
|
||||
|
|
@ -22,10 +22,10 @@ module Touchlane
|
|||
@export_method = type
|
||||
@configuration = "Debug"
|
||||
@prefix = DEVELOPMENT_PREFIX
|
||||
when ENTERPRISE
|
||||
@export_method = type
|
||||
when ADHOC
|
||||
@export_method = "ad-hoc"
|
||||
@configuration = "Release"
|
||||
@prefix = ENTERPRISE_PREFIX
|
||||
@prefix = ADHOC_PREFIX
|
||||
when APP_STORE
|
||||
@export_method = "app-store"
|
||||
@configuration = "AppStore"
|
||||
|
|
@ -41,15 +41,15 @@ module Touchlane
|
|||
|
||||
def self.from_lane_name(lane_name)
|
||||
case
|
||||
when lane_name.start_with?(ENTERPRISE_PREFIX)
|
||||
from_type(ENTERPRISE)
|
||||
when lane_name.start_with?(ADHOC_PREFIX)
|
||||
from_type(ADHOC)
|
||||
when lane_name.start_with?(APP_STORE_PREFIX)
|
||||
from_type(APP_STORE)
|
||||
when lane_name.start_with?(DEVELOPMENT_PREFIX)
|
||||
from_type(DEVELOPMENT)
|
||||
else
|
||||
raise "Unable to map #{lane_name} to #{ConfigurationType.class}."
|
||||
+ "Available prefixes: #{DEVELOPMENT_PREFIX}, #{ENTERPRISE_PREFIX}, #{APP_STORE_PREFIX}"
|
||||
+ "Available prefixes: #{DEVELOPMENT_PREFIX}, #{ADHOC_PREFIX}, #{APP_STORE_PREFIX}"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
@ -61,13 +61,13 @@ module Touchlane
|
|||
case account_type
|
||||
when DEVELOPMENT_PREFIX
|
||||
from_type(DEVELOPMENT)
|
||||
when ENTERPRISE_PREFIX
|
||||
from_type(ENTERPRISE)
|
||||
when ADHOC_PREFIX
|
||||
from_type(ADHOC)
|
||||
when APP_STORE_PREFIX
|
||||
from_type(APP_STORE)
|
||||
else
|
||||
raise "Unable to map #{account_type} to #{ConfigurationType.class}."
|
||||
+ "Available account types: #{DEVELOPMENT_PREFIX}, #{ENTERPRISE_PREFIX}, #{APP_STORE_PREFIX}"
|
||||
+ "Available account types: #{DEVELOPMENT_PREFIX}, #{ADHOC_PREFIX}, #{APP_STORE_PREFIX}"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue