After quick look at DebugPlugin code I found that DebugPlugin#getDefault()
method is simple getter to fgDefaultPlugin
field, and return this field value which is null
by default. Since you're invoking DebugPlugin#getDefault()
as very first method of your main
function it's reasonable that it returns null
, since DebugPlugin#setDefault()
was not previously called.
You can't run Eclipse from a main method like that. You need to write a plugin, and it will be accesible from inside the plugin method.