Conversation
9799dc4 to
d6a0e59
Compare
Member
|
Mabye spotless ? https://github.com/diffplug/spotless |
Member
Author
Wait for another PR - I have success with palantir-java-format. That is a) more maintained and b) seems to work well and c) has better formatting than GJF: (1) google-java-format output: private static void configureResolvedVersionsWithVersionMapping(Project project) {
project.getPluginManager()
.withPlugin(
"maven-publish",
plugin -> {
project.getExtensions()
.getByType(PublishingExtension.class)
.getPublications()
.withType(MavenPublication.class)
.configureEach(
publication ->
publication.versionMapping(
mapping -> {
mapping.allVariants(
VariantVersionMappingStrategy
::fromResolutionResult);
}));
});
}(1) palantir-java-format output: private static void configureResolvedVersionsWithVersionMapping(Project project) {
project.getPluginManager().withPlugin("maven-publish", plugin -> {
project.getExtensions()
.getByType(PublishingExtension.class)
.getPublications()
.withType(MavenPublication.class)
.configureEach(publication -> publication.versionMapping(mapping -> {
mapping.allVariants(VariantVersionMappingStrategy::fromResolutionResult);
}));
});
}
|
Member
Author
|
New try at #663 |
# Conflicts: # .github/workflows/tests.yml
Member
Author
|
I applied the binary from https://github.com/google/google-java-format/releases/tag/v1.24.0 MINGW64 /c/git-repositories/jabref (add-gjf)
$ find . -name "*.java" -exec /c/Users/koppor/Downloads/google-java-format_windows-x86-64.exe -r -a --skip-reflowing-long-strings --skip-javadoc-formatting "{}" \; |
Member
Author
|
OMG - the windows binary of GJF behaves differently to the JAR -- google/google-java-format#1171 |
Member
Author
|
Palantir is maintained again. GJF is not that good. Closing. For reference: Main diff: #661 (comment) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I am so fed up that
Thus, I am looking for good autoformatting tools. The most prominent tool with style guide is Google's:
This PR adds it.
Let's hope for the best that the reformatting action a) really adds a new commit and b) the contributors will be able to pull these changes 😅🙈
I am aware, that there is no maintained gradle plugin.
I am also aware, that there is no AOSP support for Eclipse since 5 years (google/google-java-format#251), but maybe, this will be resolved.
One needs to run it twice for coments: google/google-java-format#211
Blockers
Mandatory checks
CHANGELOG.mddescribed in a way that is understandable for the average user (if applicable)