Excluding “provided” dependencies from Maven assembly

后端 未结 4 1298
长情又很酷
长情又很酷 2020-12-25 13:49

I am trying to use the Maven assembly plugin to build a jar-with-dependencies, except those that have provided scope.

I have copied the jar-with-dependencie

4条回答
  •  失恋的感觉
    2020-12-25 14:48

    In theory the tags "ignoreNonCompile" and "excludeScope" should help, but be warned that they do not necessarily work properly.

    With maven3 and the maven-dependency-plugin 2.4, one solution is:

    
    junit,mockito-all
    true
    
    

提交回复
热议问题