【发布时间】:2017-05-24 15:57:05
【问题描述】:
我正在使用 maven-bundle-plugin 为 OSGi 容器生成 MANIFEST.MF。
<build>
<plugins>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<instructions>
<Export-Package>com.example.mypackage</Export-Package>
</instructions>
</configuration>
<executions>
<execution>
<id>bundle-manifest</id>
<phase>process-classes</phase>
<goals>
<goal>manifest</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
但是,在 f.g Maven/Update Project 或 Clean/Build 之后,该清单文件被 Eclipse (4.6.1 Neon) 破坏(覆盖)。
是否有可能让 Eclipse 以某种方式了解 maven 插件,而不破坏它们的输出?我应该设置什么来防止这种(错误)行为?
如果这个问题不能用 Eclipse 来解决,例如,它用 IntelliJ 会更好吗? IDE 中的 OSGi 支持对我来说非常重要...
【问题讨论】: