Skip to content
This repository has been archived by the owner on Mar 17, 2021. It is now read-only.

Automatically format pom.xml #474

Open
2 tasks
robertklaus-bosch opened this issue Mar 25, 2020 · 0 comments
Open
2 tasks

Automatically format pom.xml #474

robertklaus-bosch opened this issue Mar 25, 2020 · 0 comments

Comments

@robertklaus-bosch
Copy link

Summary of the Feature

With my last contribution I had to struggle with changes that came from upstream. They were due to formatting issues in pom.xml.
As a suggestion: you could use the sortpom-maven-plugin to do this.
I other projects we decided to always format the code. In order verify that no unformatted file is introduced in the main stream, the pull request build executed a profile with the goal verify instead to fail the build.

Example:

<plugin>
        <groupId>com.github.ekryd.sortpom</groupId>
        <artifactId>sortpom-maven-plugin</artifactId>
        <executions>
          <execution>
            <id>sort pom</id>
            <goals>
              <goal>sort</goal>
            </goals>
            <phase>process-sources</phase>
          </execution>
        </executions>
      </plugin>

This is up to you. Consider this more of a suggestion.

Acceptance Criteria

In case you want to do this

  • a pom.xml is always formatted the same way regardless of IDE/Editor used
  • formatting can be performed by build system

Definition of Done

  • Acceptance criteria fulfilled
  • A PR is created, the CI infrastructure reports green
  • The PR is reviewed and approved
  • No TODOs left in the code unless explained in the ticket, if something else is still open, this is summarized in a comment in the issue
  • Test cases are created to prove the functionality of the feature
  • Documentation is updated
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant