vedeu 0.4.11 → 0.4.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +736 -0
- data/Rakefile +7 -0
- data/bin/vedeu_drb_server +1 -1
- data/config/rubocop_disabled.yml +50 -0
- data/config/rubocop_enabled.yml +1044 -0
- data/examples/borders_app.rb +3 -1
- data/examples/colours_app.rb +3 -1
- data/examples/configuration_app.rb +1 -1
- data/examples/cursor_app.rb +4 -1
- data/examples/drb_app.rb +3 -1
- data/examples/focus_app.rb +1 -1
- data/examples/geometry_app.rb +3 -1
- data/examples/hello_world.rb +3 -1
- data/examples/lines_app.rb +3 -1
- data/examples/typed_commands/typed_commands_app.rb +1 -1
- data/examples/view_templates_app/view_templates_app.rb +3 -1
- data/lib/vedeu/api.rb +4 -3
- data/lib/vedeu/bindings.rb +1 -1
- data/lib/vedeu/configuration/api.rb +1 -1
- data/lib/vedeu/configuration/cli.rb +3 -2
- data/lib/vedeu/configuration/configuration.rb +1 -1
- data/lib/vedeu/cursor/cursor.rb +2 -2
- data/lib/vedeu/cursor/refresh_cursor.rb +3 -1
- data/lib/vedeu/distributed/templates/default_configuration.vedeu +1 -1
- data/lib/vedeu/events/event.rb +3 -5
- data/lib/vedeu/geometry/position.rb +1 -1
- data/lib/vedeu/input/all.rb +1 -1
- data/lib/vedeu/input/key.rb +5 -8
- data/lib/vedeu/models/all.rb +9 -12
- data/lib/vedeu/models/interface.rb +1 -1
- data/lib/vedeu/models/menu.rb +1 -1
- data/lib/vedeu/output/border.rb +18 -14
- data/lib/vedeu/output/clear.rb +10 -3
- data/lib/vedeu/output/esc.rb +4 -14
- data/lib/vedeu/output/html_char.rb +11 -7
- data/lib/vedeu/output/null_border.rb +10 -0
- data/lib/vedeu/output/presentation.rb +6 -22
- data/lib/vedeu/output/refresh.rb +0 -11
- data/lib/vedeu/output/renderers/terminal_renderer.rb +1 -1
- data/lib/vedeu/output/translator.rb +5 -5
- data/lib/vedeu/output/viewport.rb +12 -9
- data/lib/vedeu/repositories/collections.rb +6 -0
- data/lib/vedeu/support/visible.rb +17 -12
- data/lib/vedeu/traps.rb +3 -3
- data/test/lib/vedeu/configuration/cli_test.rb +1 -1
- data/test/lib/vedeu/output/null_border_test.rb +14 -0
- data/test/lib/vedeu/output/refresh_test.rb +0 -21
- data/test/lib/vedeu/support/coercions_test.rb +5 -5
- data/test/lib/vedeu/support/common_test.rb +1 -1
- data/test/lib/vedeu/support/visible_test.rb +10 -5
- data/test/test_helper.rb +2 -2
- data/vedeu.gemspec +3 -2
- metadata +22 -5
data/Rakefile
CHANGED
@@ -4,6 +4,7 @@ require 'cucumber'
|
|
4
4
|
require 'cucumber/rake/task'
|
5
5
|
require 'inch/rake'
|
6
6
|
require 'yard'
|
7
|
+
require 'rubocop/rake_task'
|
7
8
|
|
8
9
|
Cucumber::Rake::Task.new(:cucumber) do |t|
|
9
10
|
t.cucumber_opts = "features --format progress"
|
@@ -31,4 +32,10 @@ Inch::Rake::Suggest.new(:inch) do |suggest|
|
|
31
32
|
suggest.args << "--all"
|
32
33
|
end
|
33
34
|
|
35
|
+
RuboCop::RakeTask.new(:rubocop) do |task|
|
36
|
+
task.patterns = ['lib/**/*.rb']
|
37
|
+
task.formatters = ['progress']
|
38
|
+
task.fail_on_error = false
|
39
|
+
end
|
40
|
+
|
34
41
|
task :default => :test
|
data/bin/vedeu_drb_server
CHANGED
@@ -0,0 +1,50 @@
|
|
1
|
+
# These are all the cops that are disabled in the default configuration.
|
2
|
+
|
3
|
+
Style/AutoResourceCleanup:
|
4
|
+
Description: 'Suggests the usage of an auto resource cleanup version of a method (if available).'
|
5
|
+
Enabled: false
|
6
|
+
|
7
|
+
Style/CollectionMethods:
|
8
|
+
Description: 'Preferred collection methods.'
|
9
|
+
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#map-find-select-reduce-size'
|
10
|
+
Enabled: false
|
11
|
+
|
12
|
+
Style/Encoding:
|
13
|
+
Description: 'Use UTF-8 as the source file encoding.'
|
14
|
+
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#utf-8'
|
15
|
+
Enabled: false
|
16
|
+
|
17
|
+
Style/InlineComment:
|
18
|
+
Description: 'Avoid inline comments.'
|
19
|
+
Enabled: false
|
20
|
+
|
21
|
+
Style/MethodCalledOnDoEndBlock:
|
22
|
+
Description: 'Avoid chaining a method call on a do...end block.'
|
23
|
+
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#single-line-blocks'
|
24
|
+
Enabled: false
|
25
|
+
|
26
|
+
Style/MissingElse:
|
27
|
+
Description: >-
|
28
|
+
Require if/case expressions to have an else branches.
|
29
|
+
If enabled, it is recommended that
|
30
|
+
Style/UnlessElse and Style/EmptyElse be enabled.
|
31
|
+
This will conflict with Style/EmptyElse if
|
32
|
+
Style/EmptyElse is configured to style "both"
|
33
|
+
Enabled: false
|
34
|
+
EnforcedStyle: both
|
35
|
+
SupportedStyles:
|
36
|
+
# if - warn when an if expression is missing an else branch
|
37
|
+
# case - warn when a case expression is misisng an else branch
|
38
|
+
# both - warn when an if or case expression is missing an else branch
|
39
|
+
- if
|
40
|
+
- case
|
41
|
+
- both
|
42
|
+
|
43
|
+
Style/SymbolArray:
|
44
|
+
Description: 'Use %i or %I for arrays of symbols.'
|
45
|
+
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-i'
|
46
|
+
Enabled: false
|
47
|
+
|
48
|
+
Style/ExtraSpacing:
|
49
|
+
Description: 'Do not use unnecessary spacing.'
|
50
|
+
Enabled: false
|