Skip to content

Commit

Permalink
Add the editorconfig maven plugin
Browse files Browse the repository at this point in the history
so that the editorconfig settings can be checked with Maven

Related to #476
  • Loading branch information
egli committed Nov 1, 2021
1 parent 2010423 commit cf4d7c4
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ The nordic migrator can be built with Maven,
either directly (with for instance `mvn clean package`),
or indirectly with Docker (with for instance `docker build .`).

To check the code conventions use a special Maven plugin: `mvn
editorconfig:check`. The conventions are defined in `.editorconfig`
which is picked up by most editors, see https://editorconfig.org/. You
can also fix the conventions in all files with `mvn
editorconfig:format`.

Releasing
---------

Expand Down
22 changes: 22 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,28 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.ec4j.maven</groupId>
<artifactId>editorconfig-maven-plugin</artifactId>
<version>0.1.1</version>
<executions>
<execution>
<id>check</id>
<phase>verify</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
<configuration>
<excludes>
<!-- You can exclude further files from processing: -->
<exclude>src/test/**/*.epub</exclude>
<exclude>**/*.otf</exclude>
<exclude>documentation/*.odg</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</build>

Expand Down

0 comments on commit cf4d7c4

Please sign in to comment.