vedeu 0.4.58 → 0.4.59
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 +4 -4
- data/.rubocop.yml +0 -558
- data/README.md +2 -0
- data/docs/dsl.md +66 -54
- data/lib/vedeu/all.rb +44 -16
- data/lib/vedeu/api.rb +0 -2
- data/lib/vedeu/bindings/drb.rb +0 -1
- data/lib/vedeu/bindings/menus.rb +0 -1
- data/lib/vedeu/bindings/movement.rb +0 -1
- data/lib/vedeu/bindings/system.rb +0 -1
- data/lib/vedeu/bindings/visibility.rb +0 -1
- data/lib/vedeu/bootstrap.rb +2 -2
- data/lib/vedeu/buffers/buffers.rb +0 -4
- data/lib/vedeu/cli/generator/all.rb +0 -4
- data/lib/vedeu/cli/generator/helpers.rb +0 -2
- data/lib/vedeu/cli/generator/templates/application/application.erb +8 -5
- data/lib/vedeu/cli/generator/view.rb +4 -2
- data/lib/vedeu/cli/main.rb +0 -2
- data/lib/vedeu/colours/backgrounds.rb +0 -1
- data/lib/vedeu/colours/colours.rb +0 -1
- data/lib/vedeu/colours/foregrounds.rb +0 -1
- data/lib/vedeu/configuration/api.rb +19 -6
- data/lib/vedeu/configuration/cli.rb +9 -1
- data/lib/vedeu/configuration/configuration.rb +9 -0
- data/lib/vedeu/cursor/cursor.rb +0 -2
- data/lib/vedeu/cursor/cursors.rb +0 -3
- data/lib/vedeu/debug.rb +0 -1
- data/lib/vedeu/dsl.rb +0 -1
- data/lib/vedeu/dsl/border.rb +69 -106
- data/lib/vedeu/dsl/composition.rb +1 -2
- data/lib/vedeu/dsl/geometry.rb +102 -67
- data/lib/vedeu/dsl/group.rb +21 -9
- data/lib/vedeu/dsl/interface.rb +0 -1
- data/lib/vedeu/dsl/keymap.rb +26 -36
- data/lib/vedeu/dsl/line.rb +5 -10
- data/lib/vedeu/dsl/menu.rb +7 -13
- data/lib/vedeu/dsl/presentation.rb +0 -1
- data/lib/vedeu/dsl/stream.rb +0 -1
- data/lib/vedeu/dsl/text.rb +0 -1
- data/lib/vedeu/dsl/use.rb +0 -1
- data/lib/vedeu/dsl/view.rb +28 -31
- data/lib/vedeu/events/event.rb +0 -3
- data/lib/vedeu/events/events.rb +0 -1
- data/lib/vedeu/events/trigger.rb +0 -1
- data/lib/vedeu/geometry/geometries.rb +0 -4
- data/lib/vedeu/geometry/geometry.rb +0 -2
- data/lib/vedeu/geometry/grid.rb +2 -25
- data/lib/vedeu/input/keymap.rb +0 -3
- data/lib/vedeu/input/keymaps.rb +0 -3
- data/lib/vedeu/launcher.rb +0 -1
- data/lib/vedeu/log.rb +0 -1
- data/lib/vedeu/models/char.rb +0 -5
- data/lib/vedeu/models/group.rb +0 -2
- data/lib/vedeu/models/groups.rb +0 -3
- data/lib/vedeu/models/interface.rb +0 -19
- data/lib/vedeu/models/interfaces.rb +0 -4
- data/lib/vedeu/models/menus.rb +0 -3
- data/lib/vedeu/null/interface.rb +6 -7
- data/lib/vedeu/output/border.rb +0 -2
- data/lib/vedeu/output/borders.rb +0 -4
- data/lib/vedeu/output/esc.rb +0 -1
- data/lib/vedeu/output/html_char.rb +0 -2
- data/lib/vedeu/output/refresh.rb +0 -3
- data/lib/vedeu/output/refresh_group.rb +0 -2
- data/lib/vedeu/output/renderers.rb +0 -13
- data/lib/vedeu/repositories.rb +2 -15
- data/lib/vedeu/repositories/model.rb +0 -2
- data/lib/vedeu/repositories/repository.rb +0 -2
- data/lib/vedeu/templating/template.rb +0 -2
- data/lib/vedeu/terminal.rb +0 -3
- data/lib/vedeu/timer.rb +0 -1
- data/lib/vedeu/version.rb +1 -1
- data/test/lib/vedeu/bootstrap_test.rb +8 -1
- data/test/lib/vedeu/configuration/api_test.rb +14 -0
- data/test/lib/vedeu/configuration/cli_test.rb +15 -0
- data/test/lib/vedeu/cursor/cursor_test.rb +0 -1
- data/test/lib/vedeu/models/interface_test.rb +12 -4
- data/test/lib/vedeu/null/interface_test.rb +3 -12
- data/test/support/helpers/model_test_class.rb +0 -3
- data/test/test_helper.rb +0 -2
- data/vedeu.gemspec +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: 9d42efc42e66cb1d9fdc36ec19e54ddb05ecae3f
|
|
4
|
+
data.tar.gz: 1ece4b4a8e6492d6ee360a517fbe060f18be5e00
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 851df985ee89a74620a1b35ffabb58d2b8a40248991d8b6846c1cc1850dadb9b159b1623a913db7ff51b3a3358f7f2bdc1eab8f568b2272abb7c1550f2057e1f
|
|
7
|
+
data.tar.gz: 9e2c4ad401bc028172a05826c37b6af642c8558481b4e9db6742c014d99eed9a621490a9d9129e20eedbf9833a5ede4707d68c0951da2c15a49dcb66f4979bdc
|
data/.rubocop.yml
CHANGED
|
@@ -43,285 +43,14 @@ AllCops:
|
|
|
43
43
|
# the --only-guide-cops option.
|
|
44
44
|
StyleGuideCopsOnly: false
|
|
45
45
|
|
|
46
|
-
# Indent private/protected/public as deep as method definitions
|
|
47
|
-
Style/AccessModifierIndentation:
|
|
48
|
-
EnforcedStyle: indent
|
|
49
|
-
SupportedStyles:
|
|
50
|
-
- outdent
|
|
51
|
-
- indent
|
|
52
|
-
|
|
53
|
-
# Align the elements of a hash literal if they span more than one line.
|
|
54
|
-
Style/AlignHash:
|
|
55
|
-
# Alignment of entries using hash rocket as separator. Valid values are:
|
|
56
|
-
#
|
|
57
|
-
# key - left alignment of keys
|
|
58
|
-
# 'a' => 2
|
|
59
|
-
# 'bb' => 3
|
|
60
|
-
# separator - alignment of hash rockets, keys are right aligned
|
|
61
|
-
# 'a' => 2
|
|
62
|
-
# 'bb' => 3
|
|
63
|
-
# table - left alignment of keys, hash rockets, and values
|
|
64
|
-
# 'a' => 2
|
|
65
|
-
# 'bb' => 3
|
|
66
|
-
EnforcedHashRocketStyle: key
|
|
67
|
-
# Alignment of entries using colon as separator. Valid values are:
|
|
68
|
-
#
|
|
69
|
-
# key - left alignment of keys
|
|
70
|
-
# a: 0
|
|
71
|
-
# bb: 1
|
|
72
|
-
# separator - alignment of colons, keys are right aligned
|
|
73
|
-
# a: 0
|
|
74
|
-
# bb: 1
|
|
75
|
-
# table - left alignment of keys and values
|
|
76
|
-
# a: 0
|
|
77
|
-
# bb: 1
|
|
78
|
-
EnforcedColonStyle: key
|
|
79
|
-
# Select whether hashes that are the last argument in a method call should be
|
|
80
|
-
# inspected? Valid values are:
|
|
81
|
-
#
|
|
82
|
-
# always_inspect - Inspect both implicit and explicit hashes.
|
|
83
|
-
# Registers an offense for:
|
|
84
|
-
# function(a: 1,
|
|
85
|
-
# b: 2)
|
|
86
|
-
# Registers an offense for:
|
|
87
|
-
# function({a: 1,
|
|
88
|
-
# b: 2})
|
|
89
|
-
# always_ignore - Ignore both implicit and explicit hashes.
|
|
90
|
-
# Accepts:
|
|
91
|
-
# function(a: 1,
|
|
92
|
-
# b: 2)
|
|
93
|
-
# Accepts:
|
|
94
|
-
# function({a: 1,
|
|
95
|
-
# b: 2})
|
|
96
|
-
# ignore_implicit - Ignore only implicit hashes.
|
|
97
|
-
# Accepts:
|
|
98
|
-
# function(a: 1,
|
|
99
|
-
# b: 2)
|
|
100
|
-
# Registers an offense for:
|
|
101
|
-
# function({a: 1,
|
|
102
|
-
# b: 2})
|
|
103
|
-
# ignore_explicit - Ignore only explicit hashes.
|
|
104
|
-
# Accepts:
|
|
105
|
-
# function({a: 1,
|
|
106
|
-
# b: 2})
|
|
107
|
-
# Registers an offense for:
|
|
108
|
-
# function(a: 1,
|
|
109
|
-
# b: 2)
|
|
110
|
-
EnforcedLastArgumentHashStyle: always_inspect
|
|
111
|
-
SupportedLastArgumentHashStyles:
|
|
112
|
-
- always_inspect
|
|
113
|
-
- always_ignore
|
|
114
|
-
- ignore_implicit
|
|
115
|
-
- ignore_explicit
|
|
116
|
-
|
|
117
|
-
Style/AlignParameters:
|
|
118
|
-
# Alignment of parameters in multi-line method calls.
|
|
119
|
-
#
|
|
120
|
-
# The `with_first_parameter` style aligns the following lines along the same
|
|
121
|
-
# column as the first parameter.
|
|
122
|
-
#
|
|
123
|
-
# method_call(a,
|
|
124
|
-
# b)
|
|
125
|
-
#
|
|
126
|
-
# The `with_fixed_indentation` style aligns the following lines with one
|
|
127
|
-
# level of indentation relative to the start of the line with the method call.
|
|
128
|
-
#
|
|
129
|
-
# method_call(a,
|
|
130
|
-
# b)
|
|
131
|
-
EnforcedStyle: with_first_parameter
|
|
132
|
-
SupportedStyles:
|
|
133
|
-
- with_first_parameter
|
|
134
|
-
- with_fixed_indentation
|
|
135
|
-
|
|
136
|
-
Style/AndOr:
|
|
137
|
-
# Whether `and` and `or` are banned only in conditionals (conditionals)
|
|
138
|
-
# or completely (always).
|
|
139
|
-
EnforcedStyle: always
|
|
140
|
-
SupportedStyles:
|
|
141
|
-
- always
|
|
142
|
-
- conditionals
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
# Checks if usage of %() or %Q() matches configuration.
|
|
146
|
-
Style/BarePercentLiterals:
|
|
147
|
-
EnforcedStyle: bare_percent
|
|
148
|
-
SupportedStyles:
|
|
149
|
-
- percent_q
|
|
150
|
-
- bare_percent
|
|
151
|
-
|
|
152
|
-
Style/BracesAroundHashParameters:
|
|
153
|
-
EnforcedStyle: context_dependent
|
|
154
|
-
SupportedStyles:
|
|
155
|
-
# The `braces` style enforces braces around all method parameters that are
|
|
156
|
-
# hashes.
|
|
157
|
-
- braces
|
|
158
|
-
# The `no_braces` style checks that the last parameter doesn't have braces
|
|
159
|
-
# around it.
|
|
160
|
-
- no_braces
|
|
161
|
-
# The `context_dependent` style checks that the last parameter doesn't have
|
|
162
|
-
# braces around it, but requires braces if the second to last parameter is
|
|
163
|
-
# also a hash literal.
|
|
164
|
-
- context_dependent
|
|
165
|
-
|
|
166
|
-
# Indentation of `when`.
|
|
167
|
-
Style/CaseIndentation:
|
|
168
|
-
IndentWhenRelativeTo: case
|
|
169
|
-
SupportedStyles:
|
|
170
|
-
- case
|
|
171
|
-
- end
|
|
172
|
-
IndentOneStep: false
|
|
173
|
-
|
|
174
|
-
Style/ClassAndModuleChildren:
|
|
175
|
-
# Checks the style of children definitions at classes and modules.
|
|
176
|
-
#
|
|
177
|
-
# Basically there are two different styles:
|
|
178
|
-
#
|
|
179
|
-
# `nested` - have each child on a separate line
|
|
180
|
-
# class Foo
|
|
181
|
-
# class Bar
|
|
182
|
-
# end
|
|
183
|
-
# end
|
|
184
|
-
#
|
|
185
|
-
# `compact` - combine definitions as much as possible
|
|
186
|
-
# class Foo::Bar
|
|
187
|
-
# end
|
|
188
|
-
#
|
|
189
|
-
# The compact style is only forced, for classes / modules with one child.
|
|
190
|
-
EnforcedStyle: nested
|
|
191
|
-
SupportedStyles:
|
|
192
|
-
- nested
|
|
193
|
-
- compact
|
|
194
|
-
|
|
195
|
-
Style/ClassCheck:
|
|
196
|
-
EnforcedStyle: is_a?
|
|
197
|
-
SupportedStyles:
|
|
198
|
-
- is_a?
|
|
199
|
-
- kind_of?
|
|
200
|
-
|
|
201
|
-
# Align with the style guide.
|
|
202
|
-
Style/CollectionMethods:
|
|
203
|
-
# Mapping from undesired method to desired_method
|
|
204
|
-
# e.g. to use `detect` over `find`:
|
|
205
|
-
#
|
|
206
|
-
# CollectionMethods:
|
|
207
|
-
# PreferredMethods:
|
|
208
|
-
# find: detect
|
|
209
|
-
PreferredMethods:
|
|
210
|
-
collect: 'map'
|
|
211
|
-
collect!: 'map!'
|
|
212
|
-
inject: 'reduce'
|
|
213
|
-
detect: 'find'
|
|
214
|
-
find_all: 'select'
|
|
215
|
-
|
|
216
|
-
# Use ` or %x around command literals.
|
|
217
|
-
Style/CommandLiteral:
|
|
218
|
-
EnforcedStyle: backticks
|
|
219
|
-
# backticks: Always use backticks.
|
|
220
|
-
# percent_x: Always use %x.
|
|
221
|
-
# mixed: Use backticks on single-line commands, and %x on multi-line commands.
|
|
222
|
-
SupportedStyles:
|
|
223
|
-
- backticks
|
|
224
|
-
- percent_x
|
|
225
|
-
- mixed
|
|
226
|
-
# If false, the cop will always recommend using %x if one or more backticks
|
|
227
|
-
# are found in the command string.
|
|
228
|
-
AllowInnerBackticks: false
|
|
229
|
-
|
|
230
|
-
# Checks formatting of special comments
|
|
231
|
-
Style/CommentAnnotation:
|
|
232
|
-
Keywords:
|
|
233
|
-
- TODO
|
|
234
|
-
- FIXME
|
|
235
|
-
- OPTIMIZE
|
|
236
|
-
- HACK
|
|
237
|
-
- REVIEW
|
|
238
|
-
|
|
239
|
-
# Multi-line method chaining should be done with leading dots.
|
|
240
|
-
Style/DotPosition:
|
|
241
|
-
EnforcedStyle: leading
|
|
242
|
-
SupportedStyles:
|
|
243
|
-
- leading
|
|
244
|
-
- trailing
|
|
245
|
-
|
|
246
|
-
# Warn on empty else statements
|
|
247
|
-
# empty - warn only on empty else
|
|
248
|
-
# nil - warn on else with nil in it
|
|
249
|
-
# both - warn on empty else and else with nil in it
|
|
250
|
-
Style/EmptyElse:
|
|
251
|
-
EnforcedStyle: both
|
|
252
|
-
SupportedStyles:
|
|
253
|
-
- empty
|
|
254
|
-
- nil
|
|
255
|
-
- both
|
|
256
|
-
|
|
257
|
-
# Use empty lines between defs.
|
|
258
|
-
Style/EmptyLineBetweenDefs:
|
|
259
|
-
# If true, this parameter means that single line method definitions don't
|
|
260
|
-
# need an empty line between them.
|
|
261
|
-
AllowAdjacentOneLineDefs: false
|
|
262
|
-
|
|
263
46
|
Style/EmptyLinesAroundBlockBody:
|
|
264
47
|
EnforcedStyle: no_empty_lines
|
|
265
|
-
SupportedStyles:
|
|
266
|
-
- empty_lines
|
|
267
|
-
- no_empty_lines
|
|
268
48
|
|
|
269
49
|
Style/EmptyLinesAroundClassBody:
|
|
270
50
|
EnforcedStyle: empty_lines
|
|
271
|
-
SupportedStyles:
|
|
272
|
-
- empty_lines
|
|
273
|
-
- no_empty_lines
|
|
274
51
|
|
|
275
52
|
Style/EmptyLinesAroundModuleBody:
|
|
276
53
|
EnforcedStyle: empty_lines
|
|
277
|
-
SupportedStyles:
|
|
278
|
-
- empty_lines
|
|
279
|
-
- no_empty_lines
|
|
280
|
-
|
|
281
|
-
# Checks whether the source file has a utf-8 encoding comment or not
|
|
282
|
-
# AutoCorrectEncodingComment must match the regex
|
|
283
|
-
# /#.*coding\s?[:=]\s?(?:UTF|utf)-8/
|
|
284
|
-
Style/Encoding:
|
|
285
|
-
EnforcedStyle: always
|
|
286
|
-
SupportedStyles:
|
|
287
|
-
- when_needed
|
|
288
|
-
- always
|
|
289
|
-
AutoCorrectEncodingComment: '# encoding: utf-8'
|
|
290
|
-
|
|
291
|
-
Style/FileName:
|
|
292
|
-
# File names listed in AllCops:Include are excluded by default. Add extra
|
|
293
|
-
# excludes here.
|
|
294
|
-
Exclude: []
|
|
295
|
-
|
|
296
|
-
Style/FirstParameterIndentation:
|
|
297
|
-
EnforcedStyle: special_for_inner_method_call_in_parentheses
|
|
298
|
-
SupportedStyles:
|
|
299
|
-
# The first parameter should always be indented one step more than the
|
|
300
|
-
# preceding line.
|
|
301
|
-
- consistent
|
|
302
|
-
# The first parameter should normally be indented one step more than the
|
|
303
|
-
# preceding line, but if it's a parameter for a method call that is itself
|
|
304
|
-
# a parameter in a method call, then the inner parameter should be indented
|
|
305
|
-
# relative to the inner method.
|
|
306
|
-
- special_for_inner_method_call
|
|
307
|
-
# Same as special_for_inner_method_call except that the special rule only
|
|
308
|
-
# applies if the outer method call encloses its arguments in parentheses.
|
|
309
|
-
- special_for_inner_method_call_in_parentheses
|
|
310
|
-
|
|
311
|
-
# Checks use of for or each in multiline loops.
|
|
312
|
-
Style/For:
|
|
313
|
-
EnforcedStyle: each
|
|
314
|
-
SupportedStyles:
|
|
315
|
-
- for
|
|
316
|
-
- each
|
|
317
|
-
|
|
318
|
-
# Enforce the method used for string formatting.
|
|
319
|
-
Style/FormatString:
|
|
320
|
-
EnforcedStyle: format
|
|
321
|
-
SupportedStyles:
|
|
322
|
-
- format
|
|
323
|
-
- sprintf
|
|
324
|
-
- percent
|
|
325
54
|
|
|
326
55
|
# Built-in global variables are allowed by default.
|
|
327
56
|
Style/GlobalVars:
|
|
@@ -332,20 +61,10 @@ Style/GlobalVars:
|
|
|
332
61
|
Style/GuardClause:
|
|
333
62
|
MinBodyLength: 1
|
|
334
63
|
|
|
335
|
-
Style/HashSyntax:
|
|
336
|
-
EnforcedStyle: ruby19
|
|
337
|
-
SupportedStyles:
|
|
338
|
-
- ruby19
|
|
339
|
-
- ruby19_no_mixed_keys
|
|
340
|
-
- hash_rockets
|
|
341
|
-
# Force hashes that have a symbol value to use hash rockets
|
|
342
|
-
UseHashRocketsWithSymbolValues: false
|
|
343
|
-
|
|
344
64
|
Style/IfUnlessModifier:
|
|
345
65
|
MaxLineLength: 80
|
|
346
66
|
|
|
347
67
|
Style/IndentationWidth:
|
|
348
|
-
# Number of spaces for each indentation level.
|
|
349
68
|
Width: 2
|
|
350
69
|
|
|
351
70
|
# Checks the indentation of the first key in a hash literal.
|
|
@@ -362,12 +81,6 @@ Style/IndentHash:
|
|
|
362
81
|
- special_inside_parentheses
|
|
363
82
|
- consistent
|
|
364
83
|
|
|
365
|
-
Style/LambdaCall:
|
|
366
|
-
EnforcedStyle: call
|
|
367
|
-
SupportedStyles:
|
|
368
|
-
- call
|
|
369
|
-
- braces
|
|
370
|
-
|
|
371
84
|
Style/ModuleFunction:
|
|
372
85
|
Enabled: false
|
|
373
86
|
|
|
@@ -383,239 +96,23 @@ Style/Next:
|
|
|
383
96
|
- skip_modifier_ifs
|
|
384
97
|
- always
|
|
385
98
|
|
|
386
|
-
Style/NonNilCheck:
|
|
387
|
-
# With `IncludeSemanticChanges` set to `true`, this cop reports offenses for
|
|
388
|
-
# `!x.nil?` and autocorrects that and `x != nil` to solely `x`, which is
|
|
389
|
-
# **usually** OK, but might change behavior.
|
|
390
|
-
#
|
|
391
|
-
# With `IncludeSemanticChanges` set to `false`, this cop does not report
|
|
392
|
-
# offenses for `!x.nil?` and does no changes that might change behavior.
|
|
393
|
-
IncludeSemanticChanges: false
|
|
394
|
-
|
|
395
|
-
Style/MethodDefParentheses:
|
|
396
|
-
EnforcedStyle: require_parentheses
|
|
397
|
-
SupportedStyles:
|
|
398
|
-
- require_parentheses
|
|
399
|
-
- require_no_parentheses
|
|
400
|
-
|
|
401
|
-
Style/MethodName:
|
|
402
|
-
EnforcedStyle: snake_case
|
|
403
|
-
SupportedStyles:
|
|
404
|
-
- snake_case
|
|
405
|
-
- camelCase
|
|
406
|
-
|
|
407
|
-
Style/MultilineOperationIndentation:
|
|
408
|
-
EnforcedStyle: aligned
|
|
409
|
-
SupportedStyles:
|
|
410
|
-
- aligned
|
|
411
|
-
- indented
|
|
412
|
-
|
|
413
|
-
Style/NumericLiterals:
|
|
414
|
-
MinDigits: 5
|
|
415
|
-
|
|
416
|
-
# Allow safe assignment in conditions.
|
|
417
|
-
Style/ParenthesesAroundCondition:
|
|
418
|
-
AllowSafeAssignment: true
|
|
419
|
-
|
|
420
|
-
Style/PercentLiteralDelimiters:
|
|
421
|
-
PreferredDelimiters:
|
|
422
|
-
'%': ()
|
|
423
|
-
'%i': ()
|
|
424
|
-
'%q': ()
|
|
425
|
-
'%Q': ()
|
|
426
|
-
'%r': '{}'
|
|
427
|
-
'%s': ()
|
|
428
|
-
'%w': ()
|
|
429
|
-
'%W': ()
|
|
430
|
-
'%x': ()
|
|
431
|
-
|
|
432
|
-
Style/PercentQLiterals:
|
|
433
|
-
EnforcedStyle: lower_case_q
|
|
434
|
-
SupportedStyles:
|
|
435
|
-
- lower_case_q # Use %q when possible, %Q when necessary
|
|
436
|
-
- upper_case_q # Always use %Q
|
|
437
|
-
|
|
438
|
-
Style/PredicateName:
|
|
439
|
-
# Predicate name prefices.
|
|
440
|
-
NamePrefix:
|
|
441
|
-
- is_
|
|
442
|
-
- has_
|
|
443
|
-
- have_
|
|
444
|
-
# Predicate name prefices that should be removed.
|
|
445
|
-
NamePrefixBlacklist:
|
|
446
|
-
- is_
|
|
447
|
-
- has_
|
|
448
|
-
- have_
|
|
449
|
-
|
|
450
|
-
Style/RaiseArgs:
|
|
451
|
-
EnforcedStyle: exploded
|
|
452
|
-
SupportedStyles:
|
|
453
|
-
- compact # raise Exception.new(msg)
|
|
454
|
-
- exploded # raise Exception, msg
|
|
455
|
-
|
|
456
|
-
Style/RedundantReturn:
|
|
457
|
-
# When true allows code like `return x, y`.
|
|
458
|
-
AllowMultipleReturnValues: false
|
|
459
|
-
|
|
460
|
-
# Use / or %r around regular expressions.
|
|
461
|
-
Style/RegexpLiteral:
|
|
462
|
-
EnforcedStyle: slashes
|
|
463
|
-
# slashes: Always use slashes.
|
|
464
|
-
# percent_r: Always use %r.
|
|
465
|
-
# mixed: Use slashes on single-line regexes, and %r on multi-line regexes.
|
|
466
|
-
SupportedStyles:
|
|
467
|
-
- slashes
|
|
468
|
-
- percent_r
|
|
469
|
-
- mixed
|
|
470
|
-
# If false, the cop will always recommend using %r if one or more slashes
|
|
471
|
-
# are found in the regexp string.
|
|
472
|
-
AllowInnerSlashes: false
|
|
473
|
-
|
|
474
|
-
Style/Semicolon:
|
|
475
|
-
# Allow ; to separate several expressions on the same line.
|
|
476
|
-
AllowAsExpressionSeparator: false
|
|
477
|
-
|
|
478
|
-
Style/SignalException:
|
|
479
|
-
EnforcedStyle: semantic
|
|
480
|
-
SupportedStyles:
|
|
481
|
-
- only_raise
|
|
482
|
-
- only_fail
|
|
483
|
-
- semantic
|
|
484
|
-
|
|
485
|
-
Style/SingleLineBlockParams:
|
|
486
|
-
Methods:
|
|
487
|
-
- reduce:
|
|
488
|
-
- a
|
|
489
|
-
- e
|
|
490
|
-
- inject:
|
|
491
|
-
- a
|
|
492
|
-
- e
|
|
493
|
-
|
|
494
|
-
Style/SingleLineMethods:
|
|
495
|
-
AllowIfMethodIsEmpty: true
|
|
496
|
-
|
|
497
|
-
Style/StringLiterals:
|
|
498
|
-
EnforcedStyle: single_quotes
|
|
499
|
-
SupportedStyles:
|
|
500
|
-
- single_quotes
|
|
501
|
-
- double_quotes
|
|
502
|
-
|
|
503
|
-
Style/StringLiteralsInInterpolation:
|
|
504
|
-
EnforcedStyle: single_quotes
|
|
505
|
-
SupportedStyles:
|
|
506
|
-
- single_quotes
|
|
507
|
-
- double_quotes
|
|
508
|
-
|
|
509
|
-
Style/SpaceAroundBlockParameters:
|
|
510
|
-
EnforcedStyleInsidePipes: no_space
|
|
511
|
-
SupportedStyles:
|
|
512
|
-
- space
|
|
513
|
-
- no_space
|
|
514
|
-
|
|
515
99
|
Style/SpaceAroundEqualsInParameterDefault:
|
|
516
100
|
EnforcedStyle: space
|
|
517
|
-
SupportedStyles:
|
|
518
|
-
- space
|
|
519
|
-
- no_space
|
|
520
|
-
|
|
521
|
-
Style/SpaceAroundOperators:
|
|
522
|
-
MultiSpaceAllowedForOperators:
|
|
523
|
-
- '='
|
|
524
|
-
- '=>'
|
|
525
101
|
|
|
526
102
|
Style/SpaceBeforeBlockBraces:
|
|
527
103
|
EnforcedStyle: space
|
|
528
|
-
SupportedStyles:
|
|
529
|
-
- space
|
|
530
|
-
- no_space
|
|
531
104
|
|
|
532
105
|
Style/SpaceInsideBlockBraces:
|
|
533
106
|
EnforcedStyle: space
|
|
534
|
-
SupportedStyles:
|
|
535
|
-
- space
|
|
536
|
-
- no_space
|
|
537
|
-
# Valid values are: space, no_space
|
|
538
|
-
EnforcedStyleForEmptyBraces: no_space
|
|
539
|
-
# Space between { and |. Overrides EnforcedStyle if there is a conflict.
|
|
540
|
-
SpaceBeforeBlockParameters: true
|
|
541
107
|
|
|
542
108
|
Style/SpaceInsideHashLiteralBraces:
|
|
543
109
|
EnforcedStyle: space
|
|
544
|
-
EnforcedStyleForEmptyBraces: no_space
|
|
545
|
-
SupportedStyles:
|
|
546
|
-
- space
|
|
547
|
-
- no_space
|
|
548
|
-
|
|
549
|
-
Style/SymbolProc:
|
|
550
|
-
# A list of method names to be ignored by the check.
|
|
551
|
-
# The names should be fairly unique, otherwise you'll end up ignoring lots of code.
|
|
552
|
-
IgnoredMethods:
|
|
553
|
-
- respond_to
|
|
554
110
|
|
|
555
111
|
Style/TrailingBlankLines:
|
|
556
112
|
EnforcedStyle: final_newline
|
|
557
|
-
SupportedStyles:
|
|
558
|
-
- final_newline
|
|
559
|
-
- final_blank_line
|
|
560
113
|
|
|
561
114
|
Style/TrailingComma:
|
|
562
|
-
# If EnforcedStyleForMultiline is comma, the cop requires a comma after the
|
|
563
|
-
# last item of a list, but only for lists where each item is on its own line.
|
|
564
|
-
# If EnforcedStyleForMultiline is consistent_comma, the cop requires a comma
|
|
565
|
-
# after the last item of a list, for all lists.
|
|
566
115
|
EnforcedStyleForMultiline: comma
|
|
567
|
-
SupportedStyles:
|
|
568
|
-
- comma
|
|
569
|
-
- consistent_comma
|
|
570
|
-
- no_comma
|
|
571
|
-
|
|
572
|
-
# TrivialAccessors doesn't require exact name matches and doesn't allow
|
|
573
|
-
# predicated methods by default.
|
|
574
|
-
Style/TrivialAccessors:
|
|
575
|
-
ExactNameMatch: false
|
|
576
|
-
AllowPredicates: false
|
|
577
|
-
# Allows trivial writers that don't end in an equal sign. e.g.
|
|
578
|
-
#
|
|
579
|
-
# def on_exception(action)
|
|
580
|
-
# @on_exception=action
|
|
581
|
-
# end
|
|
582
|
-
# on_exception :restart
|
|
583
|
-
#
|
|
584
|
-
# Commonly used in DSLs
|
|
585
|
-
AllowDSLWriters: false
|
|
586
|
-
IgnoreClassMethods: false
|
|
587
|
-
Whitelist:
|
|
588
|
-
- to_ary
|
|
589
|
-
- to_a
|
|
590
|
-
- to_c
|
|
591
|
-
- to_enum
|
|
592
|
-
- to_h
|
|
593
|
-
- to_hash
|
|
594
|
-
- to_i
|
|
595
|
-
- to_int
|
|
596
|
-
- to_io
|
|
597
|
-
- to_open
|
|
598
|
-
- to_path
|
|
599
|
-
- to_proc
|
|
600
|
-
- to_r
|
|
601
|
-
- to_regexp
|
|
602
|
-
- to_str
|
|
603
|
-
- to_s
|
|
604
|
-
- to_sym
|
|
605
|
-
|
|
606
|
-
Style/VariableName:
|
|
607
|
-
EnforcedStyle: snake_case
|
|
608
|
-
SupportedStyles:
|
|
609
|
-
- snake_case
|
|
610
|
-
- camelCase
|
|
611
|
-
|
|
612
|
-
Style/WhileUntilModifier:
|
|
613
|
-
MaxLineLength: 80
|
|
614
|
-
|
|
615
|
-
Style/WordArray:
|
|
616
|
-
MinSize: 0
|
|
617
|
-
# The regular expression WordRegex decides what is considered a word.
|
|
618
|
-
WordRegex: !ruby/regexp '/\A[\p{Word}]+\z/'
|
|
619
116
|
|
|
620
117
|
##################### Metrics ##################################
|
|
621
118
|
|
|
@@ -683,58 +180,3 @@ Lint/DefEndAlignment:
|
|
|
683
180
|
- start_of_line
|
|
684
181
|
- def
|
|
685
182
|
|
|
686
|
-
##################### Rails ##################################
|
|
687
|
-
|
|
688
|
-
Rails/ActionFilter:
|
|
689
|
-
EnforcedStyle: action
|
|
690
|
-
SupportedStyles:
|
|
691
|
-
- action
|
|
692
|
-
- filter
|
|
693
|
-
Include:
|
|
694
|
-
- app/controllers/**/*.rb
|
|
695
|
-
|
|
696
|
-
Rails/Date:
|
|
697
|
-
# The value `always` disallows usage of `Date.today`, `Date.current`,
|
|
698
|
-
# `Date#to_time` etc.
|
|
699
|
-
# The value `acceptable` allows usage of `Date.current`, `Date.yesterday`, etc
|
|
700
|
-
# (but not `Date.today`) which are overriden by ActiveSupport to handle current
|
|
701
|
-
# time zone.
|
|
702
|
-
EnforcedStyle: always
|
|
703
|
-
SupportedStyles:
|
|
704
|
-
- always
|
|
705
|
-
- acceptable
|
|
706
|
-
|
|
707
|
-
Rails/DefaultScope:
|
|
708
|
-
Include:
|
|
709
|
-
- app/models/**/*.rb
|
|
710
|
-
|
|
711
|
-
Rails/HasAndBelongsToMany:
|
|
712
|
-
Include:
|
|
713
|
-
- app/models/**/*.rb
|
|
714
|
-
|
|
715
|
-
Rails/Output:
|
|
716
|
-
Include:
|
|
717
|
-
- app/**/*.rb
|
|
718
|
-
- config/**/*.rb
|
|
719
|
-
- db/**/*.rb
|
|
720
|
-
- lib/**/*.rb
|
|
721
|
-
|
|
722
|
-
Rails/ReadWriteAttribute:
|
|
723
|
-
Include:
|
|
724
|
-
- app/models/**/*.rb
|
|
725
|
-
|
|
726
|
-
Rails/ScopeArgs:
|
|
727
|
-
Include:
|
|
728
|
-
- app/models/**/*.rb
|
|
729
|
-
|
|
730
|
-
Rails/TimeZone:
|
|
731
|
-
# The value `always` means that `Time` should be used with `zone`.
|
|
732
|
-
# The value `acceptable` allows usage of `in_time_zone` instead of `zone`.
|
|
733
|
-
EnforcedStyle: always
|
|
734
|
-
SupportedStyles:
|
|
735
|
-
- always
|
|
736
|
-
- acceptable
|
|
737
|
-
|
|
738
|
-
Rails/Validation:
|
|
739
|
-
Include:
|
|
740
|
-
- app/models/**/*.rb
|