Add and configure rubocop and rubocop-rspec
This commit is contained in:
parent
e3ef933b4f
commit
b8d663ca00
22
.rubocop.yml
22
.rubocop.yml
@ -1,13 +1,33 @@
|
||||
require: rubocop-rspec
|
||||
|
||||
AllCops:
|
||||
TargetRubyVersion: 3.2
|
||||
DisplayCopNames: true
|
||||
NewCops: enable
|
||||
|
||||
# ----------------------- Style -----------------------
|
||||
|
||||
Style/StringLiterals:
|
||||
Enabled: true
|
||||
EnforcedStyle: double_quotes
|
||||
EnforcedStyle: single_quotes
|
||||
|
||||
Style/StringLiteralsInInterpolation:
|
||||
Enabled: true
|
||||
EnforcedStyle: double_quotes
|
||||
|
||||
# ----------------------- Layout ----------------------
|
||||
|
||||
Layout/LineLength:
|
||||
Max: 120
|
||||
|
||||
# ---------------------- Metrics ----------------------
|
||||
|
||||
Metrics/BlockLength:
|
||||
Exclude:
|
||||
- '**/*_spec.rb'
|
||||
- nostr.gemspec
|
||||
|
||||
# ----------------------- RSpec -----------------------
|
||||
|
||||
RSpec/ExampleLength:
|
||||
Enabled: false
|
||||
|
@ -13,6 +13,7 @@ Gem::Specification.new do |spec|
|
||||
spec.homepage = "https://github.com/wilsonsilva/nostr"
|
||||
spec.license = "MIT"
|
||||
spec.required_ruby_version = ">= 3.2.0"
|
||||
spec.metadata["rubygems_mfa_required"] = "true"
|
||||
|
||||
spec.metadata["homepage_uri"] = spec.homepage
|
||||
spec.metadata["source_code_uri"] = "https://github.com/wilsonsilva/nostr"
|
||||
@ -33,4 +34,5 @@ Gem::Specification.new do |spec|
|
||||
spec.add_development_dependency "rake", "~> 13.0"
|
||||
spec.add_development_dependency "rspec", "~> 3.12"
|
||||
spec.add_development_dependency "rubocop", "~> 1.42"
|
||||
spec.add_development_dependency "rubocop-rspec", "2.16"
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user