fastlane 1.17.1 → 1.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6d7680183725bf8a55700c383ee9f8dfc02f1d3c
4
- data.tar.gz: cd143876f1b00045c2ca888114ab13b3c3f1bb83
3
+ metadata.gz: 113e596cd87aeba33d9bc3db0b6864c94de0ca20
4
+ data.tar.gz: 8746dd48df41803c9e868099211af4c8fedddd90
5
5
  SHA512:
6
- metadata.gz: 8fa5f918bbda8d8076311c0dd720c391885fb201db4db7c644347334917e13ad71940997e85b54e3f13a068bedb1d661cb86c87b706c7566698e7948972bdc42
7
- data.tar.gz: 0f0717e2adf8caf0e3fe790dd7559438c62fde3780d031bd416e98374910c62f2384ec8300700895ea5a2f4dd6975f4588650d60b2712479beffbd0c13c9f41a
6
+ metadata.gz: 04b070d6da9487c6633e7af1706b3fa455346ec9409bfe665735b8964a54da2c12d8ed5795bb7429c2f30411c82472833d75b18be9ce2940efb7e780b11a848a
7
+ data.tar.gz: f4d5c2f7c92370e2351b8dc143682db08674b429a018ebce64378210983ff1e7d05c1542dcca7af018906fca572af84c35870b15b18e7b9b79f35ee3617969ec
@@ -105,7 +105,7 @@ module Fastlane
105
105
  result << line
106
106
  end
107
107
  io.close
108
- exit_status = $?.to_i
108
+ exit_status = $?.exitstatus
109
109
  end
110
110
 
111
111
  if exit_status != 0
@@ -0,0 +1,85 @@
1
+ module Fastlane
2
+ module Actions
3
+ class GetBuildNumberAction < Action
4
+ require 'shellwords'
5
+
6
+ def self.run(params)
7
+ # More information about how to set up your project and how it works:
8
+ # https://developer.apple.com/library/ios/qa/qa1827/_index.html
9
+
10
+ begin
11
+ folder = params[:xcodeproj] ? File.join('.', params[:xcodeproj], '..') : '.'
12
+
13
+ command_prefix = [
14
+ 'cd',
15
+ File.expand_path(folder).shellescape,
16
+ '&&'
17
+ ].join(' ')
18
+
19
+ command = [
20
+ command_prefix,
21
+ 'agvtool',
22
+ 'what-version',
23
+ '-terse'
24
+ ].join(' ')
25
+
26
+ if Helper.test?
27
+ Actions.lane_context[SharedValues::BUILD_NUMBER] = command
28
+ else
29
+
30
+ build_number = (Actions.sh command).split("\n").last.to_i
31
+
32
+ # Store the number in the shared hash
33
+ Actions.lane_context[SharedValues::BUILD_NUMBER] = build_number
34
+ end
35
+ rescue => ex
36
+ Helper.log.error 'Make sure to to follow the steps to setup your Xcode project: https://developer.apple.com/library/ios/qa/qa1827/_index.html'.yellow
37
+ raise ex
38
+ end
39
+ end
40
+
41
+ #####################################################
42
+ # @!group Documentation
43
+ #####################################################
44
+
45
+ def self.description
46
+ "Get the build number of your project"
47
+ end
48
+
49
+ def self.details
50
+ [
51
+ "This action will return the current build number set on your project.",
52
+ "You first have to set up your Xcode project, if you haven't done it already:",
53
+ "https://developer.apple.com/library/ios/qa/qa1827/_index.html"
54
+ ].join(' ')
55
+ end
56
+
57
+ def self.available_options
58
+ [
59
+ FastlaneCore::ConfigItem.new(key: :xcodeproj,
60
+ env_name: "FL_BUILD_NUMBER_PROJECT",
61
+ description: "optional, you must specify the path to your main Xcode project if it is not in the project root directory",
62
+ optional: true,
63
+ verify_block: Proc.new do |value|
64
+ raise "Please pass the path to the project, not the workspace".red if value.include?"workspace"
65
+ raise "Could not find Xcode project".red if (not File.exists?(value) and not Helper.is_test?)
66
+ end)
67
+ ]
68
+ end
69
+
70
+ def self.output
71
+ [
72
+ ['BUILD_NUMBER', 'The build number']
73
+ ]
74
+ end
75
+
76
+ def self.authors
77
+ ["Liquidsoul"]
78
+ end
79
+
80
+ def self.is_supported?(platform)
81
+ [:ios, :mac].include?platform
82
+ end
83
+ end
84
+ end
85
+ end
@@ -0,0 +1,85 @@
1
+ module Fastlane
2
+ module Actions
3
+ class GetVersionNumberAction < Action
4
+ require 'shellwords'
5
+
6
+ def self.run(params)
7
+ # More information about how to set up your project and how it works:
8
+ # https://developer.apple.com/library/ios/qa/qa1827/_index.html
9
+
10
+ begin
11
+ folder = params[:xcodeproj] ? File.join('.', params[:xcodeproj], '..') : '.'
12
+
13
+ command_prefix = [
14
+ 'cd',
15
+ File.expand_path(folder).shellescape,
16
+ '&&'
17
+ ].join(' ')
18
+
19
+ command = [
20
+ command_prefix,
21
+ 'agvtool',
22
+ 'what-marketing-version',
23
+ '-terse1'
24
+ ].join(' ')
25
+
26
+ if Helper.test?
27
+ Actions.lane_context[SharedValues::VERSION_NUMBER] = command
28
+ else
29
+
30
+ version_number = (Actions.sh command).split("\n").last
31
+
32
+ # Store the number in the shared hash
33
+ Actions.lane_context[SharedValues::VERSION_NUMBER] = version_number
34
+ end
35
+ rescue => ex
36
+ Helper.log.error 'Make sure to to follow the steps to setup your Xcode project: https://developer.apple.com/library/ios/qa/qa1827/_index.html'.yellow
37
+ raise ex
38
+ end
39
+ end
40
+
41
+ #####################################################
42
+ # @!group Documentation
43
+ #####################################################
44
+
45
+ def self.description
46
+ "Get the version number of your project"
47
+ end
48
+
49
+ def self.details
50
+ [
51
+ "This action will return the current version number set on your project.",
52
+ "You first have to set up your Xcode project, if you haven't done it already:",
53
+ "https://developer.apple.com/library/ios/qa/qa1827/_index.html"
54
+ ].join(' ')
55
+ end
56
+
57
+ def self.available_options
58
+ [
59
+ FastlaneCore::ConfigItem.new(key: :xcodeproj,
60
+ env_name: "FL_VERSION_NUMBER_PROJECT",
61
+ description: "optional, you must specify the path to your main Xcode project if it is not in the project root directory",
62
+ optional: true,
63
+ verify_block: Proc.new do |value|
64
+ raise "Please pass the path to the project, not the workspace".red if value.include?"workspace"
65
+ raise "Could not find Xcode project".red if (not File.exists?(value) and not Helper.is_test?)
66
+ end)
67
+ ]
68
+ end
69
+
70
+ def self.output
71
+ [
72
+ ['VERSION_NUMBER', 'The version number']
73
+ ]
74
+ end
75
+
76
+ def self.authors
77
+ ["Liquidsoul"]
78
+ end
79
+
80
+ def self.is_supported?(platform)
81
+ [:ios, :mac].include?platform
82
+ end
83
+ end
84
+ end
85
+ end
@@ -69,17 +69,18 @@ module Fastlane
69
69
  Actions.lane_context[SharedValues::DSYM_OUTPUT_PATH] = absolute_dsym_path
70
70
  ENV[SharedValues::IPA_OUTPUT_PATH.to_s] = absolute_ipa_path # for deliver
71
71
  ENV[SharedValues::DSYM_OUTPUT_PATH.to_s] = absolute_dsym_path
72
+
73
+ Helper.log.info "You are using legacy `shenzhen` to build your app".yellow
74
+ Helper.log.info "It is recommended to upgrade to `gym`".yellow
75
+ Helper.log.info "https://github.com/fastlane/gym".yellow
72
76
  rescue => ex
73
77
  [
74
78
  "-------------------------------------------------------",
75
79
  "Original Error:",
76
80
  " => " + ex.to_s,
77
- "A build error occured. This can have many reasons, usually",
78
- "it has something to do with code signing. The `ipa` action",
79
- "uses `shenzhen` under the hood: https://github.com/nomad/shenzhen",
80
- "For code signing related issues, check out this guide:",
81
- "https://github.com/KrauseFx/fastlane/blob/master/docs/CodeSigning.md",
82
- "The command that was used by fastlane:",
81
+ "A build error occured. You are using legacy `shenzhen` for building",
82
+ "it is recommended to upgrade to `gym`: ",
83
+ "https://github.com/fastlane/gym",
83
84
  core_command,
84
85
  "-------------------------------------------------------"
85
86
  ].each do |txt|
@@ -198,7 +198,28 @@ module Fastlane
198
198
 
199
199
  xcpretty_args = xcpretty_args.join(" ")
200
200
 
201
- Actions.sh "set -o pipefail && xcodebuild #{xcodebuild_args} | xcpretty #{xcpretty_args}"
201
+ # In some cases the simulator is not booting up in time
202
+ # One way to solve it is to try to rerun it for one more time
203
+ begin
204
+ Actions.sh "set -o pipefail && xcodebuild #{xcodebuild_args} | xcpretty #{xcpretty_args}"
205
+ rescue => ex
206
+ exit_status = $?.exitstatus
207
+
208
+ raise_error = true
209
+ if exit_status.eql? 65
210
+ iphone_simulator_time_out_error = /iPhoneSimulator: Timed out waiting/
211
+
212
+ if (iphone_simulator_time_out_error =~ ex.message) != nil
213
+ raise_error = false
214
+
215
+ Helper.log.warn "First attempt failed with iPhone Simulator error: #{iphone_simulator_time_out_error.source}"
216
+ Helper.log.warn "Retrying once more..."
217
+ Actions.sh "set -o pipefail && xcodebuild #{xcodebuild_args} | xcpretty #{xcpretty_args}"
218
+ end
219
+ end
220
+
221
+ raise ex if raise_error
222
+ end
202
223
  end
203
224
 
204
225
  def self.hash_to_args(hash)
@@ -1,3 +1,3 @@
1
1
  module Fastlane
2
- VERSION = '1.17.1'
2
+ VERSION = '1.18.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.17.1
4
+ version: 1.18.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Felix Krause
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-08-14 00:00:00.000000000 Z
11
+ date: 2015-08-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri
@@ -461,7 +461,9 @@ files:
461
461
  - lib/fastlane/actions/fastlane_version.rb
462
462
  - lib/fastlane/actions/frameit.rb
463
463
  - lib/fastlane/actions/gcovr.rb
464
+ - lib/fastlane/actions/get_build_number.rb
464
465
  - lib/fastlane/actions/get_github_release.rb
466
+ - lib/fastlane/actions/get_version_number.rb
465
467
  - lib/fastlane/actions/git_branch.rb
466
468
  - lib/fastlane/actions/git_pull.rb
467
469
  - lib/fastlane/actions/gym.rb
@@ -477,7 +479,7 @@ files:
477
479
  - lib/fastlane/actions/increment_build_number.rb
478
480
  - lib/fastlane/actions/increment_version_number.rb
479
481
  - lib/fastlane/actions/install_carthage.rb
480
- - lib/fastlane/actions/install_cocapods.rb
482
+ - lib/fastlane/actions/install_cocoapods.rb
481
483
  - lib/fastlane/actions/ipa.rb
482
484
  - lib/fastlane/actions/lane_context.rb
483
485
  - lib/fastlane/actions/last_git_tag.rb