Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce rubocop-on-rbs #1899

Merged
merged 5 commits into from
Sep 13, 2024
Merged

Introduce rubocop-on-rbs #1899

merged 5 commits into from
Sep 13, 2024

Conversation

ksss
Copy link
Collaborator

@ksss ksss commented Jun 18, 2024

I propose to introduce rubocop-on-rbs.

This is a lint tool for RBS file.

This tool automates trivial indentation and style remarks during review.

Examples of remarks from RuboCop

image

Departments

This PR enables RBS/Layout and RBS/Lint departments.

  • RBS/Layout provides feedback on indentation and spacing, which does not affect the semantics of RBS at all.
  • RBS/Lint points out important issues such as syntax errors and unused type variables.

See also all documentation.
https://github.com/ksss/rubocop-on-rbs/blob/main/docs/modules/ROOT/pages/cops.adoc

This introduction does not use RBS/Style cops.
RBS/Style will be discussed and introduced one by one later.

Notice

I'm not sure that running the RuboCop task on both head and 3.3 in CI.
Probably for the purpose of running rubycw with head.

ksss added 3 commits June 18, 2024 17:24
Applied followings

- RBS/Layout/SpaceAroundOperators
- RBS/Layout/OverloadIndentation
- RBS/Layout/SpaceBeforeOverload
- RBS/Layout/ExtraSpacing
- RBS/Layout/SpaceAroundBraces
@ksss ksss marked this pull request as ready for review June 18, 2024 10:06
Copy link
Member

@soutaro soutaro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏 👏

@soutaro soutaro added this pull request to the merge queue Sep 13, 2024
Merged via the queue into ruby:master with commit c64bc1d Sep 13, 2024
19 checks passed
@ksss ksss deleted the rubocop-on-rbs branch September 15, 2024 13:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants