cocoapods-core 1.10.2 → 1.11.0.beta.1
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 +4 -4
- data/lib/cocoapods-core/cdn_source.rb +1 -1
- data/lib/cocoapods-core/dependency.rb +12 -7
- data/lib/cocoapods-core/gem_version.rb +1 -1
- data/lib/cocoapods-core/podfile.rb +19 -2
- data/lib/cocoapods-core/podfile/dsl.rb +23 -11
- data/lib/cocoapods-core/podfile/target_definition.rb +1 -1
- data/lib/cocoapods-core/requirement.rb +1 -1
- data/lib/cocoapods-core/source.rb +8 -1
- data/lib/cocoapods-core/source/manager.rb +43 -17
- data/lib/cocoapods-core/specification.rb +2 -2
- data/lib/cocoapods-core/specification/consumer.rb +29 -1
- data/lib/cocoapods-core/specification/dsl.rb +69 -5
- data/lib/cocoapods-core/specification/linter.rb +0 -16
- data/lib/cocoapods-core/specification/linter/analyzer.rb +1 -1
- data/lib/cocoapods-core/yaml_helper.rb +4 -6
- metadata +16 -16
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fc77a2caddc23264c82d1b938d3861baa7db772d1aa64a2e8796d48fce457029
|
|
4
|
+
data.tar.gz: c456ecc4030277077b806f0e4cc73eb4ee292d48278cd2bde8ef45a64a180d32
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b3d173d8a43823bba5466e2385c8eaa728f6221a356a00ea557cd1488969154967b8175aed46b39fcb8f632ef18e28f73c8bc1bdbdaa3aa8aa08747733005a60
|
|
7
|
+
data.tar.gz: e9cfcadb169aff82575dac6e0e7a0e293a24cb4f69a603ff153397f168aedd426c0d8a23e1eb40822903d73afdb6f9f89b561df48e3be24dfc3330d9f885205e
|
|
@@ -350,7 +350,7 @@ module Pod
|
|
|
350
350
|
end
|
|
351
351
|
|
|
352
352
|
unless @check_existing_files_for_update
|
|
353
|
-
debug "CDN: #{name} Relative path: #{partial_url} exists! Returning local because checking is only
|
|
353
|
+
debug "CDN: #{name} Relative path: #{partial_url} exists! Returning local because checking is only performed in repo update"
|
|
354
354
|
return Promises.fulfilled_future(partial_url, HYDRA_EXECUTOR)
|
|
355
355
|
end
|
|
356
356
|
end
|
|
@@ -109,11 +109,16 @@ module Pod
|
|
|
109
109
|
# one or more version restrictions).
|
|
110
110
|
#
|
|
111
111
|
def requirement
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
112
|
+
@specific_requirement || @requirement
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
# @param [Version] version the specific version to point to
|
|
116
|
+
#
|
|
117
|
+
def specific_version=(version)
|
|
118
|
+
@specific_version = version
|
|
119
|
+
@specific_requirement = if version
|
|
120
|
+
Requirement.new(Version.new(version.version))
|
|
121
|
+
end
|
|
117
122
|
end
|
|
118
123
|
|
|
119
124
|
# @return [Bool] whether the dependency points to a subspec.
|
|
@@ -196,9 +201,9 @@ module Pod
|
|
|
196
201
|
def ==(other)
|
|
197
202
|
self.class == other.class &&
|
|
198
203
|
name == other.name &&
|
|
199
|
-
requirement == other.requirement &&
|
|
200
204
|
external_source == other.external_source &&
|
|
201
|
-
podspec_repo == other.podspec_repo
|
|
205
|
+
podspec_repo == other.podspec_repo &&
|
|
206
|
+
requirement == other.requirement
|
|
202
207
|
end
|
|
203
208
|
alias_method :eql?, :==
|
|
204
209
|
|
|
@@ -166,6 +166,23 @@ module Pod
|
|
|
166
166
|
end
|
|
167
167
|
end
|
|
168
168
|
|
|
169
|
+
# Calls the pre integrate callback if defined.
|
|
170
|
+
#
|
|
171
|
+
# @param [Pod::Installer] installer
|
|
172
|
+
# the installer that is performing the installation.
|
|
173
|
+
#
|
|
174
|
+
# @return [Bool] whether a pre integrate callback was specified and it was
|
|
175
|
+
# called.
|
|
176
|
+
#
|
|
177
|
+
def pre_integrate!(installer)
|
|
178
|
+
if @pre_integrate_callback
|
|
179
|
+
@pre_integrate_callback.call(installer)
|
|
180
|
+
true
|
|
181
|
+
else
|
|
182
|
+
false
|
|
183
|
+
end
|
|
184
|
+
end
|
|
185
|
+
|
|
169
186
|
# Calls the post install callback if defined.
|
|
170
187
|
#
|
|
171
188
|
# @param [Pod::Installer] installer
|
|
@@ -310,9 +327,9 @@ module Pod
|
|
|
310
327
|
podfile = Podfile.new(path) do
|
|
311
328
|
# rubocop:disable Lint/RescueException
|
|
312
329
|
begin
|
|
313
|
-
# rubocop:disable Eval
|
|
330
|
+
# rubocop:disable Security/Eval
|
|
314
331
|
eval(contents, nil, path.to_s)
|
|
315
|
-
# rubocop:enable Eval
|
|
332
|
+
# rubocop:enable Security/Eval
|
|
316
333
|
rescue Exception => e
|
|
317
334
|
message = "Invalid `#{path.basename}` file: #{e.message}"
|
|
318
335
|
raise DSLError.new(message, path, e, contents)
|
|
@@ -921,9 +921,7 @@ module Pod
|
|
|
921
921
|
# This hook allows you to make any changes to the Pods after they have
|
|
922
922
|
# been downloaded but before they are installed.
|
|
923
923
|
#
|
|
924
|
-
# It receives the
|
|
925
|
-
# [`Pod::Installer`](http://rubydoc.info/gems/cocoapods/Pod/Installer/)
|
|
926
|
-
# as its only argument.
|
|
924
|
+
# It receives the [Pod::Installer] as its only argument.
|
|
927
925
|
#
|
|
928
926
|
# @example Defining a pre-install hook in a Podfile.
|
|
929
927
|
#
|
|
@@ -936,15 +934,31 @@ module Pod
|
|
|
936
934
|
@pre_install_callback = block
|
|
937
935
|
end
|
|
938
936
|
|
|
937
|
+
# This hook allows you to make changes before the project is written
|
|
938
|
+
# to disk.
|
|
939
|
+
#
|
|
940
|
+
# It receives the [Pod::Installer] as its only argument.
|
|
941
|
+
#
|
|
942
|
+
# @example Customizing the dependencies before integration
|
|
943
|
+
#
|
|
944
|
+
# pre_integrate do |installer|
|
|
945
|
+
# # perform some changes on dependencies
|
|
946
|
+
# end
|
|
947
|
+
#
|
|
948
|
+
# @return [void]
|
|
949
|
+
#
|
|
950
|
+
def pre_integrate(&block)
|
|
951
|
+
raise Informative, 'Specifying multiple `pre_integrate` hooks is unsupported.' if @pre_integrate_callback
|
|
952
|
+
@pre_integrate_callback = block
|
|
953
|
+
end
|
|
954
|
+
|
|
939
955
|
# This hook allows you to make any last changes to the generated Xcode
|
|
940
956
|
# project before it is written to disk, or any other tasks you might want
|
|
941
957
|
# to perform.
|
|
942
958
|
#
|
|
943
|
-
# It receives the
|
|
944
|
-
# [`Pod::Installer`](http://rubydoc.info/gems/cocoapods/Pod/Installer/)
|
|
945
|
-
# as its only argument.
|
|
959
|
+
# It receives the [Pod::Installer] as its only argument.
|
|
946
960
|
#
|
|
947
|
-
# @example
|
|
961
|
+
# @example Customizing the build settings of all targets
|
|
948
962
|
#
|
|
949
963
|
# post_install do |installer|
|
|
950
964
|
# installer.pods_project.targets.each do |target|
|
|
@@ -964,11 +978,9 @@ module Pod
|
|
|
964
978
|
# This hook allows you to make changes after the project is written
|
|
965
979
|
# to disk.
|
|
966
980
|
#
|
|
967
|
-
# It receives the
|
|
968
|
-
# [`Pod::Installer`](http://rubydoc.info/gems/cocoapods/Pod/Installer/)
|
|
969
|
-
# as its only argument.
|
|
981
|
+
# It receives the [Pod::Installer] as its only argument.
|
|
970
982
|
#
|
|
971
|
-
# @example
|
|
983
|
+
# @example Customizing the build settings of all targets
|
|
972
984
|
#
|
|
973
985
|
# post_integrate do |installer|
|
|
974
986
|
# # some change after project write to disk
|
|
@@ -963,7 +963,7 @@ module Pod
|
|
|
963
963
|
if exclusive?
|
|
964
964
|
whitelist_hash
|
|
965
965
|
else
|
|
966
|
-
parent.send(:configuration_pod_whitelist).merge(whitelist_hash) { |l, r| (l
|
|
966
|
+
parent.send(:configuration_pod_whitelist).merge(whitelist_hash) { |_, l, r| Array(l).concat(r).uniq }
|
|
967
967
|
end
|
|
968
968
|
end
|
|
969
969
|
|
|
@@ -15,7 +15,7 @@ module Pod
|
|
|
15
15
|
#
|
|
16
16
|
PATTERN = /\A\s*(#{quoted_operators})?\s*(#{Version::VERSION_PATTERN})\s*\z/
|
|
17
17
|
|
|
18
|
-
DefaultRequirement = ['>=', Version.new(0)] # rubocop:disable
|
|
18
|
+
DefaultRequirement = ['>=', Version.new(0)] # rubocop:disable Naming/ConstantName
|
|
19
19
|
|
|
20
20
|
#-------------------------------------------------------------------------#
|
|
21
21
|
|
|
@@ -167,9 +167,11 @@ module Pod
|
|
|
167
167
|
pod_dir = pod_path(name)
|
|
168
168
|
return unless pod_dir.exist?
|
|
169
169
|
@versions_by_name[name] ||= pod_dir.children.map do |v|
|
|
170
|
+
next nil unless v.directory?
|
|
170
171
|
basename = v.basename.to_s
|
|
172
|
+
next unless basename[0, 1] != '.'
|
|
171
173
|
begin
|
|
172
|
-
Version.new(basename)
|
|
174
|
+
Version.new(basename)
|
|
173
175
|
rescue ArgumentError
|
|
174
176
|
raise Informative, 'An unexpected version directory ' \
|
|
175
177
|
"`#{basename}` was encountered for the " \
|
|
@@ -266,6 +268,11 @@ module Pod
|
|
|
266
268
|
query = query.root_name
|
|
267
269
|
end
|
|
268
270
|
|
|
271
|
+
if (versions = @versions_by_name[query]) && !versions.empty?
|
|
272
|
+
set = set(query)
|
|
273
|
+
return set if set.specification_name == query
|
|
274
|
+
end
|
|
275
|
+
|
|
269
276
|
found = []
|
|
270
277
|
Pathname.glob(pod_path(query)) do |path|
|
|
271
278
|
next unless Dir.foreach(path).any? { |child| child != '.' && child != '..' }
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
require 'public_suffix'
|
|
2
|
+
|
|
1
3
|
module Pod
|
|
2
4
|
class Source
|
|
3
5
|
class Manager
|
|
@@ -265,6 +267,11 @@ module Pod
|
|
|
265
267
|
require 'json'
|
|
266
268
|
begin
|
|
267
269
|
index = JSON.parse(search_index_path.read)
|
|
270
|
+
unless index # JSON.parse("null") => nil
|
|
271
|
+
search_index_path.delete
|
|
272
|
+
return nil
|
|
273
|
+
end
|
|
274
|
+
|
|
268
275
|
index if index.is_a?(Hash) # TODO: should we also check if hash has correct hierarchy?
|
|
269
276
|
rescue JSON::ParserError
|
|
270
277
|
search_index_path.delete
|
|
@@ -404,12 +411,12 @@ module Pod
|
|
|
404
411
|
# @example A non-Github.com URL
|
|
405
412
|
#
|
|
406
413
|
# name_for_url('https://sourceforge.org/Artsy/Specs.git')
|
|
407
|
-
# # sourceforge-artsy
|
|
414
|
+
# # sourceforge-artsy
|
|
408
415
|
#
|
|
409
416
|
# @example A file URL
|
|
410
417
|
#
|
|
411
418
|
# name_for_url('file:///Artsy/Specs.git')
|
|
412
|
-
# # artsy
|
|
419
|
+
# # artsy
|
|
413
420
|
#
|
|
414
421
|
# @param [#to_s] url
|
|
415
422
|
# The URL of the source.
|
|
@@ -419,33 +426,52 @@ module Pod
|
|
|
419
426
|
def name_for_url(url)
|
|
420
427
|
base_from_host_and_path = lambda do |host, path|
|
|
421
428
|
if host && !host.empty?
|
|
422
|
-
|
|
423
|
-
base
|
|
429
|
+
domain = PublicSuffix.parse(host) rescue nil
|
|
430
|
+
base = [domain&.sld || host]
|
|
431
|
+
base = [] if base == %w(github)
|
|
424
432
|
else
|
|
425
|
-
base =
|
|
433
|
+
base = []
|
|
426
434
|
end
|
|
427
435
|
|
|
428
|
-
|
|
436
|
+
path = path.gsub(/.git$/, '').gsub(%r{^/}, '').split('/')
|
|
437
|
+
path.pop if path.last == 'specs'
|
|
438
|
+
|
|
439
|
+
(base + path).join('-')
|
|
440
|
+
end
|
|
441
|
+
|
|
442
|
+
valid_url = lambda do |url|
|
|
443
|
+
url =~ URI.regexp && (URI(url) rescue false)
|
|
429
444
|
end
|
|
430
445
|
|
|
431
|
-
|
|
446
|
+
valid_scp_url = lambda do |url|
|
|
447
|
+
valid_url['scp://' + url]
|
|
448
|
+
end
|
|
449
|
+
|
|
450
|
+
url = url.to_s.downcase
|
|
451
|
+
|
|
452
|
+
case url
|
|
432
453
|
when %r{https://#{Regexp.quote(trunk_repo_hostname)}}i
|
|
454
|
+
# Main CDN repo
|
|
433
455
|
base = Pod::TrunkSource::TRUNK_REPO_NAME
|
|
434
|
-
when
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
url =
|
|
456
|
+
when valid_url
|
|
457
|
+
# HTTPS URL or something similar
|
|
458
|
+
url = valid_url[url]
|
|
459
|
+
base = base_from_host_and_path[url.host, url.path]
|
|
460
|
+
when valid_scp_url
|
|
461
|
+
# SCP-style URLs for private git repos
|
|
462
|
+
url = valid_scp_url[url]
|
|
441
463
|
base = base_from_host_and_path[url.host, url.path]
|
|
464
|
+
when %r{(?:git|ssh|https?|[a-z0-9_-]+@([-\w.]+)):(\/\/)?(.*?)(\.git)(\/?|\#[-\d\w._]+?)$}i
|
|
465
|
+
# Additional SCP-style URLs for private git repos
|
|
466
|
+
host, _, path = Regexp.last_match.captures
|
|
467
|
+
base = base_from_host_and_path[host, path]
|
|
442
468
|
else
|
|
443
|
-
|
|
469
|
+
# This is nearly impossible, with all the previous cases
|
|
470
|
+
raise Informative, "Couldn't determine repo name for URL: #{url}"
|
|
444
471
|
end
|
|
445
472
|
|
|
446
473
|
name = base
|
|
447
|
-
|
|
448
|
-
(1..infinity).each do |i|
|
|
474
|
+
(1..).each do |i|
|
|
449
475
|
break unless source_dir(name).exist?
|
|
450
476
|
name = "#{base}-#{i}"
|
|
451
477
|
end
|
|
@@ -824,9 +824,9 @@ module Pod
|
|
|
824
824
|
#
|
|
825
825
|
#
|
|
826
826
|
def self._eval_podspec(string, path)
|
|
827
|
-
# rubocop:disable Eval
|
|
827
|
+
# rubocop:disable Security/Eval
|
|
828
828
|
eval(string, nil, path.to_s)
|
|
829
|
-
# rubocop:enable Eval
|
|
829
|
+
# rubocop:enable Security/Eval
|
|
830
830
|
|
|
831
831
|
# rubocop:disable Lint/RescueException
|
|
832
832
|
rescue Exception => e
|
|
@@ -168,6 +168,10 @@ module Pod
|
|
|
168
168
|
#
|
|
169
169
|
spec_attr_accessor :public_header_files
|
|
170
170
|
|
|
171
|
+
# @return [Array<String>] the project headers of the Pod.
|
|
172
|
+
#
|
|
173
|
+
spec_attr_accessor :project_header_files
|
|
174
|
+
|
|
171
175
|
# @return [Array<String>] the private headers of the Pod.
|
|
172
176
|
#
|
|
173
177
|
spec_attr_accessor :private_header_files
|
|
@@ -182,7 +186,13 @@ module Pod
|
|
|
182
186
|
#
|
|
183
187
|
spec_attr_accessor :vendored_libraries
|
|
184
188
|
|
|
185
|
-
# @return [Hash{String=>String}]
|
|
189
|
+
# @return [Hash{String => Array<String>}] hash where the keys are the tags of
|
|
190
|
+
# the on demand resources and the values are their relative file
|
|
191
|
+
# patterns.
|
|
192
|
+
#
|
|
193
|
+
spec_attr_accessor :on_demand_resources
|
|
194
|
+
|
|
195
|
+
# @return [Hash{String=>String}]] hash where the keys are the names of
|
|
186
196
|
# the resource bundles and the values are their relative file
|
|
187
197
|
# patterns.
|
|
188
198
|
#
|
|
@@ -455,6 +465,24 @@ module Pod
|
|
|
455
465
|
Specification.convert_keys_to_symbol(value, :recursive => false) if value && value.is_a?(Hash)
|
|
456
466
|
end
|
|
457
467
|
|
|
468
|
+
# Ensures that the file patterns of the on demand resources are contained in
|
|
469
|
+
# an array.
|
|
470
|
+
#
|
|
471
|
+
# @param [String, Array, Hash] value.
|
|
472
|
+
# The value of the attribute as specified by the user.
|
|
473
|
+
#
|
|
474
|
+
# @return [Hash] the on demand resources1.
|
|
475
|
+
#
|
|
476
|
+
def _prepare_on_demand_resources(value)
|
|
477
|
+
result = {}
|
|
478
|
+
if value
|
|
479
|
+
value.each do |key, patterns|
|
|
480
|
+
result[key] = [*patterns].compact
|
|
481
|
+
end
|
|
482
|
+
end
|
|
483
|
+
result
|
|
484
|
+
end
|
|
485
|
+
|
|
458
486
|
# Ensures that the file patterns of the resource bundles are contained in
|
|
459
487
|
# an array.
|
|
460
488
|
#
|
|
@@ -1077,7 +1077,7 @@ module Pod
|
|
|
1077
1077
|
SCRIPT_PHASE_OPTIONAL_KEYS = [:shell_path, :input_files, :output_files, :input_file_lists, :output_file_lists,
|
|
1078
1078
|
:show_env_vars_in_log, :execution_position, :dependency_file].freeze
|
|
1079
1079
|
|
|
1080
|
-
EXECUTION_POSITION_KEYS = [:before_compile, :after_compile, :any].freeze
|
|
1080
|
+
EXECUTION_POSITION_KEYS = [:before_compile, :after_compile, :before_headers, :after_headers, :any].freeze
|
|
1081
1081
|
|
|
1082
1082
|
ALL_SCRIPT_PHASE_KEYS = (SCRIPT_PHASE_REQUIRED_KEYS + SCRIPT_PHASE_OPTIONAL_KEYS).freeze
|
|
1083
1083
|
|
|
@@ -1259,6 +1259,32 @@ module Pod
|
|
|
1259
1259
|
|
|
1260
1260
|
#------------------#
|
|
1261
1261
|
|
|
1262
|
+
# @!method project_header_files=(project_header_files)
|
|
1263
|
+
#
|
|
1264
|
+
# A list of file patterns that should be used to mark project headers.
|
|
1265
|
+
#
|
|
1266
|
+
# ---
|
|
1267
|
+
#
|
|
1268
|
+
# These patterns are matched against the public headers (or all the
|
|
1269
|
+
# headers if no public headers have been specified) to exclude those
|
|
1270
|
+
# headers which should not be exposed to the user project and which
|
|
1271
|
+
# should not be used to generate the documentation. When the library
|
|
1272
|
+
# is built, these headers will _not_ appear in the build directory.
|
|
1273
|
+
#
|
|
1274
|
+
#
|
|
1275
|
+
# @example
|
|
1276
|
+
#
|
|
1277
|
+
# spec.project_header_files = 'Headers/Project/*.h'
|
|
1278
|
+
#
|
|
1279
|
+
# @param [String, Array<String>] project_header_files
|
|
1280
|
+
# the project headers of the Pod.
|
|
1281
|
+
#
|
|
1282
|
+
attribute :project_header_files,
|
|
1283
|
+
:container => Array,
|
|
1284
|
+
:file_patterns => true
|
|
1285
|
+
|
|
1286
|
+
#------------------#
|
|
1287
|
+
|
|
1262
1288
|
# @!method private_header_files=(private_header_files)
|
|
1263
1289
|
#
|
|
1264
1290
|
# A list of file patterns that should be used to mark private headers.
|
|
@@ -1271,7 +1297,7 @@ module Pod
|
|
|
1271
1297
|
# should not be used to generate the documentation. When the library
|
|
1272
1298
|
# is built, these headers will appear in the build directory.
|
|
1273
1299
|
#
|
|
1274
|
-
# Header files that are not listed as neither public nor private will
|
|
1300
|
+
# Header files that are not listed as neither public nor project or private will
|
|
1275
1301
|
# be treated as private, but in addition will not appear in the build
|
|
1276
1302
|
# directory at all.
|
|
1277
1303
|
#
|
|
@@ -1335,6 +1361,32 @@ module Pod
|
|
|
1335
1361
|
|
|
1336
1362
|
#------------------#
|
|
1337
1363
|
|
|
1364
|
+
# @!method on_demand_resources=(on_demand_resources)
|
|
1365
|
+
#
|
|
1366
|
+
# A hash of on_demand_resources that should be copied into the target bundle. Resources specified here
|
|
1367
|
+
# will automatically become part of the resources build phase of the target.
|
|
1368
|
+
#
|
|
1369
|
+
# @example
|
|
1370
|
+
#
|
|
1371
|
+
# s.on_demand_resources = {
|
|
1372
|
+
# 'Tag1' => 'file1.png'
|
|
1373
|
+
# }
|
|
1374
|
+
#
|
|
1375
|
+
# s.on_demand_resources = {
|
|
1376
|
+
# 'Tag1' => ['file1.png', 'file2.png']
|
|
1377
|
+
# }
|
|
1378
|
+
#
|
|
1379
|
+
# @param [Hash{String=>String}, Hash{String=>Array<String>}] on_demand_resources
|
|
1380
|
+
# The on_demand_resources shipped with the Pod.
|
|
1381
|
+
#
|
|
1382
|
+
attribute :on_demand_resources,
|
|
1383
|
+
:types => [String, Array],
|
|
1384
|
+
:container => Hash,
|
|
1385
|
+
:file_patterns => true,
|
|
1386
|
+
:singularize => true
|
|
1387
|
+
|
|
1388
|
+
#------------------#
|
|
1389
|
+
|
|
1338
1390
|
# @!method resource_bundles=(*resource_bundles)
|
|
1339
1391
|
#
|
|
1340
1392
|
# This attribute allows to define the name and the file of the resource
|
|
@@ -1458,6 +1510,12 @@ module Pod
|
|
|
1458
1510
|
# The module map file that should be used when this pod is integrated as
|
|
1459
1511
|
# a framework.
|
|
1460
1512
|
#
|
|
1513
|
+
# `false` indicates that the default CocoaPods `modulemap` file should not
|
|
1514
|
+
# be generated.
|
|
1515
|
+
#
|
|
1516
|
+
# `true` is the default and indicates that the default CocoaPods
|
|
1517
|
+
# `modulemap` file should be generated.
|
|
1518
|
+
#
|
|
1461
1519
|
# ---
|
|
1462
1520
|
#
|
|
1463
1521
|
# By default, CocoaPods creates a module map file based upon the public
|
|
@@ -1467,11 +1525,17 @@ module Pod
|
|
|
1467
1525
|
#
|
|
1468
1526
|
# spec.module_map = 'source/module.modulemap'
|
|
1469
1527
|
#
|
|
1470
|
-
# @
|
|
1471
|
-
#
|
|
1528
|
+
# @example
|
|
1529
|
+
#
|
|
1530
|
+
# spec.module_map = false
|
|
1531
|
+
#
|
|
1532
|
+
# @param [String, Bool] module_map
|
|
1533
|
+
# the path to the module map file that should be used
|
|
1534
|
+
# or whether to disable module_map generation.
|
|
1472
1535
|
#
|
|
1473
1536
|
attribute :module_map,
|
|
1474
|
-
:
|
|
1537
|
+
:types => [TrueClass, FalseClass, String],
|
|
1538
|
+
:root_only => true
|
|
1475
1539
|
|
|
1476
1540
|
#-----------------------------------------------------------------------#
|
|
1477
1541
|
|
|
@@ -242,9 +242,6 @@ module Pod
|
|
|
242
242
|
def _validate_version(v)
|
|
243
243
|
if v.to_s.empty?
|
|
244
244
|
results.add_error('version', 'A version is required.')
|
|
245
|
-
elsif v <= Version::ZERO
|
|
246
|
-
results.add_error('version', 'The version of the spec should be' \
|
|
247
|
-
' higher than 0.')
|
|
248
245
|
end
|
|
249
246
|
end
|
|
250
247
|
|
|
@@ -337,19 +334,6 @@ module Pod
|
|
|
337
334
|
end
|
|
338
335
|
end
|
|
339
336
|
|
|
340
|
-
# Performs validations related to the `vendored_libraries` attribute.
|
|
341
|
-
#
|
|
342
|
-
# @param [Array<String>] vendored_libraries the values specified in the `vendored_libraries` attribute
|
|
343
|
-
#
|
|
344
|
-
def _validate_vendored_libraries(vendored_libraries)
|
|
345
|
-
vendored_libraries.each do |lib|
|
|
346
|
-
lib_name = lib.downcase
|
|
347
|
-
unless lib_name.end_with?('.a') && lib_name.start_with?('lib')
|
|
348
|
-
results.add_warning('vendored_libraries', "`#{File.basename(lib)}` does not match the expected static library name format `lib[name].a`")
|
|
349
|
-
end
|
|
350
|
-
end
|
|
351
|
-
end
|
|
352
|
-
|
|
353
337
|
# Performs validations related to the `license` attribute.
|
|
354
338
|
#
|
|
355
339
|
def _validate_license(l)
|
|
@@ -102,7 +102,7 @@ module Pod
|
|
|
102
102
|
# Check empty subspec attributes
|
|
103
103
|
#
|
|
104
104
|
def check_if_spec_is_empty
|
|
105
|
-
methods = %w( source_files resources resource_bundles preserve_paths
|
|
105
|
+
methods = %w( source_files on_demand_resources resources resource_bundles preserve_paths
|
|
106
106
|
dependencies vendored_libraries vendored_frameworks )
|
|
107
107
|
empty_patterns = methods.all? { |m| consumer.send(m).empty? }
|
|
108
108
|
empty = empty_patterns && consumer.spec.subspecs.empty?
|
|
@@ -212,8 +212,6 @@ module Pod
|
|
|
212
212
|
|
|
213
213
|
#-----------------------------------------------------------------------#
|
|
214
214
|
|
|
215
|
-
private
|
|
216
|
-
|
|
217
215
|
# @!group Array Sorting
|
|
218
216
|
|
|
219
217
|
# Sorts an array using another one as a sort hint. All the values of the
|
|
@@ -291,21 +289,21 @@ module Pod
|
|
|
291
289
|
/0x[0-9a-fA-F]+/, # base 16 int
|
|
292
290
|
/[-+]?(\.[0-9]+|[0-9]+(\.[0-9]*)?)([eE][-+]?[0-9]+)?/, # float
|
|
293
291
|
/[-+]?\.(inf|Inf|INF)/, # infinity
|
|
294
|
-
/\.(nan|NaN|NAN)
|
|
292
|
+
/\.(nan|NaN|NAN)/ # NaN
|
|
295
293
|
)
|
|
296
294
|
private_constant :RESOLVED_TAGS
|
|
297
295
|
|
|
298
296
|
INDICATOR_START_CHARS = %w(- ? : , [ ] { } # & * ! | > ' " % @ `).freeze
|
|
299
|
-
INDICATOR_START = /\A#{Regexp.union(INDICATOR_START_CHARS)}
|
|
297
|
+
INDICATOR_START = /\A#{Regexp.union(INDICATOR_START_CHARS)}/.freeze
|
|
300
298
|
private_constant :INDICATOR_START_CHARS, :INDICATOR_START
|
|
301
299
|
|
|
302
|
-
RESOLVED_TAGS_PATTERN = /\A#{Regexp.union(RESOLVED_TAGS)}\z
|
|
300
|
+
RESOLVED_TAGS_PATTERN = /\A#{Regexp.union(RESOLVED_TAGS)}\z/.freeze
|
|
303
301
|
private_constant :RESOLVED_TAGS_PATTERN
|
|
304
302
|
|
|
305
303
|
VALID_PLAIN_SCALAR_STRING = %r{\A
|
|
306
304
|
[\w&&[^#{INDICATOR_START_CHARS}]] # valid first character
|
|
307
305
|
[\w/\ \(\)~<>=\.:`,-]* # all characters allowed after the first one
|
|
308
|
-
\z}ox
|
|
306
|
+
\z}ox.freeze
|
|
309
307
|
private_constant :VALID_PLAIN_SCALAR_STRING
|
|
310
308
|
|
|
311
309
|
def process_string(string)
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: cocoapods-core
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.11.0.beta.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Eloy Duran
|
|
@@ -9,28 +9,28 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2021-
|
|
12
|
+
date: 2021-08-09 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: activesupport
|
|
16
16
|
requirement: !ruby/object:Gem::Requirement
|
|
17
17
|
requirements:
|
|
18
|
-
- - "
|
|
18
|
+
- - ">="
|
|
19
19
|
- !ruby/object:Gem::Version
|
|
20
20
|
version: '5.0'
|
|
21
21
|
- - "<"
|
|
22
22
|
- !ruby/object:Gem::Version
|
|
23
|
-
version: '
|
|
23
|
+
version: '7'
|
|
24
24
|
type: :runtime
|
|
25
25
|
prerelease: false
|
|
26
26
|
version_requirements: !ruby/object:Gem::Requirement
|
|
27
27
|
requirements:
|
|
28
|
-
- - "
|
|
28
|
+
- - ">="
|
|
29
29
|
- !ruby/object:Gem::Version
|
|
30
30
|
version: '5.0'
|
|
31
31
|
- - "<"
|
|
32
32
|
- !ruby/object:Gem::Version
|
|
33
|
-
version: '
|
|
33
|
+
version: '7'
|
|
34
34
|
- !ruby/object:Gem::Dependency
|
|
35
35
|
name: nap
|
|
36
36
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -121,28 +121,28 @@ dependencies:
|
|
|
121
121
|
requirements:
|
|
122
122
|
- - "~>"
|
|
123
123
|
- !ruby/object:Gem::Version
|
|
124
|
-
version: '2.
|
|
124
|
+
version: '2.8'
|
|
125
125
|
type: :runtime
|
|
126
126
|
prerelease: false
|
|
127
127
|
version_requirements: !ruby/object:Gem::Requirement
|
|
128
128
|
requirements:
|
|
129
129
|
- - "~>"
|
|
130
130
|
- !ruby/object:Gem::Version
|
|
131
|
-
version: '2.
|
|
131
|
+
version: '2.8'
|
|
132
132
|
- !ruby/object:Gem::Dependency
|
|
133
133
|
name: public_suffix
|
|
134
134
|
requirement: !ruby/object:Gem::Requirement
|
|
135
135
|
requirements:
|
|
136
|
-
- - "
|
|
136
|
+
- - "~>"
|
|
137
137
|
- !ruby/object:Gem::Version
|
|
138
|
-
version: '0'
|
|
138
|
+
version: '4.0'
|
|
139
139
|
type: :runtime
|
|
140
140
|
prerelease: false
|
|
141
141
|
version_requirements: !ruby/object:Gem::Requirement
|
|
142
142
|
requirements:
|
|
143
|
-
- - "
|
|
143
|
+
- - "~>"
|
|
144
144
|
- !ruby/object:Gem::Version
|
|
145
|
-
version: '0'
|
|
145
|
+
version: '4.0'
|
|
146
146
|
- !ruby/object:Gem::Dependency
|
|
147
147
|
name: bacon
|
|
148
148
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -224,15 +224,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
224
224
|
requirements:
|
|
225
225
|
- - ">="
|
|
226
226
|
- !ruby/object:Gem::Version
|
|
227
|
-
version: 2.
|
|
227
|
+
version: '2.6'
|
|
228
228
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
229
229
|
requirements:
|
|
230
|
-
- - "
|
|
230
|
+
- - ">"
|
|
231
231
|
- !ruby/object:Gem::Version
|
|
232
|
-
version:
|
|
232
|
+
version: 1.3.1
|
|
233
233
|
requirements: []
|
|
234
234
|
rubygems_version: 3.0.3
|
|
235
235
|
signing_key:
|
|
236
|
-
specification_version:
|
|
236
|
+
specification_version: 4
|
|
237
237
|
summary: The models of CocoaPods
|
|
238
238
|
test_files: []
|