fastlane 1.44.0 → 1.45.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 454f1499e121f0653fd4d7775fd6486b76fe0bbf
4
- data.tar.gz: dabb9f88154401cc6902d71944490049a0e51fac
3
+ metadata.gz: 6c527b7a97a0d442bfed70878ae1260f9fa812e7
4
+ data.tar.gz: 7e5d085aa8127bdb4a1a4a9c7928ab17afaa2c2b
5
5
  SHA512:
6
- metadata.gz: 85d47d73ddb2bb3feaaebe2b085a7caea8980a105e48132941936c5c1d4c41684456ec470bb634321846f90a9b26eb594af2186e3d9eb460f13d6f92008b03bb
7
- data.tar.gz: 8f7c16a3374af3a570bfe3d834401487fb65ed2a9422dba075e33791d0f97a83298bac86bec450c3d7479d881b8630634ba9f50e5259c9cd56262e6a8503d920
6
+ metadata.gz: 51102a2598902baa5c1877da30cc805cf94e0565fa5918c41035a1cfcba022e08435d636ef96bbcfc11a094500e75bb8506842e6a6d746e84f2413fef22ae16a
7
+ data.tar.gz: 759d872fe3ebed5e5c28fcf2cded21463e90cb805663b10cc95c432e272fc0abe9fff464696d15263e2c47750dfbcf096ba83bb413e2a14bd3359779cc1ee40e
data/README.md CHANGED
@@ -25,7 +25,7 @@ fastlane
25
25
  [![Gem](https://img.shields.io/gem/v/fastlane.svg?style=flat)](http://rubygems.org/gems/fastlane)
26
26
  [![Build Status](https://img.shields.io/travis/fastlane/fastlane/master.svg?style=flat)](https://travis-ci.org/fastlane/fastlane)
27
27
 
28
- ######*fastlane* lets you define and run your deployment pipelines for different environments. It helps you unify your apps release process and automate the whole process. fastlane connects all fastlane tools and third party tools, like [CocoaPods](https://cocoapods.org/) and [xctool](https://github.com/facebook/xctool).
28
+ ######*fastlane* lets you define and run your deployment pipelines for different environments. It helps you unify your apps release process and automate the whole process. fastlane connects all fastlane tools and third party tools, like [CocoaPods](https://cocoapods.org/) and [Slack](https://slack.com).
29
29
 
30
30
  Get in contact with the developer on Twitter: [@KrauseFx](https://twitter.com/KrauseFx)
31
31
 
@@ -57,7 +57,7 @@ You define a `lane` like this (more details about the commands in the [Actions](
57
57
  lane :appstore do
58
58
  increment_build_number
59
59
  cocoapods
60
- xctool
60
+ scan
61
61
  snapshot
62
62
  sigh
63
63
  deliver
@@ -0,0 +1,263 @@
1
+ module Fastlane
2
+ module Actions
3
+ class AppaloosaAction < Action
4
+ APPALOOSA_SERVER = 'https://www.appaloosa-store.com/api/v1'
5
+ def self.run(params)
6
+ require 'http'
7
+
8
+ api_key = params[:api_token]
9
+ store_id = params[:store_id]
10
+
11
+ if request_email?(api_key, store_id)
12
+ auth = create_an_account params[:email]
13
+ api_key = auth['api_key']
14
+ store_id = auth['store_id']
15
+ return if error_detected(auth['errors'])
16
+ end
17
+
18
+ binary = normalize_binary_name(params[:binary])
19
+ remove_extra_screenshots_file(params[:screenshots])
20
+ binary_url = get_binary_link(binary, api_key, store_id, params[:group_ids])
21
+ return if binary_url.nil?
22
+ screenshots_url = get_screenshots_links(api_key, store_id, params[:screenshots], params[:locale], params[:device])
23
+ upload_on_appaloosa(api_key, store_id, binary_url, screenshots_url, params[:group_ids])
24
+ reset_original_binary_names(binary, params[:binary])
25
+ end
26
+
27
+ def self.get_binary_link(binary, api_key, store_id, group_ids)
28
+ key_s3 = upload_on_s3(binary, api_key, store_id, group_ids)
29
+ return if key_s3.nil?
30
+ get_s3_url(api_key, store_id, key_s3)
31
+ end
32
+
33
+ def self.upload_on_s3(file, api_key, store_id, group_ids = '')
34
+ file_name = file.split('/').last
35
+ response = HTTP.get("#{APPALOOSA_SERVER}/upload_services/presign_form",
36
+ json: { file: file_name,
37
+ store_id: store_id,
38
+ group_ids: group_ids })
39
+ json_res = JSON.parse(response)
40
+ return if error_detected json_res['errors']
41
+ url = json_res['s3_sign']
42
+ path = json_res['path']
43
+ uri = URI.parse(Base64.decode64(url))
44
+ File.open(file, 'rb') do |f|
45
+ Net::HTTP.start(uri.host) do |http|
46
+ http.send_request('PUT', uri.request_uri, f.read, 'content-type' => '')
47
+ end
48
+ end
49
+ path
50
+ end
51
+
52
+ def self.get_s3_url(api_key, store_id, path)
53
+ binary_path = HTTP.get("#{APPALOOSA_SERVER}/#{store_id}/upload_services/url_for_download",
54
+ json: { store_id: store_id,
55
+ api_key: api_key,
56
+ key: path })
57
+ if binary_path.status == 404
58
+ return nil if error_detected("A problem occurred with your API token and your store id. Please try again.")
59
+ end
60
+ json_res = JSON.parse(binary_path)
61
+ return if error_detected(json_res['errors'])
62
+ json_res['binary_url']
63
+ end
64
+
65
+ def self.reset_original_binary_names(current_name, original_name)
66
+ File.rename("#{current_name}", "#{original_name}")
67
+ end
68
+
69
+ def self.remove_extra_screenshots_file(screenshots_env)
70
+ extra_file = "#{screenshots_env}/screenshots.html"
71
+ File.unlink(extra_file) if File.exist?(extra_file)
72
+ end
73
+
74
+ def self.normalize_binary_name(binary)
75
+ binary_rename = binary.delete(' ')
76
+ File.rename("#{binary}", "#{binary_rename}")
77
+ binary_rename
78
+ end
79
+
80
+ def self.create_an_account(email)
81
+ response = HTTP.post("#{APPALOOSA_SERVER}/upload_services/create_an_account", form: { email: email })
82
+ JSON.parse(response)
83
+ end
84
+
85
+ def self.request_email?(api_key, store_id)
86
+ api_key.size == 0 && store_id.size == 0
87
+ end
88
+
89
+ def self.upload_screenshots(screenshots, api_key, store_id)
90
+ return if screenshots.nil?
91
+ list = []
92
+ list << screenshots.map do |screen|
93
+ upload_on_s3(screen, api_key, store_id)
94
+ end
95
+ end
96
+
97
+ def self.get_uploaded_links(uploaded_screenshots, api_key, store_id)
98
+ return if uploaded_screenshots.nil?
99
+ urls = []
100
+ urls << uploaded_screenshots.flatten.map do |url|
101
+ get_s3_url(api_key, store_id, url)
102
+ end
103
+ end
104
+
105
+ def self.get_screenshots_links(api_key, store_id, screenshots_path, locale, device)
106
+ screenshots = get_screenshots(screenshots_path, locale, device)
107
+ return if screenshots.nil?
108
+ uploaded = upload_screenshots(screenshots, api_key, store_id)
109
+ links = get_uploaded_links(uploaded, api_key, store_id)
110
+ links.kind_of?(Array) ? links.flatten : nil
111
+ end
112
+
113
+ def self.get_screenshots(screenshots_path, locale, device)
114
+ get_env_value('screenshots').nil? ? locale = '' : locale.concat('/')
115
+ device.nil? ? device = '' : device.concat('-')
116
+ screenshots_path.strip.size > 0 ? screenshots_list(screenshots_path, locale, device) : nil
117
+ end
118
+
119
+ def self.screenshots_list(path, locale, device)
120
+ return warning_detected("screenshots folder not found") unless Dir.exist?("#{path}/#{locale}")
121
+ list = Dir.entries("#{path}/#{locale}") - ['.', '..']
122
+ list.map do |screen|
123
+ next if screen.match(device).nil?
124
+ "#{path}/#{locale}#{screen}" unless Dir.exist?("#{path}/#{locale}#{screen}")
125
+ end.compact
126
+ end
127
+
128
+ def self.upload_on_appaloosa(api_key, store_id, binary_path, screenshots, group_ids)
129
+ screenshots = all_screenshots_links(screenshots)
130
+ response = HTTP.post("#{APPALOOSA_SERVER}/#{store_id}/applications/upload",
131
+ json: { store_id: store_id,
132
+ api_key: api_key,
133
+ application: {
134
+ binary_path: binary_path,
135
+ screenshot1: screenshots[0],
136
+ screenshot2: screenshots[1],
137
+ screenshot3: screenshots[2],
138
+ screenshot4: screenshots[3],
139
+ screenshot5: screenshots[4],
140
+ group_ids: group_ids,
141
+ provider: 'fastlane'
142
+ }
143
+ })
144
+ json_res = JSON.parse(response)
145
+ if json_res['errors']
146
+ Helper.log.info "App: #{json_res['errors']}".red
147
+ else
148
+ Helper.log.info "Binary processing: Check your app': #{json_res['link']}".green
149
+ end
150
+ end
151
+
152
+ def self.all_screenshots_links(screenshots)
153
+ if screenshots.nil?
154
+ screens = %w(screenshot1 screenshot2 screenshot3 screenshot4 screenshot5)
155
+ screenshots = screens.map do |_k, _v|
156
+ ''
157
+ end
158
+ else
159
+ missings = 5 - screenshots.count
160
+ (1..missings).map do |_i|
161
+ screenshots << ''
162
+ end
163
+ end
164
+ screenshots
165
+ end
166
+
167
+ def self.get_env_value(option)
168
+ available_options.map do |opt|
169
+ opt if opt.key == option.to_sym
170
+ end.compact[0].default_value
171
+ end
172
+
173
+ def self.error_detected(errors)
174
+ if errors
175
+ Helper.log.info("ERROR: #{errors}".red)
176
+ true
177
+ else
178
+ false
179
+ end
180
+ end
181
+
182
+ def self.warning_detected(warning)
183
+ Helper.log.info("WARNING: #{warning}".yellow)
184
+ nil
185
+ end
186
+
187
+ #####################################################
188
+ # @!group Documentation
189
+ #####################################################
190
+
191
+ def self.description
192
+ 'Upload your app to Appaloosa Store'
193
+ end
194
+
195
+ def self.details
196
+ [
197
+ "Appaloosa is a private mobile application store. This action offers a quick deployment on the platform.",
198
+ "You can create an account, push to your existing account, or manage your user groups. We accept iOS, Mac and Android applications."
199
+ ].join(" ")
200
+ end
201
+
202
+ def self.available_options
203
+ [
204
+ FastlaneCore::ConfigItem.new(key: :binary,
205
+ env_name: 'FL_APPALOOSA_BINARY',
206
+ description: 'Path to your IPA or APK file. Optional for ipa if you use the `ipa` or `xcodebuild` action. For Mac zip the .app',
207
+ default_value: Actions.lane_context[SharedValues::IPA_OUTPUT_PATH],
208
+ verify_block: proc do |value|
209
+ fail "Couldn't find ipa || apk file at path '#{value}'".red unless File.exist?(value)
210
+ end),
211
+ FastlaneCore::ConfigItem.new(key: :api_token,
212
+ env_name: 'FL_APPALOOSA_API_TOKEN',
213
+ description: "Your API Token, if you don\'t have an account hit [enter]",
214
+ verify_block: proc do
215
+ end),
216
+ FastlaneCore::ConfigItem.new(key: :store_id,
217
+ env_name: 'FL_APPALOOSA_STORE_ID',
218
+ description: "Your Store id, if you don\'t have an account hit [enter]",
219
+ verify_block: proc do |_value|
220
+ end),
221
+ FastlaneCore::ConfigItem.new(key: :email,
222
+ env_name: 'FL_APPALOOSA_EMAIL',
223
+ description: "It's your first time? Give your email address",
224
+ optional: false),
225
+ FastlaneCore::ConfigItem.new(key: :group_ids,
226
+ env_name: 'FL_APPALOOSA_GROUPS',
227
+ description: 'Your app is limited to special users? Give us the group ids',
228
+ default_value: '',
229
+ optional: true),
230
+ FastlaneCore::ConfigItem.new(key: :screenshots,
231
+ env_name: 'FL_APPALOOSA_SCREENSHOTS',
232
+ description: 'Add some screenshots application to your store or hit [enter]',
233
+ default_value: Actions.lane_context[SharedValues::SNAPSHOT_SCREENSHOTS_PATH]),
234
+ FastlaneCore::ConfigItem.new(key: :locale,
235
+ env_name: 'FL_APPALOOSA_LOCALE',
236
+ description: 'Select the folder locale for yours screenshots',
237
+ default_value: 'en-US',
238
+ optional: true
239
+ ),
240
+ FastlaneCore::ConfigItem.new(key: :device,
241
+ env_name: 'FL_APPALOOSA_DEVICE',
242
+ description: 'Select the device format for yours screenshots',
243
+ optional: true
244
+ ),
245
+ FastlaneCore::ConfigItem.new(key: :development,
246
+ env_name: 'FL_APPALOOSA_DEVELOPMENT',
247
+ description: 'Create a development certificate instead of a distribution one',
248
+ is_string: false,
249
+ default_value: false,
250
+ optional: true)
251
+ ]
252
+ end
253
+
254
+ def self.authors
255
+ ['Appaloosa']
256
+ end
257
+
258
+ def self.is_supported?(platform)
259
+ [:ios, :mac, :android].include? platform
260
+ end
261
+ end
262
+ end
263
+ end
@@ -0,0 +1,80 @@
1
+ module Fastlane
2
+ module Actions
3
+ module SharedValues
4
+ FL_CHANGELOG = :FL_CHANGELOG
5
+ end
6
+
7
+ class ChangelogFromGitCommitsAction < Action
8
+ def self.run(params)
9
+ if params[:between]
10
+ from, to = params[:between]
11
+ else
12
+ from = Actions.last_git_tag_name(params[:match_lightweight_tag])
13
+ Helper.log.debug "Found the last Git tag: #{from}"
14
+ to = 'HEAD'
15
+ end
16
+
17
+ Helper.log.info "Collecting Git commits between #{from} and #{to}".green
18
+
19
+ changelog = Actions.git_log_between(params[:pretty], from, to).gsub("\n\n", "\n") # as there are duplicate newlines
20
+ Actions.lane_context[SharedValues::FL_CHANGELOG] = changelog
21
+
22
+ changelog
23
+ end
24
+
25
+ #####################################################
26
+ # @!group Documentation
27
+ #####################################################
28
+
29
+ def self.description
30
+ "Collect git commit messages into a changelog"
31
+ end
32
+
33
+ def self.details
34
+ "By default, messages will be collected back to the last tag, but the range can be controlled"
35
+ end
36
+
37
+ def self.output
38
+ ['FL_CHANGELOG', 'The changelog String generated from the collected Git commit messages']
39
+ end
40
+
41
+ def self.available_options
42
+ [
43
+ FastlaneCore::ConfigItem.new(key: :between,
44
+ env_name: 'FL_GIT_COLLECT_MESSAGES_BETWEEN',
45
+ description: 'Array containing two Git revision values between which to collect messages',
46
+ optional: true,
47
+ is_string: false,
48
+ verify_block: proc do |value|
49
+ raise ":between must be of type array".red unless value.kind_of?(Array)
50
+ raise ":between must be an array of size 2".red unless (value || []).size == 2
51
+ end),
52
+ FastlaneCore::ConfigItem.new(key: :pretty,
53
+ env_name: 'FL_GIT_COLLECT_MESSAGES_PRETTY',
54
+ description: 'The format applied to each commit while generating the collected value',
55
+ optional: true,
56
+ default_value: '%B',
57
+ is_string: true),
58
+ FastlaneCore::ConfigItem.new(key: :match_lightweight_tag,
59
+ env_name: 'FL_GIT_COLLECT_MESSAGES_MATCH_LIGHTWEIGHT_TAG',
60
+ description: 'Whether or not to match a lightweight tag when searching for the last one',
61
+ optional: true,
62
+ default_value: true,
63
+ is_string: false)
64
+ ]
65
+ end
66
+
67
+ def self.return_value
68
+ "Returns a String containing your formatted git commits"
69
+ end
70
+
71
+ def self.author
72
+ ['mfurtak', 'asfalcone']
73
+ end
74
+
75
+ def self.is_supported?(platform)
76
+ true
77
+ end
78
+ end
79
+ end
80
+ end
@@ -7,16 +7,16 @@ module Fastlane
7
7
 
8
8
  params.values # to validate all inputs before looking for the ipa/apk
9
9
 
10
+ # We need to store notes in a file, because the crashlytics CLI (iOS) says so
10
11
  if params[:notes]
11
- require 'tempfile'
12
- # We need to store it in a file, because the crashlytics CLI (iOS) says so
13
12
  Helper.log.error "Overwriting :notes_path, because you specified :notes" if params[:notes_path]
14
13
 
15
- changelog = Tempfile.new('changelog')
16
- changelog.write(params[:notes])
17
- changelog.close
14
+ params[:notes_path] = Helper::CrashlyticsHelper.write_to_tempfile(params[:notes], 'changelog').path
15
+ elsif Actions.lane_context[SharedValues::FL_CHANGELOG] && !params[:notes_path]
16
+ Helper.log.info "Sending FL_CHANGELOG as release notes to Beta by Crashlytics"
18
17
 
19
- params[:notes_path] = changelog.path # we can only set it *after* writing the file there as it gets validated
18
+ params[:notes_path] = Helper::CrashlyticsHelper.write_to_tempfile(
19
+ Actions.lane_context[SharedValues::FL_CHANGELOG], 'changelog').path
20
20
  end
21
21
 
22
22
  if params[:ipa_path]
@@ -73,13 +73,13 @@ module Fastlane
73
73
  env_name: "CRASHLYTICS_API_TOKEN",
74
74
  description: "Crashlytics Beta API Token",
75
75
  verify_block: proc do |value|
76
- raise "No API token for Crashlytics given, pass using `api_token: 'token'`".red unless value and !value.empty?
76
+ raise "No API token for Crashlytics given, pass using `api_token: 'token'`".red unless value && !value.empty?
77
77
  end),
78
78
  FastlaneCore::ConfigItem.new(key: :build_secret,
79
79
  env_name: "CRASHLYTICS_BUILD_SECRET",
80
80
  description: "Crashlytics Build Secret",
81
81
  verify_block: proc do |value|
82
- raise "No build secret for Crashlytics given, pass using `build_secret: 'secret'`".red unless value and !value.empty?
82
+ raise "No build secret for Crashlytics given, pass using `build_secret: 'secret'`".red unless value && !value.empty?
83
83
  end),
84
84
  FastlaneCore::ConfigItem.new(key: :notes_path,
85
85
  env_name: "CRASHLYTICS_NOTES_PATH",
@@ -88,7 +88,7 @@ module Fastlane
88
88
  FastlaneCore::ConfigItem.new(key: :notes,
89
89
  env_name: "FL_HOCKEY_NOTES",
90
90
  description: "Beta Notes",
91
- default_value: "No changelog given"),
91
+ default_value: Actions.lane_context[SharedValues::FL_CHANGELOG] || "No changelog given"),
92
92
  FastlaneCore::ConfigItem.new(key: :notify,
93
93
  env_name: "FL_HOCKEY_NOTIFY",
94
94
  description: "Notify testers? 1 for yes",
@@ -2,10 +2,7 @@ module Fastlane
2
2
  module Actions
3
3
  class LastGitCommitAction < Action
4
4
  def self.run(params)
5
- message = sh "git log -1 --pretty=%B"
6
- author = sh "git log -1 --pretty=%an"
7
-
8
- {author: author, message: message}
5
+ Actions.last_git_commit_dict
9
6
  end
10
7
 
11
8
  #####################################################
@@ -2,7 +2,7 @@ module Fastlane
2
2
  module Actions
3
3
  class LastGitTagAction < Action
4
4
  def self.run(params)
5
- sh "git describe --tags --abbrev=0"
5
+ Actions.last_git_tag_name
6
6
  end
7
7
 
8
8
  #####################################################
@@ -98,8 +98,8 @@ module Fastlane
98
98
 
99
99
  def self.mail_teplate(options)
100
100
  hash = {
101
- author: Actions.git_author,
102
- last_commit: Actions.last_git_commit,
101
+ author: Actions.git_author_email,
102
+ last_commit: Actions.last_git_commit_message,
103
103
  message: options[:message],
104
104
  app_link: options[:app_link]
105
105
  }
@@ -156,23 +156,23 @@ module Fastlane
156
156
  end
157
157
 
158
158
  # git_author
159
- if Actions.git_author && should_add_payload[:git_author]
159
+ if Actions.git_author_email && should_add_payload[:git_author]
160
160
  if ENV['FASTLANE_SLACK_HIDE_AUTHOR_ON_SUCCESS'] && options[:success]
161
161
  # We only show the git author if the build failed
162
162
  else
163
163
  slack_attachment[:fields] << {
164
164
  title: 'Git Author',
165
- value: Actions.git_author,
165
+ value: Actions.git_author_email,
166
166
  short: true
167
167
  }
168
168
  end
169
169
  end
170
170
 
171
171
  # last_git_commit
172
- if Actions.last_git_commit && should_add_payload[:last_git_commit]
172
+ if Actions.last_git_commit_message && should_add_payload[:last_git_commit]
173
173
  slack_attachment[:fields] << {
174
174
  title: 'Git Commit',
175
- value: Actions.last_git_commit,
175
+ value: Actions.last_git_commit_message,
176
176
  short: false
177
177
  }
178
178
  end
@@ -27,7 +27,6 @@ module Fastlane
27
27
  end
28
28
 
29
29
  dot_env = Helper.is_test? ? nil : options.env
30
-
31
30
  Fastlane::LaneManager.cruise_lane(platform, lane, lane_parameters, dot_env)
32
31
  end
33
32
 
@@ -101,7 +101,7 @@ module Fastlane
101
101
 
102
102
  # User defines a platform block
103
103
  def platform(platform_name, &block)
104
- SupportedPlatforms.verify! platform_name
104
+ SupportedPlatforms.verify!(platform_name)
105
105
 
106
106
  self.current_platform = platform_name
107
107
 
@@ -79,6 +79,15 @@ module Fastlane
79
79
 
80
80
  return jar_path
81
81
  end
82
+
83
+ def write_to_tempfile(value, tempfilename)
84
+ require 'tempfile'
85
+
86
+ Tempfile.new(tempfilename).tap do |t|
87
+ t.write(value)
88
+ t.close
89
+ end
90
+ end
82
91
  end
83
92
  end
84
93
  end
@@ -1,17 +1,55 @@
1
1
  module Fastlane
2
2
  module Actions
3
- # Get the author name of the last git commit
3
+ def self.git_log_between(pretty_format, from, to)
4
+ Actions.sh("git log --pretty=#{pretty_format} #{from}...#{to}", log: false).chomp
5
+ end
6
+
7
+ def self.last_git_tag_name(match_lightweight = true)
8
+ command = ['git describe']
9
+ command << '--tags' if match_lightweight
10
+ command << '--abbrev=0'
11
+ Actions.sh(command.join(' '), log: false).chomp
12
+ end
13
+
14
+ def self.last_git_commit_dict
15
+ {
16
+ author: last_git_commit_formatted_with('%an'),
17
+ message: last_git_commit_formatted_with('%B')
18
+ }
19
+ end
20
+
21
+ # Gets the last git commit information formatted into a String by the provided
22
+ # pretty format String. See the git-log documentation for valid format placeholders
23
+ def self.last_git_commit_formatted_with(pretty_format)
24
+ Actions.sh("git log -1 --pretty=#{pretty_format}", log: false).chomp
25
+ end
26
+
27
+ # Get the author email of the last git commit
28
+ # <b>DEPRECATED:</b> Use <tt>git_author_email</tt> instead.
4
29
  def self.git_author
5
- s = `git log --name-status HEAD^..HEAD`
6
- s = s.match(/Author:.*<(.*)>/)[1]
30
+ Helper.log.warn '`git_author` is deprecated. Please use `git_author_email` instead.'.red
31
+ git_author_email
32
+ end
33
+
34
+ # Get the author email of the last git commit
35
+ def self.git_author_email
36
+ s = last_git_commit_formatted_with('%ae')
7
37
  return s if s.to_s.length > 0
8
38
  return nil
9
39
  rescue
10
40
  return nil
11
41
  end
12
42
 
43
+ # Returns the unwrapped subject and body of the last commit
44
+ # <b>DEPRECATED:</b> Use <tt>last_git_commit_message</tt> instead.
13
45
  def self.last_git_commit
14
- s = `git log -1 --pretty=%B`.strip
46
+ Helper.log.warn '`last_git_commit` is deprecated. Please use `last_git_commit_message` instead.'.red
47
+ last_git_commit_message
48
+ end
49
+
50
+ # Returns the unwrapped subject and body of the last commit
51
+ def self.last_git_commit_message
52
+ s = last_git_commit_formatted_with('%B').strip
15
53
  return s if s.to_s.length > 0
16
54
  nil
17
55
  end
@@ -4,7 +4,7 @@ module Fastlane
4
4
  # JUnit file documentation: http://llg.cubic.org/docs/junit/
5
5
  # And http://nelsonwells.net/2012/09/how-jenkins-ci-parses-and-displays-junit-output/
6
6
 
7
- containing_folder = Fastlane::FastlaneFolder.path || Dir.pwd
7
+ containing_folder = ENV['FL_REPORT_PATH'] || Fastlane::FastlaneFolder.path || Dir.pwd
8
8
  path = File.join(containing_folder, 'report.xml')
9
9
 
10
10
  @steps = results
@@ -13,21 +13,24 @@ module Fastlane
13
13
 
14
14
  is_platform = false
15
15
  begin
16
- is_platform = ff.is_platform_block? lane
17
- rescue
16
+ is_platform = ff.is_platform_block?(lane)
17
+ rescue # rescue, because this raises an exception if it can't be found at all
18
18
  end
19
19
 
20
- unless is_platform # rescue, because this raises an exception if it can't be found at all
20
+ unless is_platform
21
21
  # maybe the user specified a default platform
22
22
  # We'll only do this, if the lane specified isn't a platform, as we want to list all platforms then
23
23
 
24
- platform ||= Actions.lane_context[Actions::SharedValues::DEFAULT_PLATFORM]
24
+ # Make sure that's not a lane without a platform
25
+ unless ff.runner.available_lanes.include?(lane)
26
+ platform ||= Actions.lane_context[Actions::SharedValues::DEFAULT_PLATFORM]
27
+ end
25
28
  end
26
29
 
27
30
  if !platform and lane
28
31
  # Either, the user runs a specific lane in root or want to auto complete the available lanes for a platform
29
32
  # e.g. `fastlane ios` should list all available iOS actions
30
- if ff.is_platform_block? lane
33
+ if ff.is_platform_block?(lane)
31
34
  platform = lane
32
35
  lane = nil
33
36
  end
@@ -1,3 +1,3 @@
1
1
  module Fastlane
2
- VERSION = '1.44.0'
2
+ VERSION = '1.45.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.44.0
4
+ version: 1.45.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-12-03 00:00:00.000000000 Z
11
+ date: 2015-12-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: krausefx-shenzhen
@@ -148,7 +148,7 @@ dependencies:
148
148
  requirements:
149
149
  - - ">="
150
150
  - !ruby/object:Gem::Version
151
- version: 0.27.0
151
+ version: 0.28.0
152
152
  - - "<"
153
153
  - !ruby/object:Gem::Version
154
154
  version: 1.0.0
@@ -158,7 +158,7 @@ dependencies:
158
158
  requirements:
159
159
  - - ">="
160
160
  - !ruby/object:Gem::Version
161
- version: 0.27.0
161
+ version: 0.28.0
162
162
  - - "<"
163
163
  - !ruby/object:Gem::Version
164
164
  version: 1.0.0
@@ -208,7 +208,7 @@ dependencies:
208
208
  requirements:
209
209
  - - ">="
210
210
  - !ruby/object:Gem::Version
211
- version: 1.5.1
211
+ version: 1.6.2
212
212
  - - "<"
213
213
  - !ruby/object:Gem::Version
214
214
  version: 2.0.0
@@ -218,7 +218,7 @@ dependencies:
218
218
  requirements:
219
219
  - - ">="
220
220
  - !ruby/object:Gem::Version
221
- version: 1.5.1
221
+ version: 1.6.2
222
222
  - - "<"
223
223
  - !ruby/object:Gem::Version
224
224
  version: 2.0.0
@@ -228,7 +228,7 @@ dependencies:
228
228
  requirements:
229
229
  - - ">="
230
230
  - !ruby/object:Gem::Version
231
- version: 1.2.1
231
+ version: 1.2.2
232
232
  - - "<"
233
233
  - !ruby/object:Gem::Version
234
234
  version: 2.0.0
@@ -238,7 +238,7 @@ dependencies:
238
238
  requirements:
239
239
  - - ">="
240
240
  - !ruby/object:Gem::Version
241
- version: 1.2.1
241
+ version: 1.2.2
242
242
  - - "<"
243
243
  - !ruby/object:Gem::Version
244
244
  version: 2.0.0
@@ -308,7 +308,7 @@ dependencies:
308
308
  requirements:
309
309
  - - ">="
310
310
  - !ruby/object:Gem::Version
311
- version: 1.1.3
311
+ version: 1.2.0
312
312
  - - "<"
313
313
  - !ruby/object:Gem::Version
314
314
  version: 2.0.0
@@ -318,7 +318,7 @@ dependencies:
318
318
  requirements:
319
319
  - - ">="
320
320
  - !ruby/object:Gem::Version
321
- version: 1.1.3
321
+ version: 1.2.0
322
322
  - - "<"
323
323
  - !ruby/object:Gem::Version
324
324
  version: 2.0.0
@@ -328,7 +328,7 @@ dependencies:
328
328
  requirements:
329
329
  - - ">="
330
330
  - !ruby/object:Gem::Version
331
- version: 1.0.1
331
+ version: 1.0.2
332
332
  - - "<"
333
333
  - !ruby/object:Gem::Version
334
334
  version: 2.0.0
@@ -338,7 +338,7 @@ dependencies:
338
338
  requirements:
339
339
  - - ">="
340
340
  - !ruby/object:Gem::Version
341
- version: 1.0.1
341
+ version: 1.0.2
342
342
  - - "<"
343
343
  - !ruby/object:Gem::Version
344
344
  version: 2.0.0
@@ -368,7 +368,7 @@ dependencies:
368
368
  requirements:
369
369
  - - ">="
370
370
  - !ruby/object:Gem::Version
371
- version: 1.0.1
371
+ version: 1.1.0
372
372
  - - "<"
373
373
  - !ruby/object:Gem::Version
374
374
  version: 2.0.0
@@ -378,7 +378,7 @@ dependencies:
378
378
  requirements:
379
379
  - - ">="
380
380
  - !ruby/object:Gem::Version
381
- version: 1.0.1
381
+ version: 1.1.0
382
382
  - - "<"
383
383
  - !ruby/object:Gem::Version
384
384
  version: 2.0.0
@@ -561,6 +561,7 @@ files:
561
561
  - lib/fastlane/actions/README.md
562
562
  - lib/fastlane/actions/actions_helper.rb
563
563
  - lib/fastlane/actions/add_git_tag.rb
564
+ - lib/fastlane/actions/appaloosa.rb
564
565
  - lib/fastlane/actions/appetize.rb
565
566
  - lib/fastlane/actions/appledoc.rb
566
567
  - lib/fastlane/actions/appstore.rb
@@ -570,6 +571,7 @@ files:
570
571
  - lib/fastlane/actions/bundle_install.rb
571
572
  - lib/fastlane/actions/carthage.rb
572
573
  - lib/fastlane/actions/cert.rb
574
+ - lib/fastlane/actions/changelog_from_git_commits.rb
573
575
  - lib/fastlane/actions/chatwork.rb
574
576
  - lib/fastlane/actions/clean_build_artifacts.rb
575
577
  - lib/fastlane/actions/clean_cocoapods_cache.rb
@@ -727,7 +729,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
727
729
  version: '0'
728
730
  requirements: []
729
731
  rubyforge_project:
730
- rubygems_version: 2.2.2
732
+ rubygems_version: 2.4.0
731
733
  signing_key:
732
734
  specification_version: 4
733
735
  summary: Connect all iOS deployment tools into one streamlined workflow