Skip to content

google-java-format and indentation settings #420

@Puneetha17

Description

@Puneetha17

We would like to use Google Java Format and still enforce 4 space indentation. Ideal way of doing this would be to use both googleJavaFormat("1.7") and indentWithSpaces(4) in the order and expect spotless to apply them in the given order and get the required result.

    java {
            removeUnusedImports()
            googleJavaFormat("1.7")
            indentWithSpaces(4)
            trimTrailingWhitespace()
            endWithNewline()
            paddedCell()
        }

Is there a way to enforce order of the execution of spotless to get the best of both?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions