rails_real_favicon 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/generators/favicon_generator.rb +2 -2
- data/lib/rails_real_favicon/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0a064c0d3848a4a00324f86b128bb4d2d22556af
|
4
|
+
data.tar.gz: b3b4358b115abb5c9ea95e1f120ca2cb1909d7b8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8f6911038e24d3abcf0ec717857c41036e5c97f67734b535d2ea31bcc15f0289e1be12b47228c392805fa0168b96a07948d04d165aa160e77e279a2e0abc4f5c
|
7
|
+
data.tar.gz: d0473c17705676986a5e4bdf36129a580e7212fb755275bfde11eb96bef82fb19ca668d1f02bc3ffe385a49a724258ad411ac84206e9ca254a605c4b97f7bd98
|
@@ -21,7 +21,7 @@ class FaviconGenerator < Rails::Generators::Base
|
|
21
21
|
master_pic = File.expand_path(".") + '/' + req['master_picture']
|
22
22
|
req['master_picture'] = Hash.new
|
23
23
|
req['master_picture']['type'] = 'inline'
|
24
|
-
req['master_picture']['content'] = Base64.encode64(File.
|
24
|
+
req['master_picture']['content'] = Base64.encode64(File.binread(master_pic))
|
25
25
|
|
26
26
|
response = RestClient.post("https://realfavicongenerator.net/api/favicon",
|
27
27
|
{favicon_generation: req}.to_json, content_type: :json)
|
@@ -33,7 +33,7 @@ class FaviconGenerator < Rails::Generators::Base
|
|
33
33
|
Dir.mktmpdir 'rfg' do |tmp_dir|
|
34
34
|
download_package zip, tmp_dir
|
35
35
|
Dir["#{tmp_dir}/*.*"].each do |file|
|
36
|
-
content = File.
|
36
|
+
content = File.binread(file)
|
37
37
|
new_ext = ''
|
38
38
|
if File.extname(file) == '.json' or File.extname(file) == '.xml'
|
39
39
|
content = replace_url_by_asset_path content
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails_real_favicon
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Philippe Bernard
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-12-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|