开发者

Exclude whole parent dependency

The parent pom has got the following dependencies

<dependencies>
    <dependency>
        <groupId>tv.my</groupId>
        <artifactId>cable</artifactId>
    </dependency>
    <dependency>
        <groupId>tv.my</groupId>
        <artifactId>sat</artifactId>
    </dependency>
</dependencies>

In the child's pom I want to exclude the whole tv.my:sat dependency. Maybe with something like this:

<dependencies>
    <excludes>
        <exlude>
            <dependency>
                <groupId>tv.my</groupI开发者_如何学JAVAd>
                <artifactId>cable</artifactId>
            </dependency>
        <exlude>
    <excludes>
</dependencies>

Is this somehow possible?


You have no choice but to repair the parent POM to use dependencyManagement correctly. Dependencies in parent poms are almost never a good idea, and once you use a parent that has them, you are stuck.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜