Intellij Kotlin - Missing proceed on errors - kotlin

While coding Java one can set the configuration "Proceed on errors" for example on the eclipse compiler in Intellij.
Is there an equivalent for Kotlin?
My specific case right now: all code (written in Java) is build OK, junit tests (written in Kotlin) are broken. I'm trying to fix and build the tests one by one.
Kind regards,
GJS

Related

Which Kotlin download do I need?

I'm getting started with Kotlin, and on the downloads page I see two different possibilities that look relevant for me:
kotlin-compiler
kotlin-native-windows
What's the difference? In what case would I need one or the other?
Most probably you won't use CLI to compile, build and run Kotlin projects a lot. Well, maybe you'll need a standalone compiler a few times compiling "Hello world" when starting with this language. BTW, you can use https://try.kotlinlang.org to compile simple programs and play with the language without local installations.
But as you proceed, it won't be enough. Most Kotlin projects today use either Gradle or Maven. Gradle scripts could be written in Kotlin themselves. I recommend you taking this extra step and use build tools instead of standalone compiler, as it will simplify a lot if things in future. IntelliJ IDEA, the most popular IDE for Kotlin made by JetBrains, the company behind Kotlin, allows you to create Gralde-based Kotlin projects in a few clicks.
Kotlin is a multi-platform language. It can be compiled to produce binaries compatible either with:
Java
JavaScript
A native platform (Windows, Linux, iOS, etc.)
Which compiler you should choose depends on your needs. If you don't need to make your code operate with a C library or a specific OS tool, I'd recommend the kotlin-compiler, so you'll get an app executable through Java, which (at least for now) produce more optimized programs, and also easily portable (install a jre on target computer and you're ready to execute your Kotlin program). Plus, you'll be able to use any Java lib you need in your kotlin program.
Note : Official documentation contains guides to get started:
Command line compiler for JVM
Command line compiler for native executables

JUnit library for Kotlin

I am new to Kotlin.
Can anyone explain what I'm doing wrong?
Why IDE cannot see #Test?
Understood. There are couple solutions how to add JUnit to your project here JUnit
But when I added it automatically it had "scope" Test and somehow it doesn't work. I changed to Compile and now it is fine

standalone scenebuilder to get intellij project

Okay, I may get responses to read the manual - I did review and did google searches and I am just not seeing it.
I have created a UI using a standalone Scenebuilder. I have a working Kotlin code in intellij. Basically all I want to do is getting what I created from the standalone Scenebuilder to intellij in my Kotlin project so that I can connect them. Get my Kotlin code that works at on the command prompt to give it some life in a GUI. I am still in the learning stages of programming in Kotlin and using Scenebuilder (standalone).
If anyone can point me on where I would find how to provide this connectivity, I would really appreciate it -- thank you!
I guess you talk about JavaFX. There is a JavaFX Framework for Kotlin called tornadoFx. You can check that out here https://github.com/edvin/tornadofx
If you use the SceneBuilder (and therefore FXML), have also a look at that documentation: https://edvin.gitbooks.io/tornadofx-guide/content/10.%20FXML.html

Working with IntelliJ + Spring Data + AspectJ

I am attempting to work with a Spring Data Graph project in IntelliJ 11.1.4 Ultimate edition. The project builds fine but the editor says that the persist() method on my classes annotated with #NodeEntity can't be found. Additionally, none if the aspect enhanced methods, like persist, show up for auto-complete suggestions.
I am using the AspectJ Support plugin and I have the compiler set to AJC. Both IntelliJ and Maven can build and run the project, it appears that the editor is the only piece that has the problem.
Am I missing something obvious? Is this a limitation of IntelliJ? I thought 11.1.4 addressed this but I might be mistaken.
Unfortunately AspectJ support isn't fully implemented yet - though resolve and completion should work. Could you please file a ticket in the tracker with a small demo project attached?

Is there an eclipse plugin for Play2?

I know there is one for play1, but I don't find any for play2.
I hope the plugin can compile the templates to scala code automatically. It's not convenient now.
I just came across Scala IDE Play2 plugin for Eclipse Indigo/Juno and Scala IDE. The current features are
Syntax Highlighting (routes and templates)
Code completion (templates)
Formatter (routes)
Hyperlinking (routes and templates)
Note that hyperlinking to Java files is not supported for now. Also there are some limitations for the code completion feature, just take some time to read the doc. I didn't try it myself as I'm not working with Play2 right now, but thought it might be helpful for someone.
Edit: This answer is outdated. A Play Eclipse plugin has been written, as #Baztoune says.
There is no Play 2 plugin for Eclipse at the time I’m writing these lines. However, there is an eclipsify sbt command, provided by the Play 2 sbt plugin, which is able to generate an Eclipse project from a Play 2 application.
You won’t get syntax highlighting, contextual completion or code navigation inside Play 2 templates, but you can have them to be automatically compiled when saved by using the ~run sbt command (instead of just run). Check the Eclipse “General −> Workspace −> Refresh using native hooks or polling” option is enabled so it will take compiled templates changes into account.
Yes, here's how to get started:
Find the correct update site for your version of Eclipse from http://scala-ide.org/download/current.html.
In Eclipse go to Help->Install New Software. Use the update site from above to locate Scala related plugins.
Install both the Scala IDE for Eclipse plugin and the Play2 support in Scala IDE plugin. Note that the Play2 support in Scala IDE plugin is listed under the Scala IDE plugins checkbox.
I was unable to get this working at all starting from bare Eclipse, as many sources have suggested doing. The problem seems to be incompatible dependencies that only show up after much wasted time. The Scala IDE route eliminated this problem.
Yes. That's Scala IDE.
Update Site for Eclipse Juno and Kepler: http://download.scala-ide.org/sdk/e38/scala210/stable/site
Install with the following features:
Scala IDE for Eclipse
Scala IDE Plugins (incubation)
I use Scala IDE from http://scala-ide.org/ , then eclipsify my play2 project and import.
It works like a charm: it compiles my scala/java code.
You can get more details at this URL http://scala-ide.org/docs/tutorials/play20scalaide20/index.html