cyborg 0.5.17 → 0.5.18
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/cyborg.gemspec +1 -1
- data/lib/cyborg/plugin/assets/svgs.rb +10 -6
- data/lib/cyborg/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 60a1134fc18d219fdafcf49b874374b6738bb045
|
4
|
+
data.tar.gz: 3e69ba9f4668e26019a6f34ce72e026f608ba90b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af30ab530c5bfca37bb755d71c5df79075f5c87e35f71f88110ec4686f77c028e725c87de8740cc7a9b8c4fd63371f730cb63c9663ce29c42c13f09af5d6d6ed
|
7
|
+
data.tar.gz: 775bb1cc42a5a3b9fcf72e234aaf871ea67c956195bdd9fd1e37e8ee57b1629e81eadb5bbf0832b977d09e4ec4511172c64a17920ab863980b2033b7cd8e1d5d
|
data/cyborg.gemspec
CHANGED
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
|
|
19
19
|
spec.require_paths = ['lib']
|
20
20
|
|
21
21
|
spec.add_runtime_dependency 'sass', '~> 3.4'
|
22
|
-
spec.add_runtime_dependency 'esvg', '~>
|
22
|
+
spec.add_runtime_dependency 'esvg', '~> 3.0'
|
23
23
|
spec.add_runtime_dependency 'listen', '~> 3.0.0'
|
24
24
|
spec.add_runtime_dependency 'block_helpers', '~> 0.3'
|
25
25
|
spec.add_runtime_dependency 'colorize', '~> 0.8'
|
@@ -7,15 +7,14 @@ module Cyborg
|
|
7
7
|
@plugin = plugin
|
8
8
|
@base = path
|
9
9
|
|
10
|
-
return if find_files.empty?
|
11
|
-
|
12
10
|
@svg = Esvg.new({
|
13
11
|
config_file: File.join(plugin.root, 'config', 'esvg.yml'),
|
14
12
|
path: path,
|
15
13
|
tmp_path: Cyborg.rails_path('tmp/cache/assets'),
|
16
|
-
js_path: File.join(plugin.paths[:javascripts], '
|
14
|
+
js_path: File.join(plugin.paths[:javascripts], '_icons.js'),
|
17
15
|
optimize: true
|
18
16
|
})
|
17
|
+
|
19
18
|
end
|
20
19
|
|
21
20
|
def icons
|
@@ -26,14 +25,19 @@ module Cyborg
|
|
26
25
|
"svg"
|
27
26
|
end
|
28
27
|
|
28
|
+
def local_path(path)
|
29
|
+
File.expand_path(path).sub(plugin.paths[:javascripts], '').sub(/^\//,'')
|
30
|
+
end
|
31
|
+
|
29
32
|
def build
|
30
|
-
return if find_files.empty?
|
31
33
|
|
32
34
|
begin
|
33
35
|
@svg.read_files
|
34
36
|
|
35
|
-
if
|
36
|
-
|
37
|
+
return if @svg.files.empty?
|
38
|
+
|
39
|
+
if files = @svg.write
|
40
|
+
files.each { |file| puts build_success(file) }
|
37
41
|
else
|
38
42
|
log_error "FAILED TO BUILD SVGs"
|
39
43
|
end
|
data/lib/cyborg/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cyborg
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.18
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brandon Mathis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-03
|
11
|
+
date: 2017-05-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sass
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
33
|
+
version: '3.0'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
40
|
+
version: '3.0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: listen
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|