rails-erb-lint 1.2.1 → 1.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/lib/rails-erb-lint/helpers/rails_erb_check.rb +3 -3
- data/lib/rails-erb-lint/version.rb +1 -1
- metadata +13 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 45bfc62461cb0028f2e1782608ce6e33e21e9fba9a721626c604ea8a41b91a4a
|
4
|
+
data.tar.gz: f69f99be1f40ad6f34531300f23f2be7a6b98e410e151cba43c7e64e1a7ce154
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b22a3ae6f298a6ef1bc065f8a877e51f86729e432567f80fc4be075a6db1578decd88f86ece6ac19542c337a67203570ec3dde9f26926103d3fdefefacfbab03
|
7
|
+
data.tar.gz: be4e649576e779ecb8ad566c933f646b2432889e48a560226c9be467433608be06503f1abffdb7bbf5c9a57f5090625751c000b4e312d4db087c2924fd5247c3
|
@@ -4,9 +4,9 @@ module RailsErbCheck
|
|
4
4
|
class Checker
|
5
5
|
CHECKER =
|
6
6
|
if defined?(ActionView::Template::Handlers::ERB::Erubi)
|
7
|
-
ActionView::Template::Handlers::ERB::Erubi
|
7
|
+
->(erb) { eval ActionView::Template::Handlers::ERB::Erubi.new(erb).src }
|
8
8
|
else
|
9
|
-
ActionView::Template::Handlers::Erubis
|
9
|
+
->(erb) { ActionView::Template::Handlers::Erubis.new(erb).result }
|
10
10
|
end
|
11
11
|
|
12
12
|
attr_reader :error
|
@@ -17,7 +17,7 @@ module RailsErbCheck
|
|
17
17
|
|
18
18
|
def valid_syntax?
|
19
19
|
begin
|
20
|
-
CHECKER.
|
20
|
+
CHECKER.call(@erb)
|
21
21
|
rescue SyntaxError => e
|
22
22
|
@error = e
|
23
23
|
return false
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails-erb-lint
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Katherine Pe
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-03-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -42,16 +42,22 @@ dependencies:
|
|
42
42
|
name: rainbow
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 2.2.2
|
48
|
+
- - "<"
|
49
|
+
- !ruby/object:Gem::Version
|
50
|
+
version: '4.0'
|
48
51
|
type: :runtime
|
49
52
|
prerelease: false
|
50
53
|
version_requirements: !ruby/object:Gem::Requirement
|
51
54
|
requirements:
|
52
|
-
- - "
|
55
|
+
- - ">="
|
53
56
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
57
|
+
version: 2.2.2
|
58
|
+
- - "<"
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
version: '4.0'
|
55
61
|
- !ruby/object:Gem::Dependency
|
56
62
|
name: actionpack
|
57
63
|
requirement: !ruby/object:Gem::Requirement
|
@@ -141,7 +147,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
141
147
|
version: '0'
|
142
148
|
requirements: []
|
143
149
|
rubyforge_project:
|
144
|
-
rubygems_version: 2.
|
150
|
+
rubygems_version: 2.7.3
|
145
151
|
signing_key:
|
146
152
|
specification_version: 4
|
147
153
|
summary: Checks validity of ERB files for your Rails app.
|