haml_lint 0.13.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (60) hide show
  1. checksums.yaml +7 -0
  2. data/bin/haml-lint +7 -0
  3. data/config/default.yml +91 -0
  4. data/lib/haml_lint/cli.rb +122 -0
  5. data/lib/haml_lint/configuration.rb +97 -0
  6. data/lib/haml_lint/configuration_loader.rb +68 -0
  7. data/lib/haml_lint/constants.rb +8 -0
  8. data/lib/haml_lint/exceptions.rb +15 -0
  9. data/lib/haml_lint/file_finder.rb +69 -0
  10. data/lib/haml_lint/haml_visitor.rb +36 -0
  11. data/lib/haml_lint/lint.rb +25 -0
  12. data/lib/haml_lint/linter/alt_text.rb +12 -0
  13. data/lib/haml_lint/linter/class_attribute_with_static_value.rb +51 -0
  14. data/lib/haml_lint/linter/classes_before_ids.rb +26 -0
  15. data/lib/haml_lint/linter/consecutive_comments.rb +20 -0
  16. data/lib/haml_lint/linter/consecutive_silent_scripts.rb +23 -0
  17. data/lib/haml_lint/linter/empty_script.rb +12 -0
  18. data/lib/haml_lint/linter/html_attributes.rb +14 -0
  19. data/lib/haml_lint/linter/implicit_div.rb +20 -0
  20. data/lib/haml_lint/linter/leading_comment_space.rb +14 -0
  21. data/lib/haml_lint/linter/line_length.rb +19 -0
  22. data/lib/haml_lint/linter/multiline_pipe.rb +43 -0
  23. data/lib/haml_lint/linter/multiline_script.rb +43 -0
  24. data/lib/haml_lint/linter/object_reference_attributes.rb +14 -0
  25. data/lib/haml_lint/linter/rubocop.rb +76 -0
  26. data/lib/haml_lint/linter/ruby_comments.rb +18 -0
  27. data/lib/haml_lint/linter/space_before_script.rb +52 -0
  28. data/lib/haml_lint/linter/space_inside_hash_attributes.rb +32 -0
  29. data/lib/haml_lint/linter/tag_name.rb +13 -0
  30. data/lib/haml_lint/linter/trailing_whitespace.rb +16 -0
  31. data/lib/haml_lint/linter/unnecessary_interpolation.rb +29 -0
  32. data/lib/haml_lint/linter/unnecessary_string_output.rb +39 -0
  33. data/lib/haml_lint/linter.rb +156 -0
  34. data/lib/haml_lint/linter_registry.rb +26 -0
  35. data/lib/haml_lint/logger.rb +107 -0
  36. data/lib/haml_lint/node_transformer.rb +28 -0
  37. data/lib/haml_lint/options.rb +89 -0
  38. data/lib/haml_lint/parser.rb +87 -0
  39. data/lib/haml_lint/rake_task.rb +107 -0
  40. data/lib/haml_lint/report.rb +16 -0
  41. data/lib/haml_lint/reporter/default_reporter.rb +39 -0
  42. data/lib/haml_lint/reporter/json_reporter.rb +44 -0
  43. data/lib/haml_lint/reporter.rb +36 -0
  44. data/lib/haml_lint/ruby_parser.rb +29 -0
  45. data/lib/haml_lint/runner.rb +76 -0
  46. data/lib/haml_lint/script_extractor.rb +181 -0
  47. data/lib/haml_lint/tree/comment_node.rb +5 -0
  48. data/lib/haml_lint/tree/doctype_node.rb +5 -0
  49. data/lib/haml_lint/tree/filter_node.rb +9 -0
  50. data/lib/haml_lint/tree/haml_comment_node.rb +18 -0
  51. data/lib/haml_lint/tree/node.rb +98 -0
  52. data/lib/haml_lint/tree/plain_node.rb +5 -0
  53. data/lib/haml_lint/tree/root_node.rb +5 -0
  54. data/lib/haml_lint/tree/script_node.rb +11 -0
  55. data/lib/haml_lint/tree/silent_script_node.rb +12 -0
  56. data/lib/haml_lint/tree/tag_node.rb +221 -0
  57. data/lib/haml_lint/utils.rb +58 -0
  58. data/lib/haml_lint/version.rb +4 -0
  59. data/lib/haml_lint.rb +36 -0
  60. metadata +175 -0
metadata ADDED
@@ -0,0 +1,175 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: haml_lint
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.13.0
5
+ platform: ruby
6
+ authors:
7
+ - Brigade Engineering
8
+ - Shane da Silva
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2015-05-03 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: haml
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "~>"
19
+ - !ruby/object:Gem::Version
20
+ version: '4.0'
21
+ type: :runtime
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "~>"
26
+ - !ruby/object:Gem::Version
27
+ version: '4.0'
28
+ - !ruby/object:Gem::Dependency
29
+ name: rubocop
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: 0.25.0
35
+ type: :runtime
36
+ prerelease: false
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - ">="
40
+ - !ruby/object:Gem::Version
41
+ version: 0.25.0
42
+ - !ruby/object:Gem::Dependency
43
+ name: sysexits
44
+ requirement: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - "~>"
47
+ - !ruby/object:Gem::Version
48
+ version: '1.1'
49
+ type: :runtime
50
+ prerelease: false
51
+ version_requirements: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - "~>"
54
+ - !ruby/object:Gem::Version
55
+ version: '1.1'
56
+ - !ruby/object:Gem::Dependency
57
+ name: rspec
58
+ requirement: !ruby/object:Gem::Requirement
59
+ requirements:
60
+ - - "~>"
61
+ - !ruby/object:Gem::Version
62
+ version: '3.0'
63
+ type: :development
64
+ prerelease: false
65
+ version_requirements: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - "~>"
68
+ - !ruby/object:Gem::Version
69
+ version: '3.0'
70
+ - !ruby/object:Gem::Dependency
71
+ name: rspec-its
72
+ requirement: !ruby/object:Gem::Requirement
73
+ requirements:
74
+ - - "~>"
75
+ - !ruby/object:Gem::Version
76
+ version: '1.0'
77
+ type: :development
78
+ prerelease: false
79
+ version_requirements: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - "~>"
82
+ - !ruby/object:Gem::Version
83
+ version: '1.0'
84
+ description: Configurable tool for writing clean and consistent HAML
85
+ email:
86
+ - eng@brigade.com
87
+ - shane.dasilva@brigade.com
88
+ executables:
89
+ - haml-lint
90
+ extensions: []
91
+ extra_rdoc_files: []
92
+ files:
93
+ - bin/haml-lint
94
+ - config/default.yml
95
+ - lib/haml_lint.rb
96
+ - lib/haml_lint/cli.rb
97
+ - lib/haml_lint/configuration.rb
98
+ - lib/haml_lint/configuration_loader.rb
99
+ - lib/haml_lint/constants.rb
100
+ - lib/haml_lint/exceptions.rb
101
+ - lib/haml_lint/file_finder.rb
102
+ - lib/haml_lint/haml_visitor.rb
103
+ - lib/haml_lint/lint.rb
104
+ - lib/haml_lint/linter.rb
105
+ - lib/haml_lint/linter/alt_text.rb
106
+ - lib/haml_lint/linter/class_attribute_with_static_value.rb
107
+ - lib/haml_lint/linter/classes_before_ids.rb
108
+ - lib/haml_lint/linter/consecutive_comments.rb
109
+ - lib/haml_lint/linter/consecutive_silent_scripts.rb
110
+ - lib/haml_lint/linter/empty_script.rb
111
+ - lib/haml_lint/linter/html_attributes.rb
112
+ - lib/haml_lint/linter/implicit_div.rb
113
+ - lib/haml_lint/linter/leading_comment_space.rb
114
+ - lib/haml_lint/linter/line_length.rb
115
+ - lib/haml_lint/linter/multiline_pipe.rb
116
+ - lib/haml_lint/linter/multiline_script.rb
117
+ - lib/haml_lint/linter/object_reference_attributes.rb
118
+ - lib/haml_lint/linter/rubocop.rb
119
+ - lib/haml_lint/linter/ruby_comments.rb
120
+ - lib/haml_lint/linter/space_before_script.rb
121
+ - lib/haml_lint/linter/space_inside_hash_attributes.rb
122
+ - lib/haml_lint/linter/tag_name.rb
123
+ - lib/haml_lint/linter/trailing_whitespace.rb
124
+ - lib/haml_lint/linter/unnecessary_interpolation.rb
125
+ - lib/haml_lint/linter/unnecessary_string_output.rb
126
+ - lib/haml_lint/linter_registry.rb
127
+ - lib/haml_lint/logger.rb
128
+ - lib/haml_lint/node_transformer.rb
129
+ - lib/haml_lint/options.rb
130
+ - lib/haml_lint/parser.rb
131
+ - lib/haml_lint/rake_task.rb
132
+ - lib/haml_lint/report.rb
133
+ - lib/haml_lint/reporter.rb
134
+ - lib/haml_lint/reporter/default_reporter.rb
135
+ - lib/haml_lint/reporter/json_reporter.rb
136
+ - lib/haml_lint/ruby_parser.rb
137
+ - lib/haml_lint/runner.rb
138
+ - lib/haml_lint/script_extractor.rb
139
+ - lib/haml_lint/tree/comment_node.rb
140
+ - lib/haml_lint/tree/doctype_node.rb
141
+ - lib/haml_lint/tree/filter_node.rb
142
+ - lib/haml_lint/tree/haml_comment_node.rb
143
+ - lib/haml_lint/tree/node.rb
144
+ - lib/haml_lint/tree/plain_node.rb
145
+ - lib/haml_lint/tree/root_node.rb
146
+ - lib/haml_lint/tree/script_node.rb
147
+ - lib/haml_lint/tree/silent_script_node.rb
148
+ - lib/haml_lint/tree/tag_node.rb
149
+ - lib/haml_lint/utils.rb
150
+ - lib/haml_lint/version.rb
151
+ homepage: https://github.com/brigade/haml-lint
152
+ licenses:
153
+ - MIT
154
+ metadata: {}
155
+ post_install_message:
156
+ rdoc_options: []
157
+ require_paths:
158
+ - lib
159
+ required_ruby_version: !ruby/object:Gem::Requirement
160
+ requirements:
161
+ - - ">="
162
+ - !ruby/object:Gem::Version
163
+ version: 1.9.3
164
+ required_rubygems_version: !ruby/object:Gem::Requirement
165
+ requirements:
166
+ - - ">="
167
+ - !ruby/object:Gem::Version
168
+ version: '0'
169
+ requirements: []
170
+ rubyforge_project:
171
+ rubygems_version: 2.4.5
172
+ signing_key:
173
+ specification_version: 4
174
+ summary: HAML lint tool
175
+ test_files: []