Last active
August 9, 2020 19:47
-
-
Save beyondxscratch/0b1e0379d7d84f786c51b533ee2ad563 to your computer and use it in GitHub Desktop.
Maven Enforcer Plugin to seal a domain in Hexagonal Architecture
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<plugin> | |
<artifactId>maven-enforcer-plugin</artifactId> | |
<executions> | |
<execution> | |
<goals> | |
<goal>enforce</goal> | |
</goals> | |
<configuration> | |
<rules> | |
<bannedDependencies> | |
<excludes> | |
<exclude>*</exclude> <!-- forbids non domain dependencies --> | |
</excludes> | |
<includes> | |
<!-- but allow kotlin dependencies--> | |
<include>org.jetbrains.kotlin:*</include> | |
<include>org.jetbrains:annotations</include> | |
<!-- and test dependencies--> | |
<include>*:*:*:*:test</include> | |
</includes> | |
</bannedDependencies> | |
</rules> | |
</configuration> | |
</execution> | |
</executions> | |
</plugin> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment