fastlane 0.1.1 → 0.1.2

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: 7712610ad940e76f9e9548555f84834db2022939
4
- data.tar.gz: 32c170a4ac5b1a17069785ca55b2192524df301f
3
+ metadata.gz: a8e57997943c582fafba1fc9005757af2a43252c
4
+ data.tar.gz: b55cc9e00c8cc3f0e90e2cae93263f9758a8ba1b
5
5
  SHA512:
6
- metadata.gz: ee1e46c4830c9990c112e6be84a85fdf44433023a95f8b9c242f736272ea0b0841f80c9700f1dd54780ff4acd85265ea2e17884ec73c3283c5d4b2a7a469a25f
7
- data.tar.gz: baa6239e7d1287df96d30e3a2149e3415a07665a4744385c5dc2b232854c7672fa2705ae929a6efde994c3d4a4db94d5db9e7ab5508d016e608188119de5075d
6
+ metadata.gz: 2c405b38e8700620c015b19c1ad79a793075d64911ffe88af7eab498fd96b501f3ebc35463fc26fc833c6803492cc6bedf32977964187c52d637fa9ddfc8ace7
7
+ data.tar.gz: cdb1520235d1983d00a596f9d9aba33c3e73a9394c297bdddd6c0f0dede22b58f6e8a66a4c92581ced3ce24dc88098b18eb91ab3e347b9029abcafec9fdaeef4
data/README.md CHANGED
@@ -16,6 +16,7 @@ fastlane
16
16
  [![Twitter: @KauseFx](https://img.shields.io/badge/contact-@KrauseFx-blue.svg?style=flat)](https://twitter.com/KrauseFx)
17
17
  [![License](http://img.shields.io/badge/license-MIT-green.svg?style=flat)](https://github.com/KrauseFx/fastlane/blob/master/LICENSE)
18
18
  [![Gem](https://img.shields.io/gem/v/fastlane.svg?style=flat)](http://rubygems.org/gems/fastlane)
19
+ [![Build Status](https://img.shields.io/travis/KrauseFx/fastlane/master.svg?style=flat)](https://travis-ci.org/KrauseFx/fastlane)
19
20
 
20
21
  ######*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](http://cocoapods.org) and [xctool](https://github.com/facebook/xctool).
21
22
 
@@ -193,8 +194,22 @@ hockey({
193
194
  notes: "Changelog"
194
195
  })
195
196
  ```
197
+
198
+ Symbols will also be uploaded automatically if a `app.dSYM.zip` file is found next to `app.ipa`. In case it is located in a different place you can specify the path explicitly in `:dsym` parameter.
199
+
196
200
  More information about the available options can be found in the [HockeyApp Docs](http://support.hockeyapp.net/kb/api/api-versions#upload-version).
197
201
 
202
+ #### [Slack](http://slack.com)
203
+ Send a message to **#channel** (by default) or a direct message to **@username** with success (green) or failure (red) status.
204
+
205
+ ```ruby
206
+ slack({
207
+ message: "App successfully released!",
208
+ channel: "#channel",
209
+ success: true,
210
+ })
211
+ ```
212
+
198
213
  #### [Testmunk](http://testmunk.com)
199
214
  Run your functional tests on real iOS devices over the cloud (for free on an iPod). With this simple [testcase](https://github.com/testmunk/TMSample/blob/master/testcases/smoke/smoke_features.zip) you can ensure your app launches and there is no crash at launch. Tests can be extended with [Testmunk's library](http://docs.testmunk.com/en/latest/steps.html) or custom steps. More details about this action can be found in [`testmunk.rb`](https://github.com/KrauseFx/fastlane/blob/master/lib/fastlane/actions/testmunk.rb).
200
215
  ```ruby
@@ -238,8 +253,7 @@ This block will get executed when an error occurs, in any of the blocks (*before
238
253
  error do |lane, exception|
239
254
  slack({
240
255
  message: "Successfully deployed new App Update for [AppName](http://link.com).",
241
- success: false,
242
- channel: 'development'
256
+ success: false
243
257
  })
244
258
  end
245
259
  ```
@@ -247,6 +261,8 @@ end
247
261
  # Extensions
248
262
  Why only use the default actions? Create your own to extend the functionality of `fastlane`.
249
263
 
264
+ The build step you create will behave exactly like the built in actions.
265
+
250
266
  Just run `fastlane new_action`. Then enter the name of the action and edit the generated Ruby file in `fastlane/actions/[action_name].rb`.
251
267
 
252
268
  From then on, you can just start using your action in your `Fastfile`.
@@ -288,9 +304,9 @@ I recommend the following plugins:
288
304
  ## Build Step
289
305
  Use the following as your build step:
290
306
  ```
291
- fastlane appstore --trace
307
+ fastlane appstore
292
308
  ```
293
- Replace `appstore` with the lane you want to use. I recommend appending the `--trace` to make debugging easier in case something goes wrong.
309
+ Replace `appstore` with the lane you want to use.
294
310
 
295
311
  ## Test Results and Screenshtos
296
312
 
@@ -400,10 +416,10 @@ actions_path '../custom_actions_folder/'
400
416
  ```
401
417
 
402
418
  # Credentials
403
- A detailed description about your credentials is available on a [seperate repo](https://github.com/KrauseFx/CredentialsManager).
419
+ A detailed description about your credentials is available on a [separate repo](https://github.com/KrauseFx/CredentialsManager).
404
420
 
405
421
  # Need help?
406
- - If there is a technical problem with ```fastlane```, submit an issue. Run ```fastlane --trace``` to get the stack trace.
422
+ - If there is a technical problem with ```fastlane```, submit an issue.
407
423
  - I'm available for contract work - drop me an email: fastlane@krausefx.com
408
424
 
409
425
  # License
@@ -20,7 +20,7 @@ class FastlaneApplication
20
20
  program :help, 'GitHub', 'https://github.com/krausefx/fastlane'
21
21
  program :help_formatter, :compact
22
22
 
23
- global_option('--verbose') { $verbose = true }
23
+ always_trace!
24
24
 
25
25
  command :run do |c|
26
26
  c.syntax = 'fastlane run [lane]'
@@ -1,4 +1,4 @@
1
- # Customise this file, documentation can be found here:
1
+ # Customise this file, documentation can be found here:
2
2
  # https://github.com/krausefx/fastlane#customise-the-fastfile
3
3
 
4
4
  # Change the syntax highlighting to Ruby
@@ -11,13 +11,13 @@ before_all do
11
11
  # sh "./customShellScript.sh"
12
12
 
13
13
  # increment_build_number
14
-
14
+
15
15
  cocoapods
16
16
 
17
17
  xctool
18
18
  end
19
19
 
20
- lane :test do
20
+ lane :test do
21
21
  snapshot
22
22
  end
23
23
 
@@ -6,6 +6,8 @@ module Fastlane
6
6
 
7
7
  class FrameitAction
8
8
  def self.run(params)
9
+ return if Helper.is_test?
10
+
9
11
  require 'frameit'
10
12
 
11
13
  color = Frameit::Editor::Color::BLACK
@@ -25,6 +25,19 @@ module Fastlane
25
25
  raise "No IPA file given or found, pass using `ipa: 'path.ipa'`".red unless options[:ipa]
26
26
  raise "IPA file on path '#{File.expand_path(options[:ipa])}' not found".red unless File.exists?(options[:ipa])
27
27
 
28
+ if options[:dsym]
29
+ options[:dsym_filename] = options[:dsym]
30
+ else
31
+ dsym_path = options[:ipa].gsub("ipa", "app.dSYM.zip")
32
+ if File.exists?(dsym_path)
33
+ options[:dsym_filename] = dsym_path
34
+ else
35
+ Helper.log.info "Symbols not found on path #{File.expand_path(dsym_path)}. Crashes won't be symbolicated properly".yellow
36
+ end
37
+ end
38
+
39
+ raise "Symbols on path '#{File.expand_path(options[:dsym_filename])}' not found".red if (options[:dsym_filename] && !File.exists?(options[:dsym_filename]))
40
+
28
41
  Helper.log.info "Starting with ipa upload to HockeyApp... this could take some time.".green
29
42
 
30
43
  client = Shenzhen::Plugins::HockeyApp::Client.new(options[:api_token])
@@ -20,16 +20,18 @@ module Fastlane
20
20
  command = "agvtool next-version -all"
21
21
  end
22
22
 
23
- Actions.sh command
23
+ if Helper.is_test?
24
+ Actions.lane_context[SharedValues::BUILD_NUMBER] = command
25
+ else
24
26
 
25
- # Store the new number in the shared hash
26
- build_number = `agvtool what-version`.split("\n").last.to_i
27
+ Actions.sh command
27
28
 
28
- if Helper.is_test?
29
- build_number = command
30
- end
29
+ # Store the new number in the shared hash
30
+ build_number = `agvtool what-version`.split("\n").last.to_i
31
+
32
+ Actions.lane_context[SharedValues::BUILD_NUMBER] = build_number
31
33
 
32
- Actions.lane_context[SharedValues::BUILD_NUMBER] = build_number
34
+ end
33
35
  rescue => ex
34
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
35
37
  raise ex
@@ -10,8 +10,8 @@ module Fastlane
10
10
  require 'credentials_manager/appfile_config'
11
11
 
12
12
  type = Sigh::DeveloperCenter::APPSTORE
13
- type = Sigh::DeveloperCenter::ADHOC if params.first == :adhoc
14
- type = Sigh::DeveloperCenter::DEVELOPMENT if params.first == :development
13
+ type = Sigh::DeveloperCenter::ADHOC if params.include? :adhoc
14
+ type = Sigh::DeveloperCenter::DEVELOPMENT if params.include? :development
15
15
 
16
16
  return type if Helper.is_test?
17
17
 
@@ -22,10 +22,10 @@ module Fastlane
22
22
  output_path = File.expand_path(File.join('.', File.basename(path)))
23
23
  FileUtils.mv(path, output_path)
24
24
  Helper.log.info "Exported provisioning profile to '#{output_path}'".green
25
- Actions.sh "open '#{output_path}'"
25
+ Actions.sh "open '#{output_path}'" unless params.include? :skip_install
26
26
 
27
27
  Actions.lane_context[SharedValues::SIGH_PROFILE_PATH] = output_path # absolute URL
28
28
  end
29
29
  end
30
30
  end
31
- end
31
+ end
@@ -1,16 +1,16 @@
1
1
  module Fastlane
2
2
  module Actions
3
3
  module SharedValues
4
-
4
+
5
5
  end
6
6
 
7
7
  class SlackAction
8
8
  def self.run(params)
9
- options = { message: '',
10
- success: true,
9
+ options = { message: '',
10
+ success: true,
11
11
  channel: nil
12
12
  }.merge(params.first || {})
13
-
13
+
14
14
  require 'slack-notifier'
15
15
 
16
16
  color = (options[:success] ? 'good' : 'danger')
@@ -25,7 +25,8 @@ module Fastlane
25
25
  notifier = Slack::Notifier.new url
26
26
 
27
27
  notifier.username = 'fastlane'
28
- notifier.channel = "##{options[:channel]}" if options[:channel].to_s.length > 0
28
+ notifier.channel = "#{options[:channel]}" if options[:channel].to_s.length > 0
29
+ notifier.channel = "##{notifier.channel}" unless ["#", "@"].include? notifier.channel[0] # send message to channel by default
29
30
 
30
31
  test_result = {
31
32
  fallback: options[:message],
@@ -45,7 +46,7 @@ module Fastlane
45
46
  ]
46
47
  }
47
48
 
48
- notifier.ping "",
49
+ notifier.ping "",
49
50
  icon_url: 'https://s3-eu-west-1.amazonaws.com/fastlane.tools/fastlane.png',
50
51
  attachments: [test_result]
51
52
 
@@ -53,4 +54,4 @@ module Fastlane
53
54
  end
54
55
  end
55
56
  end
56
- end
57
+ end
@@ -6,8 +6,6 @@ module Fastlane
6
6
 
7
7
  class SnapshotAction
8
8
  def self.run(params)
9
- require 'snapshot'
10
-
11
9
  clean = true
12
10
  clean = false if params.first == :noclean
13
11
 
@@ -16,6 +14,8 @@ module Fastlane
16
14
  return clean
17
15
  end
18
16
 
17
+ require 'snapshot'
18
+
19
19
  Dir.chdir(FastlaneFolder.path) do
20
20
  Snapshot::SnapshotConfig.shared_instance
21
21
  Snapshot::Runner.new.work(clean: clean)
@@ -2,7 +2,10 @@ module Fastlane
2
2
  module Actions
3
3
  class XctoolAction
4
4
  def self.run(params)
5
- raise "xctool not installed, please install using `brew install xctool`".red if `which xctool`.length == 0
5
+ unless Helper.is_test?
6
+ raise "xctool not installed, please install using `brew install xctool`".red if `which xctool`.length == 0
7
+ end
8
+
6
9
  Actions.sh("xctool " + params.join(" "))
7
10
  end
8
11
  end
@@ -29,7 +29,11 @@ module Fastlane
29
29
  duration = ((Time.now - start) / 60.0).round
30
30
 
31
31
  unless e
32
- Helper.log.info "fastlane.tools just saved you #{duration} minutes! 🎉".green
32
+ if duration > 5
33
+ Helper.log.info "fastlane.tools just saved you #{duration} minutes! 🎉".green
34
+ else
35
+ Helper.log.info "fastlane.tools finished successfully 🎉".green
36
+ end
33
37
  else
34
38
  Helper.log.fatal "fastlane finished with errors".red
35
39
  raise e
@@ -1,3 +1,3 @@
1
1
  module Fastlane
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
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: 0.1.1
4
+ version: 0.1.2
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-01-16 00:00:00.000000000 Z
11
+ date: 2015-01-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json