Scala for Netbeans Beta Is Ready, Working with NetBeans 6.5 Beta
>>> Updated Aug 15:
For Windows Vista users:
There is a known bug #135547 that may have been fixed in trunk but not for NetBeans 6.5 Beta, which causes exception of "NullPointerException at org.openide.filesystems.FileUtil.normalizeFileOnWindows" when create Scala project. If you are Vista user and like to have a try on Scala plugins, you may need to download a recent nightly build version of NetBeans. Since I have none Vista environment, I'm not sure about above message.
======
I'm pleased to announce that the first beta of Scala for NetBeans is released, followed NetBeans 6.5 beta releasing. The availability and installation instructions can be found at http://wiki.netbeans.org/Scala.
Features:
- Full featured Scala editor
- syntax and semantic coloring
- outline navigator
- code folding
- mark occurrences
- go to declaration
- instant rename
- indentation
- formatting
- pair matching
- error annotations
- code completion
- Project management (build/run/debug project)
- Debugger
- Interactive console
- JUnit integration
- Maven integration (works with Lift Web Framework)
There are some known issues. Bug reports are welcome.
Installation on NetBeans 6.5 beta:
- Get the NetBeans 6.5 beta or later version from: http://download.netbeans.org/netbeans/6.5/beta/
- Get the Scala plugins beta binary from: http://plugins.netbeans.org/PluginPortal/faces/PluginDetailPage.jsp?pluginid=11854
- Unzip Scala plugin binary to somewhere
- Open NetBeans, go to "Tools" -> "Plugins", click on "Downloaded" tab title, click on "Add Plugins..." button, choose the directory where the Scala plugins are unzipped, select all listed *.nbm files, following the instructions. Restart IDE.
Posted at 01:53AM Aug 14, 2008 by dcaoyuan in NetBeans | Comments[11]

Good work! Some issues I found:
Posted by Jesper Nordenberg on August 14, 2008 at 09:32 AM PDT #
Hi Jesper,
Which version of Scala plugins are you using?
Breakpoints should works;
>>Pressing Enter on a blank line unindents one level.
This should also be resolved sometimes ago.
Posted by Caoyuan on August 14, 2008 at 10:06 AM PDT #
I downloaded the Netbeans beta and 1217968713508_scala-plugin-080805. After I installed the plugin it reports Scala Kit 0.10.0 and Scala Runtime Library 2.7.1.1. There are no other Scala plugins in the installed list even though I installed many more.
Posted by Jesper Nordenberg on August 14, 2008 at 11:14 AM PDT #
Jesper,
If so, are you using NetBeans 6.5 beta (I should have ask this question).
Thanks
Posted by Caoyuan on August 14, 2008 at 02:13 PM PDT #
Great. I installed latest night build of NetBeans and Scala plugin.
As a note, there is still some small issue with a debugger.
Posted by Vladimir Kelman on August 15, 2008 at 05:26 AM PDT #
Vladimir,
I'll go on getting debugger more featured, thanks for the cases
Posted by Caoyuan on August 15, 2008 at 10:06 AM PDT #
i installed the plugin and created a new project. it creates the hello world example.
1. can set breakpoints by clicking, but when i try to debug Main.scala from the menu it complains that it doesn't have a main method.
2. mostly i want to try the interactive console, but can't find anywhere how to start it. what menu option starts the console ?
Posted by lytles on August 19, 2008 at 11:23 PM PDT #
lytles,
In case of complaining for main method, could you send me your code? it seems your code couldn't pass compile.
Interactive console is under menu: windows->other->Interactive Scala Shell, but there is bug which I just fixed, please see "known issues" in this blog
Posted by caoyuan on August 20, 2008 at 10:55 AM PDT #
ok - if i do "run main project" or "debug main project" it works (and stops at the bp). but if i do "run file (Main.scala)" or "debug Main.scala" it complains about the missing main. which is ok, but odd. here's my code:
package scalaapplication1
object Main {
def main(args: Array[String]) = {
println("Hello, world!");
}
}
ok, thanks for the pointer to the console (how did i miss that, i even looked under "other" :) looking forward to the next release so i can really try it.
Posted by lytles on August 20, 2008 at 07:28 PM PDT #
lytles,
Thanks for your confirmation on the debugger part. I have not got "run file" or "debug file" working yet, although it's not a hard work.
Writing language support or IDE is really a complex work, too many features to be finished, and sometimes I have to wait or modify the underlying modules of NetBeans.
Anyway, we've got a almost working scala IDE now, and I think it will be much better when next release.
Posted by Caoyuan on August 21, 2008 at 12:20 AM PDT #
looks good - thanks for the help
Posted by lytles on August 21, 2008 at 08:10 PM PDT #