Skip to content

Conversation

ydah
Copy link
Contributor

@ydah ydah commented Jan 4, 2024

This PR removes an unnecessary setting in Layout/EndAlignment.

As shown below for the default Layout/EndAlignment' setting, the AutoCorrect' setting is not needed for `Layout/EndAlignment'. AutoCorrect is already enabled without this setting.

Layout/EndAlignment:
  Description: 'Align ends correctly.'
  Enabled: true
  VersionAdded: '0.53'
  # The value `keyword` means that `end` should be aligned with the matching
  # keyword (`if`, `while`, etc.).
  # The value `variable` means that in assignments, `end` should be aligned
  # with the start of the variable on the left hand side of `=`. In all other
  # situations, `end` should still be aligned with the keyword.
  # The value `start_of_line` means that `end` should be aligned with the start
  # of the line which the matching keyword appears on.
  EnforcedStyleAlignWith: keyword
  SupportedStylesAlignWith:
    - keyword
    - variable
    - start_of_line
  Severity: warning

Refs: https://github.com/rubocop/rubocop/blob/9dd56ef7981d8d8a1a466217bd2d65787f0374c7/config/default.yml#L692-L708

@dhh dhh merged commit 63a7608 into rails:main Sep 15, 2024
@ydah ydah deleted the remove-unnecessary-setting branch March 3, 2025 09:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants