fastlane 2.82.0.beta.20180222010003 → 2.82.0.beta.20180223010003

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: 0071ace38acf8e4f22d7eff9f2981444490e2b8f
4
- data.tar.gz: de15fafda10e49643d02cb3d889bfab577b5dc74
3
+ metadata.gz: ff02f04c2efc782d90b6082d827aa42b8779915c
4
+ data.tar.gz: 5c35f24eb249af77add3fa24d19c1f69411f3626
5
5
  SHA512:
6
- metadata.gz: 5821d0f4d9811339dea1d80285c1b41408e57a811b64dc99479cde3ffb15cd716347ffe29652246acfaf9ba58b4a4edd636170763cab73eb283930c406029ab0
7
- data.tar.gz: 56fa75771b88ae4135e9e69833e80db5cc92926bfbace671d06c6379c1b6cabd66218553ada1c8dbf577fc1eb00723bef63a196044ee6228611efab9b02eacfa
6
+ metadata.gz: 46efa7c14c4881c6d6d426295a48407ac3dd5ecfd9f56114d6191e5311cfeda40b9db46603464b0cf98ed1370991e1fcb4e46b21adb0e843007916328576ef03
7
+ data.tar.gz: 83647d742c6f92503ff756de030b72fedc698d40ba4d2dc190579e1e0184ff3c976366456099cb597214b26f7d5944ff986a8f158c5494911edfdf265751de2b
@@ -44,10 +44,9 @@ Key | Description | Default
44
44
  <%- (action.available_options || []).each do |config_item| -%>
45
45
  <%- next unless config_item.kind_of?(FastlaneCore::ConfigItem) -%>
46
46
  <%- next if config_item.description.to_s.length == 0 -%>
47
- `<%= config_item.key %>` | <%= config_item.description %> | <%= config_item.default_value.nil? ? "-" : (config_item.default_value_dynamic ? "*" : config_item.default_value) %>
47
+ `<%= config_item.key %>` | <%= config_item.description %> | <%= config_item.doc_default_value %>
48
48
  <%- end %>
49
- _- = this parameter doesn't have a default value_<br/>
50
- _* = this default value is dependent on the user's system_
49
+ <em id="dynamic">* = default value is dependent on the user's system</em>
51
50
  <% end %><%# End of action.available_options... %>
52
51
 
53
52
  <hr />
@@ -46,7 +46,7 @@ module Fastlane
46
46
  optional: true),
47
47
  FastlaneCore::ConfigItem.new(key: :grouping,
48
48
  env_name: "FL_GIT_TAG_GROUPING",
49
- description: "Is used to keep your tags organised under one 'folder'. Defaults to 'builds'",
49
+ description: "Is used to keep your tags organised under one 'folder'",
50
50
  default_value: 'builds'),
51
51
  FastlaneCore::ConfigItem.new(key: :prefix,
52
52
  env_name: "FL_GIT_TAG_PREFIX",
@@ -65,10 +65,12 @@ module Fastlane
65
65
  FastlaneCore::ConfigItem.new(key: :message,
66
66
  env_name: "FL_GIT_TAG_MESSAGE",
67
67
  description: "The tag message. Defaults to the tag's name",
68
+ default_value_dynamic: true,
68
69
  optional: true),
69
70
  FastlaneCore::ConfigItem.new(key: :commit,
70
71
  env_name: "FL_GIT_TAG_COMMIT",
71
72
  description: "The commit or object where the tag will be set. Defaults to the current HEAD",
73
+ default_value_dynamic: true,
72
74
  optional: true),
73
75
  FastlaneCore::ConfigItem.new(key: :force,
74
76
  env_name: "FL_GIT_TAG_FORCE",
@@ -115,7 +115,7 @@ module Fastlane
115
115
  optional: true),
116
116
  FastlaneCore::ConfigItem.new(key: :platform,
117
117
  env_name: "APPETIZE_PLATFORM",
118
- description: "Platform. Either `ios` or `android`. Default is `ios`",
118
+ description: "Platform. Either `ios` or `android`",
119
119
  is_string: true,
120
120
  default_value: 'ios'),
121
121
  FastlaneCore::ConfigItem.new(key: :path,
@@ -82,17 +82,18 @@ module Fastlane
82
82
  UI.user_error!("Couldn't find the destination folder at '#{value}'") if !Helper.test? && !File.directory?(value) && !File.exist?(value)
83
83
  end),
84
84
  FastlaneCore::ConfigItem.new(key: :zip,
85
- description: 'Enable compression of the archive. Default value `true`',
85
+ description: 'Enable compression of the archive',
86
86
  is_string: false,
87
87
  default_value: true,
88
88
  optional: true,
89
89
  env_name: 'BACKUP_XCARCHIVE_ZIP'),
90
90
  FastlaneCore::ConfigItem.new(key: :zip_filename,
91
91
  description: 'Filename of the compressed archive. Will be appended by `.xcarchive.zip`. Default value is the output xcarchive filename',
92
+ default_value_dynamic: true,
92
93
  optional: true,
93
94
  env_name: 'BACKUP_XCARCHIVE_ZIP_FILENAME'),
94
95
  FastlaneCore::ConfigItem.new(key: :versioned,
95
- description: 'Create a versioned (date and app version) subfolder where to put the archive. Default value `true`',
96
+ description: 'Create a versioned (date and app version) subfolder where to put the archive',
96
97
  is_string: false,
97
98
  default_value: true,
98
99
  optional: true,
@@ -120,7 +121,7 @@ module Fastlane
120
121
  xcarchive: "/path/to/file.xcarchive", # Optional if you use the `xcodebuild` action
121
122
  destination: "/somewhere/else/file.xcarchive", # Where the backup should be created
122
123
  zip: false, # Enable compression of the archive. Defaults to `true`.
123
- versioned: true # Create a versioned (date and app version) subfolder where to put the archive. Default value `true`
124
+ versioned: true # Create a versioned (date and app version) subfolder where to put the archive
124
125
  )'
125
126
  ]
126
127
  end
@@ -126,6 +126,7 @@ module Fastlane
126
126
  FastlaneCore::ConfigItem.new(key: :message,
127
127
  env_name: "FL_COMMIT_GITHUB_FILE_MESSAGE",
128
128
  description: "The commit message. Defaults to the file name",
129
+ default_value_dynamic: true,
129
130
  optional: true),
130
131
  FastlaneCore::ConfigItem.new(key: :secure,
131
132
  env_name: "FL_COMMIT_GITHUB_FILE_SECURE",
@@ -221,6 +221,10 @@ fastlane snapshot reset_simulators
221
221
 
222
222
  You can use the environment variable `SNAPSHOT_FORCE_DELETE` to stop asking for confirmation before deleting.
223
223
 
224
+ ```no-highlight
225
+ SNAPSHOT_FORCE_DELETE=1 fastlane snapshot reset_simulators
226
+ ```
227
+
224
228
  ## Update snapshot helpers
225
229
 
226
230
  Some updates require the helper files to be updated. _snapshot_ will automatically warn you and tell you how to update.
@@ -113,7 +113,7 @@ module Fastlane
113
113
  is_string: true),
114
114
  FastlaneCore::ConfigItem.new(key: :project_dir,
115
115
  env_name: 'FL_GRADLE_PROJECT_DIR',
116
- description: 'The root directory of the gradle project. Defaults to `.`',
116
+ description: 'The root directory of the gradle project',
117
117
  default_value: '.',
118
118
  is_string: true),
119
119
  FastlaneCore::ConfigItem.new(key: :gradle_path,
@@ -26,7 +26,7 @@ module Fastlane
26
26
  [
27
27
  FastlaneCore::ConfigItem.new(key: :force,
28
28
  env_name: "FL_HG_PUSH_FORCE",
29
- description: "Force push to remote. Defaults to false",
29
+ description: "Force push to remote",
30
30
  is_string: false,
31
31
  default_value: false),
32
32
  FastlaneCore::ConfigItem.new(key: :destination,
@@ -52,14 +52,14 @@ module Fastlane
52
52
  [
53
53
  'import_from_git(
54
54
  url: "git@github.com:fastlane/fastlane.git", # The URL of the repository to import the Fastfile from.
55
- branch: "HEAD", # The branch to checkout on the repository. Defaults to `HEAD`.
56
- path: "fastlane/Fastfile" # The path of the Fastfile in the repository. Defaults to `fastlane/Fastfile`.
55
+ branch: "HEAD", # The branch to checkout on the repository
56
+ path: "fastlane/Fastfile", # The path of the Fastfile in the repository
57
57
  version: "~> 1.0.0" # The version to checkout on the repository. Optimistic match operator can be used to select the latest version within constraints.
58
58
  )',
59
59
  'import_from_git(
60
60
  url: "git@github.com:fastlane/fastlane.git", # The URL of the repository to import the Fastfile from.
61
- branch: "HEAD", # The branch to checkout on the repository. Defaults to `HEAD`.
62
- path: "fastlane/Fastfile" # The path of the Fastfile in the repository. Defaults to `fastlane/Fastfile`.
61
+ branch: "HEAD", # The branch to checkout on the repository
62
+ path: "fastlane/Fastfile", # The path of the Fastfile in the repository
63
63
  version: [">= 1.1.0", "< 2.0.0"] # The version to checkout on the repository. Multiple conditions can be used to select the latest version within constraints.
64
64
  )'
65
65
  ]
@@ -163,6 +163,7 @@ module Fastlane
163
163
  FastlaneCore::ConfigItem.new(key: :destination,
164
164
  env_name: "IPA_DESTINATION",
165
165
  description: "Build destination. Defaults to current directory",
166
+ default_value_dynamic: true,
166
167
  optional: true),
167
168
  FastlaneCore::ConfigItem.new(key: :embed,
168
169
  env_name: "IPA_EMBED",
@@ -107,7 +107,7 @@ module Fastlane
107
107
  optional: false),
108
108
  FastlaneCore::ConfigItem.new(key: :mount_path,
109
109
  env_name: "FL_NEXUS_MOUNT_PATH",
110
- description: "Nexus mount path. Defaults to /nexus",
110
+ description: "Nexus mount path",
111
111
  default_value: "/nexus",
112
112
  optional: true),
113
113
  FastlaneCore::ConfigItem.new(key: :username,
@@ -29,7 +29,7 @@ module Fastlane
29
29
  [
30
30
  FastlaneCore::ConfigItem.new(key: :force,
31
31
  env_name: "FL_PUSH_GIT_FORCE",
32
- description: "Force push to remote. Defaults to false",
32
+ description: "Force push to remote",
33
33
  is_string: false,
34
34
  default_value: false,
35
35
  optional: true),
@@ -40,24 +40,26 @@ module Fastlane
40
40
  FastlaneCore::ConfigItem.new(key: :local_branch,
41
41
  env_name: "FL_GIT_PUSH_LOCAL_BRANCH",
42
42
  description: "The local branch to push from. Defaults to the current branch",
43
+ default_value_dynamic: true,
43
44
  optional: true),
44
45
  FastlaneCore::ConfigItem.new(key: :remote_branch,
45
46
  env_name: "FL_GIT_PUSH_REMOTE_BRANCH",
46
47
  description: "The remote branch to push to. Defaults to the local branch",
48
+ default_value_dynamic: true,
47
49
  optional: true),
48
50
  FastlaneCore::ConfigItem.new(key: :force,
49
51
  env_name: "FL_PUSH_GIT_FORCE",
50
- description: "Force push to remote. Defaults to false",
52
+ description: "Force push to remote",
51
53
  is_string: false,
52
54
  default_value: false),
53
55
  FastlaneCore::ConfigItem.new(key: :tags,
54
56
  env_name: "FL_PUSH_GIT_TAGS",
55
- description: "Whether tags are pushed to remote. Defaults to true",
57
+ description: "Whether tags are pushed to remote",
56
58
  is_string: false,
57
59
  default_value: true),
58
60
  FastlaneCore::ConfigItem.new(key: :remote,
59
61
  env_name: "FL_GIT_PUSH_REMOTE",
60
- description: "The remote to push to. Defaults to `origin`",
62
+ description: "The remote to push to",
61
63
  default_value: 'origin')
62
64
  ]
63
65
  end
@@ -88,7 +88,7 @@ module Fastlane
88
88
  default_value: false),
89
89
  FastlaneCore::ConfigItem.new(key: :skip_clean,
90
90
  env_name: "FL_RESET_GIT_SKIP_CLEAN",
91
- description: "Skip 'git clean' to avoid removing untracked files like `.env`. Defaults to false",
91
+ description: "Skip 'git clean' to avoid removing untracked files like `.env`",
92
92
  is_string: false,
93
93
  default_value: false),
94
94
  FastlaneCore::ConfigItem.new(key: :disregard_gitignore,
@@ -134,7 +134,7 @@ module Fastlane
134
134
  default_value: false),
135
135
  FastlaneCore::ConfigItem.new(key: :no_update,
136
136
  env_name: "FL_NO_UPDATE",
137
- description: "Don't update during this run. Defaults to false. This is used internally",
137
+ description: "Don't update during this run. This is used internally",
138
138
  is_string: false,
139
139
  default_value: false),
140
140
  FastlaneCore::ConfigItem.new(key: :tools,
@@ -135,7 +135,6 @@ module Fastlane
135
135
  else
136
136
  puts("No available options".yellow)
137
137
  end
138
- puts("- = this parameter doesn't have a default value")
139
138
  puts("* = this default value is dependent on the user's system")
140
139
  puts("")
141
140
  end
@@ -192,11 +191,7 @@ module Fastlane
192
191
  if options.kind_of?(Array)
193
192
  options.each do |current|
194
193
  if current.kind_of?(FastlaneCore::ConfigItem)
195
- current_default = current.default_value
196
- # rubocop:disable Metrics/BlockNesting, Style/NestedTernaryOperator
197
- default = current.default_value_dynamic ? "#{current_default} *".strip : (current_default.nil? ? "-" : current_default)
198
- # rubocop:enable Metrics/BlockNesting, Style/NestedTernaryOperator
199
- rows << [current.key.to_s.yellow, current.description, current.env_name, default]
194
+ rows << [current.key.to_s.yellow, current.description, current.env_name, current.help_default_value]
200
195
  elsif current.kind_of?(Array)
201
196
  # Legacy actions that don't use the new config manager
202
197
  UI.user_error!("Invalid number of elements in this row: #{current}. Must be 2 or 3") unless [2, 3].include?(current.count)
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
- VERSION = '2.82.0.beta.20180222010003'.freeze
2
+ VERSION = '2.82.0.beta.20180223010003'.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
@@ -277,5 +277,20 @@ module FastlaneCore
277
277
  def to_s
278
278
  [@key, @description].join(": ")
279
279
  end
280
+
281
+ def doc_default_value
282
+ return "[*](#dynamic)" if self.default_value_dynamic
283
+ return "" if self.default_value.nil?
284
+ return "`''`" if self.default_value.instance_of?(String) && self.default_value.empty?
285
+
286
+ "`#{self.default_value}`"
287
+ end
288
+
289
+ def help_default_value
290
+ return "#{self.default_value} *".strip if self.default_value_dynamic
291
+ return "" if self.default_value.nil?
292
+
293
+ self.default_value
294
+ end
280
295
  end
281
296
  end
@@ -23,10 +23,10 @@ module FastlaneCore
23
23
  # "TimeToLive"=>185,
24
24
  # "UUID"=>"1752e382-53bd-4910-a393-aaa7de0005ad",
25
25
  # "Version"=>1}
26
- def parse(path)
26
+ def parse(path, keychain_path = nil)
27
27
  require 'plist'
28
28
 
29
- plist = Plist.parse_xml(decode(path))
29
+ plist = Plist.parse_xml(decode(path, keychain_path))
30
30
  if (plist || []).count > 5
31
31
  plist
32
32
  else
@@ -35,13 +35,13 @@ module FastlaneCore
35
35
  end
36
36
 
37
37
  # @return [String] The UUID of the given provisioning profile
38
- def uuid(path)
39
- parse(path).fetch("UUID")
38
+ def uuid(path, keychain_path = nil)
39
+ parse(path, keychain_path).fetch("UUID")
40
40
  end
41
41
 
42
42
  # @return [String] The Name of the given provisioning profile
43
- def name(path)
44
- parse(path).fetch("Name")
43
+ def name(path, keychain_path = nil)
44
+ parse(path, keychain_path).fetch("Name")
45
45
  end
46
46
 
47
47
  def profiles_path
@@ -55,9 +55,9 @@ module FastlaneCore
55
55
  end
56
56
 
57
57
  # Installs a provisioning profile for Xcode to use
58
- def install(path)
58
+ def install(path, keychain_path = nil)
59
59
  UI.message("Installing provisioning profile...")
60
- profile_filename = uuid(path) + ".mobileprovision"
60
+ profile_filename = uuid(path, keychain_path) + ".mobileprovision"
61
61
  destination = File.join(profiles_path, profile_filename)
62
62
 
63
63
  if path != destination
@@ -73,13 +73,17 @@ module FastlaneCore
73
73
 
74
74
  private
75
75
 
76
- def decode(path)
76
+ def decode(path, keychain_path = nil)
77
77
  require 'tmpdir'
78
78
  Dir.mktmpdir('fastlane') do |dir|
79
79
  err = "#{dir}/cms.err"
80
80
  # we want to prevent the error output to mix up with the standard output because of
81
81
  # /dev/null: https://github.com/fastlane/fastlane/issues/6387
82
- decoded = `security cms -D -i "#{path}" 2> #{err}`
82
+ if keychain_path.nil?
83
+ decoded = `security cms -D -i "#{path}" 2> #{err}`
84
+ else
85
+ decoded = `security cms -D -i "#{path}" -k "#{keychain_path.shellescape}" 2> #{err}`
86
+ end
83
87
  UI.error("Failure to decode #{path}. Exit: #{$?.exitstatus}: #{File.read(err)}") if $?.exitstatus != 0
84
88
  decoded
85
89
  end
@@ -67,6 +67,7 @@ module Gym
67
67
  short_option: "-q",
68
68
  env_name: "GYM_CONFIGURATION",
69
69
  description: "The configuration to use when building the app. Defaults to 'Release'",
70
+ default_value_dynamic: true,
70
71
  optional: true),
71
72
  FastlaneCore::ConfigItem.new(key: :silent,
72
73
  short_option: "-a",
@@ -135,13 +135,14 @@ module Match
135
135
  profile_name = names.join("_").gsub("*", '\*') # this is important, as it shouldn't be a wildcard
136
136
  base_dir = File.join(params[:workspace], "profiles", prov_type.to_s)
137
137
  profiles = Dir[File.join(base_dir, "#{profile_name}.mobileprovision")]
138
+ keychain_path = FastlaneCore::Helper.keychain_path(params[:keychain_name]) unless params[:keychain_name].nil?
138
139
 
139
140
  # Install the provisioning profiles
140
141
  profile = profiles.last
141
142
 
142
143
  if params[:force_for_new_devices] && !params[:readonly]
143
144
  if prov_type != :appstore
144
- params[:force] = device_count_different?(profile: profile) unless params[:force]
145
+ params[:force] = device_count_different?(profile: profile, keychain_path: keychain_path) unless params[:force]
145
146
  else
146
147
  # App Store provisioning profiles don't contain device identifiers and
147
148
  # thus shouldn't be renewed if the device count has changed.
@@ -167,9 +168,8 @@ module Match
167
168
  self.files_to_commmit << profile
168
169
  end
169
170
 
170
- installed_profile = FastlaneCore::ProvisioningProfile.install(profile)
171
-
172
- parsed = FastlaneCore::ProvisioningProfile.parse(profile)
171
+ installed_profile = FastlaneCore::ProvisioningProfile.install(profile, keychain_path)
172
+ parsed = FastlaneCore::ProvisioningProfile.parse(profile, keychain_path)
173
173
  uuid = parsed["UUID"]
174
174
 
175
175
  if spaceship && !spaceship.profile_exists(username: params[:username], uuid: uuid)
@@ -204,9 +204,9 @@ module Match
204
204
  return uuid
205
205
  end
206
206
 
207
- def device_count_different?(profile: nil)
207
+ def device_count_different?(profile: nil, keychain_path: nil)
208
208
  if profile
209
- parsed = FastlaneCore::ProvisioningProfile.parse(profile)
209
+ parsed = FastlaneCore::ProvisioningProfile.parse(profile, keychain_path)
210
210
  uuid = parsed["UUID"]
211
211
  portal_profile = Spaceship.provisioning_profile.all.detect { |i| i.uuid == uuid }
212
212
 
@@ -22,7 +22,7 @@ module PEM
22
22
  default_value: true),
23
23
  FastlaneCore::ConfigItem.new(key: :active_days_limit,
24
24
  env_name: "PEM_ACTIVE_DAYS_LIMIT",
25
- description: "If the current certificate is active for less than this number of days, generate a new one. Default value is 30 days",
25
+ description: "If the current certificate is active for less than this number of days, generate a new one",
26
26
  default_value: 30,
27
27
  is_string: false,
28
28
  type: Integer,
@@ -196,6 +196,7 @@ module Scan
196
196
  short_option: "-q",
197
197
  env_name: "SCAN_CONFIGURATION",
198
198
  description: "The configuration to use when building the app. Defaults to 'Release'",
199
+ default_value_dynamic: true,
199
200
  optional: true),
200
201
  FastlaneCore::ConfigItem.new(key: :destination,
201
202
  short_option: "-d",
@@ -638,6 +638,71 @@ function resign {
638
638
  # Start with using what comes in provisioning profile entitlements before patching
639
639
  cp -f "$PROFILE_ENTITLEMENTS" "$PATCHED_ENTITLEMENTS"
640
640
 
641
+ log "Removing blacklisted keys from patched profile"
642
+ # See https://github.com/facebook/buck/issues/798 and https://github.com/facebook/buck/pull/802/files
643
+
644
+ # Update in https://github.com/facebook/buck/commit/99c0fbc3ab5ecf04d186913374f660683deccdef
645
+ # Update in https://github.com/facebook/buck/commit/36db188da9f6acbb9df419dc1904315ab00c4e19
646
+
647
+ # Buck changes referenced above are not self-explanatory and do not seem exhaustive or up-to-date
648
+ # Comments below explain the rules applied to each key in order to make realignment with future Xcode export logic easier
649
+ BLACKLISTED_KEYS=(\
650
+ # PP list identifiers inconsistent with app-defined ones and this key does not seem to appear in IPA entitlements, so ignore it
651
+ "com.apple.developer.icloud-container-development-container-identifiers" \
652
+ # This key has an invalid generic value in PP (actual value is set by Xcode during export), see dedicated processing a few blocks below
653
+ "com.apple.developer.icloud-container-environment" \
654
+ # PP list identifiers inconsistent with app-defined ones, must use App entitlements value
655
+ "com.apple.developer.icloud-container-identifiers" \
656
+ # PP enable all available services and not app-defined ones, must use App entitlements value
657
+ "com.apple.developer.icloud-services" \
658
+ # Was already blacklisted in previous version, but has someone ever seen this key in a PP?
659
+ "com.apple.developer.restricted-resource-mode" \
660
+ # If actually used by the App, this value will be set in its entitlements
661
+ "com.apple.developer.nfc.readersession.formats" \
662
+ # PP list a single TeamID.* identifier and not app-defined ones, must use App entitlements value
663
+ "com.apple.developer.pass-type-identifiers" \
664
+ # If actually used by the App, this value will be set in its entitlements
665
+ "com.apple.developer.siri" \
666
+ # PP list identifiers inconsistent with app-defined ones, must use App entitlements value
667
+ "com.apple.developer.ubiquity-container-identifiers" \
668
+ # PP define a generic TeamID.* identifier and not the app-defined one, must use App entitlements value
669
+ "com.apple.developer.ubiquity-kvstore-identifier" \
670
+ # If actually used by the App, this value will be set in its entitlements
671
+ "inter-app-audio" \
672
+ # PP define a generic TeamID.* identifier and not the app-defined one, must use App entitlements value
673
+ "keychain-access-groups" \
674
+ # If actually used by the App, this value will be set in its entitlements
675
+ "com.apple.developer.homekit" \
676
+ # If actually used by the App, this value will be set in its entitlements
677
+ "com.apple.developer.healthkit" \
678
+ # PP list identifiers inconsistent with app-defined ones, must use App entitlements value
679
+ "com.apple.developer.in-app-payments" \
680
+ # If actually used by the App, this value will be set in its entitlements
681
+ "com.apple.developer.networking.vpn.api" \
682
+ # If actually used by the App, this value will be set in its entitlements
683
+ "com.apple.developer.networking.HotspotConfiguration" \
684
+ # PP list all available extensions and not app-defined ones, must use App entitlements value
685
+ "com.apple.developer.networking.networkextension" \
686
+ # If actually used by the App, this value will be set in its entitlements
687
+ "com.apple.developer.networking.multipath" \
688
+ # PP enable all domains via a non-AppStore-compliant '*' value, must use App entitlements value
689
+ "com.apple.developer.associated-domains" \
690
+ # If actually used by the App, this value will be set in its entitlements
691
+ "com.apple.developer.default-data-protection" \
692
+ # PP seem to list the same groups as the App, but use App entitlements value to be sure
693
+ "com.apple.security.application-groups" \
694
+ # Was already blacklisted in previous version, seems to be an artifact from an old Xcode release
695
+ "com.apple.developer.maps" \
696
+ # If actually used by the App, this value will be set in its entitlements
697
+ "com.apple.external-accessory.wireless-configuration"
698
+ )
699
+
700
+ # Blacklisted keys must not be included into new profile, so remove them from patched profile
701
+ for KEY in "${BLACKLISTED_KEYS[@]}"; do
702
+ log "Removing blacklisted key: $KEY"
703
+ PlistBuddy -c "Delete $KEY" "$PATCHED_ENTITLEMENTS" 2>/dev/null
704
+ done
705
+
641
706
  # Get the old and new app identifier (prefix)
642
707
  APP_ID_KEY="application-identifier"
643
708
  # Extract just the identifier from the value
@@ -664,13 +729,22 @@ function resign {
664
729
  # There can be only one ID_TYPE specified
665
730
  # If entitlements use more than one ID type for single entitlement, then this way of resigning will not work
666
731
  # instead an entitlements file must be provided explicitly
667
- ENTITLEMENTS_TRANSFER_RULES=("com.apple.developer.associated-domains" \
732
+ ENTITLEMENTS_TRANSFER_RULES=(\
733
+ "com.apple.developer.associated-domains" \
734
+ "com.apple.developer.default-data-protection" \
668
735
  "com.apple.developer.healthkit" \
669
736
  "com.apple.developer.homekit" \
737
+ "com.apple.developer.icloud-container-environment" \
670
738
  "com.apple.developer.icloud-container-identifiers" \
671
739
  "com.apple.developer.icloud-services" \
672
740
  "com.apple.developer.in-app-payments" \
741
+ "com.apple.developer.networking.HotspotConfiguration" \
742
+ "com.apple.developer.networking.multipath" \
743
+ "com.apple.developer.networking.networkextension" \
673
744
  "com.apple.developer.networking.vpn.api" \
745
+ "com.apple.developer.nfc.readersession.formats" \
746
+ "com.apple.developer.pass-type-identifiers|TEAM_ID" \
747
+ "com.apple.developer.siri" \
674
748
  "com.apple.developer.ubiquity-container-identifiers" \
675
749
  "com.apple.developer.ubiquity-kvstore-identifier|TEAM_ID" \
676
750
  "com.apple.external-accessory.wireless-configuration" \
@@ -691,6 +765,22 @@ function resign {
691
765
  continue
692
766
  fi
693
767
 
768
+ if [[ "$KEY" == "com.apple.developer.icloud-container-environment" ]]; then
769
+ # Add specific iCloud Environment key to patched entitlements
770
+ # This value is set by Xcode during export (manually selected for Development and AdHoc, automatically set to Production for Store)
771
+ # Would need an additional dedicated option to specify the iCloud environment to be used (Development or Production)
772
+ # For now, we assume Production is to be used when signing with a Distribution certificate, Development if not
773
+ if [[ "$CERTIFICATE" =~ "Distribution:" ]]; then
774
+ ICLOUD_ENV="Production"
775
+ else
776
+ ICLOUD_ENV="Development"
777
+ fi
778
+ log "Overriding value for $KEY"
779
+ log "Old value: $ENTITLEMENTS_VALUE"
780
+ log "New value: $ICLOUD_ENV"
781
+ ENTITLEMENTS_VALUE="$ICLOUD_ENV"
782
+ fi
783
+
694
784
  log "App entitlements value for key '$KEY':"
695
785
  log "$ENTITLEMENTS_VALUE"
696
786
 
@@ -711,7 +801,7 @@ function resign {
711
801
  log "Replacing old app identifier prefix '$OLD_APP_ID' with new value '$NEW_APP_ID'"
712
802
  sed -i .bak "s/$OLD_APP_ID/$NEW_APP_ID/g" "$PATCHED_ENTITLEMENTS"
713
803
  elif [[ "$ID_TYPE" == "TEAM_ID" ]]; then
714
- # Replace new team identifier with new value
804
+ # Replace old team identifier with new value
715
805
  log "Replacing old team ID '$OLD_TEAM_ID' with new team ID: '$NEW_TEAM_ID'"
716
806
  sed -i .bak "s/$OLD_TEAM_ID/$NEW_TEAM_ID/g" "$PATCHED_ENTITLEMENTS"
717
807
  else
@@ -726,33 +816,6 @@ function resign {
726
816
  log "Replacing old bundle ID '$OLD_BUNDLE_ID' with new bundle ID '$NEW_BUNDLE_ID' in patched entitlements"
727
817
  sed -i .bak "s/$OLD_BUNDLE_ID/$NEW_BUNDLE_ID/g" "$PATCHED_ENTITLEMENTS"
728
818
 
729
- log "Removing blacklisted keys from patched profile"
730
- # See https://github.com/facebook/buck/issues/798 and https://github.com/facebook/buck/pull/802/files
731
-
732
- # Update in https://github.com/facebook/buck/commit/99c0fbc3ab5ecf04d186913374f660683deccdef
733
- # Update in https://github.com/facebook/buck/commit/36db188da9f6acbb9df419dc1904315ab00c4e19
734
- BLACKLISTED_KEYS=(\
735
- "com.apple.developer.icloud-container-development-container-identifiers" \
736
- "com.apple.developer.icloud-container-environment" \
737
- "com.apple.developer.icloud-container-identifiers" \
738
- "com.apple.developer.icloud-services" \
739
- "com.apple.developer.restricted-resource-mode" \
740
- "com.apple.developer.ubiquity-container-identifiers" \
741
- "com.apple.developer.ubiquity-kvstore-identifier" \
742
- "inter-app-audio" \
743
- "com.apple.developer.homekit" \
744
- "com.apple.developer.healthkit" \
745
- "com.apple.developer.in-app-payments" \
746
- "com.apple.developer.maps" \
747
- "com.apple.external-accessory.wireless-configuration"
748
- )
749
-
750
- # Blacklisted keys must not be included into new profile, so remove them from patched profile
751
- for KEY in "${BLACKLISTED_KEYS[@]}"; do
752
- log "Removing blacklisted key: $KEY"
753
- PlistBuddy -c "Delete $KEY" "$PATCHED_ENTITLEMENTS" 2>/dev/null
754
- done
755
-
756
819
  log "Resigning application using certificate: '$CERTIFICATE'"
757
820
  log "and patched entitlements:"
758
821
  log "$(cat "$PATCHED_ENTITLEMENTS")"
@@ -153,6 +153,7 @@ module Snapshot
153
153
  short_option: "-q",
154
154
  env_name: "SNAPSHOT_CONFIGURATION",
155
155
  description: "The configuration to use when building the app. Defaults to 'Release'",
156
+ default_value_dynamic: true,
156
157
  optional: true),
157
158
  FastlaneCore::ConfigItem.new(key: :xcpretty_args,
158
159
  short_option: "-x",
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.82.0.beta.20180222010003
4
+ version: 2.82.0.beta.20180223010003
5
5
  platform: ruby
6
6
  authors:
7
7
  - Olivier Halligon
@@ -25,7 +25,7 @@ authors:
25
25
  autorequire:
26
26
  bindir: bin
27
27
  cert_chain: []
28
- date: 2018-02-22 00:00:00.000000000 Z
28
+ date: 2018-02-23 00:00:00.000000000 Z
29
29
  dependencies:
30
30
  - !ruby/object:Gem::Dependency
31
31
  name: slack-notifier