0

I have generated a demo popup menu plugin project automatically by Eclipse. Here is the project structure,

enter image description here

I have set a objectContribution to the point org.eclipse.ui.popupMenus,

enter image description here

When I right click the project and choose Run as -> Eclipse Application, another Eclipse process run and I can see the configured menu works well,

enter image description here

How can I install this plugin for my original Eclipse process?

What I have tried

I did some research and tried to Export -> Deployable plug-ins and fragments, then put it into the %EclipseFolder%/plugins, but it didn't work. I also have tried to Export -> Deployable features and installed it by Help->Install New Software, also failed to see the menu when right click the project.

Will you please help? BTW, I would like to know how to contribute a menu which will display when I right click on a package in a project? Thanks so much.

Rüdiger Herrmann
  • 20,512
  • 11
  • 62
  • 79
J.Lyu
  • 932
  • 7
  • 16

1 Answers1

0

Use the Deployable plug-ins and fragments wizard and select Intall into Host on the Destination page.

This will create a p2 repository at the denoted location and install the selected plug-ins from there into the host instance, i.e. the Eclipse IDE that you are currently working with. I think a restart may be required.

Rüdiger Herrmann
  • 20,512
  • 11
  • 62
  • 79
  • See http://stackoverflow.com/a/33133450/2796832 for step-by-step instructions including screenshots along the way. – Jonah Graham Nov 12 '15 at 11:23
  • @JonahGraham and Herrmann thanks for you guys' reply. But actually it didn't work well. I was using Windows and I did Export -> Deployable plug-ins and fragments, then choose Install into host. Repository. And configured the repo as C:/Users/Administrator/workspace/.metadata/.plugins/org.eclipse.pde.core/install/ which is my current workspace's location. After restarting the Eclipse nothing changed. I noticed that there is jar of my project in C:\Users\Administrator\workspace\.metadata\.plugins\org.eclipse.pde.core\install. But seems it doesn't work. – J.Lyu Nov 13 '15 at 01:08
  • 2
    All I can recommend with the info available is to create a new plugin project from scratch using the hello world template on the last page of the wizard and determine if that works. One common error is that build.properties is missing the plugin.xml or other required file. – Jonah Graham Nov 13 '15 at 06:59