fastlane 2.71.0.beta.20171221010003 → 2.71.0.beta.20171222010003

Sign up to get free protection for your applications and to get access to all the features.
Files changed (53) hide show
  1. checksums.yaml +4 -4
  2. data/cert/lib/cert/options.rb +3 -0
  3. data/deliver/lib/deliver/options.rb +7 -0
  4. data/fastlane/lib/fastlane/actions/app_store_build_number.rb +3 -0
  5. data/fastlane/lib/fastlane/actions/automatic_code_signing.rb +1 -0
  6. data/fastlane/lib/fastlane/actions/commit_github_file.rb +1 -0
  7. data/fastlane/lib/fastlane/actions/create_pull_request.rb +3 -0
  8. data/fastlane/lib/fastlane/actions/dotgpg_environment.rb +1 -0
  9. data/fastlane/lib/fastlane/actions/download_dsyms.rb +10 -1
  10. data/fastlane/lib/fastlane/actions/get_version_number.rb +7 -1
  11. data/fastlane/lib/fastlane/actions/github_api.rb +1 -0
  12. data/fastlane/lib/fastlane/actions/import_from_git.rb +8 -2
  13. data/fastlane/lib/fastlane/actions/latest_testflight_build_number.rb +3 -0
  14. data/fastlane/lib/fastlane/actions/modify_services.rb +3 -0
  15. data/fastlane/lib/fastlane/actions/register_device.rb +2 -0
  16. data/fastlane/lib/fastlane/actions/register_devices.rb +2 -0
  17. data/fastlane/lib/fastlane/actions/s3.rb +2 -0
  18. data/fastlane/lib/fastlane/actions/set_changelog.rb +3 -0
  19. data/fastlane/lib/fastlane/actions/set_github_release.rb +1 -0
  20. data/fastlane/lib/fastlane/actions/update_app_identifier.rb +2 -0
  21. data/fastlane/lib/fastlane/actions/update_info_plist.rb +1 -0
  22. data/fastlane/lib/fastlane/actions/update_project_code_signing.rb +2 -0
  23. data/fastlane/lib/fastlane/actions/update_project_team.rb +1 -0
  24. data/fastlane/lib/fastlane/actions/verify_xcode.rb +1 -0
  25. data/fastlane/lib/fastlane/actions/version_bump_podspec.rb +1 -0
  26. data/fastlane/lib/fastlane/actions/version_get_podspec.rb +1 -0
  27. data/fastlane/lib/fastlane/actions/xcode_install.rb +1 -0
  28. data/fastlane/lib/fastlane/fast_file.rb +9 -75
  29. data/fastlane/lib/fastlane/swift_fastlane_api_generator.rb +1 -2
  30. data/fastlane/lib/fastlane/swift_fastlane_function.rb +0 -32
  31. data/fastlane/lib/fastlane/version.rb +1 -1
  32. data/fastlane/swift/Deliverfile.swift +1 -1
  33. data/fastlane/swift/Fastlane.swift +12 -12
  34. data/fastlane/swift/Gymfile.swift +1 -1
  35. data/fastlane/swift/Matchfile.swift +1 -1
  36. data/fastlane/swift/Precheckfile.swift +1 -1
  37. data/fastlane/swift/Scanfile.swift +1 -1
  38. data/fastlane/swift/Screengrabfile.swift +1 -1
  39. data/fastlane/swift/Snapshotfile.swift +1 -1
  40. data/fastlane_core/lib/fastlane_core.rb +1 -0
  41. data/fastlane_core/lib/fastlane_core/configuration/config_item.rb +31 -0
  42. data/fastlane_core/lib/fastlane_core/tag_version.rb +24 -0
  43. data/match/lib/match/options.rb +3 -0
  44. data/pem/lib/pem/options.rb +3 -0
  45. data/pilot/lib/pilot/options.rb +6 -0
  46. data/precheck/lib/precheck/options.rb +3 -0
  47. data/produce/lib/produce/options.rb +7 -0
  48. data/scan/lib/scan/options.rb +2 -0
  49. data/screengrab/lib/screengrab/options.rb +4 -0
  50. data/sigh/lib/sigh/options.rb +3 -0
  51. data/snapshot/lib/snapshot/options.rb +1 -0
  52. data/supply/lib/supply/options.rb +6 -0
  53. metadata +5 -4
@@ -39,6 +39,7 @@ module Fastlane
39
39
  FastlaneCore::ConfigItem.new(key: :teamid,
40
40
  env_name: "FL_PROJECT_TEAM_ID",
41
41
  description: "The Team ID you want to use",
42
+ code_gen_sensitive: true,
42
43
  default_value: ENV["TEAM_ID"] || CredentialsManager::AppfileConfig.try_fetch_value(:team_id))
43
44
  ]
44
45
  end
@@ -124,6 +124,7 @@ module Fastlane
124
124
  FastlaneCore::ConfigItem.new(key: :xcode_path,
125
125
  env_name: "FL_VERIFY_XCODE_XCODE_PATH",
126
126
  description: "The path to the Xcode installation to test",
127
+ code_gen_sensitive: true,
127
128
  default_value: File.expand_path('../../', FastlaneCore::Helper.xcode_path),
128
129
  verify_block: proc do |value|
129
130
  UI.user_error!("Couldn't find Xcode at path '#{value}'") unless File.exist?(value)
@@ -47,6 +47,7 @@ module Fastlane
47
47
  FastlaneCore::ConfigItem.new(key: :path,
48
48
  env_name: "FL_VERSION_BUMP_PODSPEC_PATH",
49
49
  description: "You must specify the path to the podspec file to update",
50
+ code_gen_sensitive: true,
50
51
  default_value: Dir["*.podspec"].last,
51
52
  verify_block: proc do |value|
52
53
  UI.user_error!("Please pass a path to the `version_bump_podspec` action") if value.length == 0
@@ -25,6 +25,7 @@ module Fastlane
25
25
  env_name: "FL_VERSION_PODSPEC_PATH",
26
26
  description: "You must specify the path to the podspec file",
27
27
  is_string: true,
28
+ code_gen_sensitive: true,
28
29
  default_value: Dir["*.podspec"].last,
29
30
  verify_block: proc do |value|
30
31
  UI.user_error!("Please pass a path to the `version_get_podspec` action") if value.length == 0
@@ -62,6 +62,7 @@ module Fastlane
62
62
  env_name: "XCODE_INSTALL_TEAM_ID",
63
63
  description: "The ID of your team if you're in multiple teams",
64
64
  optional: true,
65
+ code_gen_sensitive: true,
65
66
  default_value: CredentialsManager::AppfileConfig.try_fetch_value(:team_id))
66
67
  ]
67
68
  end
@@ -1,3 +1,5 @@
1
+ require "rubygems/requirement"
2
+
1
3
  module Fastlane
2
4
  class FastFile
3
5
  # Stores all relevant information from the currently running process
@@ -229,7 +231,7 @@ module Fastlane
229
231
  # @param url [String] The git URL to clone the repository from
230
232
  # @param branch [String] The branch to checkout in the repository
231
233
  # @param path [String] The path to the Fastfile
232
- # @param verion [String] Version of the required Fastlane version
234
+ # @param version [String, Array] Version requirement for repo tags
233
235
  def import_from_git(url: nil, branch: 'HEAD', path: 'fastlane/Fastfile', version: nil)
234
236
  UI.user_error!("Please pass a path to the `import_from_git` action") if url.to_s.length == 0
235
237
 
@@ -251,13 +253,10 @@ module Fastlane
251
253
  Actions.sh("GIT_TERMINAL_PROMPT=0 git clone '#{url}' '#{clone_folder}' --depth 1 -n #{branch_option}")
252
254
 
253
255
  unless version.nil?
254
- git_tags = fetch_remote_tags(folder: clone_folder)
255
-
256
- # Separate version from optimistic operator
257
- version_number = version(version_string: version)
258
- operator = operator(version_string: version)
259
-
260
- checkout_param = checkout_param_for_operator(operator: operator, version: version_number, git_tags: git_tags)
256
+ req = Gem::Requirement.new(version)
257
+ all_tags = fetch_remote_tags(folder: clone_folder)
258
+ checkout_param = all_tags.select { |t| req =~ FastlaneCore::TagVersion.new(t) }.last
259
+ UI.user_error! "No tag found matching #{version.inspect}" if checkout_param.nil?
261
260
  end
262
261
 
263
262
  Actions.sh("cd '#{clone_folder}' && git checkout #{checkout_param} '#{path}'")
@@ -293,75 +292,10 @@ module Fastlane
293
292
  git_tags_string = Actions.sh("cd '#{folder}' && git tag -l")
294
293
  git_tags = git_tags_string.split("\n")
295
294
 
296
- # Delete tags that are not a real version number
297
- git_tags.delete_if { |tag| Gem::Version.correct?(tag) != 0 }
298
-
299
295
  # Sort tags based on their version number
300
- git_tags.sort_by { |tag| Gem::Version.new(tag) }
301
-
302
296
  return git_tags
303
- end
304
-
305
- def checkout_param_for_operator(operator: nil, version: nil, git_tags: nil)
306
- # ~> should select the latest version withing constraints.
307
- # -> should select a specific version without fallback.
308
- if operator == "~>"
309
- return checkout_param_twiddle_wakka(version: version, git_tags: git_tags)
310
-
311
- elsif operator == "->" || operator.nil?
312
- return checkout_param_specific_version(version: version, git_tags: git_tags)
313
-
314
- else
315
- UI.user_error!("The specified operator \"#{operator}\" in \"#{version}\" is unknown. Please use one of these '~> ->'")
316
- end
317
- end
318
-
319
- def checkout_param_specific_version(version: nil, git_tags: nil)
320
- # Search matching version in array
321
- matching_git_tags = git_tags.select do |tag|
322
- tag == version
323
- end
324
-
325
- UI.user_error!("The specified version \"#{version}\" doesn't exist") if matching_git_tags.count == 0
326
- return matching_git_tags.last
327
- end
328
-
329
- def checkout_param_twiddle_wakka(version: nil, git_tags: nil)
330
- # Drop last specified digit in version
331
- last_dot_index = version.rindex('.')
332
- version_range = version[0..last_dot_index - 1]
333
-
334
- # Search matching version in array
335
- matching_git_tags = git_tags.select do |tag|
336
- tag.start_with?(version_range)
337
- end
338
-
339
- UI.user_error!("No version found within the \"#{version_range}.*\" range") if matching_git_tags.count == 0
340
-
341
- return matching_git_tags.last
342
- end
343
-
344
- def operator(version_string: nil)
345
- version_info = version_range_info(version_string: version_string)
346
-
347
- # version_info will have 2 elements if an optimistic operator is specified.
348
- if version_info.count > 1
349
-
350
- # Optimistic operator is always the first part. e.g.: ["~>", "2.0.0"]
351
- return version_info.first
352
- end
353
-
354
- return nil
355
- end
356
-
357
- def version(version_string: nil)
358
- version_info = version_range_info(version_string: version_string)
359
- return version_info.last
360
- end
361
-
362
- def version_range_info(version_string: nil)
363
- # Separate version from optimistic operator
364
- return version_string.split(" ")
297
+ .select { |tag| FastlaneCore::TagVersion.correct?(tag) }
298
+ .sort_by { |tag| FastlaneCore::TagVersion.new(tag) }
365
299
  end
366
300
 
367
301
  #####################################################
@@ -233,10 +233,9 @@ func parseInt(fromString: String, function: String = #function) -> Int {
233
233
  if ignore_param?(function_name: action_name, param_name: current.key)
234
234
  next
235
235
  end
236
-
237
236
  keys << current.key.to_s
238
237
  key_descriptions << current.description
239
- key_default_values << current.default_value
238
+ key_default_values << current.code_gen_default_value
240
239
  key_optionality_values << current.optional
241
240
  key_type_overrides << current.data_type
242
241
  end
@@ -23,29 +23,6 @@ module Fastlane
23
23
  # class instance?
24
24
  @reserved_words = %w[associativity break case catch class continue convenience default deinit didSet do else enum extension fallthrough false final for func get guard if in infix init inout internal lazy let mutating nil operator override postfix precedence prefix private public repeat required return self set static struct subscript super switch throws true try var weak where while willSet].to_set
25
25
  # rubocop:enable LineLength
26
-
27
- @default_values_to_ignore = {
28
- "cert" => ["keychain_path"].to_set,
29
- "get_certificates" => ["keychain_path"].to_set,
30
- "set_github_release" => ["api_token"].to_set,
31
- "github_api" => ["api_token"].to_set,
32
- "create_pull_request" => ["api_token", "head", "api_url"].to_set,
33
- "commit_github_file" => ["api_token"].to_set,
34
- "verify_xcode" => ["xcode_path"].to_set,
35
- "produce" => ["sku"].to_set,
36
- "create_app_online" => ["sku"].to_set,
37
- "screengrab" => ["android_home"].to_set,
38
- "capture_android_screenshots" => ["android_home"].to_set
39
- }
40
- end
41
-
42
- def ignore_default_value?(function_name: nil, param_name: nil)
43
- action_set = @default_values_to_ignore[function_name]
44
- unless action_set
45
- return false
46
- end
47
-
48
- return action_set.include?(param_name)
49
26
  end
50
27
 
51
28
  def sanitize_reserved_word(word: nil)
@@ -106,8 +83,6 @@ module Fastlane
106
83
  end
107
84
 
108
85
  def override_default_value_if_not_correct_type(param_name: nil, param_type: nil, default_value: nil)
109
- default_value = nil if ignore_default_value?(function_name: @function_name, param_name: param_name)
110
-
111
86
  return "[]" if param_type == "[String]" && default_value == ""
112
87
  return "{_ in }" if param_type == "((String) -> Void)"
113
88
 
@@ -124,10 +99,6 @@ module Fastlane
124
99
  # if we are optional and don't have a default value, we'll need to use ?
125
100
  optional_specifier = "?" if (optional && default_value.nil?) && type != "((String) -> Void)"
126
101
 
127
- if optional && ignore_default_value?(function_name: @function_name, param_name: param)
128
- optional_specifier = "?"
129
- end
130
-
131
102
  # If we have a default value of true or false, we can infer it is a Bool
132
103
  if default_value.class == FalseClass
133
104
  type = "Bool"
@@ -284,9 +255,6 @@ module Fastlane
284
255
 
285
256
  swift_implementations = @param_names.zip(param_default_values, param_optionality_values, param_type_overrides).map do |param, default_value, optional, param_type_override|
286
257
  type = get_type(param: param, default_value: default_value, optional: optional, param_type_override: param_type_override)
287
-
288
- default_value = nil if ignore_default_value?(function_name: @function_name, param_name: param)
289
-
290
258
  param = camel_case_lower(string: param)
291
259
  param = sanitize_reserved_word(word: param)
292
260
  var_for_parameter_name = param
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
- VERSION = '2.71.0.beta.20171221010003'.freeze
2
+ VERSION = '2.71.0.beta.20171222010003'.freeze
3
3
  DESCRIPTION = "The easiest way to automate beta deployments and releases for your iOS and Android apps".freeze
4
4
  MINIMUM_XCODE_RELEASE = "7.0".freeze
5
5
  RUBOCOP_REQUIREMENT = '0.49.1'.freeze
@@ -11,4 +11,4 @@ class Deliverfile: DeliverfileProtocol {
11
11
 
12
12
 
13
13
 
14
- // Generated with fastlane 2.70.1
14
+ // Generated with fastlane 2.70.3
@@ -641,7 +641,7 @@ func bundleInstall(binstubs: String? = nil,
641
641
  RubyCommand.Argument(name: "with", value: with)])
642
642
  _ = runner.executeCommand(command)
643
643
  }
644
- func captureAndroidScreenshots(androidHome: String?,
644
+ func captureAndroidScreenshots(androidHome: String? = nil,
645
645
  buildToolsVersion: String? = nil,
646
646
  locales: [String] = ["en-US"],
647
647
  clearPreviousScreenshots: Bool = false,
@@ -1103,9 +1103,9 @@ func createPullRequest(apiToken: String,
1103
1103
  repo: String,
1104
1104
  title: String,
1105
1105
  body: String? = nil,
1106
- head: String?,
1106
+ head: String? = nil,
1107
1107
  base: String = "master",
1108
- apiUrl: String?) {
1108
+ apiUrl: String = "https://api.github.com") {
1109
1109
  let command = RubyCommand(commandID: "", methodName: "create_pull_request", className: nil, args: [RubyCommand.Argument(name: "api_token", value: apiToken),
1110
1110
  RubyCommand.Argument(name: "repo", value: repo),
1111
1111
  RubyCommand.Argument(name: "title", value: title),
@@ -1494,7 +1494,7 @@ func getPushCertificate(development: Bool = false,
1494
1494
  username: String,
1495
1495
  teamId: String? = nil,
1496
1496
  teamName: String? = nil,
1497
- p12Password: String = "",
1497
+ p12Password: String,
1498
1498
  pemName: String? = nil,
1499
1499
  outputPath: String = ".",
1500
1500
  newProfile: String? = nil) {
@@ -1513,13 +1513,13 @@ func getPushCertificate(development: Bool = false,
1513
1513
  RubyCommand.Argument(name: "new_profile", value: newProfile)])
1514
1514
  _ = runner.executeCommand(command)
1515
1515
  }
1516
- func getVersionNumber(xcodeproj: String? = nil,
1517
- scheme: String? = nil,
1518
- target: String? = nil) {
1516
+ @discardableResult func getVersionNumber(xcodeproj: String? = nil,
1517
+ scheme: String? = nil,
1518
+ target: String? = nil) -> String {
1519
1519
  let command = RubyCommand(commandID: "", methodName: "get_version_number", className: nil, args: [RubyCommand.Argument(name: "xcodeproj", value: xcodeproj),
1520
1520
  RubyCommand.Argument(name: "scheme", value: scheme),
1521
1521
  RubyCommand.Argument(name: "target", value: target)])
1522
- _ = runner.executeCommand(command)
1522
+ return runner.executeCommand(command)
1523
1523
  }
1524
1524
  func gitAdd(path: String? = nil,
1525
1525
  pathspec: String? = nil) {
@@ -1803,7 +1803,7 @@ func importCertificate(keychainName: String,
1803
1803
  keychainPath: String? = nil,
1804
1804
  keychainPassword: String? = nil,
1805
1805
  certificatePath: String,
1806
- certificatePassword: String = "",
1806
+ certificatePassword: String? = nil,
1807
1807
  logOutput: Bool = false) {
1808
1808
  let command = RubyCommand(commandID: "", methodName: "import_certificate", className: nil, args: [RubyCommand.Argument(name: "keychain_name", value: keychainName),
1809
1809
  RubyCommand.Argument(name: "keychain_path", value: keychainPath),
@@ -2154,7 +2154,7 @@ func pem(development: Bool = false,
2154
2154
  username: String,
2155
2155
  teamId: String? = nil,
2156
2156
  teamName: String? = nil,
2157
- p12Password: String = "",
2157
+ p12Password: String,
2158
2158
  pemName: String? = nil,
2159
2159
  outputPath: String = ".",
2160
2160
  newProfile: String? = nil) {
@@ -2778,7 +2778,7 @@ func setupJenkins(force: Bool = false,
2778
2778
  addKeychainToSearchList: String = "replace",
2779
2779
  setDefaultKeychain: Bool = true,
2780
2780
  keychainPath: String? = nil,
2781
- keychainPassword: String = "",
2781
+ keychainPassword: String,
2782
2782
  setCodeSigningIdentity: Bool = true,
2783
2783
  codeSigningIdentity: String? = nil,
2784
2784
  outputDirectory: String = "./output",
@@ -3661,7 +3661,7 @@ func xcexport() {
3661
3661
  botName: String,
3662
3662
  integrationNumber: String? = nil,
3663
3663
  username: String = "",
3664
- password: String = "",
3664
+ password: String? = nil,
3665
3665
  targetFolder: String = "./xcs_assets",
3666
3666
  keepAllAssets: Bool = false,
3667
3667
  trustSelfSignedCerts: Bool = true) -> [String] {
@@ -11,4 +11,4 @@ class Gymfile: GymfileProtocol {
11
11
 
12
12
 
13
13
 
14
- // Generated with fastlane 2.70.1
14
+ // Generated with fastlane 2.70.3
@@ -11,4 +11,4 @@ class Matchfile: MatchfileProtocol {
11
11
 
12
12
 
13
13
 
14
- // Generated with fastlane 2.70.1
14
+ // Generated with fastlane 2.70.3
@@ -11,4 +11,4 @@ class Precheckfile: PrecheckfileProtocol {
11
11
 
12
12
 
13
13
 
14
- // Generated with fastlane 2.70.1
14
+ // Generated with fastlane 2.70.3
@@ -11,4 +11,4 @@ class Scanfile: ScanfileProtocol {
11
11
 
12
12
 
13
13
 
14
- // Generated with fastlane 2.70.1
14
+ // Generated with fastlane 2.70.3
@@ -11,4 +11,4 @@ class Screengrabfile: ScreengrabfileProtocol {
11
11
 
12
12
 
13
13
 
14
- // Generated with fastlane 2.70.1
14
+ // Generated with fastlane 2.70.3
@@ -11,4 +11,4 @@ class Snapshotfile: SnapshotfileProtocol {
11
11
 
12
12
 
13
13
 
14
- // Generated with fastlane 2.70.1
14
+ // Generated with fastlane 2.70.3
@@ -46,6 +46,7 @@ require 'fastlane_core/analytics/action_launch_context'
46
46
  require 'fastlane_core/analytics/analytics_event_builder'
47
47
  require 'fastlane_core/analytics/analytics_ingester_client'
48
48
  require 'fastlane_core/analytics/analytics_session'
49
+ require 'fastlane_core/tag_version'
49
50
 
50
51
  # Third Party code
51
52
  require 'colored'
@@ -15,6 +15,13 @@ module FastlaneCore
15
15
  # the value which is used if there was no given values and no environment values
16
16
  attr_accessor :default_value
17
17
 
18
+ # the value which is used during Swift code generation
19
+ # if the default_value reads from ENV or a file, or from local credentials, we need
20
+ # to provide a different default or it might be included in our autogenerated Swift
21
+ # as a built-in default for the fastlane gem. This is because when we generate the
22
+ # Swift API at deployment time, it fetches the default_value from the config_items
23
+ attr_accessor :code_gen_default_value
24
+
18
25
  # An optional block which is called when a new value is set.
19
26
  # Check value is valid. This could be type checks or if a folder/file exists
20
27
  # You have to raise a specific exception if something goes wrong. Append .red after the string
@@ -36,8 +43,15 @@ module FastlaneCore
36
43
  attr_accessor :deprecated
37
44
 
38
45
  # [Boolean] Set if the variable is sensitive, such as a password or API token, to prevent echoing when prompted for the parameter
46
+ # If a default value exists, it won't be used during code generation as default values can read from environment variables.
39
47
  attr_accessor :sensitive
40
48
 
49
+ # [Boolean] Set if the default value should never be used during code generation for Swift
50
+ # We generate the Swift API at deployment time, and if there is a value that should never be
51
+ # included in the Fastlane.swift or other autogenerated classes, we need to strip it out.
52
+ # This includes things like API keys that could be read from ENV[]
53
+ attr_accessor :code_gen_sensitive
54
+
41
55
  # [Boolean] Set if the variable is to be converted to a shell-escaped String when provided as a Hash or Array
42
56
  # Allows items expected to be strings used in shell arguments to be alternatively provided as a Hash or Array for better readability and auto-escaped for us.
43
57
  attr_accessor :allow_shell_conversion
@@ -77,6 +91,8 @@ module FastlaneCore
77
91
  conflict_block: nil,
78
92
  deprecated: nil,
79
93
  sensitive: nil,
94
+ code_gen_sensitive: false,
95
+ code_gen_default_value: nil,
80
96
  display_in_shell: true)
81
97
  UI.user_error!("key must be a symbol") unless key.kind_of? Symbol
82
98
  UI.user_error!("env_name must be a String") unless (env_name || '').kind_of? String
@@ -121,9 +137,24 @@ module FastlaneCore
121
137
  @conflict_block = conflict_block
122
138
  @deprecated = deprecated
123
139
  @sensitive = sensitive
140
+ @code_gen_sensitive = code_gen_sensitive || sensitive
124
141
  @allow_shell_conversion = (type == :shell_string)
125
142
  @display_in_shell = display_in_shell
126
143
  @skip_type_validation = skip_type_validation # sometimes we allow multiple types which causes type validation failures, e.g.: export_options in gym
144
+
145
+ @code_gen_default_value = code_gen_default_value
146
+
147
+ update_code_gen_default_value_if_able!
148
+ end
149
+
150
+ # if code_gen_default_value is nil, use the default value if it isn't a `code_gen_sensitive` value
151
+ def update_code_gen_default_value_if_able!
152
+ if @code_gen_default_value.nil?
153
+ unless @code_gen_sensitive
154
+
155
+ @code_gen_default_value = @default_value
156
+ end
157
+ end
127
158
  end
128
159
 
129
160
  def verify!(value)
@@ -0,0 +1,24 @@
1
+ require "rubygems/version"
2
+
3
+ module FastlaneCore
4
+ # Utility class to construct a Gem::Version from a tag.
5
+ # Accepts vX.Y.Z and X.Y.Z.
6
+ class TagVersion < Gem::Version
7
+ class << self
8
+ def correct?(tag)
9
+ superclass.correct?(version_number_from_tag(tag))
10
+ end
11
+
12
+ # Gem::Version.new barfs on things like "v0.1.0", which is the style
13
+ # generated by the rake release task. Just strip off any initial v
14
+ # to generate a Gem::Version from a tag.
15
+ def version_number_from_tag(tag)
16
+ tag.sub(/^v/, "")
17
+ end
18
+ end
19
+
20
+ def initialize(tag)
21
+ super(self.class.version_number_from_tag(tag))
22
+ end
23
+ end
24
+ end