Disabling a Netbeans plugin before startup

Just yesterday, I forwarded my Review Comment Assistant Netbeans plugin (look at the previous post for a description) to Sathish, my team's Tech Lead. However, after installing the plugin, his Netbeans 5.0 wouldnt start. The splash screen used to come up and then just vanish.

We looked at the startup log and found an issue with my plugin. Now fixing that would take some time, but I wanted to get Sathish's Netbeans up and running fast. In other words, I wanted to stop Netbeans from loading my plugin during startup.

This is what I did to disable the plugin from loading:

  1. Go to <user_home>/.netbeans/config/Modules
  2. Find <plugin_name>.xml and open it in your editor and change the "enabled" property. The plugin name for my case was com-sun-sps-devtools-commentator and so I fired up gedit and opened com-sun-sps-devtools-commentator.xml and modified the "enabled" property (marked in red box in the figure below) to make it false.
  3. Ran Netbeans, it started without a problem.

When modules are installed by a user, they are typically installed in the <userhome>/.netbeans/modules directory. But a good question is, How are modules registered? How does Netbeans know which modules to load?

Well, Netbeans has a concept of a System Filesystem (more about it here). When modules are installed, an entry of the module is kept in the .netbeans/config/modules directory. This directory is scanned by Netbeans during startup to load all user-installed modules. Changing the enabled property to false, stopped Netbeans from loading my problematic module.

Back to fixing my plugin :-) !

Comments:

Post a Comment:
Comments are closed for this entry.
About

Rohan Ranade's musings on anything and everything.

Search

Archives
« April 2015
SunMonTueWedThuFriSat
   
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
  
       
Today