fastlane 2.180.1 → 2.181.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +90 -90
  3. data/fastlane/lib/fastlane/actions/clipboard.rb +3 -6
  4. data/fastlane/lib/fastlane/actions/ensure_env_vars.rb +2 -6
  5. data/fastlane/lib/fastlane/actions/git_branch.rb +1 -1
  6. data/fastlane/lib/fastlane/actions/slack.rb +148 -127
  7. data/fastlane/lib/fastlane/helper/git_helper.rb +9 -1
  8. data/fastlane/lib/fastlane/lane_manager.rb +3 -2
  9. data/fastlane/lib/fastlane/version.rb +1 -1
  10. data/fastlane/swift/Deliverfile.swift +1 -1
  11. data/fastlane/swift/DeliverfileProtocol.swift +1 -1
  12. data/fastlane/swift/Fastlane.swift +5 -5
  13. data/fastlane/swift/Gymfile.swift +1 -1
  14. data/fastlane/swift/GymfileProtocol.swift +1 -1
  15. data/fastlane/swift/Matchfile.swift +1 -1
  16. data/fastlane/swift/MatchfileProtocol.swift +1 -1
  17. data/fastlane/swift/Precheckfile.swift +1 -1
  18. data/fastlane/swift/PrecheckfileProtocol.swift +1 -1
  19. data/fastlane/swift/Scanfile.swift +1 -1
  20. data/fastlane/swift/ScanfileProtocol.swift +1 -1
  21. data/fastlane/swift/Screengrabfile.swift +1 -1
  22. data/fastlane/swift/ScreengrabfileProtocol.swift +1 -1
  23. data/fastlane/swift/Snapshotfile.swift +1 -1
  24. data/fastlane/swift/SnapshotfileProtocol.swift +1 -1
  25. data/fastlane/swift/formatting/Brewfile.lock.json +10 -8
  26. data/fastlane_core/lib/fastlane_core.rb +22 -21
  27. data/fastlane_core/lib/fastlane_core/build_watcher.rb +50 -9
  28. data/fastlane_core/lib/fastlane_core/clipboard.rb +20 -0
  29. data/gym/lib/gym/runner.rb +5 -1
  30. data/scan/lib/scan/runner.rb +2 -0
  31. data/scan/lib/scan/test_command_generator.rb +3 -1
  32. data/snapshot/lib/snapshot/reports_generator.rb +4 -0
  33. data/spaceship/README.md +2 -12
  34. data/spaceship/lib/spaceship/commands_generator.rb +2 -1
  35. data/spaceship/lib/spaceship/spaceauth_runner.rb +19 -9
  36. data/spaceship/lib/spaceship/tunes/members.rb +1 -1
  37. data/supply/lib/supply/client.rb +3 -1
  38. data/supply/lib/supply/options.rb +2 -2
  39. data/supply/lib/supply/uploader.rb +1 -0
  40. metadata +21 -22
  41. data/fastlane/lib/fastlane/.fastlane_require.rb.swp +0 -0
  42. data/fastlane/lib/fastlane/actions/.cocoapods.rb.swp +0 -0
data/spaceship/README.md CHANGED
@@ -111,21 +111,11 @@ When your Apple account has 2 factor verification enabled, you'll automatically
111
111
 
112
112
  #### Web sessions
113
113
 
114
- To generate a web session for your CI machine, use
115
-
116
- ```sh
117
- fastlane spaceauth -u user@example.org
118
- ```
119
-
120
- This will authenticate you and provide a string that can be transferred to your CI system. Copy everything from `---\n` to your CI server and provide it as environment variable named `FASTLANE_SESSION`. For example:
121
-
122
- ```
123
- export FASTLANE_SESSION='---\n- !ruby/object:HTTP::Cookie\n name: DES5c148586dfd451e55afbaaa5f62418f91\n value: HSARMTKNSRVTWFla1+yO4gVPowH17VaaaxPFnUdMUegQZxqy1Ie1c2v6bM1vSOzIbuOmrl/FNenlScsd/NbF7/Lw4cpnL15jsyg0TOJwP32tC/NguPiyOaaaU+jrj4tf4uKdIywVaaaFSRVT\n domain: idmsa.apple.com\n for_domain: true\n path: "/"\n secure: true\n httponly: true\n expires: 2016-04-27 23:55:56.000000000 Z\n max_age: \n created_at: 2016-03-28 16:55:57.032086000 -07:00\n accessed_at: 2016-03-28 19:11:17.828141000 -07:00\n'
124
- ```
114
+ See [Continuous Integration > Authenticating with Apple services > Method 2: Two-step or two-factor authentication > Storing a manually verified session using spaceauth](https://docs.fastlane.tools/best-practices/continuous-integration/#storing-a-manually-verified-session-using-spaceauth)
125
115
 
126
116
  #### Transporter
127
117
 
128
- See [Continuous Integration > Authentication with Apple services > Application specific passwords](https://docs.fastlane.tools/best-practices/continuous-integration/#application-specific-passwords)
118
+ See [Getting Started > iOS > Authentication > Method 3: Application-specific passwords](https://docs.fastlane.tools/getting-started/ios/authentication/#method-3-application-specific-passwords)
129
119
 
130
120
  ## _spaceship_ in use
131
121
 
@@ -39,9 +39,10 @@ module Spaceship
39
39
  command :spaceauth do |c|
40
40
  c.syntax = 'fastlane spaceship spaceauth'
41
41
  c.description = 'Authentication helper for spaceship/fastlane to work with Apple 2-Step/2FA'
42
+ c.option('--copy_to_clipboard', 'Whether the session string should be copied to clipboard. For more info see https://docs.fastlane.tools/best-practices/continuous-integration/#storing-a-manually-verified-session-using-spaceauth`')
42
43
 
43
44
  c.action do |args, options|
44
- Spaceship::SpaceauthRunner.new(username: options.user).run
45
+ Spaceship::SpaceauthRunner.new(username: options.user, copy_to_clipboard: options.copy_to_clipboard).run
45
46
  end
46
47
  end
47
48
 
@@ -1,15 +1,17 @@
1
1
  require 'colored'
2
2
  require 'credentials_manager/appfile_config'
3
3
  require 'yaml'
4
+ require 'fastlane_core'
4
5
 
5
6
  require_relative 'tunes/tunes_client'
6
7
 
7
8
  module Spaceship
8
9
  class SpaceauthRunner
9
- def initialize(username: nil)
10
+ def initialize(username: nil, copy_to_clipboard: nil)
10
11
  @username = username
11
12
  @username ||= CredentialsManager::AppfileConfig.try_fetch_value(:apple_id)
12
13
  @username ||= ask("Username: ")
14
+ @copy_to_clipboard = copy_to_clipboard
13
15
  end
14
16
 
15
17
  def run
@@ -22,7 +24,7 @@ module Spaceship
22
24
  puts("Could not login to App Store Connect".red)
23
25
  puts("Please check your credentials and try again.".yellow)
24
26
  puts("This could be an issue with App Store Connect,".yellow)
25
- puts("Please try unsetting the FASTLANE_SESSION environment variable".yellow)
27
+ puts("Please try unsetting the FASTLANE_SESSION environment variable by calling 'unset FASTLANE_SESSION'".yellow)
26
28
  puts("(if it is set) and re-run `fastlane spaceauth`".yellow)
27
29
  puts("")
28
30
  puts("Exception type: #{ex.class}")
@@ -49,22 +51,30 @@ module Spaceship
49
51
  cookie.name.start_with?("myacinfo") || cookie.name == "dqsid" || cookie.name.start_with?("DES")
50
52
  end
51
53
 
52
- yaml = cookies.to_yaml.gsub("\n", "\\n")
54
+ @yaml = cookies.to_yaml.gsub("\n", "\\n")
53
55
 
54
56
  puts("---")
55
57
  puts("")
56
58
  puts("Pass the following via the FASTLANE_SESSION environment variable:")
57
- puts(yaml.cyan.underline)
59
+ puts(@yaml.cyan.underline)
58
60
  puts("")
59
61
  puts("")
60
62
  puts("Example:")
61
- puts("export FASTLANE_SESSION='#{yaml}'".cyan.underline)
63
+ puts("export FASTLANE_SESSION='#{@yaml}'".cyan.underline)
62
64
 
63
- if mac? && Spaceship::Client::UserInterface.interactive? && agree("🙄 Should fastlane copy the cookie into your clipboard, so you can easily paste it? (y/n)", true)
64
- require 'open3'
65
- Open3.popen3('pbcopy') { |input, _, _| input << yaml }
66
- puts("Successfully copied text into your clipboard 🎨".green)
65
+ if @copy_to_clipboard == false
66
+ puts("Skipped asking to copy the session string into your clipboard ⏭️".green)
67
+ elsif @copy_to_clipboard || (mac? && Spaceship::Client::UserInterface.interactive? && agree("🙄 Should fastlane copy the cookie into your clipboard, so you can easily paste it? (y/n)", true))
68
+ FastlaneCore::Clipboard.copy(content: @yaml)
69
+ puts("Successfully copied the session string into your clipboard 🎨".green)
67
70
  end
71
+
72
+ return self
73
+ end
74
+
75
+ def session_string
76
+ FastlaneCore::UI.user_error!("`#{__method__}` method called before calling `run` in `SpaceauthRunner`") unless @yaml
77
+ @yaml
68
78
  end
69
79
 
70
80
  def mac?
@@ -15,7 +15,7 @@ module Spaceship
15
15
 
16
16
  def find(email)
17
17
  all.each do |member|
18
- if member.email_address == email
18
+ if member.email_address.casecmp?(email)
19
19
  return member
20
20
  end
21
21
  end
@@ -327,12 +327,14 @@ module Supply
327
327
  def upload_mapping(path_to_mapping, apk_version_code)
328
328
  ensure_active_edit!
329
329
 
330
+ extension = File.extname(path_to_mapping).downcase
331
+
330
332
  call_google_api do
331
333
  client.upload_edit_deobfuscationfile(
332
334
  current_package_name,
333
335
  current_edit.id,
334
336
  apk_version_code,
335
- "proguard",
337
+ extension == ".zip" ? "nativeCode" : "proguard",
336
338
  upload_source: path_to_mapping,
337
339
  content_type: "application/octet-stream"
338
340
  )
@@ -223,7 +223,7 @@ module Supply
223
223
  default_value: false),
224
224
  FastlaneCore::ConfigItem.new(key: :mapping,
225
225
  env_name: "SUPPLY_MAPPING",
226
- description: "Path to the mapping file to upload",
226
+ description: "Path to the mapping file to upload (mapping.txt or native-debug-symbols.zip alike)",
227
227
  short_option: "-d",
228
228
  conflicting_options: [:mapping_paths],
229
229
  optional: true,
@@ -235,7 +235,7 @@ module Supply
235
235
  conflicting_options: [:mapping],
236
236
  optional: true,
237
237
  type: Array,
238
- description: "An array of paths to mapping files to upload",
238
+ description: "An array of paths to mapping files to upload (mapping.txt or native-debug-symbols.zip alike)",
239
239
  short_option: "-s",
240
240
  verify_block: proc do |value|
241
241
  UI.user_error!("Could not evaluate array from '#{value}'") unless value.kind_of?(Array)
@@ -304,6 +304,7 @@ module Supply
304
304
  mapping_paths = [Supply.config[:mapping]] unless (mapping_paths = Supply.config[:mapping_paths])
305
305
  mapping_paths.zip(apk_version_codes).each do |mapping_path, version_code|
306
306
  if mapping_path
307
+ UI.message("Preparing mapping at path '#{mapping_path}', version code #{version_code} for upload...")
307
308
  client.upload_mapping(mapping_path, version_code)
308
309
  end
309
310
  end
metadata CHANGED
@@ -1,37 +1,37 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.180.1
4
+ version: 2.181.0
5
5
  platform: ruby
6
6
  authors:
7
- - Roger Oba
8
- - Jimmy Dee
9
- - Stefan Natchev
10
- - Jorge Revuelta H
7
+ - Matthew Ellis
8
+ - Maksym Grebenets
9
+ - Iulian Onofrei
10
+ - Jérôme Lacoste
11
11
  - Josh Holtz
12
- - Fumiya Nakamura
13
- - Helmut Januschka
12
+ - Luka Mirosevic
13
+ - Joshua Liebowitz
14
14
  - Manu Wallner
15
- - Jan Piotrowski
16
- - Daniel Jankowski
17
- - Iulian Onofrei
18
- - Olivier Halligon
19
15
  - Max Ott
20
- - Kohki Miki
16
+ - Jorge Revuelta H
17
+ - Andrew McBurney
18
+ - Fumiya Nakamura
21
19
  - Felix Krause
22
20
  - Satoshi Namai
23
- - Maksym Grebenets
24
- - Joshua Liebowitz
25
- - Danielle Tomlinson
26
- - Jérôme Lacoste
27
- - Luka Mirosevic
21
+ - Helmut Januschka
28
22
  - Aaron Brager
29
- - Andrew McBurney
30
- - Matthew Ellis
23
+ - Roger Oba
24
+ - Jan Piotrowski
25
+ - Danielle Tomlinson
26
+ - Olivier Halligon
27
+ - Daniel Jankowski
28
+ - Jimmy Dee
29
+ - Stefan Natchev
30
+ - Kohki Miki
31
31
  autorequire:
32
32
  bindir: bin
33
33
  cert_chain: []
34
- date: 2021-04-08 00:00:00.000000000 Z
34
+ date: 2021-04-20 00:00:00.000000000 Z
35
35
  dependencies:
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: slack-notifier
@@ -1011,10 +1011,8 @@ files:
1011
1011
  - fastlane/lib/assets/s3_version_template.erb
1012
1012
  - fastlane/lib/fastlane.rb
1013
1013
  - fastlane/lib/fastlane/.erb_template_helper.rb.swp
1014
- - fastlane/lib/fastlane/.fastlane_require.rb.swp
1015
1014
  - fastlane/lib/fastlane/action.rb
1016
1015
  - fastlane/lib/fastlane/action_collector.rb
1017
- - fastlane/lib/fastlane/actions/.cocoapods.rb.swp
1018
1016
  - fastlane/lib/fastlane/actions/.git_commit.rb.swp
1019
1017
  - fastlane/lib/fastlane/actions/README.md
1020
1018
  - fastlane/lib/fastlane/actions/actions_helper.rb
@@ -1400,6 +1398,7 @@ files:
1400
1398
  - fastlane_core/lib/fastlane_core/android_package_name_guesser.rb
1401
1399
  - fastlane_core/lib/fastlane_core/build_watcher.rb
1402
1400
  - fastlane_core/lib/fastlane_core/cert_checker.rb
1401
+ - fastlane_core/lib/fastlane_core/clipboard.rb
1403
1402
  - fastlane_core/lib/fastlane_core/command_executor.rb
1404
1403
  - fastlane_core/lib/fastlane_core/configuration/commander_generator.rb
1405
1404
  - fastlane_core/lib/fastlane_core/configuration/config_item.rb