Click here to Skip to main content
15,891,841 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have a project and i am using maven. It is working correctly, but i have to stop some of the imports that are done automatically using this code

<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>2.3.6</version>
<extensions>true</extensions>
<configuration>
<instructions>
...
<excludeDependencies>false</excludeDependencies>
<Embed-Dependency>*;scope=compile|runtime;inline=false;</Embed-Dependency>
<Import-Package>!groovy.lang,!javax.jms,!javax.mail,!javax.mail.internet,!jav
ax.management,!javax.naming,!javax.naming.spi,!javax.net,!javax.net.ssl,!jav
ax.servlet,!javax.servlet.http,!javax.sql,!javax.transaction.xa,!javax.xml.
bind.annotation,!javax.xml.parsers,!javax.xml.stream,!javax.xml.transform,!.......,*</Import-Package>


By this i eliminated the unnecessary imports and it works fine. otherwise it was giving an error from the unnecessary imports. Is there a way to exclude transitive dependencies, or otherwise? maybe someone met this problem before?

Thank you in advance.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900