New parameter failOnFormat
Closed this issue · 2 comments
Is your feature request related to a problem? Please describe.
The developers IDE may not format according to the team-rules. Assuming this scenario:
- The team-formatting-rules say we have a max-line-length of 120.
- A developer X made no code-change but formatted a source-file wrong having 100 max-line-length.
- The developer X commit/push the source-modifications without calling
formatter:format
. - Then a review of the source-file (using upsource for example) is intensive because almost every second line has pseudo-changes.
Today the 4th step is 100% manual work and may or may not lead to a 100% rejection of the developers commit.
This leads to a inharmoniousness between the committer and the reviewer. Inharmoniousness between collegues should be avoided.
Describe the solution you'd like
I like to have a jenkins-build that fail and notify the developers if they did not format the source according to the team-formatting-rules.
Describe alternatives you've considered
Intervention of the teamlead to blame the villain to force someones discipline using a whip or other painful furniture.
Describe the solution you'd like I like to have a jenkins-build that fail and notify the developers if they did not format the source according to the team-formatting-rules.
This is possible using formatter:validate
Here's one example of this being deployed in another project:
- Here's a GitHub Actions run that activates a validation profile
- Here is the corresponding profile in the pom.xml
Describe alternatives you've considered Intervention of the teamlead to blame the villain to force someones discipline using a whip or other painful furniture.
LOL.
Gr8 tnx