podfileDep 2.0.0 → 2.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -1
- data/lib/cocoapods_plugin.rb +7 -3
- data/lib/podfileDep/indirect/indirect.rb +37 -0
- data/lib/podfileDep/version.rb +1 -1
- data/lib/podfileDep.rb +3 -2
- data/podfileDep.gemspec +4 -4
- metadata +8 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 31ed880f0e6108b180135bac80ed10c8ebeb2fc1957c1cfb63427de66fd5cab5
|
4
|
+
data.tar.gz: deec07c419b895a77ce4a0a40a81cb9c7abc9baa2270d8dc1cd453a1f9f5e8cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c0855321340787feefabfc1a3308d2a249d7f558038b966ee0fb8f8529f79c01efbb89066680a55c4de941c886dd9d164e4064f7eede9aa2266140ed2361607d
|
7
|
+
data.tar.gz: b423ce91ec6fa2f982b7b993478453cba175b0932a0fecb98fd32c6f1dbf39f0dada8ee2152c044cb1c7c9650c1347248c46a2acb50ad52828c9c9c3f28ddcb2
|
data/CHANGELOG.md
CHANGED
data/lib/cocoapods_plugin.rb
CHANGED
@@ -4,15 +4,16 @@ require_relative 'podfileDep/check/import'
|
|
4
4
|
require_relative 'podfileDep/modify/modify_code'
|
5
5
|
require_relative 'podfileDep/reference/unused'
|
6
6
|
require_relative 'podfileDep/reference/project'
|
7
|
+
require_relative 'podfileDep/indirect/indirect'
|
7
8
|
|
8
9
|
# 注册插件
|
9
10
|
module CocoapodsPlugin
|
10
|
-
# Pod::HooksManager.register('
|
11
|
+
# Pod::HooksManager.register('podfileDep', :source_provider) do |context|
|
11
12
|
# puts "hook source_provider"
|
12
13
|
# puts context
|
13
14
|
# end
|
14
15
|
#
|
15
|
-
# Pod::HooksManager.register('
|
16
|
+
# Pod::HooksManager.register('podfileDep', :pre_install) do |context|
|
16
17
|
# puts "hook pre_install"
|
17
18
|
# puts context
|
18
19
|
# end
|
@@ -27,6 +28,9 @@ module CocoapodsPlugin
|
|
27
28
|
# 代码文件处理
|
28
29
|
ModifyCode::Modify.modify_fb
|
29
30
|
|
31
|
+
# 间接依赖
|
32
|
+
PodfileLock::Indirect.new.log_indirect
|
33
|
+
|
30
34
|
# 未被使用的依赖库
|
31
35
|
Unused::UnusedManager.check_unused
|
32
36
|
|
@@ -34,7 +38,7 @@ module CocoapodsPlugin
|
|
34
38
|
Project::ProjectManager.yaml_deal
|
35
39
|
end
|
36
40
|
|
37
|
-
# Pod::HooksManager.register('
|
41
|
+
# Pod::HooksManager.register('podfileDep', :post_integrate) do |context|
|
38
42
|
# puts context
|
39
43
|
# end
|
40
44
|
end
|
@@ -0,0 +1,37 @@
|
|
1
|
+
require_relative '../podfilelock'
|
2
|
+
|
3
|
+
module PodfileLock
|
4
|
+
class Indirect
|
5
|
+
def log_indirect
|
6
|
+
|
7
|
+
# 内容读取
|
8
|
+
dependencies_lock = PodfileLock::PodfileLockManager.podfile_lock_content
|
9
|
+
|
10
|
+
dependencies = dependencies_lock['DEPENDENCIES']
|
11
|
+
unless dependencies
|
12
|
+
return
|
13
|
+
end
|
14
|
+
|
15
|
+
check_sums = dependencies_lock['SPEC CHECKSUMS']
|
16
|
+
unless check_sums
|
17
|
+
return
|
18
|
+
end
|
19
|
+
|
20
|
+
# 数组处理
|
21
|
+
check_values = dependencies.collect! {|item|
|
22
|
+
item.split(' (')[0]
|
23
|
+
}
|
24
|
+
check_values = dependencies.collect! {|item|
|
25
|
+
item.split('/')[0]
|
26
|
+
}
|
27
|
+
|
28
|
+
puts ''
|
29
|
+
check_sums.each{ |array|
|
30
|
+
be_check_value = array[0]
|
31
|
+
unless check_values.include?(be_check_value)
|
32
|
+
puts '↪️ 间接依赖: '+ be_check_value
|
33
|
+
end
|
34
|
+
}
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
data/lib/podfileDep/version.rb
CHANGED
data/lib/podfileDep.rb
CHANGED
@@ -18,8 +18,9 @@ end
|
|
18
18
|
# 兼容旧的方式
|
19
19
|
module PodfileDep
|
20
20
|
def PodfileDep.setup(targets)
|
21
|
-
|
22
|
-
|
21
|
+
res = Pod::YamlRelies.analysis_yaml(nil, true)
|
22
|
+
warn "\n⚠️ [PodfileDep.setup方法已过期],请使用新的方式, 参考:https://gitee.com/sourceiOS/podfileDepDemo/blob/master/Podfile\n"
|
23
|
+
res
|
23
24
|
end
|
24
25
|
|
25
26
|
end
|
data/podfileDep.gemspec
CHANGED
@@ -5,12 +5,12 @@ require_relative "lib/podfileDep/version"
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = "podfileDep"
|
7
7
|
spec.version = PodfileDep::VERSION
|
8
|
-
spec.authors = ["
|
8
|
+
spec.authors = ["王帅朋"]
|
9
9
|
spec.email = ["wsp810@163.com"]
|
10
10
|
|
11
|
-
spec.summary = "
|
12
|
-
spec.description = "iOS
|
13
|
-
spec.homepage = "https://gitee.com/sourceiOS/
|
11
|
+
spec.summary = "iOS端 依赖库使用yaml文件管理"
|
12
|
+
spec.description = "iOS端 依赖库使用yaml文件管理,并提供其他扩展功能"
|
13
|
+
spec.homepage = "https://gitee.com/sourceiOS/podfileDepDemo"
|
14
14
|
spec.required_ruby_version = ">= 2.6.0"
|
15
15
|
|
16
16
|
# spec.metadata["allowed_push_host"] = "TODO: Set to your gem server 'https://example.com'"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: podfileDep
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
-
-
|
7
|
+
- 王帅朋
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-06-
|
11
|
+
date: 2023-06-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cocoapods
|
@@ -38,7 +38,7 @@ dependencies:
|
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
-
description: iOS
|
41
|
+
description: iOS端 依赖库使用yaml文件管理,并提供其他扩展功能
|
42
42
|
email:
|
43
43
|
- wsp810@163.com
|
44
44
|
executables: []
|
@@ -59,6 +59,7 @@ files:
|
|
59
59
|
- lib/podfileDep/check/module.rb
|
60
60
|
- lib/podfileDep/check/xcodeproj.rb
|
61
61
|
- lib/podfileDep/constants.rb
|
62
|
+
- lib/podfileDep/indirect/indirect.rb
|
62
63
|
- lib/podfileDep/modify/modify_code.rb
|
63
64
|
- lib/podfileDep/podfilelock.rb
|
64
65
|
- lib/podfileDep/reference/project.rb
|
@@ -67,10 +68,10 @@ files:
|
|
67
68
|
- lib/podfileDep/yaml/yaml_dep.rb
|
68
69
|
- podfileDep.gemspec
|
69
70
|
- release.sh
|
70
|
-
homepage: https://gitee.com/sourceiOS/
|
71
|
+
homepage: https://gitee.com/sourceiOS/podfileDepDemo
|
71
72
|
licenses: []
|
72
73
|
metadata:
|
73
|
-
homepage_uri: https://gitee.com/sourceiOS/
|
74
|
+
homepage_uri: https://gitee.com/sourceiOS/podfileDepDemo
|
74
75
|
source_code_uri: https://gitee.com/sourceiOS/podfileDep
|
75
76
|
changelog_uri: https://gitee.com/sourceiOS/podfileDep
|
76
77
|
post_install_message:
|
@@ -91,5 +92,5 @@ requirements: []
|
|
91
92
|
rubygems_version: 3.4.6
|
92
93
|
signing_key:
|
93
94
|
specification_version: 4
|
94
|
-
summary:
|
95
|
+
summary: iOS端 依赖库使用yaml文件管理
|
95
96
|
test_files: []
|