yptools 1.0.4 → 1.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '0733003875644967a3c509aba882ca4943103073c7654a4261eeb8f5ba344539'
4
- data.tar.gz: 03205021d0ba02fe41f25c83d2282c6bfdb86b9484da8fabc7d099690f96ab48
3
+ metadata.gz: 0dccb524415e377e39b368189b62ab6ae8df04d7ac2216741dc3af9a5a755cb8
4
+ data.tar.gz: d65bbc47f40f20ecb0045501e89b92fbd09eba62cf1daa88a359679e95d24ff2
5
5
  SHA512:
6
- metadata.gz: 5a96eb5ad7af9f4b9b39cb4ca207bec5f5416ba71fcd81ea8422cbc5a48690f32bdb1d4854af02b1c83699af575a6efc5ca2b89fc13f0656681c172a5a8f077e
7
- data.tar.gz: 4022ddd23fb4a6d523e2bf4fba21ed7be57b6d175dd07206979c266fe53decbdca48e95030db135318a6e1ff9f0a4b6b0359304d1c32f0ecfd50ad392966ae32
6
+ metadata.gz: 3b12b50159cba782f78eec045632bcf53b9e5932dcc0c7e262725c064cb22bc356e9a0e746b09b37debe72fa110c1379001ae8f8c82c1611415de9b11c5ffbc3
7
+ data.tar.gz: f86d85bcb797df249f54980e8804e43e3321cb34890c1e12520731d419584e2947108a5547e0d85ec9b78bd9dd3f895c59512e3c7d8719d42f313e1e47473e8c
@@ -7,8 +7,9 @@ class YPHelp
7
7
 
8
8
  mgc: use [yptools mgc suffix] 在当前目录生成垃圾代码(当前目录需要有.xcworkspace或者.xcodeproj目录)
9
9
 
10
- help: use [yptools help] 查看帮助
10
+ update: use [yptools update] 更新yptools
11
11
 
12
+ help: use [yptools help] 查看帮助
12
13
 
13
14
  }
14
15
  end
@@ -0,0 +1,19 @@
1
+ require 'colored'
2
+ require 'fileutils'
3
+ require_relative '../mgc/yp_makegarbagecode'
4
+ require_relative '../log/yp_log'
5
+
6
+ class YPUpdate
7
+ def self.update
8
+ yp_log_doing '准备更新...'
9
+
10
+ system("gem install colored")
11
+ system("gem install bundler")
12
+ system("gem install rake")
13
+ system("gem install yptools")
14
+
15
+ yp_log_success "更新YPTools完成"
16
+
17
+ end
18
+
19
+ end
data/lib/yptools.rb CHANGED
@@ -2,6 +2,7 @@ require_relative 'yptools/mgc/yp_makegarbagecode'
2
2
  require_relative 'yptools/help/yp_help'
3
3
  require_relative 'yptools/log/yp_log'
4
4
  require_relative 'yptools/install/yp_install'
5
+ require_relative 'yptools/update/yp_update'
5
6
 
6
7
  class YPTools
7
8
 
@@ -26,6 +27,8 @@ class YPTools
26
27
  yp_log_fail "'yptools install ..' 参数缺失"
27
28
  self.help
28
29
  end
30
+ when 'update'
31
+ self.update
29
32
  else
30
33
  self.help
31
34
  end
@@ -44,6 +47,10 @@ class YPTools
44
47
  YPInstall.install(name)
45
48
  end
46
49
 
50
+ def self.update
51
+ YPUpdate.update
52
+ end
53
+
47
54
  end
48
55
 
49
56
  #puts "🚀🚀🚀🚀🚀🚀🚀🚀🚀🚀🚀🚀";
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yptools
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - chenghengsheng
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-08-08 00:00:00.000000000 Z
11
+ date: 2022-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -94,6 +94,7 @@ files:
94
94
  - lib/yptools/install/yp_install.rb
95
95
  - lib/yptools/log/yp_log.rb
96
96
  - lib/yptools/mgc/yp_makegarbagecode.rb
97
+ - lib/yptools/update/yp_update.rb
97
98
  homepage: https://github.com/HansenCCC/YPTools.git
98
99
  licenses:
99
100
  - MIT
@@ -113,7 +114,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
113
114
  - !ruby/object:Gem::Version
114
115
  version: '0'
115
116
  requirements: []
116
- rubygems_version: 3.0.3.1
117
+ rubygems_version: 3.0.9
117
118
  signing_key:
118
119
  specification_version: 4
119
120
  summary: YPTools!