rubocop-ordered_methods 0.2 → 0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/config/default.yml +4 -0
- data/lib/rubocop/ordered_methods.rb +15 -0
- data/lib/rubocop-ordered_methods.rb +3 -0
- data/rubocop-ordered_methods.gemspec +1 -1
- metadata +3 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 33871b68e39c03de6c12f462dc732d282489b190bdaedca681f955c60a27c20c
|
4
|
+
data.tar.gz: c9c22948ef1db00f774d8fcfdf0cd2f60422da6c44b16a3e9430bdef42c86efb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 571d2b28004397aff91256be2d4b153255870d5b7a4bd8877c3956003e3d73959e5bca95fa7b26901ccf43ee343a5b722eae24dea79540948cbe48a3d016d3bb
|
7
|
+
data.tar.gz: 3fe6b38928ed8c4ee6b5c08d27e3ba4e84277f98e7dfa9fe2e74cca570874b4f63caed8ba40ef5e8799d22bd6ae39db4a619beaddde5cc5328d9685e02525809
|
data/config/default.yml
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
module RuboCop
|
2
|
+
module OrderedMethods
|
3
|
+
PROJECT_ROOT = Pathname.new(__dir__).parent.parent.expand_path.freeze
|
4
|
+
CONFIG_DEFAULT = PROJECT_ROOT.join("config", "default.yml").freeze
|
5
|
+
|
6
|
+
def self.inject_defaults!
|
7
|
+
path = CONFIG_DEFAULT.to_s
|
8
|
+
hash = ConfigLoader.send(:load_yaml_configuration, path)
|
9
|
+
config = Config.new(hash, path)
|
10
|
+
puts "configuration from #{path}" if ConfigLoader.debug?
|
11
|
+
config = ConfigLoader.merge_with_default(config, path)
|
12
|
+
ConfigLoader.instance_variable_set(:@default_configuration, config)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubocop-ordered_methods
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.3'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shane Cavanaugh
|
@@ -83,9 +83,11 @@ files:
|
|
83
83
|
- README.md
|
84
84
|
- Rakefile
|
85
85
|
- bin/console
|
86
|
+
- config/default.yml
|
86
87
|
- lib/rubocop-ordered_methods.rb
|
87
88
|
- lib/rubocop/cop/correctors/ordered_methods_corrector.rb
|
88
89
|
- lib/rubocop/cop/layout/ordered_methods.rb
|
90
|
+
- lib/rubocop/ordered_methods.rb
|
89
91
|
- rubocop-ordered_methods.gemspec
|
90
92
|
homepage: https://github.com/shanecav84/rubocop-ordered_methods
|
91
93
|
licenses:
|