reevoocop 0.0.6 → 0.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d3d7a072511b43e6aad906cc529b20ed6e84312a
4
- data.tar.gz: 93fc7805a8a3bdaacfd18220736e29830e043306
3
+ metadata.gz: 12143b030d02ebc1472a0bea19cc70a4e7903c37
4
+ data.tar.gz: e248efbcc1dbfdc8576d2e9536b5b51963b5b33e
5
5
  SHA512:
6
- metadata.gz: e05d1a66265be13ef530f38cdbe6a53eca44cbb7552ac03e3d218066524c996290f414ff4d0f201cfe7aaaa87a50ad2755a48dcb2ee86bd1f0c0e9466ac5a7fe
7
- data.tar.gz: 25f5e586e512d1cb51c80c7033824ef6ff2a9cfdf67f1093e6dc9f45bec0f2737d04b1c24eb9f7c543b4f613766dde935a1ec65a3fc6822b32f3b41f0203902f
6
+ metadata.gz: 5dcf7d227b2c43577b9ae0fa38b0737397504f5ed4aae7a0a29a6ec5367a194ef45b1941a406504292e7809e1a0bd0236062e7f38a4bcd7e42dc78ce76274605
7
+ data.tar.gz: 85d5a678890979f117eca6206327c51d6084147c4ca5bcf8919ef1a276d4fa851d8a9e12c6c7a8db914fa56d2fc736995bd17401315f2edae614497f3caf3acc
data/.travis.yml ADDED
@@ -0,0 +1,5 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.3.0
4
+ - 2.2.4
5
+ - 2.1.8
data/Gemfile CHANGED
@@ -1,6 +1,6 @@
1
- source 'https://rubygems.org'
1
+ source "https://rubygems.org"
2
2
 
3
3
  # Specify your gem's dependencies in reevoocop.gemspec
4
4
  gemspec
5
5
 
6
- gem 'pry'
6
+ gem "pry"
data/Rakefile CHANGED
@@ -1,12 +1,12 @@
1
1
  # encoding: utf-8
2
2
 
3
- require 'bundler/gem_tasks'
4
- require 'reevoocop/rake_task'
3
+ require "bundler/gem_tasks"
4
+ require "reevoocop/rake_task"
5
5
 
6
6
  ReevooCop::RakeTask.new(:reevoocop)
7
7
 
8
8
  task :reevoocop_cli do
9
- sh 'bin/reevoocop'
9
+ sh "bin/reevoocop"
10
10
  end
11
11
 
12
12
  task default: [:reevoocop, :reevoocop_cli]
data/bin/reevoocop CHANGED
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/env ruby
2
2
  # encoding: utf-8
3
3
 
4
- $LOAD_PATH.unshift(File.dirname(File.realpath(__FILE__)) + '/../lib')
4
+ $LOAD_PATH.unshift(File.dirname(File.realpath(__FILE__)) + "/../lib")
5
5
 
6
- require 'reevoocop'
7
- require 'benchmark'
6
+ require "reevoocop"
7
+ require "benchmark"
8
8
 
9
9
  cli = RuboCop::CLI.new
10
10
  result = 0
@@ -1,11 +1,11 @@
1
1
  # encoding: utf-8
2
2
 
3
- require 'rubocop/rake_task'
3
+ require "rubocop/rake_task"
4
4
 
5
5
  module ReevooCop
6
6
  class RakeTask < RuboCop::RakeTask
7
7
  def run_cli(verbose, options)
8
- require 'reevoocop'
8
+ require "reevoocop"
9
9
  super(verbose, options)
10
10
  end
11
11
  end
@@ -1,5 +1,5 @@
1
1
  # encoding: utf-8
2
2
 
3
3
  module ReevooCop
4
- VERSION = '0.0.6'
4
+ VERSION = "0.0.7"
5
5
  end
data/lib/reevoocop.rb CHANGED
@@ -1,12 +1,12 @@
1
1
  # encoding: utf-8
2
2
 
3
- require 'rubocop'
3
+ require "rubocop"
4
4
 
5
5
  module RuboCop
6
6
  class ConfigLoader
7
7
  class << self
8
8
  def configuration_file_for(_target_dir)
9
- File.join(File.realpath(File.dirname(__FILE__)), 'reevoocop.yml')
9
+ File.join(File.realpath(File.dirname(__FILE__)), "reevoocop.yml")
10
10
  end
11
11
  end
12
12
  end
data/lib/reevoocop.yml CHANGED
@@ -1,7 +1,12 @@
1
1
  LineLength:
2
2
  Max: 120
3
+
4
+ # See https://github.com/reevoo/reevoocop/pull/13
5
+ # * Other metrics like complexity should discorage complexity
6
+ # * Sometimes it is less clear to squeese things on too few lines
3
7
  Metrics/MethodLength:
4
8
  Enabled: false
9
+
5
10
  Documentation:
6
11
  Enabled: false
7
12
  AndOr:
@@ -10,17 +15,46 @@ AndOr:
10
15
  # Allow use of empty lines to visually group code into 'paragraphs'
11
16
  EmptyLines:
12
17
  Enabled: false
18
+
19
+ # Keeping parameters in a line makes them easier to read, but in long lines the
20
+ # parameters look ridiculous if using the "with_first_parameter" option, making
21
+ # it more difficult to read the code
22
+ Style/AlignParameters:
23
+ EnforcedStyle: with_fixed_indentation
24
+
25
+ # Blank lines are useful in separating methods, specs, etc. from one another,
26
+ # and improves the aesthetics of the code. Consequently, we've enabled
27
+ # EmptyLines around blocks and methods. This is less desirable for Classes and
28
+ # Modules where the definitions may be usefully put on consecutive lines, e.g.:
29
+ #
30
+ # module API
31
+ # module Auth
32
+ # class Person
33
+ # ... etc
34
+ #
13
35
  Style/EmptyLinesAroundBlockBody:
14
- Enabled: false
36
+ Enabled: true
15
37
  Style/EmptyLinesAroundClassBody:
16
38
  Enabled: false
17
39
  Style/EmptyLinesAroundMethodBody:
18
- Enabled: false
40
+ Enabled: true
19
41
  Style/EmptyLinesAroundModuleBody:
20
42
  Enabled: false
43
+
44
+
45
+ # See https://github.com/reevoo/reevoocop/issues/10
21
46
  Style/ModuleFunction:
22
47
  Enabled: false
23
48
 
49
+ # See more here: https://viget.com/extend/just-use-double-quoted-ruby-strings
50
+ Style/StringLiterals:
51
+ EnforcedStyle: double_quotes
52
+ Style/StringLiteralsInInterpolation:
53
+ EnforcedStyle: double_quotes
54
+
55
+ # See https://github.com/reevoo/reevoocop/issues/1
56
+ # * For cleaner git diffs
57
+ # * Simpler :sort:
24
58
  TrailingComma:
25
59
  Enabled: true
26
60
  EnforcedStyleForMultiline: comma
data/reevoocop.gemspec CHANGED
@@ -1,24 +1,24 @@
1
1
  # coding: utf-8
2
- lib = File.expand_path('../lib', __FILE__)
2
+ lib = File.expand_path("../lib", __FILE__)
3
3
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
- require 'reevoocop/version'
4
+ require "reevoocop/version"
5
5
 
6
6
  Gem::Specification.new do |spec|
7
- spec.name = 'reevoocop'
7
+ spec.name = "reevoocop"
8
8
  spec.version = ReevooCop::VERSION
9
- spec.authors = ['Ed Robinson']
10
- spec.email = ['ed.robinson@reevoo.com']
11
- spec.summary = 'Like RuboCop only for Reevoo'
12
- spec.description = 'RuboCop patched for to enforce the use of Reevoo Style Guidelines'
13
- spec.homepage = 'http://reevoo.github.io'
14
- spec.license = 'MIT'
9
+ spec.authors = ["Ed Robinson"]
10
+ spec.email = ["ed.robinson@reevoo.com"]
11
+ spec.summary = "Like RuboCop only for Reevoo"
12
+ spec.description = "RuboCop patched for to enforce the use of Reevoo Style Guidelines"
13
+ spec.homepage = "http://reevoo.github.io"
14
+ spec.license = "MIT"
15
15
 
16
16
  spec.files = `git ls-files -z`.split("\x0")
17
17
  spec.executables = spec.files.grep(/^bin\//) { |f| File.basename(f) }
18
18
  spec.test_files = spec.files.grep(/^(test|spec|features)\//)
19
- spec.require_paths = ['lib']
19
+ spec.require_paths = ["lib"]
20
20
 
21
- spec.add_dependency 'rubocop', '0.28.0'
22
- spec.add_development_dependency 'bundler', '~> 1.5'
23
- spec.add_development_dependency 'rake'
21
+ spec.add_dependency "rubocop", "0.28.0"
22
+ spec.add_development_dependency "bundler", "~> 1.5"
23
+ spec.add_development_dependency "rake"
24
24
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: reevoocop
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ed Robinson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-11-18 00:00:00.000000000 Z
11
+ date: 2016-02-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -61,6 +61,7 @@ extensions: []
61
61
  extra_rdoc_files: []
62
62
  files:
63
63
  - ".gitignore"
64
+ - ".travis.yml"
64
65
  - Gemfile
65
66
  - LICENSE.txt
66
67
  - README.md
@@ -91,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
91
92
  version: '0'
92
93
  requirements: []
93
94
  rubyforge_project:
94
- rubygems_version: 2.2.3
95
+ rubygems_version: 2.4.5.1
95
96
  signing_key:
96
97
  specification_version: 4
97
98
  summary: Like RuboCop only for Reevoo