feed_processor_utils 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 +5 -13
- data/lib/feed_processor_utils/feed_post_builder.rb +11 -16
- metadata +11 -25
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
data.tar.gz: !binary |-
|
6
|
-
MTY3NGZjMmRiYzU4MjBmZTc4YzQxNmEwYzcxMWQwMjdmYTg4ZWQyOQ==
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: ca55fd6bb1157c063c6cd5f0a85d746b34905f4a
|
4
|
+
data.tar.gz: 1041a177867cb6ed8de3d8992b5aadb8227d6d99
|
7
5
|
SHA512:
|
8
|
-
metadata.gz:
|
9
|
-
|
10
|
-
MDRlZWM0MTZkY2JiOTU4NGUxYWU2MDEwMzRjZGRhZGFkYTRiNDE2ZjM0NDlj
|
11
|
-
OWU1Y2ZhNmM5YzJhNmEzZWMzYTA3YjI2NDg0MDdlNDU2Njk3MGM=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
N2JiMzUwZWI2YjU3NjU2ZGNkYzM3MjEyZjcwMTAzZmVlZjRhN2IzODhmYjJk
|
14
|
-
MjBhZDA2NGRjOTFiN2I0ZTRmMGRiOGFkOTBjZTRkMWEwMGE2YjVkZjJhNzA1
|
15
|
-
ODRmMWRhOWY2NjNiOTZmYmJlODk5YjcwOTBhYzM1MWU4MzY3NWQ=
|
6
|
+
metadata.gz: ba27d174f9ab95135f423af384024444c36088dd245730f3523bb622fa5f1f05542d382814b65ebd3669dad5f70f873ce3fe9e5e321e19adfd81003e3f0d7ac4
|
7
|
+
data.tar.gz: dc33435a06f1b9977ccb1e20ac72e03a303ccb2e03a4df7066a9bfbd0c9301e2eb0c5b67670618976c1c878db3fed4c5be03905cdc7e7707e915d566ace62773
|
@@ -30,24 +30,19 @@ module FeedProcessorUtils
|
|
30
30
|
end
|
31
31
|
|
32
32
|
def self.get_image_dimensions(uri)
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
return [0,0]
|
33
|
+
begin
|
34
|
+
match = match_based64?(uri)
|
35
|
+
if match
|
36
|
+
base64 = uri.split(",").last
|
37
|
+
img = Magick::Image.read_inline(base64)[0]
|
38
|
+
else
|
39
|
+
img = Magick::Image.read(uri)[0]
|
41
40
|
end
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
NewerImageSize.new(file).size
|
47
|
-
else
|
48
|
-
ImageSize.new(data).get_size
|
41
|
+
|
42
|
+
[img.columns, img.rows]
|
43
|
+
rescue
|
44
|
+
[0,0]
|
49
45
|
end
|
50
|
-
|
51
46
|
end
|
52
47
|
|
53
48
|
def self.dimensions_ok?(dimensions)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: feed_processor_utils
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- FTBpro
|
@@ -14,42 +14,28 @@ dependencies:
|
|
14
14
|
name: nokogiri
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
|
-
name:
|
28
|
+
name: rmagick
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
39
|
-
- !ruby/object:Gem::Version
|
40
|
-
version: '0'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: newer_image_size
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ! '>='
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '0'
|
48
|
-
type: :runtime
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ! '>='
|
38
|
+
- - ">="
|
53
39
|
- !ruby/object:Gem::Version
|
54
40
|
version: '0'
|
55
41
|
description: utility classes to work with feeds
|
@@ -59,10 +45,10 @@ extensions: []
|
|
59
45
|
extra_rdoc_files: []
|
60
46
|
files:
|
61
47
|
- lib/feed_processor_utils.rb
|
48
|
+
- lib/feed_processor_utils/config/feed_post_builder.yml
|
49
|
+
- lib/feed_processor_utils/config/html_parser.yml
|
62
50
|
- lib/feed_processor_utils/feed_post_builder.rb
|
63
51
|
- lib/feed_processor_utils/html_parser.rb
|
64
|
-
- lib/feed_processor_utils/config/html_parser.yml
|
65
|
-
- lib/feed_processor_utils/config/feed_post_builder.yml
|
66
52
|
homepage: http://rubygems.org/gems/feed_processor_utils
|
67
53
|
licenses:
|
68
54
|
- MIT
|
@@ -73,17 +59,17 @@ require_paths:
|
|
73
59
|
- lib
|
74
60
|
required_ruby_version: !ruby/object:Gem::Requirement
|
75
61
|
requirements:
|
76
|
-
- -
|
62
|
+
- - ">="
|
77
63
|
- !ruby/object:Gem::Version
|
78
64
|
version: '0'
|
79
65
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
80
66
|
requirements:
|
81
|
-
- -
|
67
|
+
- - ">="
|
82
68
|
- !ruby/object:Gem::Version
|
83
69
|
version: '0'
|
84
70
|
requirements: []
|
85
71
|
rubyforge_project:
|
86
|
-
rubygems_version: 2.
|
72
|
+
rubygems_version: 2.2.2
|
87
73
|
signing_key:
|
88
74
|
specification_version: 4
|
89
75
|
summary: Feed Processing toolbox
|