eclipse-pde

Eclipse v4.5 without delta-pack: How to perform a multiplatform headless PDE build?

喜欢而已 提交于 2019-11-30 20:01:16
Now that eclipse 4.5 is out and the eclipse team decided to not build the so-called "delta-pack" anymore, I don'tknow how to perform a PDE headless build with ant.. Official PDE build documentation here http://help.eclipse.org/mars/index.jsp?nav=%2F4_2_0 states that variable "baseLocation" should point to "the location of an eclipse install containing all the pre-built features and plug-ins that your product requires in features/ and plugins/ subdirectories" With v4.4, it was easy, this variable was pointing to the location of the unzipped delta-pack with all the platform specific stuff But

How do I install eclipse PDE on Indigo (3.7)

倾然丶 夕夏残阳落幕 提交于 2019-11-30 19:56:08
I just re-installed eclipse, using the latest version (Indigo / 3.7), and I run into the exact same problem as I did half a year ago. I installed the eclipse java IDE, now how do I get the plugin development enviroment (PDE) working? I've installed the RCP components as in my previous question: How do I install eclipse PDE? Although installation of the RCP components completes as expected, it's somehow not enabled. I can't create OSGi run configurations, there is no Target Platform entry in the preferences dialog, and there is no option to convert a project to a plug-in. Do I need to install

Eclipse Plugin: how to get the path to the currently selected project

南笙酒味 提交于 2019-11-30 14:54:33
问题 I am writing an Eclipse plugin that will display a menu item in the context menu for a Java Project. I have written the plugin.xml as follows: <plugin> <extension point="org.eclipse.ui.menus"> <menuContribution locationURI="popup:org.eclipse.jdt.ui.PackageExplorer"> <dynamic class="uk.co.dajohnston.plugin.classpathswitcher.menu.MenuContribution" id="uk.co.dajohnston.plugin.classpathSwitcher.switchMenuContribution"> <visibleWhen> <with variable="activeMenuSelection"> <iterate> <adapt type="org

How to add a pulldown button in a view's toolbar?

余生颓废 提交于 2019-11-30 07:27:41
I need to add a pulldown button to a view's toolbar in an Eclipse plugin. Actually buttons in the toolbar are added like that : <extension point="org.eclipse.ui.viewActions"> <viewContribution id="..." targetId="$MyViewId$"> <action id="..." toolbarPath="action1" class="Class extending Action and implementing IViewActionDelegate"> </action> </viewContribution> </extension> Julien Hoarau I've figured it out. Two ways: one using org.eclipse.ui.viewActions extension, the other with org.eclipse.ui.menus Using org.eclipse.ui.viewActions extension (eclipse >= 3.5) action's style must set to pulldown

How do I install eclipse PDE on Indigo (3.7)

拜拜、爱过 提交于 2019-11-30 04:47:38
问题 I just re-installed eclipse, using the latest version (Indigo / 3.7), and I run into the exact same problem as I did half a year ago. I installed the eclipse java IDE, now how do I get the plugin development enviroment (PDE) working? I've installed the RCP components as in my previous question: How do I install eclipse PDE? Although installation of the RCP components completes as expected, it's somehow not enabled. I can't create OSGi run configurations, there is no Target Platform entry in

Want to open a eclipse xml file in code and navigate to a specific line number with reference to its IFile

安稳与你 提交于 2019-11-29 16:33:23
I have a reference to an xml file in eclipse IDE through its IFile instance. I know want to add an action on my view that opens the file in the xml editor and navigate to a specific line number. Anyone have any ideas on how to go about this? Assuming you know the file's URL: IWorkbenchPage page = activeWorkbenchPage(); if (page == null) { throw new RuntimeException(); } IFile file; IFile[] files = ResourcesPlugin.getWorkspace().getRoot() .findFilesForLocationURI(url.toURI()); file = files[0]; IMarker marker; marker = file.createMarker(IMarker.TEXT); HashMap<String, Object> map = new HashMap

How to add a pulldown button in a view's toolbar?

随声附和 提交于 2019-11-29 10:29:44
问题 I need to add a pulldown button to a view's toolbar in an Eclipse plugin. Actually buttons in the toolbar are added like that : <extension point="org.eclipse.ui.viewActions"> <viewContribution id="..." targetId="$MyViewId$"> <action id="..." toolbarPath="action1" class="Class extending Action and implementing IViewActionDelegate"> </action> </viewContribution> </extension> 回答1: I've figured it out. Two ways: one using org.eclipse.ui.viewActions extension, the other with org.eclipse.ui.menus

Building Eclipse plugins and features on the command line

こ雲淡風輕ζ 提交于 2019-11-28 20:28:17
I have a bunch of Eclipse plugins and features, which I would like to build as part of a nightly (headless) build. I've managed to do this using a complicated setup involving manually specifying paths to Eclipse plugin jars, copying customTargets.xml, etc. Is there really no simpler solution? Isn't there a way to just point out my Update Site's site.xml and say "build"; i.e. the equivalent of clicking "Build All" in the Update Site project? Given that all the answers to this question are all 3-5 years old, I figure an update would be useful to others. For those who want to add the building of

How to programmatically find a java file in eclipse from full classname?

假装没事ソ 提交于 2019-11-28 05:22:46
问题 Inside an eclipse plugin, I'd like to open a file in editor. I know the full package and class name, how can I determine the path of the java file from this? 回答1: Take a look at IJavaProject.findType( name ) method. Once you have an IType , you can use getPath() or getResource() methods to locate the file. This method searches across a project and everything visible from that project. To search the whole workspace, iterate through all the Java projects in the workspace, calling the findType()

How to run Eclipse launch configurations programmatically?

强颜欢笑 提交于 2019-11-28 04:39:40
I'm finding it difficult to phrase this question well, as there are quite a few generic terms (run, configuration, launch, etc.). Here goes: You can save run configurations in a .launch file . (in the Run Configuration Dialog, under the Common tab, Save as a shared file. We check these in to SVN. The developers can pass them around, and it helps getting new devs running a working application quicker. I'd like to check these out as part of our build and use them to programatically run the application, the tests, etc, without spinning up the whole IDE. What would be the best way to run a .launch