-
Notifications
You must be signed in to change notification settings - Fork 39
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
Manual formatting/validating misses files #27
Comments
Manual formatter and validator browse directories provided by You have to make Maven consider your Found on https://www.testwithspring.com/lesson/running-integration-tests-with-maven/ : <plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.12</version>
<executions>
<execution>
<id>add-integration-test-sources</id>
<phase>generate-test-sources</phase>
<goals>
<goal>add-test-source</goal>
</goals>
<configuration>
<sources>
<source>src/integration-test/java</source>
</sources>
</configuration>
</execution>
</executions>
</plugin> |
Hi, thanks for the response. I did have When I run
When I run |
Ok.
Without doing any further investigation I would say that the issue comes from the fact that you execute the formatter/validator outside of any maven phase. Because of that, build-helper-maven-plugin is not executed before manual formatter/validator.
Please try to bind build-helper-maven-plugin to the initialize phase and try again.
Réda Housni Alaoui
… Le 7 nov. 2019 à 17:14, Dillan Cooke ***@***.***> a écrit :
Hi, thanks for the response.
I did have build-helper-maven-plugin configured that way, though I was using an older version of it (1.9.1). I tried updating to 1.12, and also to the newest version (3.0.0), but got the same results with all versions.
When I run mvn clean install, build fails with this error:
[ERROR] Failed to execute goal com.cosium.code:maven-git-code-format:1.32:validate-code-format (validate-code-format) on project pinery-client: .../pinery/pinery-client/src/it/java/ca/on/oicr/pinery/client/AttributeNameClientIT.java is not correctly formatted ! -> [Help 1]
When I run mvn git-code-format:validate-code-format -DglobPattern=**/*, it is successful, and none of the files in src/it/java/ are checked.
Project: https://github.com/oicr-gsi/pinery
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
I just performed tests on your project.
includes If you are looking for a more elegant solution, I suggest you bring the subject to the Maven team. |
Thanks for the info. I just tried leaving the
or
|
Hello,
My build was failing due to incorrectly formatted code in files under
.../src/it/java/
. When I manually ran the formatter (mvn git-code-format:format-code -DglobPattern=**/*
), it did not format these files. When I manually ran the validator (mvn git-code-format:validate-code-format -DglobPattern=**/*
), it did not check these files, and completed successfully.I was able to get around the issue by changing each of the affected files and then committing them. The formatter run by pre-commit hook did format the affected files.
My plugin config from
pom.xml
:The text was updated successfully, but these errors were encountered: