big_resources 0.1.2 → 0.1.3

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: c2262c80b486eea2e0621e56211242574e7ede791061130c74e859b9062cfda8
4
- data.tar.gz: 7811ebcfa9861e7f40a0df71a08f8fb6e4dfb639fa39d75ffa60c34c6ecef561
3
+ metadata.gz: ea493d0b6479e373fedefa09201fc691ee0d7278c5a57b2fd595b18472224102
4
+ data.tar.gz: ac3386fb03737c9e39abe33ebfc884f46bffedd2955851b9f7bbf9342858de09
5
5
  SHA512:
6
- metadata.gz: 5c1a44bb031b0a8d52d87b7afb68adfffab76101be0ac62240175b194e5cd25ef758e2092c7e0959026770ea0dce0fbdf95112923cb07038be240bf18769024b
7
- data.tar.gz: cd091d56bb7f5da32fb85e2d6b188212c6e8d02225420156f688e95575897c10e5d4b070d4875a2547e31c928713e37116c6f7b3742498ef10ad252aae783b56
6
+ metadata.gz: bda5459a54d212d68ee1c96da92f056ff60f482cc92a33b686fc33d4df71c7e496c5d33e7c06657ee85e9d36aeec936e6b55deb56ebe5e8428f3ae6e56a95510
7
+ data.tar.gz: 7279fc456811d3104d6a39ff5de9a6a5765bb7cfb3ebf4335731e1ea92e83863cef25406d69e6f4f2013634029817f7381c2fdf13ae541a9f5fa7df5b282f6c4
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- big_resources (0.1.1)
4
+ big_resources (0.1.3)
5
5
  chunky_png
6
6
  cocoapods
7
7
  colorize
@@ -12,67 +12,67 @@ GEM
12
12
  remote: https://rubygems.org/
13
13
  specs:
14
14
  CFPropertyList (3.0.0)
15
- activesupport (4.2.10)
15
+ activesupport (4.2.11.1)
16
16
  i18n (~> 0.7)
17
17
  minitest (~> 5.1)
18
18
  thread_safe (~> 0.3, >= 0.3.4)
19
19
  tzinfo (~> 1.1)
20
20
  ast (2.4.0)
21
- atomos (0.1.2)
22
- chunky_png (1.3.10)
21
+ atomos (0.1.3)
22
+ chunky_png (1.3.11)
23
23
  claide (1.0.2)
24
- cocoapods (1.5.3)
24
+ cocoapods (1.7.3)
25
25
  activesupport (>= 4.0.2, < 5)
26
26
  claide (>= 1.0.2, < 2.0)
27
- cocoapods-core (= 1.5.3)
28
- cocoapods-deintegrate (>= 1.0.2, < 2.0)
29
- cocoapods-downloader (>= 1.2.0, < 2.0)
27
+ cocoapods-core (= 1.7.3)
28
+ cocoapods-deintegrate (>= 1.0.3, < 2.0)
29
+ cocoapods-downloader (>= 1.2.2, < 2.0)
30
30
  cocoapods-plugins (>= 1.0.0, < 2.0)
31
31
  cocoapods-search (>= 1.0.0, < 2.0)
32
32
  cocoapods-stats (>= 1.0.0, < 2.0)
33
- cocoapods-trunk (>= 1.3.0, < 2.0)
33
+ cocoapods-trunk (>= 1.3.1, < 2.0)
34
34
  cocoapods-try (>= 1.1.0, < 2.0)
35
35
  colored2 (~> 3.1)
36
36
  escape (~> 0.0.4)
37
- fourflusher (~> 2.0.1)
37
+ fourflusher (>= 2.3.0, < 3.0)
38
38
  gh_inspector (~> 1.0)
39
- molinillo (~> 0.6.5)
39
+ molinillo (~> 0.6.6)
40
40
  nap (~> 1.0)
41
- ruby-macho (~> 1.1)
42
- xcodeproj (>= 1.5.7, < 2.0)
43
- cocoapods-core (1.5.3)
41
+ ruby-macho (~> 1.4)
42
+ xcodeproj (>= 1.10.0, < 2.0)
43
+ cocoapods-core (1.7.3)
44
44
  activesupport (>= 4.0.2, < 6)
45
45
  fuzzy_match (~> 2.0.4)
46
46
  nap (~> 1.0)
47
- cocoapods-deintegrate (1.0.2)
48
- cocoapods-downloader (1.2.1)
47
+ cocoapods-deintegrate (1.0.4)
48
+ cocoapods-downloader (1.2.2)
49
49
  cocoapods-plugins (1.0.0)
50
50
  nap
51
51
  cocoapods-search (1.0.0)
52
- cocoapods-stats (1.0.0)
53
- cocoapods-trunk (1.3.0)
52
+ cocoapods-stats (1.1.0)
53
+ cocoapods-trunk (1.3.1)
54
54
  nap (>= 0.8, < 2.0)
55
55
  netrc (~> 0.11)
56
56
  cocoapods-try (1.1.0)
57
57
  colored2 (3.1.2)
58
58
  colorize (0.8.1)
59
- concurrent-ruby (1.0.5)
59
+ concurrent-ruby (1.1.5)
60
60
  escape (0.0.4)
61
- fourflusher (2.0.1)
61
+ fourflusher (2.3.1)
62
62
  fuzzy_match (2.0.4)
63
63
  gh_inspector (1.1.3)
64
- gli (2.17.1)
64
+ gli (2.18.1)
65
65
  i18n (0.9.5)
66
66
  concurrent-ruby (~> 1.0)
67
67
  minitest (5.11.3)
68
- molinillo (0.6.5)
68
+ molinillo (0.6.6)
69
69
  nanaimo (0.2.6)
70
70
  nap (1.1.0)
71
71
  netrc (0.11.0)
72
- parallel (1.12.1)
73
- parser (2.5.1.2)
72
+ parallel (1.17.0)
73
+ parser (2.6.3.0)
74
74
  ast (~> 2.4.0)
75
- plist (3.4.0)
75
+ plist (3.5.0)
76
76
  powerpack (0.1.2)
77
77
  rainbow (2.2.2)
78
78
  rake
@@ -84,25 +84,25 @@ GEM
84
84
  rainbow (>= 2.2.2, < 3.0)
85
85
  ruby-progressbar (~> 1.7)
86
86
  unicode-display_width (~> 1.0, >= 1.0.1)
87
- ruby-macho (1.2.0)
88
- ruby-progressbar (1.9.0)
87
+ ruby-macho (1.4.0)
88
+ ruby-progressbar (1.10.1)
89
89
  thread_safe (0.3.6)
90
90
  tzinfo (1.2.5)
91
91
  thread_safe (~> 0.1)
92
- unicode-display_width (1.4.0)
93
- xcodeproj (1.5.9)
92
+ unicode-display_width (1.6.0)
93
+ xcodeproj (1.10.0)
94
94
  CFPropertyList (>= 2.3.3, < 4.0)
95
- atomos (~> 0.1.2)
95
+ atomos (~> 0.1.3)
96
96
  claide (>= 1.0.2, < 2.0)
97
97
  colored2 (~> 3.1)
98
- nanaimo (~> 0.2.5)
98
+ nanaimo (~> 0.2.6)
99
99
 
100
100
  PLATFORMS
101
101
  ruby
102
102
 
103
103
  DEPENDENCIES
104
104
  big_resources!
105
- bundler (~> 1.16)
105
+ bundler
106
106
  chunky_png
107
107
  cocoapods
108
108
  colorize
@@ -112,4 +112,4 @@ DEPENDENCIES
112
112
  rubocop (~> 0.50.0)
113
113
 
114
114
  BUNDLED WITH
115
- 1.16.4
115
+ 1.17.2
Binary file
@@ -36,7 +36,7 @@ Gem::Specification.new do |spec|
36
36
  spec.add_runtime_dependency "colorize"
37
37
  spec.add_runtime_dependency "chunky_png"
38
38
 
39
- spec.add_development_dependency "bundler", "~> 1.16"
39
+ spec.add_development_dependency "bundler"
40
40
  spec.add_development_dependency "rake", "~> 10.0"
41
41
  spec.add_development_dependency "gli", "~> 2.16"
42
42
  spec.add_development_dependency "cocoapods"
@@ -47,11 +47,11 @@ module BigResources
47
47
  if dic["contents"] == nil
48
48
  if dic["name"] != nil && dic["name"].include?(file_type)
49
49
  file_size = File.size(current_path)
50
- if file_size && result_dic["#{file_size} kb"] == nil
51
- result_dic["#{file_size} kb"] = {:count => 1, :path => [current_path]}
50
+ if file_size && result_dic["#{file_size} b"] == nil
51
+ result_dic["#{file_size} b"] = {:count => 1, :path => [current_path]}
52
52
  else
53
- result_dic["#{file_size} kb"][:count] += 1
54
- result_dic["#{file_size} kb"][:path] << current_path
53
+ result_dic["#{file_size} b"][:count] += 1
54
+ result_dic["#{file_size} b"][:path] << current_path
55
55
  end
56
56
  end
57
57
 
@@ -85,8 +85,11 @@ module BigResources
85
85
  #根据字节大小相等 分出相同数据
86
86
  def self.get_same_file(dic)
87
87
  duplicate = []
88
+ result = []
89
+ #按字节筛选
88
90
  dic.keys.select do | file_size |
89
91
  patterns = []
92
+ #多个文件预筛选
90
93
  if dic[file_size][:count] > 1
91
94
  dic[file_size][:path].each do | file_path |
92
95
  if patterns.count == 0
@@ -95,6 +98,7 @@ module BigResources
95
98
  end
96
99
 
97
100
  is_same = false
101
+ #和之前分类的图案进行对比
98
102
  patterns.each do | a_pattern |
99
103
  is_same = DifferAnalyzeUtil.image_diff_analyze(file_path,a_pattern.first)
100
104
  if is_same
@@ -105,13 +109,17 @@ module BigResources
105
109
  patterns << [file_path] unless is_same
106
110
  end
107
111
  end
108
- duplicate << {:file_size => file_size,
109
- :count => dic[file_size][:count],
110
- :path => dic[file_size][:path],
111
- :pattern => patterns
112
- }
112
+ is_need_output = false;
113
+ patterns.each do | a_pattern |
114
+ if a_pattern.count > 1
115
+ result << {:file_size => file_size,
116
+ :count => a_pattern.count,
117
+ :path => a_pattern,
118
+ }
119
+ end
120
+ end
113
121
  end
114
- duplicate
122
+ result
115
123
  end
116
124
 
117
125
  def self.get_current_path(last_path,file_name)
@@ -1,3 +1,3 @@
1
1
  module BigResources
2
- VERSION = "0.1.2"
2
+ VERSION = "0.1.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: big_resources
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Serena_R
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-25 00:00:00.000000000 Z
11
+ date: 2019-07-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gli
@@ -84,16 +84,16 @@ dependencies:
84
84
  name: bundler
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - "~>"
87
+ - - ">="
88
88
  - !ruby/object:Gem::Version
89
- version: '1.16'
89
+ version: '0'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - "~>"
94
+ - - ">="
95
95
  - !ruby/object:Gem::Version
96
- version: '1.16'
96
+ version: '0'
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: rake
99
99
  requirement: !ruby/object:Gem::Requirement
@@ -207,6 +207,7 @@ files:
207
207
  - LICENSE.txt
208
208
  - README.md
209
209
  - Rakefile
210
+ - big_resources-0.1.2.gem
210
211
  - big_resources.gemspec
211
212
  - bin/big_resources
212
213
  - bin/setup
@@ -219,6 +220,7 @@ files:
219
220
  - lib/big_resources/util/image/file_scan_util.rb
220
221
  - lib/big_resources/util/image/name_analyze_util.rb
221
222
  - lib/big_resources/version.rb
223
+ - pkg/big_resources-0.1.3.gem
222
224
  homepage: https://github.com/BigKeeper/bigResources
223
225
  licenses:
224
226
  - MIT