rails_best_practices 1.21.0 → 1.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e268c4837f5a1da4ac684c78bef59cd06ce20c69cc41ea9478391242897c5d4b
4
- data.tar.gz: 3bfc141a02bfcb95f40f938be6d101ab3e0aed55518eb8c42d2a6c5b2effd246
3
+ metadata.gz: 349689325c6d2ac9c0f96f076153f1cceeb93586ff23d9ce2ac3a083befcc9dc
4
+ data.tar.gz: 88f23404986309df3287a5b7c7963374e7faea592b1ce48c100ba9225497c5c5
5
5
  SHA512:
6
- metadata.gz: f3c124054e218a06478ef27973a2fc6aed24eb4bc45fac4eebd3274b61a1fea9650c8d9bd366a06657714d22c5905ba00315a75f787556eab5a6527ad947011b
7
- data.tar.gz: 4e0f3e83007b69bbba800ff378caf08adf5e87d8fd8e5d913c55ef35052775697f72c7c038cebaf417f13a29cdf654b2ce25effe570ae5e6fabf6988b4735401
6
+ metadata.gz: 0e9b9b059759295ffb811c75a4a00c4a76dcf7fac01345590fd3ea7862a717535fc0faad8b1aaf0996c6e2cf86439222292649261667cb0625cab38548364700
7
+ data.tar.gz: 82856757223d3f764ba672b4d443c350c0ecd7f54bfe7e45fb1cd5714316077e6b8ac9c4a74a227a399a7645695bd0f51c7d68d787d1330fc86d9ddfe3dae8a2
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Next Release
2
2
 
3
+ ## 1.22.0 (2021-10-27)
4
+
5
+ * Support atom editor
6
+
3
7
  ## 1.21.0 (2021-06-15)
4
8
 
5
9
  * Disable check by inline comment
data/Gemfile CHANGED
@@ -8,4 +8,3 @@ gem 'coveralls', require: false
8
8
  gem 'guard'
9
9
  gem 'guard-rspec'
10
10
  gem 'pry'
11
- gem 'rspec'
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- rails_best_practices (1.21.0)
4
+ rails_best_practices (1.22.0)
5
5
  activesupport
6
6
  code_analyzer (>= 0.5.2)
7
7
  erubis
@@ -13,7 +13,7 @@ PATH
13
13
  GEM
14
14
  remote: https://rubygems.org/
15
15
  specs:
16
- activesupport (6.1.3.2)
16
+ activesupport (6.1.4.1)
17
17
  concurrent-ruby (~> 1.0, >= 1.0.2)
18
18
  i18n (>= 1.6, < 2)
19
19
  minitest (>= 5.1)
@@ -22,70 +22,72 @@ GEM
22
22
  awesome_print (1.8.0)
23
23
  code_analyzer (0.5.2)
24
24
  sexp_processor
25
- coderay (1.1.2)
26
- concurrent-ruby (1.1.8)
25
+ coderay (1.1.3)
26
+ concurrent-ruby (1.1.9)
27
27
  coveralls (0.8.23)
28
28
  json (>= 1.8, < 3)
29
29
  simplecov (~> 0.16.1)
30
30
  term-ansicolor (~> 1.3)
31
31
  thor (>= 0.19.4, < 2.0)
32
32
  tins (~> 1.6)
33
- diff-lcs (1.3)
33
+ diff-lcs (1.4.4)
34
34
  docile (1.3.2)
35
35
  erubis (2.7.0)
36
- ffi (1.11.3)
37
- formatador (0.2.5)
38
- guard (2.16.1)
36
+ ffi (1.15.4)
37
+ formatador (0.3.0)
38
+ guard (2.18.0)
39
39
  formatador (>= 0.2.4)
40
40
  listen (>= 2.7, < 4.0)
41
41
  lumberjack (>= 1.0.12, < 2.0)
42
42
  nenv (~> 0.1)
43
43
  notiffany (~> 0.0)
44
- pry (>= 0.9.12)
44
+ pry (>= 0.13.0)
45
45
  shellany (~> 0.0)
46
46
  thor (>= 0.18.1)
47
- guard-rspec (4.3.1)
47
+ guard-compat (1.2.1)
48
+ guard-rspec (4.7.3)
48
49
  guard (~> 2.1)
49
- rspec (>= 2.14, < 4.0)
50
+ guard-compat (~> 1.1)
51
+ rspec (>= 2.99.0, < 4.0)
50
52
  haml (5.1.2)
51
53
  temple (>= 0.8.0)
52
54
  tilt
53
55
  i18n (1.8.10)
54
56
  concurrent-ruby (~> 1.0)
55
57
  json (2.3.0)
56
- listen (3.2.1)
58
+ listen (3.7.0)
57
59
  rb-fsevent (~> 0.10, >= 0.10.3)
58
60
  rb-inotify (~> 0.9, >= 0.9.10)
59
- lumberjack (1.0.13)
60
- method_source (0.9.2)
61
+ lumberjack (1.2.8)
62
+ method_source (1.0.0)
61
63
  minitest (5.14.4)
62
64
  nenv (0.3.0)
63
65
  notiffany (0.1.3)
64
66
  nenv (~> 0.1)
65
67
  shellany (~> 0.0)
66
- pry (0.12.2)
67
- coderay (~> 1.1.0)
68
- method_source (~> 0.9.0)
68
+ pry (0.14.1)
69
+ coderay (~> 1.1)
70
+ method_source (~> 1.0)
69
71
  rake (13.0.1)
70
- rb-fsevent (0.10.3)
72
+ rb-fsevent (0.11.0)
71
73
  rb-inotify (0.10.1)
72
74
  ffi (~> 1.0)
73
75
  require_all (3.0.0)
74
- rspec (3.9.0)
75
- rspec-core (~> 3.9.0)
76
- rspec-expectations (~> 3.9.0)
77
- rspec-mocks (~> 3.9.0)
78
- rspec-core (3.9.1)
79
- rspec-support (~> 3.9.1)
80
- rspec-expectations (3.9.1)
76
+ rspec (3.10.0)
77
+ rspec-core (~> 3.10.0)
78
+ rspec-expectations (~> 3.10.0)
79
+ rspec-mocks (~> 3.10.0)
80
+ rspec-core (3.10.1)
81
+ rspec-support (~> 3.10.0)
82
+ rspec-expectations (3.10.1)
81
83
  diff-lcs (>= 1.2.0, < 2.0)
82
- rspec-support (~> 3.9.0)
83
- rspec-mocks (3.9.1)
84
+ rspec-support (~> 3.10.0)
85
+ rspec-mocks (3.10.2)
84
86
  diff-lcs (>= 1.2.0, < 2.0)
85
- rspec-support (~> 3.9.0)
86
- rspec-support (3.9.2)
87
+ rspec-support (~> 3.10.0)
88
+ rspec-support (3.10.2)
87
89
  ruby-progressbar (1.11.0)
88
- sexp_processor (4.15.2)
90
+ sexp_processor (4.15.3)
89
91
  shellany (0.0.1)
90
92
  simplecov (0.16.1)
91
93
  docile (~> 1.1)
@@ -98,12 +100,12 @@ GEM
98
100
  temple (0.8.2)
99
101
  term-ansicolor (1.7.1)
100
102
  tins (~> 1.0)
101
- thor (1.0.1)
103
+ thor (1.1.0)
102
104
  tilt (2.0.10)
103
105
  tins (1.22.2)
104
106
  tzinfo (2.0.4)
105
107
  concurrent-ruby (~> 1.0)
106
- zeitwerk (2.4.2)
108
+ zeitwerk (2.5.1)
107
109
 
108
110
  PLATFORMS
109
111
  ruby
@@ -122,4 +124,4 @@ DEPENDENCIES
122
124
  slim
123
125
 
124
126
  BUNDLED WITH
125
- 2.1.4
127
+ 2.2.22
@@ -115,6 +115,8 @@
115
115
  <td class='filename'>
116
116
  <% if @github %>
117
117
  <a href='<%= @github_name %>/blob/<%= @last_commit_id %>/<%= error.short_filename %>#L<%= error.first_line_number %>' target='_blank'><%= error.short_filename %></a>
118
+ <% elsif @atom %>
119
+ <a href='atom://core/open/file?filename=<%= File.expand_path(error.filename) %>&amp;line=<%= error.line_number %>'><%= error.short_filename %></a>
118
120
  <% elsif @textmate %>
119
121
  <a href='txmt://open/?url=file://<%= File.expand_path(error.filename) %>&amp;line=<%= error.line_number %>'><%= error.short_filename %></a>
120
122
  <% elsif @sublime %>
@@ -249,6 +249,7 @@ module RailsBestPractices
249
249
  file.puts eruby.evaluate(
250
250
  errors: errors,
251
251
  error_types: error_types,
252
+ atom: @options['with-atom'],
252
253
  textmate: @options['with-textmate'],
253
254
  vscode: @options['with-vscode'],
254
255
  sublime: @options['with-sublime'],
@@ -10,6 +10,7 @@ module RailsBestPractices
10
10
  # -f, --format FORMAT output format (text, html, yaml, json, xml)
11
11
  # --output-file FILE output html file for the analyzing result
12
12
  # --without-color only output plain text without color
13
+ # --with-atom open file by atom in html format
13
14
  # --with-textmate open file by textmate in html format
14
15
  # --with-vscode open file by vscode in html format
15
16
  # --with-sublime open file by sublime in html format (requires subl-handler)
@@ -49,6 +50,10 @@ module RailsBestPractices
49
50
  options['without-color'] = true
50
51
  end
51
52
 
53
+ opts.on('--with-atom', 'open file by atom in html format') do
54
+ options['with-atom'] = true
55
+ end
56
+
52
57
  opts.on('--with-textmate', 'open file by textmate in html format') do
53
58
  options['with-textmate'] = true
54
59
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module RailsBestPractices
4
- VERSION = '1.21.0'
4
+ VERSION = '1.22.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_best_practices
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.21.0
4
+ version: 1.22.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Richard Huang
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-15 00:00:00.000000000 Z
11
+ date: 2021-10-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -403,7 +403,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
403
403
  - !ruby/object:Gem::Version
404
404
  version: 1.3.6
405
405
  requirements: []
406
- rubygems_version: 3.1.6
406
+ rubygems_version: 3.2.22
407
407
  signing_key:
408
408
  specification_version: 4
409
409
  summary: a code metric tool for rails codes.