用P2卸载功能



i*m尝试使用P2操作从Eclipse卸载功能。

我正在做什么来实现这一目标:

OperationFactory of = new OperationFactory();
ProfileChangeOperation operation;
//toInstall = List<IVersionedId> only containing the feature
operation = of.createUninstallOperation(toInstall, repos, monitor);

之后,我正在运行操作。

该功能将成功卸载,但是插件是此功能的一部分,这些功能不会保留其他功能/插件的依赖。这是不需要的行为。

我已经尝试添加

org.eclipse.equinox.p2.ui.sdk.scheduler/gcOnStartup=true 

到我的产品属性。

我也尝试运行

eclipse.exe -application org.eclipse.equinox.p2.garbagecollector.application -profile DefaultProfile

无效。

我添加了

-profileProperties org.eclipse.update.install.features=true

我的程序参数。无效。

此外,我尝试以编程方式实现GC,这也没有效果。

任何想法如何解决?P2安装功能,包括所有因插件。我希望它在卸载操作上的行为相同。

仅在用tycho buildig时出现问题。我通过在开始级别4中添加org.eclipse.update.configurator并自动启动= FALSE我的产品启动级别来解决此问题。

附加,我在产品配置中的属性中添加了带有false的org.eclipse.update.reconcile

通过使用这种特殊的设置组合,卸载的插件将不再显示。

最新更新