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

Spotless with ratchet #7133

Merged
merged 5 commits into from
Feb 28, 2022
Merged

Spotless with ratchet #7133

merged 5 commits into from
Feb 28, 2022

Conversation

yschimke
Copy link
Collaborator

@yschimke yschimke commented Feb 28, 2022

Configure spotless, with ratchet on modified files.

@yschimke
Copy link
Collaborator Author

Testing with a single change to a local file.

Execution failed for task ':okhttp:spotlessKotlinCheck'.
> The following files had format violations:
      src/commonMain/kotlin/okhttp3/Protocol.kt
          @@ -15,10 +15,9 @@
           ·*/
           package·okhttp3

Co-authored-by: Goooler <wangzongler@gmail.com>
@yschimke
Copy link
Collaborator Author

Breaking on diffplug/spotless#710

@yschimke
Copy link
Collaborator Author

@swankjesse landing to test on master.

@yschimke yschimke merged commit 7039c4a into square:master Feb 28, 2022
@JakeWharton
Copy link
Collaborator

Lgtm

@yschimke
Copy link
Collaborator Author

yschimke commented Mar 1, 2022

Thanks for the setup advice @JakeWharton

Copy link
Collaborator

@swankjesse swankjesse left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@Goooler Goooler left a comment

Choose a reason for hiding this comment

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

LGTM

@@ -173,6 +173,23 @@ subprojects {
}
}

apply(plugin = "com.diffplug.spotless")
Copy link
Collaborator

Choose a reason for hiding this comment

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

We should be loading the config from .editorconfig, rather than partially duplicating it here. As-is the two disagree on where java.* imports go.

Copy link
Contributor

@Goooler Goooler Mar 10, 2022

Choose a reason for hiding this comment

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

But it seems haven't supported yet. See diffplug/spotless#142

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.

4 participants