cocoapods-jxedt 0.0.19 → 0.0.21
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/cocoapods-jxedt/binary/Intergation.rb +9 -6
- data/lib/cocoapods-jxedt/binary/config.rb +12 -1
- data/lib/cocoapods-jxedt/binary/helper/podfile_options.rb +2 -2
- data/lib/cocoapods-jxedt/binary/helper/podfile_post_install_hook.rb +1 -0
- data/lib/cocoapods-jxedt/binary/helper/prebuild_installer.rb +12 -0
- data/lib/cocoapods-jxedt/binary/helper/target_definition.rb +15 -9
- data/lib/cocoapods-jxedt/binary/pod-room/xcodebuild_command.rb +10 -0
- data/lib/cocoapods-jxedt/binary/prebuild.rb +9 -9
- data/lib/cocoapods-jxedt/binary/targets/pod_target.rb +7 -4
- data/lib/cocoapods-jxedt/command/binary/command/push.rb +7 -2
- data/lib/cocoapods-jxedt/command/binary/command/source_project.rb +2 -0
- data/lib/cocoapods-jxedt/command/header/header.rb +5 -3
- data/lib/cocoapods-jxedt/command/jxedt.rb +1 -0
- data/lib/cocoapods-jxedt/command/modify/modify.rb +63 -0
- data/lib/cocoapods-jxedt/command/options/options.rb +24 -0
- data/lib/cocoapods-jxedt/gem_version.rb +1 -1
- data/lib/cocoapods-jxedt/git_helper/cache_pucher.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a6302e970ed73bc5b9e9d1c360b07866274dfef9c17cb525fbf421c18731a0af
|
4
|
+
data.tar.gz: bc7af03bb9f4754d6ad79011b9350f05008a311701236f69f5d8f265a85e1bd7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4792210d5b87ea5ed46be38635a2c6851a355c97cc964b59cfb8c35031bb5da0b18f36ac496ce59f031e9108cd469821ea3eb887bb22ecb6cf0b0744ecaaff4f
|
7
|
+
data.tar.gz: ae695a6d13a154a1b5d3f9fb060c1e8aabf346c719a8d5e3c2f76f07d4eb81260550796ef7721730b616090be5d0aaecd6ee726b85e6fbdd13ea51c7fd1aa4ec
|
@@ -18,8 +18,8 @@ module Pod
|
|
18
18
|
class PodSourceInstaller
|
19
19
|
|
20
20
|
def install_for_prebuild!(standard_sanbox)
|
21
|
-
|
22
|
-
target_names =
|
21
|
+
binary_sandbox = Jxedt::BinarySandbox.from_sandbox(standard_sanbox)
|
22
|
+
target_names = binary_sandbox.existed_target_names(self.name)
|
23
23
|
|
24
24
|
def walk(path, &action)
|
25
25
|
return unless path.exist?
|
@@ -53,7 +53,7 @@ module Pod
|
|
53
53
|
target_names.each do |name|
|
54
54
|
|
55
55
|
# symbol link copy all substructure
|
56
|
-
real_file_folder =
|
56
|
+
real_file_folder = binary_sandbox.framework_folder_path_for_target_name(name)
|
57
57
|
|
58
58
|
# If have only one platform, just place int the root folder of this pod.
|
59
59
|
# If have multiple paths, we use a sperated folder to store different
|
@@ -132,8 +132,11 @@ module Pod
|
|
132
132
|
end
|
133
133
|
end
|
134
134
|
end
|
135
|
+
|
136
|
+
# 设置使用二进制的targets标识
|
137
|
+
prebuilt_pod_targets.each { |target| target.use_binary = true }
|
135
138
|
|
136
|
-
|
139
|
+
binary_sandbox = Jxedt::BinarySandbox.from_sandbox(self.sandbox)
|
137
140
|
|
138
141
|
specs = self.analysis_result.specifications
|
139
142
|
prebuilt_specs = (specs.select do |spec|
|
@@ -175,7 +178,7 @@ module Pod
|
|
175
178
|
resources = [resources] if resources.kind_of?(String)
|
176
179
|
spec.attributes_hash["resources"] = resources
|
177
180
|
# spec.attributes_hash["resources"] += bundle_names.map{|n| n+".bundle"}
|
178
|
-
prebuild_bundles =
|
181
|
+
prebuild_bundles = binary_sandbox.prebuild_bundles(spec.root.name).each.map { |bundle_path| "_Prebuild/" + bundle_path }
|
179
182
|
prebuild_bundles = [] if checked_specs[spec.root.name].size > 1 # spec.root.name相同的只添加一次bundle文件
|
180
183
|
spec.attributes_hash["resources"] += prebuild_bundles
|
181
184
|
end
|
@@ -186,7 +189,7 @@ module Pod
|
|
186
189
|
targets.each do |target|
|
187
190
|
# the framework_file_path rule is decided when `install_for_prebuild`,
|
188
191
|
# as to compitable with older version and be less wordy.
|
189
|
-
|
192
|
+
binary_sandbox.prebuild_vendored_frameworks(spec.root.name).each do |frame_file_path|
|
190
193
|
framework_file_path = "_Prebuild/" + frame_file_path
|
191
194
|
framework_file_path = nil if checked_specs[spec.root.name].size > 1 # spec.root.name相同的只添加一次framework文件
|
192
195
|
add_vendered_framework(spec, target.platform.name.to_s, framework_file_path)
|
@@ -18,6 +18,7 @@ module Jxedt
|
|
18
18
|
:xcconfig_configuration_alias => "xcconfig文件中配置多configuration的别名(一定要唯一),用于搜索替换,我们用来支持多configuration的二进制。一般不需要设置,默认值为'cocoapods-jxedt-binary'",
|
19
19
|
:framework_header_search_enabled => "开启binary的组件是否配置HEADER_SEARCH_PATH头文件搜索,兼容头文件引用的问题。默认为false",
|
20
20
|
:silent_build => "静默编译,即不输出编译命令。默认true",
|
21
|
+
:fix_swiftinterface_pods => "修复swiftinterface的bug,即:组件中包含和module name同名的class,使用不同swift编译器编译时报错;需要填写需要修复的组件名称",
|
21
22
|
:configurations => "支持的configuration配置,可以写字符串'Debug'或'Release',也可以写多个'['Debug', 'Release']'。默认为'Release'",
|
22
23
|
:xcframework => "编译结果是否为xcframework。默认false",
|
23
24
|
:clean_build => "编译的时候是否clean build。默认true",
|
@@ -119,6 +120,11 @@ module Jxedt
|
|
119
120
|
@dsl_config[:silent_build] || @dsl_config[:silent_build].nil?
|
120
121
|
end
|
121
122
|
|
123
|
+
def should_fix_swiftinterface_bug?(target_name)
|
124
|
+
@fix_swiftinterface_pods = @dsl_config[:fix_swiftinterface_pods] || []
|
125
|
+
@fix_swiftinterface_pods.include?(target_name)
|
126
|
+
end
|
127
|
+
|
122
128
|
def xcframework?
|
123
129
|
@dsl_config[:xcframework] || false
|
124
130
|
end
|
@@ -201,7 +207,12 @@ module Jxedt
|
|
201
207
|
end
|
202
208
|
|
203
209
|
def git_remote_repo
|
204
|
-
@remote ||=
|
210
|
+
@remote ||= begin
|
211
|
+
remote = cache_repo[:remote]
|
212
|
+
remote.chomp!('/') if remote.is_a?(String) # 去除最后的'/'
|
213
|
+
remote.strip! if remote.is_a?(String) # 去除左右空格、转义字符
|
214
|
+
remote
|
215
|
+
end
|
205
216
|
end
|
206
217
|
|
207
218
|
def cache_repo_enabled?
|
@@ -52,8 +52,8 @@ module Pod
|
|
52
52
|
}.uniq
|
53
53
|
|
54
54
|
available_pod_names = []
|
55
|
-
|
56
|
-
available_pod_names =
|
55
|
+
binary_sandbox = Jxedt::BinarySandbox.from_sandbox(self.sandbox)
|
56
|
+
available_pod_names = binary_sandbox.target_paths.map {|path| path.basename.to_s }
|
57
57
|
if Jxedt.config.all_binary_enabled?
|
58
58
|
explicit_prebuild_pod_names = available_pod_names
|
59
59
|
else
|
@@ -20,6 +20,7 @@ module Pod
|
|
20
20
|
def handle_pods_project_configurations!(installer)
|
21
21
|
installer.pods_project.targets.each do |target|
|
22
22
|
target.build_configurations.each do |config|
|
23
|
+
config.build_settings["BUILD_LIBRARY_FOR_DISTRIBUTION"] = "YES"
|
23
24
|
config.build_settings["CODE_SIGN_IDENTITY"] = "" if target.respond_to?(:product_type) and target.product_type == "com.apple.product-type.bundle"
|
24
25
|
end
|
25
26
|
end
|
@@ -34,6 +34,18 @@ module Pod
|
|
34
34
|
# 恢复sandbox标识
|
35
35
|
sandbox.index_project_create_stage = false
|
36
36
|
end
|
37
|
+
|
38
|
+
def resolve_dependencies
|
39
|
+
analyzer = super
|
40
|
+
self.analysis_result.specifications.each do |spec|
|
41
|
+
# keep all file in pods
|
42
|
+
preserve_paths = spec.attributes_hash["preserve_paths"] || []
|
43
|
+
preserve_paths = [preserve_paths] if preserve_paths.kind_of?(String)
|
44
|
+
preserve_paths += ['_Prebuild']
|
45
|
+
spec.attributes_hash["preserve_paths"] = preserve_paths
|
46
|
+
end
|
47
|
+
analyzer
|
48
|
+
end
|
37
49
|
end
|
38
50
|
end
|
39
51
|
|
@@ -10,21 +10,16 @@ module Pod
|
|
10
10
|
if options.is_a?(Hash) && options.include?(:binary)
|
11
11
|
@explicit_prebuild_pod_names << Specification.root_name(name) if options[:binary]
|
12
12
|
@reject_prebuild_pod_names << Specification.root_name(name) unless options[:binary]
|
13
|
-
else
|
14
|
-
settings = Jxedt.config.binary_settings
|
15
|
-
symbol_name = Specification.root_name(name).to_sym
|
16
|
-
if settings.include?(symbol_name) && [true, false].include?(settings[symbol_name])
|
17
|
-
@explicit_prebuild_pod_names << Specification.root_name(name) if settings[symbol_name]
|
18
|
-
@reject_prebuild_pod_names << Specification.root_name(name) unless settings[symbol_name]
|
19
|
-
end
|
20
13
|
end
|
21
14
|
|
22
15
|
|
23
16
|
# header search path
|
24
17
|
@explicit_header_search_pod_names ||= []
|
25
18
|
@reject_header_search_pod_names ||= []
|
26
|
-
|
27
|
-
|
19
|
+
if options.is_a?(Hash) && options.include?(:framework_header_search)
|
20
|
+
@explicit_header_search_pod_names << Specification.root_name(name) if options[:framework_header_search]
|
21
|
+
@reject_header_search_pod_names << Specification.root_name(name) unless options[:framework_header_search]
|
22
|
+
end
|
28
23
|
|
29
24
|
options.delete(:binary) if options.is_a?(Hash)
|
30
25
|
options.delete(:framework_header_search) if options.is_a?(Hash)
|
@@ -37,6 +32,17 @@ module Pod
|
|
37
32
|
original_parse_inhibit_warnings = instance_method(:parse_inhibit_warnings)
|
38
33
|
define_method(:parse_inhibit_warnings) do |name, requirements|
|
39
34
|
detect_prebuilt_pod(name, requirements)
|
35
|
+
|
36
|
+
# merge binary settings
|
37
|
+
Jxedt.config.binary_settings.each { |name, val|
|
38
|
+
next if @explicit_prebuild_pod_names.include?(name) # 配置:binary的组件优先级高
|
39
|
+
next if @reject_prebuild_pod_names.include?(name)
|
40
|
+
next unless [true, false].include?(val)
|
41
|
+
|
42
|
+
@explicit_prebuild_pod_names << name.to_s if val
|
43
|
+
@reject_prebuild_pod_names << name.to_s unless val
|
44
|
+
}
|
45
|
+
|
40
46
|
original_parse_inhibit_warnings.bind(self).call(name, requirements)
|
41
47
|
end
|
42
48
|
end
|
@@ -35,6 +35,16 @@ module Jxedt
|
|
35
35
|
else
|
36
36
|
collect_output(target, Dir[target_products_dir_of(target, sdks[0]) + "/*"])
|
37
37
|
end
|
38
|
+
|
39
|
+
# fix swiftinterface bug
|
40
|
+
if target.defines_module? && Jxedt.config.should_fix_swiftinterface_bug?(target.label)
|
41
|
+
# https://developer.apple.com/forums/thread/123253
|
42
|
+
cmd = "find #{output_path(target)} -name '*.swiftinterface' -exec sed -i -e 's/#{target.product_module_name}\\.//g' {} \\;"
|
43
|
+
`#{cmd}`
|
44
|
+
|
45
|
+
Pod::UI.puts "- Fix Swiftinterface Bug: #{target}".magenta unless Jxedt.config.silent_build?
|
46
|
+
Pod::UI.puts_indented "$ #{cmd}" unless Jxedt.config.silent_build?
|
47
|
+
end
|
38
48
|
end
|
39
49
|
end
|
40
50
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
module Jxedt
|
2
|
-
class
|
3
|
-
attr_accessor :
|
2
|
+
class BinarySandbox
|
3
|
+
attr_accessor :standard_sandbox
|
4
4
|
|
5
5
|
def initialize(path=nil)
|
6
6
|
@sandbox_path = path
|
@@ -9,9 +9,9 @@ module Jxedt
|
|
9
9
|
def self.from_sandbox(sandbox)
|
10
10
|
search_path = Jxedt.config.binary_dir
|
11
11
|
binary_dir = search_path.empty? ? nil : sandbox.standard_sandbox_root + search_path
|
12
|
-
|
13
|
-
|
14
|
-
|
12
|
+
binary_sandbox = BinarySandbox.new(binary_dir)
|
13
|
+
binary_sandbox.standard_sandbox = sandbox
|
14
|
+
binary_sandbox
|
15
15
|
end
|
16
16
|
|
17
17
|
def binary_dir
|
@@ -21,11 +21,11 @@ module Jxedt
|
|
21
21
|
def target_paths
|
22
22
|
return [] if @sandbox_path.nil?
|
23
23
|
return [] unless binary_dir.exist?
|
24
|
-
return [] if @
|
24
|
+
return [] if @standard_sandbox.source_lockfile.nil?
|
25
25
|
@targets ||= begin
|
26
26
|
prebuild_targets = binary_dir.children().map do |target_path|
|
27
27
|
if target_path.directory? && (not target_path.children.empty?)
|
28
|
-
hash_key = @
|
28
|
+
hash_key = @standard_sandbox.source_lockfile.spec_checksums_hash_key(target_path.basename.to_s)
|
29
29
|
next if hash_key.nil?
|
30
30
|
|
31
31
|
checksum_files = target_path.children().select { |path| path.extname == '.checksum' }
|
@@ -126,8 +126,8 @@ module Jxedt
|
|
126
126
|
end
|
127
127
|
|
128
128
|
def build
|
129
|
-
|
130
|
-
existed_target_names =
|
129
|
+
binary_sandbox = Jxedt::BinarySandbox.from_sandbox(@source_installer.sandbox)
|
130
|
+
existed_target_names = binary_sandbox.target_paths.map { |pair| pair.basename.to_s }
|
131
131
|
targets = targets_to_prebuild.reject { |target| existed_target_names.include?(target.name.to_s) }
|
132
132
|
|
133
133
|
Pod::UI.puts "Prebuild total count: #{targets.size}"
|
@@ -54,8 +54,6 @@ module Pod
|
|
54
54
|
class BuildSettings
|
55
55
|
# missing framework header search paths
|
56
56
|
def missing_framework_header_search_path(pt)
|
57
|
-
return [] unless pt.frame_header_search_paths_enable?
|
58
|
-
|
59
57
|
paths = []
|
60
58
|
pt.file_accessors.each do |file_accessor|
|
61
59
|
# xcframeworks
|
@@ -123,7 +121,11 @@ module Pod
|
|
123
121
|
alias_method :old_raw_header_search_paths, :_raw_header_search_paths
|
124
122
|
def _raw_header_search_paths
|
125
123
|
header_search_paths = old_raw_header_search_paths
|
126
|
-
header_search_paths.concat pod_targets.flat_map { |pt|
|
124
|
+
header_search_paths.concat pod_targets.flat_map { |pt|
|
125
|
+
search_paths = []
|
126
|
+
search_paths.concat missing_framework_header_search_path(pt) if pt.frame_header_search_paths_enable?
|
127
|
+
search_paths
|
128
|
+
}
|
127
129
|
header_search_paths.uniq
|
128
130
|
end
|
129
131
|
end
|
@@ -134,7 +136,8 @@ module Pod
|
|
134
136
|
alias_method :old_raw_header_search_paths, :_raw_header_search_paths
|
135
137
|
def _raw_header_search_paths
|
136
138
|
header_search_paths = old_raw_header_search_paths
|
137
|
-
header_search_paths
|
139
|
+
# 两个条件都满足时添加header_search_paths
|
140
|
+
header_search_paths.concat dependent_targets.flat_map { |pt| missing_framework_header_search_path(pt) } if target.should_build? && target.frame_header_search_paths_enable?
|
138
141
|
header_search_paths.uniq
|
139
142
|
end
|
140
143
|
|
@@ -12,11 +12,13 @@ module Pod
|
|
12
12
|
]
|
13
13
|
def self.options
|
14
14
|
[
|
15
|
-
['--force-push', '强制推送组件二进制到远程,远程有相同的校验和会被本地覆盖']
|
15
|
+
['--force-push', '强制推送组件二进制到远程,远程有相同的校验和会被本地覆盖'],
|
16
|
+
['--name', '需要推送到远程的组件名称,不填则推送全部的二进制组件到远程']
|
16
17
|
]
|
17
18
|
end
|
18
19
|
def initialize(argv)
|
19
20
|
@force_push = argv.flag?('force-push', false)
|
21
|
+
@name = argv.option('name')
|
20
22
|
super
|
21
23
|
end
|
22
24
|
|
@@ -32,7 +34,10 @@ module Pod
|
|
32
34
|
require 'cocoapods-jxedt/git_helper/cache_pucher'
|
33
35
|
|
34
36
|
output_dir = Pod::Config.instance.sandbox.root + Jxedt.config.binary_dir
|
35
|
-
|
37
|
+
|
38
|
+
targets = []
|
39
|
+
targets += @name.split(',') if @name && @name.length > 0
|
40
|
+
Jxedt::CachePucher.push(output_dir, targets, @force_push)
|
36
41
|
end
|
37
42
|
end
|
38
43
|
end
|
@@ -75,7 +75,8 @@ module Pod
|
|
75
75
|
lines = File.readlines(file_path)
|
76
76
|
# 获取命中的行
|
77
77
|
File.foreach(file_path).with_index {|line, num|
|
78
|
-
|
78
|
+
matched_regex = "(^\s*#import\s*\"#{header_name_regulation}\")|(^\s*#import\s*<#{header_name_regulation}>)"
|
79
|
+
matched = line =~ /#{matched_regex}/
|
79
80
|
next unless matched
|
80
81
|
|
81
82
|
header_name = line.match(/(?<=")#{header_name_regulation}(?=")/) || line.match(/(?<=<)#{header_name_regulation}(?=>)/)
|
@@ -83,7 +84,7 @@ module Pod
|
|
83
84
|
|
84
85
|
changed = true # 文件需要修改
|
85
86
|
project_module_name = public_header_mapping["#{header_name}"]
|
86
|
-
replace_line = "#import
|
87
|
+
replace_line = line.gsub(/#{matched_regex}/, "#import <#{project_module_name}/#{header_name}>")
|
87
88
|
lines[num] = replace_line
|
88
89
|
record << "#{file_path} 第#{num}行,#{line} => #{replace_line}"
|
89
90
|
}
|
@@ -107,7 +108,8 @@ module Pod
|
|
107
108
|
文件修改详情:
|
108
109
|
#{JSON.pretty_generate(record)}
|
109
110
|
LOGS
|
110
|
-
logs.gsub!('\\"', '"')
|
111
|
+
logs.gsub!('\\"', '"')# 去除转义字符
|
112
|
+
logs.gsub!('\\n', '') # 去除转义字符
|
111
113
|
puts logs if @verbose_flag
|
112
114
|
File.open(log_file_path, 'w') { |file| file.write("#{logs}") } unless log_file_path.nil?
|
113
115
|
end
|
@@ -0,0 +1,63 @@
|
|
1
|
+
module Pod
|
2
|
+
class Command
|
3
|
+
class JxedtCommand < Command
|
4
|
+
class ModifyDir < JxedtCommand
|
5
|
+
self.summary = '修改文件目录的真实路径,并在原位置创建一个目录的软链接,为二进制调试提供便利。'
|
6
|
+
self.description = <<-DESC
|
7
|
+
可以把很多台机器上的工程目录统一放置到一个相同目录,这样可以确保所有的机器的工程目录都是相同的。\n
|
8
|
+
编译打包的文件路径也是相同的,然后就可以使用二进制调试的功能了。\n
|
9
|
+
这个统一的目录是`/Users/cocoapods-jxedt/`
|
10
|
+
DESC
|
11
|
+
self.command = 'modifydir'
|
12
|
+
self.arguments = [
|
13
|
+
CLAide::Argument.new('DIRECTORY_PATH', true)
|
14
|
+
]
|
15
|
+
def self.options
|
16
|
+
[
|
17
|
+
['--name', '统一路径下的工程目录名称']
|
18
|
+
]
|
19
|
+
end
|
20
|
+
def initialize(argv)
|
21
|
+
@dir_path = argv.shift_argument
|
22
|
+
@name = argv.option('name')
|
23
|
+
super
|
24
|
+
end
|
25
|
+
|
26
|
+
def validate!
|
27
|
+
super
|
28
|
+
help! '没有传入操作目录!!!' if @dir_path.nil?
|
29
|
+
# 获取完整路径
|
30
|
+
@dir_path = File.expand_path(@dir_path)
|
31
|
+
help! '操作目录不存在!!!' unless File.exist?(@dir_path)
|
32
|
+
help! '传入的地址不是一个目录!!!' unless File.directory?(@dir_path)
|
33
|
+
help! '操作目录已经是一个软链接!!!' if File.ftype(@dir_path) == 'link'
|
34
|
+
help! '操作目录已经在指定目录下!!!' if @dir_path =~ /^#{user_path}/
|
35
|
+
help! '当前目录不允许操作,操作路径最少要3层目录!!!' unless @dir_path.split('/').reject { |path| path.empty? }.count > 2
|
36
|
+
end
|
37
|
+
|
38
|
+
def run
|
39
|
+
op_dir_path = Pathname.new(@dir_path)
|
40
|
+
# 获取target name
|
41
|
+
@name = op_dir_path.basename if @name.nil? || @name.empty?
|
42
|
+
|
43
|
+
# create user directory
|
44
|
+
`sudo mkdir #{user_path} && sudo chmod -R 777 #{user_path}` unless user_path.exist?
|
45
|
+
|
46
|
+
# 路径是否存在
|
47
|
+
target_path = user_path + @name
|
48
|
+
# target_path.rmtree if target_path.exist?
|
49
|
+
help! '目录已存在!!!' if target_path.exist?
|
50
|
+
|
51
|
+
# 移动目录
|
52
|
+
FileUtils.mv(@dir_path, target_path)
|
53
|
+
# 创建软链接
|
54
|
+
FileUtils.ln_s(target_path, op_dir_path)
|
55
|
+
end
|
56
|
+
|
57
|
+
def user_path
|
58
|
+
@user_path ||= Pathname.new('/Users/cocoapods-jxedt/')
|
59
|
+
end
|
60
|
+
end
|
61
|
+
end
|
62
|
+
end
|
63
|
+
end
|
@@ -40,6 +40,30 @@ module Pod
|
|
40
40
|
log_section "🌹 GIT_CACHE_CONFIG"
|
41
41
|
git_config = Jxedt::Config::GIT_CACHE_CONFIG
|
42
42
|
Pod::UI.puts JSON.pretty_generate(git_config)
|
43
|
+
|
44
|
+
log_section "🌹 DSL支持的方法"
|
45
|
+
Pod::UI.puts dsl_support_method
|
46
|
+
|
47
|
+
log_section "🌹 组件支持的DSL配置"
|
48
|
+
Pod::UI.puts arguments_support
|
49
|
+
end
|
50
|
+
|
51
|
+
def dsl_support_method
|
52
|
+
dsl_method = <<DSL_METHOD
|
53
|
+
all_binary! 组件全部使用二进制
|
54
|
+
binary_dir('../_Prebuild') 配置二进制的放置路径
|
55
|
+
binary_switch(true) 二进制开关
|
56
|
+
framework_header_search_enabled! 开启配置依赖的framework头文件配置
|
57
|
+
use_binary_settings(Hash) 使用二进制的组件配置
|
58
|
+
cocoapods_jxedt_config(Hash) 配置插件
|
59
|
+
DSL_METHOD
|
60
|
+
end
|
61
|
+
|
62
|
+
def arguments_support
|
63
|
+
config = <<CONFIG
|
64
|
+
:binary => true 组件是否使用二进制
|
65
|
+
:framework_header_search => true 组件是否需要配置依赖的framework的头文件
|
66
|
+
CONFIG
|
43
67
|
end
|
44
68
|
|
45
69
|
def print_base_options_config
|
@@ -16,7 +16,7 @@ module Jxedt
|
|
16
16
|
output_dir.children.each do |child|
|
17
17
|
next unless child.directory?
|
18
18
|
pod_name = child.basename.to_s
|
19
|
-
next if targets && targets.is_a?(Array) && !(targets.include?(pod_name))
|
19
|
+
next if targets && targets.is_a?(Array) && targets.size > 0 && !(targets.include?(pod_name))
|
20
20
|
|
21
21
|
pod_checksum = child.children.select { |ch| ch.extname == '.checksum' }.first
|
22
22
|
pod_checksum = pod_checksum.basename.sub_ext('').to_s unless pod_checksum.nil?
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cocoapods-jxedt
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.21
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- guojiashuang
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-09-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cocoapods
|
@@ -100,6 +100,7 @@ files:
|
|
100
100
|
- lib/cocoapods-jxedt/command/binary/command/statistics.rb
|
101
101
|
- lib/cocoapods-jxedt/command/header/header.rb
|
102
102
|
- lib/cocoapods-jxedt/command/jxedt.rb
|
103
|
+
- lib/cocoapods-jxedt/command/modify/modify.rb
|
103
104
|
- lib/cocoapods-jxedt/command/options/options.rb
|
104
105
|
- lib/cocoapods-jxedt/command/user/user.rb
|
105
106
|
- lib/cocoapods-jxedt/gem_version.rb
|