Skip to content

Commit

Permalink
Introduce rubocop-on-rbs
Browse files Browse the repository at this point in the history
  • Loading branch information
ksss committed Jun 18, 2024
1 parent 9188d9f commit 26e04eb
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 2 deletions.
26 changes: 25 additions & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
require: rubocop-rubycw
require:
- rubocop-rubycw
- rubocop-on-rbs

AllCops:
TargetRubyVersion: 3.0
DisabledByDefault: true
Expand All @@ -9,6 +12,27 @@ Rubycw/Rubycw:
Exclude:
- 'test/**/*_test.rb'

RBS:
Enabled: true
RBS/Layout:
Enabled: true
Exclude:
- 'sig/**/*'
- 'test/**/*'
RBS/Layout/CommentIndentation:
Exclude:
- core/string.rbs
RBS/Lint:
Enabled: true
Exclude:
- 'sig/**/*'
- 'test/**/*'
RBS/Style:
Enabled: false
Exclude:
- 'sig/**/*'
- 'test/**/*'

Lint/DuplicateMethods:
Enabled: true
Include:
Expand Down
1 change: 1 addition & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ gem "test-unit"
gem "rspec"
gem "rubocop"
gem "rubocop-rubycw"
gem "rubocop-on-rbs"
gem "json"
gem "json-schema"
gem "goodcheck"
Expand Down
6 changes: 6 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,10 @@ GEM
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.31.3)
parser (>= 3.3.1.0)
rubocop-on-rbs (0.6.0)
rbs (~> 3.5)
rubocop (~> 1.41)
zlib
rubocop-rubycw (0.1.6)
rubocop (~> 1.0)
ruby-progressbar (1.13.0)
Expand Down Expand Up @@ -145,6 +149,7 @@ GEM
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (2.5.0)
zlib (3.1.1)

PLATFORMS
ruby
Expand Down Expand Up @@ -175,6 +180,7 @@ DEPENDENCIES
rdoc
rspec
rubocop
rubocop-on-rbs
rubocop-rubycw
stackprof
steep (~> 1.7.1)
Expand Down
8 changes: 7 additions & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,13 @@ task :raap => :compile do
end

task :rubocop do
sh "rubocop --parallel"
format = if ENV["CI"]
"github"
else
"progress"
end

sh "rubocop --parallel --format #{format}"
end

namespace :generate do
Expand Down

0 comments on commit 26e04eb

Please sign in to comment.