axr 0.7.2 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/axr/scanner.rb +10 -3
- data/lib/axr/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1c1451590219c2fdac14e2352ef0a6af39dd388b60cc8caa5c1a86fac06e901a
|
4
|
+
data.tar.gz: 54b6490d145aff76491361d3cfa05c892aeb4ada42f743617ebe0598a0e428bc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 464f7640c98b92353df69f233210d896a7036a9b0e19a723e3b1480743e93bcfd40cd2c79affb4469eb48a1ffaf485984a95b0f8677c2384a77a30cbfac58468
|
7
|
+
data.tar.gz: 878bc7e2300eea09534bae0e33d24e303903a1b7be0479f12207da6e35822cb825460ee595c74a7955e7b507e44094e85357119367c025a92ea4bc7d3c200987
|
data/Gemfile.lock
CHANGED
data/lib/axr/scanner.rb
CHANGED
@@ -21,13 +21,14 @@ module AxR
|
|
21
21
|
|
22
22
|
line_detection = AxR.app.layer_names.detect { |layer| line.include?(layer) }
|
23
23
|
line_detection = check_space_before(line, line_detection)
|
24
|
-
|
24
|
+
line_detection = nil if context && module_definition?(line, line_detection)
|
25
|
+
context_detection = AxR.app.layer_names.detect { |layer| module_definition?(line, layer) }
|
25
26
|
|
26
|
-
next unless
|
27
|
+
next unless context_detection || line_detection
|
27
28
|
|
28
29
|
detect_context(context_detection, line, loc_num) if context_detection && !context
|
29
30
|
detect_dependency(line_detection, line, loc_num)
|
30
|
-
detect_warning(line_detection, line, loc_num) if context
|
31
|
+
detect_warning(line_detection, line, loc_num) if context && line_detection
|
31
32
|
end
|
32
33
|
|
33
34
|
self
|
@@ -66,5 +67,11 @@ module AxR
|
|
66
67
|
|
67
68
|
line_detection if line[line.index(line_detection) - 1] == SPACE
|
68
69
|
end
|
70
|
+
|
71
|
+
MODULE = 'module'
|
72
|
+
|
73
|
+
def module_definition?(line, layer)
|
74
|
+
line.include?("#{MODULE} #{layer}")
|
75
|
+
end
|
69
76
|
end
|
70
77
|
end
|
data/lib/axr/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: axr
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Volodya Sveredyuk
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-08-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colorize
|