blobsterix 0.0.28 → 0.0.29

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
  SHA1:
3
- metadata.gz: 357a34133e4c01a7f32d527d2c4f2a5f0ec76cd2
4
- data.tar.gz: 9bdafb457d14a11db5a986dc327ba506330a7fb6
3
+ metadata.gz: a86be4b6c6a05bb3cb28fe815a063dfc7f716502
4
+ data.tar.gz: ef1dbad154467d89aa9dad092171103c10e1876e
5
5
  SHA512:
6
- metadata.gz: 20448a19acf25b425f329587ba24012a577c06f1b02543d44f22f3527f1e71cb9e7e62058e67d7e4dae80750255a761e9c199a99c4a4d37ffd0c00160862e01e
7
- data.tar.gz: 769cf61e0dc5968d3032a56d1200d56c119baa4701b37c83663df72f418a40a7eb643eda9f9ec1691c6560e67078551293fa1075d41e315e5c210bfcc18d6086
6
+ metadata.gz: e9045c9e592054bc109d4e31e5f8a3fbff6d143fccffa8278f45b6100b3d22f374c57ff2fab8d6879b91d899fb1c38a9c71358faf4880efb8ef94aa1e15535a9
7
+ data.tar.gz: 136631e508da0e93bed9dcf0b9d9ffb06d005e1dd0834fb2c8f43500a429388651428170122a391aa30d3d495e7a6161c0621d788c4049fb59695b3a74d105ac
data/CHANGELOG.txt CHANGED
@@ -1,3 +1,5 @@
1
+ = 0.0.29
2
+ * changed some standard transformations
1
3
  = 0.0.28
2
4
  * added header bucket option for s3 upload, added base64 decode/encode
3
5
  = 0.0.27
@@ -121,17 +121,17 @@ module Blobsterix::Transformations::Impl
121
121
  image.write target_path
122
122
  end
123
123
 
124
- create_simple_trafo("image2HTML", "image/*", "text/html", true) do |input_path, target_path, value|
125
- type = "image/*"
126
- File.open(input_path) {|file|
127
- type = MimeMagic.by_magic(file).type
128
- }
129
-
130
- image = type === "image/webp" ? {:width => "unknown", :height => "unknown"} : MiniMagick::Image.open(input_path)
131
- File.open(target_path, "w") {|file|
132
- file.write("<html><body>Mimetype: #{type}<br>Width: #{image[:width]}<br>Height: #{image[:height]}</body></html>")
133
- }
134
- end
124
+ # create_simple_trafo("image2HTML", "image/*", "text/html", true) do |input_path, target_path, value|
125
+ # type = "image/*"
126
+ # File.open(input_path) {|file|
127
+ # type = MimeMagic.by_magic(file).type
128
+ # }
129
+
130
+ # image = type === "image/webp" ? {:width => "unknown", :height => "unknown"} : MiniMagick::Image.open(input_path)
131
+ # File.open(target_path, "w") {|file|
132
+ # file.write("<html><body>Mimetype: #{type}<br>Width: #{image[:width]}<br>Height: #{image[:height]}</body></html>")
133
+ # }
134
+ # end
135
135
 
136
136
  create_simple_trafo("json", "image/*", "text/json", true) do |input_path, target_path, value|
137
137
  type = "image/*"
@@ -182,7 +182,11 @@ module Blobsterix::Transformations::Impl
182
182
  raise StandardError.new($?) unless system("convert \"#{input_path}\" gif:\"#{target_path}\"")
183
183
  end
184
184
 
185
- create_simple_trafo("webp", "image/*", "image/webp", true) do |input_path, target_path, value|
185
+ create_simple_trafo("webp", "image/png", "image/webp", true) do |input_path, target_path, value|
186
+ raise StandardError.new($?) unless system("cwebp \"#{input_path}\" -o \"#{target_path}\"")
187
+ end
188
+
189
+ create_simple_trafo("webp", "image/jpeg", "image/webp", true) do |input_path, target_path, value|
186
190
  raise StandardError.new($?) unless system("cwebp \"#{input_path}\" -o \"#{target_path}\"")
187
191
  end
188
192
 
@@ -1,3 +1,3 @@
1
1
  module Blobsterix
2
- VERSION = "0.0.28"
2
+ VERSION = "0.0.29"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: blobsterix
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.28
4
+ version: 0.0.29
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Sudmann
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-11-21 00:00:00.000000000 Z
11
+ date: 2014-12-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json