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

Maven plugin has no endWithNewLine option #2100

Open
5 of 6 tasks
Petkomat opened this issue Apr 16, 2024 · 0 comments
Open
5 of 6 tasks

Maven plugin has no endWithNewLine option #2100

Petkomat opened this issue Apr 16, 2024 · 0 comments

Comments

@Petkomat
Copy link

Petkomat commented Apr 16, 2024

Summary

Maven plugin has no option endWithNewLine for sortPom in the current version (2.43.0) although README mentions it (link to the jar here).

I decopmpiled it and indeed, there is no such @Parameter in the SortPom class. The error after mvn spotless:apply:

[ERROR] Failed to execute goal com.diffplug.spotless:spotless-maven-plugin:2.43.0:apply (default-cli) on project foo: Unable to parse configuration of mojo com.diffplug.spotless:spotless-maven-plugin:2.43.0:apply for parameter endWithNewLine: Cannot find 'endWithNewLine' in class com.diffplug.spotless.maven.pom.SortPom -> [Help 1]

Maven version & Operating system version

mvn --version outputs

Apache Maven 3.9.5 (57804ffe001d7215b5e7bcb531cf83df38f93546)
Maven home: C:\Program Files\Maven\apache-maven-3.9.5
Java version: 17.0.8, vendor: Oracle Corporation, runtime: C:\Program Files\Java\jdk-17
Default locale: en_US, platform encoding: Cp1252
OS name: "windows 11", version: "10.0", arch: "amd64", family: "windows"

Spotless version

2.43.0

Spotless configuration

<plugin>
   <groupId>com.diffplug.spotless</groupId>
   <artifactId>spotless-maven-plugin</artifactId>
   <version>2.43.0</version>
   <configuration>
      <pom>
        <sortPom>
          <endWithNewLine>true</endWithNewLine>
        </sortPom>
      </pom>
   </configuration>
</plugin>

Checklist

  • summary of problem
  • Gradle or Maven version
  • spotless version
  • operating system and version
  • copy-paste your full Spotless configuration block(s), and a link to a public git repo that reproduces the problem if possible
  • copy-paste the full content of any console errors emitted by gradlew spotless[Apply/Check] --stacktrace
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

No branches or pull requests

1 participant