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

checkstyle 8.36 -> 8.37 (and keep it up to date using excavator) #1546

Merged
merged 5 commits into from
Nov 17, 2020

Conversation

iamdanfox
Copy link
Contributor

Before this PR

@fawind is putting in a bunch of work to allow people to use some more 'cutting edge' java syntax (e.g. records). Checkstyle seems to be landing a lot of bugfixes related to these new features at the moment, e.g.

https://checkstyle.sourceforge.io/releasenotes.html

Currently, as the checkstyle version is read out of a private static field, it has to be manually updated. This means we're probably going to miss bugfixes until someone complains about them.

After this PR

==COMMIT_MSG==
checkstyle 8.36 -> 8.37, to benefit from some bugfixes to do with new java language features (e.g. records)
==COMMIT_MSG==

Possible downsides?

  • we don't read the changelog every time a new rule is introduced, so we might accidentally roll out some new strictness before validating it. I think we can just eat this risk and disable/customize the rule if we get feedback.

@changelog-app
Copy link

changelog-app bot commented Nov 16, 2020

Generate changelog in changelog/@unreleased

Type

  • Feature
  • Improvement
  • Fix
  • Break
  • Deprecation
  • Manual task
  • Migration

Description

checkstyle 8.36 -> 8.37, to benefit from some bugfixes to do with new java language features (e.g. records)

Check the box to generate changelog(s)

  • Generate changelog entry

@policy-bot policy-bot bot requested a review from ferozco November 16, 2020 16:54
@iamdanfox iamdanfox requested review from fawind and removed request for ferozco November 16, 2020 16:54

if (gradle.startParameter.isWriteDependencyLocks()) {
gradle.startParameter.taskNames += 'writeCheckstyleVersion'
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

an alternative approach here is to generate the resource just-in-time as a dependency of the ./gradlew idea task... no super strong opinions, i just kinda like that this one is reasonably bulletproof

Copy link
Contributor

Choose a reason for hiding this comment

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

Also no strong opinion but I like doing this as part of "--write-locks" as people already expect their version numbers to change through this run.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yeah, in general I hate it when i open intellij and something crucial is missing because it failed to generate somehow. this seemed more idiot dan-proof

Copy link
Contributor

@fawind fawind left a comment

Choose a reason for hiding this comment

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

nice!

@bulldozer-bot bulldozer-bot bot merged commit bbbaf43 into develop Nov 17, 2020
@bulldozer-bot bulldozer-bot bot deleted the dfox/keep-checkstyle-up-to-date branch November 17, 2020 08:30
@svc-autorelease
Copy link
Collaborator

Released 3.51.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants