cocoapods-wxpodhook 0.0.2 → 0.0.6
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-wxpodhook/gem_version.rb +1 -1
- data/lib/cocoapods-wxpodhook/helper.rb +28 -8
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e282333a2483c9053386602c2c8ad988b5753e804fd492e2e38f96a2643a46a2
|
4
|
+
data.tar.gz: 2cbe6a06d730a05ed3eda11009c8bb234df33770571f7a11965a0e8d069f1e6d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d99607c2c7fdf58dbd72d933be56a2d2fca0859aec2f9451a059b7cd91d7eaff882b337e059cec2334dcab3af1b7dfcb4a59158dab362362e3d89962eae7e788
|
7
|
+
data.tar.gz: 2565c1e4ef329a812865f2e8e94cc1ecc42cb7febb48a19dad8326cd60500455e7b9ba02dc2037284ef23d5e5796ac174e7d839cd5673e7caa467e2229ada3ab
|
@@ -15,14 +15,14 @@ module CocoapodsWxpodhook
|
|
15
15
|
|
16
16
|
before = Time.new();
|
17
17
|
|
18
|
-
put_redMsg("
|
18
|
+
put_redMsg("开始自动更新网校自有的repo仓库")
|
19
19
|
|
20
20
|
cocoapods_repo_path = File.join(ENV["HOME"], ".cocoapods/repos")
|
21
21
|
|
22
22
|
# 拿到待更新的repo名称
|
23
23
|
repo_names = Dir.children(cocoapods_repo_path)
|
24
24
|
repo_names.each do |repo_name|
|
25
|
-
if repo_name.include?("100tal-")
|
25
|
+
if repo_name.include?("100tal-") || repo_name.include?("TAL")
|
26
26
|
puts repo_name
|
27
27
|
`pod repo update #{repo_name}`
|
28
28
|
end
|
@@ -37,15 +37,30 @@ module CocoapodsWxpodhook
|
|
37
37
|
end
|
38
38
|
end
|
39
39
|
|
40
|
+
# 获取插件版本号
|
41
|
+
module Pod
|
42
|
+
class Command
|
43
|
+
|
44
|
+
class WxhookVersion < Command
|
45
|
+
def run
|
46
|
+
puts "当前版本 #{CocoapodsWxpodhook::VERSION}"
|
47
|
+
end
|
48
|
+
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
40
53
|
|
41
54
|
#一键更新除官方和阿里云的Repo仓库
|
42
55
|
module Pod
|
43
56
|
class Command
|
44
57
|
class UpdateAllrepo < Command
|
45
58
|
self.summary = <<-SUMMARY
|
59
|
+
一键更新网校自有的repo仓库
|
46
60
|
SUMMARY
|
47
61
|
|
48
62
|
self.description = <<-DESC
|
63
|
+
一键更新网校自有的repo仓库
|
49
64
|
DESC
|
50
65
|
|
51
66
|
self.arguments = []
|
@@ -82,7 +97,6 @@ module Pod
|
|
82
97
|
splitedStr = repoversion.delete(curversion)
|
83
98
|
splitedStrArr = splitedStr.split(".")
|
84
99
|
sum = 0
|
85
|
-
puts "abcdefg #{splitedStrArr}"
|
86
100
|
splitedStrArr.each do |item|
|
87
101
|
sum += item.to_i
|
88
102
|
end
|
@@ -141,7 +155,7 @@ module Pod
|
|
141
155
|
before = Time.new
|
142
156
|
|
143
157
|
# 先更新repo
|
144
|
-
|
158
|
+
CocoapodsWxpodhook::Helper.new().AutoUpdateRepo();
|
145
159
|
|
146
160
|
# 先拿到当前脚本执行的文件路径
|
147
161
|
currentFilePath = Dir.pwd
|
@@ -159,8 +173,14 @@ module Pod
|
|
159
173
|
put_redMsg("组件是否需要更新比对中")
|
160
174
|
|
161
175
|
# 先执行pod outdated
|
162
|
-
|
163
|
-
|
176
|
+
success = system("pod outdated --no-repo-update > #{prepareUpdateComponentsPath}")
|
177
|
+
if !success
|
178
|
+
put_redMsg("pod outdated失败")
|
179
|
+
textAll = File.read(prepareUpdateComponentsPath)
|
180
|
+
put_redMsg(textAll)
|
181
|
+
return
|
182
|
+
end
|
183
|
+
|
164
184
|
# 解析txt文件,拿到待更新的组件数组
|
165
185
|
componentArr = self.getPrepareUpdateComponents(prepareUpdateComponentsPath)
|
166
186
|
|
@@ -176,7 +196,7 @@ module Pod
|
|
176
196
|
put_redMsg("开始更新组件 \n #{prepareUpdateComponentStr}")
|
177
197
|
|
178
198
|
# 执行pod update
|
179
|
-
|
199
|
+
system("pod update #{prepareUpdateComponentStr} --no-repo-update")
|
180
200
|
|
181
201
|
now = Time.new();
|
182
202
|
|
@@ -187,4 +207,4 @@ module Pod
|
|
187
207
|
end
|
188
208
|
end
|
189
209
|
end
|
190
|
-
end
|
210
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cocoapods-wxpodhook
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- leev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-09-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|