I build library which use spring-boot-autoconfigure to configure spring context. I build project by maven config in Intelij and it work perfect, but when i run mvn clean install
in terminal maven throw errors that it is impossible to find any method, classes etc. Project is library so build configuration cannot include any main path.
This is my maven config
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
</plugin>
</plugins>
</build>
The command which intellij execute in maven clean install config look like this
<java-path> -Dmaven.multiModuleProjectDirectory=<project-root-dir-path> -Dmaven.home=<intellij-maven-path> -Dclassworlds.conf=/.../JetBrains/Toolbox/apps/IDEA-U/ch-0/183.5429.30/plugins/maven/lib/maven3/bin/m2.conf -javaagent:/.../JetBrains/Toolbox/apps/IDEA-U/ch-0/183.5429.30/lib/idea_rt.jar=37847:/.../JetBrains/Toolbox/apps/IDEA-U/ch-0/183.5429.30/bin -Dfile.encoding=UTF-8 -classpath /.../JetBrains/Toolbox/apps/IDEA-U/ch-0/183.5429.30/plugins/maven/lib/maven3/boot/plexus-classworlds-2.5.2.jar org.codehaus.classworlds.Launcher -Didea.version=2018.3.4 clean install
The dots in paths are my system path to JetBrains directory.
Can anyone give me tip to configure this maven project to build jar by clean install
. Remember that there is no main method because it is only library project.