【问题标题】:Uninstalling an (obsolete) Eclipse fragment during upgrade在升级期间卸载(过时的)Eclipse 片段
【发布时间】:2011-10-26 15:22:09
【问题描述】:

我有一个已过时的片段,我想创建一个更新来卸载该片段。我猜想正确的方法是将片段视为一个包,因此我将以下内容添加到包含安装程序操作的插件的 p2.inf 中:

instructions.install = \
    uninstallBundle(bundle:com.iar.cdt.arm.debugger.drivers.win32); \
    uninstallBundle(bundle:com.iar.ide.debugger.kernel.win32)

instructions.install.import \
    org.eclipse.equinox.p2.touchpoint.eclipse.uninstallBundle

但就在安装即将完成时,我收到以下错误:

An error occurred while installing the items
session context was:(profile=SDKProfile, phase=org.eclipse.equinox.internal.p2.engine.phases.Install, operand=null --> [R]com.iar.installer.arm 0.12.0.v201110251455, action=org.eclipse.equinox.internal.p2.touchpoint.eclipse.actions.UninstallBundleAction).
No matching artifact found for: com.iar.cdt.arm.debugger.drivers.win32.
No matching artifact found for: com.iar.cdt.arm.debugger.drivers.win32.

我需要卸载整个托管插件吗?

【问题讨论】:

    标签: eclipse p2


    【解决方案1】:

    试试这个

    artifacts.0.classifier=osgi.bundle
    artifacts.0.name=com.iar.cdt.arm.debugger.drivers.win32
    artifacts.0.version=<the version of your fragment>
    
    instructions.install = \
        uninstallBundle(bundle:${artifact})
    

    【讨论】:

    • 我需要instructions.install.import 声明吗?
    • ...另外,我可以指定版本范围吗?我想删除任何版本的片段。
    • @JesperE, instructions.install.import 可以是可选的。不能使用版本范围,IU的神器必须是规范的。
    • 片段没有安装怎么办?在野外至少有 4 个不同版本的片段,我需要它才能优雅地卸载用户安装的任何版本。
    • 如果你的 Fragment 依赖于它们的主机,那么如何发布一个增加了主要版本的新主机包?
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-06-12
    • 2019-01-04
    • 2011-11-15
    • 2017-12-10
    • 2022-01-03
    相关资源
    最近更新 更多