Skip to content

Commit

Permalink
[Ruby] Refactor/gherkin autofix cops (#266)
Browse files Browse the repository at this point in the history
* Autofix and manual tidy ups of token_formatter_builder with Layout/Alignment

* AF: Layout/ClosingParenthesisLocation

* AF: Layout/ReturnHaveExtraLine

* AF: Layout/SpaceAroundAttributeAccessors

* Disable naming cop not being prevented by config generator

* AF: EmptyLinesAroundClassBody

* AF All remaining EmptyLine cops

* AF: Indentation

* AF: All SpaceAround cops

* AF: All Space inside cops

* AF: Style/RexcuedExceptionVariableName

* AF: Style/GlobalStdInStream

* AF: MethodCallWithRedundantParens

* AF: Style/ParenthesesAroundCondition

* Re-generate TODO file

* Manual fixes for bin script

* Add changelog entry

* Remove changes made to parser.rb

* Regen config pending parser fixes

* AF 2 different Layout Indentation cops

* AF: Layout/LeadingCommentSpace

* Fix up Lint/NonLocalExitFromIterator

* Fix up Lint/UselessAccessModifier

* Fix up name of param inside yielding method

* Fix up conditional assignment issue in bin package

* AF: IfUnlessModifier

* AF: Style/NegatedIf

* AF Style/Regex

* AF: RedundantReturn partially

* Partial Autofix for some files of Style/StringLiterals

* Partial autofix for TrailingComma in arrays/hashes

* Regen the TODO file

* Update berp version in docs

* Updated razor and generation debug with gaspar

* Revert "Updated razor and generation debug with gaspar"

This reverts commit e7adc10.

* allow extra indent for lookahead hint

* remove spaces in newline

---------

Co-authored-by: Gáspár Nagy <gaspar.nagy@gmail.com>
  • Loading branch information
luke-hill and gasparnagy committed Sep 16, 2024
1 parent ea62dcf commit 72c973b
Show file tree
Hide file tree
Showing 24 changed files with 553 additions and 760 deletions.
7 changes: 2 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,7 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt

## [Unreleased]
### Added
- [PHP] update dependency messages up to v26 ([#268](https://github.com/cucumber/gherkin/pull/268))
- [JavaScript] update dependency messages up to v26 ([#268](https://github.com/cucumber/gherkin/pull/268))
- [JavaScript] update dependency messages up to at least v19.1.4 ([#268](https://github.com/cucumber/gherkin/pull/268))
- [Java] update dependency messages up to v26 ([#269](https://github.com/cucumber/gherkin/pull/269))
- [Ruby] update dependency messages up to v26 ([#267](https://github.com/cucumber/gherkin/pull/267))
- [PHP, Java, Ruby, JavaScript] update dependency messages up to v26

### Changed
- [.NET] Drop unsupported frameworks. Now supported target frameworks are .NET 8, .NET Standard 2.0 ([#265](https://github.com/cucumber/gherkin/pull/265))
Expand All @@ -21,6 +17,7 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
- [.NET] Adopt c# 10 ImplicitUsings
- [.NET] Replace TinyJson to System.Text.Json
- [.NET] Enable warnings as errors
- [Ruby] Initial rubocop autofixes (Mainly to style) ([#266](https://github.com/cucumber/gherkin/pull/266))

## [29.0.0] - 2024-08-12
### Added
Expand Down
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ docker run --rm --interactive --tty --volume ".:/app" berp-env
*Or* install on your system

* .NET 5.0 (to run `berp` to generate parsers)
* `berp` (install with `dotnet tool update Berp --version 1.3.0 --tool-path /usr/bin` )
* `berp` (install with `dotnet tool update Berp --version 1.4.0 --tool-path /usr/bin` )
* `make`
* `diff`

Expand All @@ -47,7 +47,7 @@ make generate

## Adding or updating an i18n language

1) Edit `gherkin-langauges.json`.
1) Edit `gherkin-languages.json`.

2) Distribute the changes to the different parser implementations:

Expand Down
4 changes: 4 additions & 0 deletions ruby/.rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,7 @@ AllCops:
# Display cop name / style guide references
DisplayCopNames: true
DisplayStyleGuide: true

# TODO: [LH] - Investigate this in terms of it not being fixed in rubocop?
Naming/MethodName:
Enabled: false
Loading

0 comments on commit 72c973b

Please sign in to comment.