Eclipse plugin deployment in same Eclipse instance - possible? - eclipse-plugin

I am developing an Eclipse plugin which will operate in plugin-only mode - mainly special context menus for certain project natures. Is there a way to deploy the plugin into the current Eclipse runtime, so I can immediately test it there?
If no, how are developers supposed to test plugins which use Eclipse's file explorer?

In your Eclipse IDE, open "Run > Run Configurations..." Select Eclipse Application and create a new run configuration.
Then on the "Main" tab there will be a "Program to Run" section. Select the radio button "Run an application:"
Then in it's drop down menu, select "org.eclipse.ui.ide.workbench"
Now switch to the tab labeled "Plug-ins". Make sure the plug-in that you are building and want to test is selected. You may have to use the drop down labeled "Launch with:" and select "plug-ins selected below only" in order for the UI to let you select the plug-in your building.
Now, just to make sure this is all going to launch correctly, select the button, "Validate Plug-ins" If there are errors, close the message box and select the button, "Add Required Plug-ins" This will auto select all dependent plugins for this run configuration.
Now select the button "Run" and a new instance of Eclipse will launch with your plug-in installed in it.

Related

Configure and install Intellij IDEA SDK

Now I want to write a plugin in intellij , development of every custom plugins requires the IntelliJ IDEA SDK to be installed and configured for that project. How can I install and configure sdk to my project?
Here you can read official guide to configure IntelliJ Idea SDK
Press CTRL + ALT + SHIFT + S
In the Project Structure dialog box that opens, do the following, and then click OK
Under Platform Settings, click SDKs, and then click the plus sign icon.
From the provided list, select IntelliJ IDEA Plugin SDK.
Using the Select Path dialog box that opens, select the IntelliJ IDEA installation directory directory, and then click OK. Note, that by default, this dialog box automatically selects the home directory of the currently running IntelliJ IDEA installation.
In the Select internal Java platform dialog box that opens, select a Java SDK (JDK 1.6 is recommended) to be used as IDEA internal platform, and then click OK.
Optionally, in Sandbox Home, change the default folder to which Intellij IDEA will copy plugins for debugging.
Open the Sourcepath tab, click Add, and then select the folder where you have checked out the sources of IntelliJ IDEA Community Edition.
In the Detected Source Roots dialog box that opens, click OK.

Can't find Web Application project in Netbeans

When I start a netbeans project, there is no categories "Java Web". Which is for make "Web Application" project. How can I add "java web" plugin or something in netbeans to see the java web categories in categories list in netbeans. please someone help me.
Go to the Tools menu and select Plugins. Then click on the "Available Plugins" tab.
Check the box for "Java Web Applications".
Click the "Install" button.
Click your way through the dialogs until the plugin and its dependencies are installed.
Restart the IDE.
You should now find "Java Web" in File -> New Project.
For anyone else that has this issue I've figured out how to fix it (when you find find the files for your webproject in htdocs).
Click on File -> New Project
Then click on Php Application from Existing Sources...
Then click on the files you have in your htdocs folder and it should show back up.
(Note you might have to double check the port numbers when you set it back up).

How to import and run existing plugins from intellij community edition repo

I'm trying to import and run the IntelliJ git4idea (Git Integration) plugin in order to play around and contribute some of my own code.
I've pulled the Intellij community edition from the github repo, and imported the git4idea plugin as a project. I'm running the Intellij community edition
My main issue is this:
After importing all the modules, the git4idea module comes up as a general module type, and not a plugin module type.
This means that when trying to create a new run\debug configuration, I get [none] under "Use classpath of module", instead of of the ability to select the git4idea plugin. This obviously results in a "Run configuration error: no plugin module specified for configuration".
So the question is -
How can I change the general type of imported "git4idea" to plugin type?
Or better yet, what are the steps required in order to import and build/debug/run a plugin from the Intellij community edition repo?
I was able to solve this by manually reordering file directories, sorting out dependencies and editing the .iml file. The type of plugin is defined by changing type="JAVA_MODULE" to type="PLUGIN_MODULE".
...
This is the answer given by Dmitry Jemerov on the official Jetbrains plugin development forum:
The easiest answer to this is "don't". The IntelliJ IDEA Community
Edition project is set up to be developed as a whole, and the
dependencies are set up accordingly. If you want to hack on the Git
plugin, you simply run IDEA using the provided run configuration, it
runs with all plugins enabled, and you simply make whatever changes
you need and test them using the main run configuration.
If you really want, you can set up a new plugin module and point it to
the source code of the git4idea plugin inside the IntelliJ IDEA
Community Edition Git checkout. This is not too hard, but it's
something you'll need to do from scratch, and you can't use the
existing .iml file.
I had the same no plugin module specified for configuration issue. To work around it, instead of importing, I created a new plugin project and used the existing code directory.
when you import the intelij plugin projects
You should run the 'runIde' task in gradle.
Step-by-step instruction
Build your IDEA plugin (usually done with gradle build).
Start Intellij IDEA.
If you have any project opened, go to menu "File->Close all projects" to return to Intellij IDEA startup screen.
Install the plugin you've just built: on the left side of the "Welcome to Intellij IDEA" startup screen go to "Plugins", then click "gear" icon on the right side, it's located to the right of "Marketplace" and "Installed". From the pop-up menu select "Install Plugin from Disk...", navigate to plugin file (usually in build folder) and click "Ignore and continue" when you see the warning message saying something about signature.
Restart Intellij IDEA.
Open the folder with your IDEA plugin.
Wait until IDEA imported your Gradle project.
Put breakpoints inside your plugin code so you can debug it.
Go to menu "Run->Edit configurations".
In the "Run/Debug Configurations" window on the left side click "+".
Select "Gradle" from the pop-up menu.
On the right side change "Name" to "gradle-run-ide" (without quotes).
On the right side under "Run", inside "Tasks and arguments" field enter runIde ("i" must be capital, other letters small).
Click "OK" to save changes.
Go to menu "Run->Debug 'gradle-run-ide'".
A new, black-colored IDEA window should appear.
In this black-colored IDEA window do whatever you need to do in order to invoke methods of your plugin. When you invoke them, the first IDEA window should stop you on breakpoints you set previously.
Happy debugging.
After changing type="JAVA_MODULE" to type="PLUGIN_MODULE" in *.iml file I was getting following error -
Error running 'IdeaPlugin': Wrong SDK type for plugin module
To fix this go to -
Module Settings -> Platform settings -> SDKs.
Click on Add new SDK
Select Intellij Platform plugin SDK
For home directory select your Inetllij installation dir
Select JAVA SDK you want to use with it.
Once this is added got to Module Settings again
Module Settings -> Project settings -> project.
In Project SDK change the JAVA sdk to the SDK we just added in the above steps.
Run/Debug you plugin now.

JProfiler not working in IntelliJ 12 (JProfiler executable is null)

I'm trying to profile my Android app. I installed the JProfiler plugin through
IntelliJ IDEA --> Preferences --> Plugins
Here's a screenshot of the plugin description:
When I try to run the profiler nothing happens and I get this message saying that the JProfiler executable is null:
Any idea on how to fix this?
You need to set or re-set the JProfiler executable. Do the following:
Select "Edit Configurations" from the "Run" drop down menu
Select "Application" under "Defaults" in the dialog box (or any existing run configuration)
Select the "Startup/Connection" tab
Select "JProfiler" in the list
Click on the "Select JProfiler Executable" button
Choose the JProfiler executable, which is
[JProfiler installation directory]\bin\jprofiler.exe on Windows
[JProfiler installation directory]/bin/jprofiler on Linux/Unix
[JProfiler installation directory]/bin/macos/jprofiler.sh on Mac OS X
You have to install JProfiler first, you can download it here.
You need to have JProfiler 7.2.2 (or newer) which integrates with IntelliJ IDEA 12
http://www.ej-technologies.com/download/jprofiler/changelog.html#7.2.2
To start, in a file browser check if you have the plugins folder, if not create it, so it looks like this
C:\Users\[username]\.IntelliJIdea12\config\plugins
If running IntelliJ IDEA 12, close it.
Inside JProfiler go to
Session -> IDE Integrations
And choose IntelliJ IDEA 12.x and click Proceed button
Choose your .IntelliJIdea12 folder
C:\Users\[username]\.IntelliJIdea12
And you're done, you should see a new button Next to Run [class#method] with Coverage that says Profile [class#method]

New>Generic problem in Eclipse Helios no other attributes

When I am trying to use eclipse Helios for plug-in development,I am not getting any attributes beside generic in any new RCL option. I have gone through net and found to download the source code but there is no way to append the same in Helios. Please suggest
You can install Eclipse RCP Plug-in Developer Resources via Eclipse update site
The shortest way to do it is:
Download the helios version for RCP developers from the eclipse web site.
Open target platform from the preferences menu.
Click "add" to add a new target platform.
"Nothing" is chosen for default target platform creation. Click next
On the new window click on the locations tab.. Click add , on the pop up window click directory and browse the plugin directory of eclipse for RCP developers (This version of helios includes the necessary plugin sources inside) and click finish
On the "implicit dependencies" tab show all the plugins added (choose all plugins)
and then click finish and close the wizard window.
Finally choose the new target platform configuration you have just created.
Now you can see all the new attributes beside generics (related to the plugin)
Download the SDK plugins from:
http://download.eclipse.org/eclipse/updates/4.3/