#805 JavascriptSideKick 1.0.0


{{{ JavascriptSideKick 1.0.0
Source: https://jedit.svn.sourceforge.net/svnroot/jedit/plugins/JavascriptSideKick/tags/JavascriptSideKick-1.0.0
Announcement: Initial release
Requires Java 1.6
Requires jEdit
Required plugins:
ErrorList 1.9 (errorlist.ErrorListPlugin)
RhinoPlugin 1.7R3 (rhino.RhinoPlugin)
SideKick 1.2 (sidekick.SideKickPlugin)

Short Description: JavascriptSideKick is a parser that will show you errors in your javascript code

Long Description: <p>JavascriptSideKick is a javascript parser that will highlight syntax errors of your javascript files. It will delegate
the source tree to the javascript parser included in XML plugin if this one is available</p>



1 2 > >> (Page 1 of 2)
  • Townsfolk

    Matthieu, I can't get this to work. I opened up a Javascript file, and switched the parser to RhinoJS. SideKick refreshes and the parser is set back to "none".

    I opened up SideKick options and set Javascript to RhinoJS, but when open a JS file, the parser is still set to none.

  • Townsfolk

    • assigned_to: nobody --> elberry
    • status: open --> pending
  • Townsfolk

    You can see from the screenshot that there's an error (looks like) in the status bar. I took this after trying to switch the parser to RhinoJS.

    • status: pending --> open
  • That's strange, I had this problem in the beginning but not anymore, I don't know from where it comes.
    Did you try with the trunk version of Sidekick ?

  • After choosing RhinoJS parser manually I get an exception and stop further testing. What's up?

    Jedit 4.4.1, plugin versions specified in props, automatically downloaded.

    java.lang.NoClassDefFoundError: org/mozilla/javascript/ErrorReporter
    at java.lang.Class.getDeclaredConstructors0(Native Method)
    at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
    at java.lang.Class.getConstructors(Class.java:1459)
    at org.gjt.sp.jedit.bsh.Reflect.constructObject(Reflect.java:603)
    at org.gjt.sp.jedit.bsh.BSHAllocationExpression.constructObject(BSHAllocationExpression.java:123)
    at org.gjt.sp.jedit.bsh.BSHAllocationExpression.objectAllocation(BSHAllocationExpression.java:114)

  • Do you have RhinoPlugin (and rhino.jar) loaded in jEdit ?

  • Sorry for the false alarm, Matthieu. I forgot about the dependencies of the dependencies. It must be that.

  • Still something is wrong. Rhino plugin is unavailable in 4.4.1 PM. And I have no clue how may rhino.jar jump into my jars directory.

  • That's probably a mistake I did, I think there is no reason to release a plugin for 4.4 now that 4.5 is out, this is more work for the packager for no benefit since 4.5 can run on the same system that run 4.4. So I will release JavascriptSidekick for 4.5

    • status: open --> closed-rejected
  • Still no luck. Every time I try to choose the RhinoJS parser it gets back to None. Once I managed to get an exception, probably trying to force the parser in many ways:
    [java] 11:52:25 AM [AWT-EventQueue-0] [error] AWT-EventQueue-0: Exception in thread "AWT-EventQueue-0"
    [java] 11:52:25 AM [AWT-EventQueue-0] [error] AWT-EventQueue-0: java.lang.RuntimeException: Unknown parser: rhinojs
    [java] 11:52:25 AM [AWT-EventQueue-0] [error] AWT-EventQueue-0: at sidekick.SideKickPlugin.setParserForBuffer(SideKickPlugin.java:244)

    The letter case is not RhinoJS but rhinojs. Important?

    Tried jedit 4.4, 4.5, trunk. Plugin tag and trunk.

  • Hi, that's right, the parser service name was RhinoJS but the parser name in the class was rhinojs, I think that was the problem.
    I retagged 1.0.0

    • status: closed-rejected --> open
  • There is already a plugin with that name: JavaScriptSideKick. Ftp accepts a new plugin differing only in letter case, but plugin wizard does not.

    I guess this plugin should change its name, because I don't know how to erase the old javascriptsidekick plugin. I don't know even if it's desired to remove it.

    • assigned_to: elberry --> jarekczek
  • Actually this one should not be named sidekick at all. It's not a sidekick. It's a parser. So what I could suggest is something around RhinoParser. Or it depends what are your plans, Matthieu, regarding this plugin.

    • status: open --> pending-rejected
  • Alan Ezust
    Alan Ezust

    If it's just a matter of the JAR filename being wrong, you can change the JAR filename from http://plugins.jedit.org/wiz/package_edit.php?id=185

    The old javascriptsidekick was merged into the XML plugin.
    Is there a good reason the newer one should not replace the older one in the XML plugin too?

  • Alan Ezust
    Alan Ezust

    • status: pending-rejected --> open
  • Alan Ezust
    Alan Ezust

    Ignore previous comment. This plugin should be renamed either RhinoScriptParser or RhinoScriptSidekick

  • Alan Ezust
    Alan Ezust

    • status: open --> closed-rejected
  • Do you think it is necessary to rename that plugin since the other one do not exist anymore and will not be maintained ?
    About the other parser in the XML plugin, it should not be removed, my parser do not build an AST tree for Sidekick, it delegates to the older parser that do not check the syntax.

  • Matthieu, the only functionality of this plugin is verifying js source code for errors. It could just provide a single command called "verify", without connecting it with sidekick plugin. Sidekick parsers are plugins able to provide a tree. Your plugin does not provide a tree, so it shouldn't appear in sidekick parsers list. Moreover, your plugin *depends* on javascriptsidekick plugin, so you definitely shouldn't give it the same name as the plugin you depend on.

    I appreciate the functionality you provide with this plugin, but I would change the way it does it. It's like JSLint plugin. It is not a sidekick.

1 2 > >> (Page 1 of 2)