没有要为命令执行的处理程序

There is no handler to execute for command

我一直在尝试构建我的第一个 eclipse 插件,我可以在其中 select 一些文本,然后使用 alt+left 和 alt+right 将其向左或向右移动。如果我将我的插件作为 eclipse 应用程序启动,一切正常,我的插件也能正常工作。但是,当我将我的插件导出为可部署插件时,目标为 "Install into host" 和 运行 命令,有时我会得到 There is no handler to execute for command sirolf2009-eclipse-tools.commands.MoveSelectionLeft。其他时候我会得到

Exception occured when loading the handler
Plug-in sirolf2009-eclipse-tools was unable to load class com.sirolf2009.eclipsetools.handlers.MoveSelectionLeft.
com.sirolf2009.eclipsetools.handlers.MoveSelectionLeft cannot be found by sirolf2009-eclipse-tools_0.0.1.SNAPSHOT

我尝试检查导出过程中生成的 jar,它在正确的位置包含一个 class。我已经上传了 jar here

每次安装到 Eclipse 时,请确保在 MANIFEST.MF 中递增版本号 (Bundle-Version),以便它知道插件是新的。

您可以更改号码的前三部分中的任意一个,第四部分不勾选。