Skip to content

Remove JvmLocalCache now that everything is round-trippable on its own#2088

Merged
nedtwigg merged 8 commits intomainfrom
feat/remove-live-cache
Apr 7, 2024
Merged

Remove JvmLocalCache now that everything is round-trippable on its own#2088
nedtwigg merged 8 commits intomainfrom
feat/remove-live-cache

Conversation

@nedtwigg
Copy link
Copy Markdown
Member

@nedtwigg nedtwigg commented Apr 4, 2024

@nedtwigg nedtwigg marked this pull request as ready for review April 4, 2024 20:05
@nedtwigg nedtwigg requested a review from Goooler April 4, 2024 20:05
Comment thread plugin-gradle/src/main/java/com/diffplug/gradle/spotless/SpotlessTask.java Outdated
Copy link
Copy Markdown
Member

@jbduncan jbduncan left a comment

Choose a reason for hiding this comment

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

Other than @Goooler's comment and my nit-picking comment below, this PR LGTM!

void whitespaceProblem() throws Exception {
Bundle spotless = create(setFile("testFile").toContent("A \nB\t\nC \n"));
spotless.task.addStep(FormatterStep.createNeverUpToDate("trimTrailing", input -> {
spotless.task.setSteps(List.of(FormatterStep.createNeverUpToDate("trimTrailing", input -> {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm tempted to revert this code change and all other addStep -> setStep changes. WDYT?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I can see an argument for setSteps(FormatterStep... steps) to remove the manual List.of, but I think the mutable-naming addStep is bad. It's used only for a few tests, which is why I just did the List.of.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Fair enough! I have no strong opinions either way, so I'm happy to continue with setSteps.

@nedtwigg nedtwigg merged commit 7262511 into main Apr 7, 2024
@nedtwigg nedtwigg deleted the feat/remove-live-cache branch April 7, 2024 22:45
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.

3 participants