To give it a try you will need a clean installation of Eclipse Neon or newer. The Kotlin plugin is available from the Eclipse Marketplace. The easiest way to install the Kotlin plugin is to drag-and-drop this button into a running Eclipse window:
Alternatively, you can use Help -> Eclipse Marketplace… menu, or the following update site:
Since Kotlin plugin contains code written in Kotlin itself, you will also need a Kotlin plugin to build the project in Eclipse. To install the Kotlin Eclipse plugin use the following update site:
Since Kotlin plugin uses weaving, you need to launch the project with weaving enabled. Installation of Equinox Weaving Launcher will add two additional launch configurations types for running plugin and for testing. To install the Equinox Weaving Launcher you can use the following update site:
Import plugin projects from the cloned repository into your workspace
File -> Import -> Existing Projects into Workspace
Using the command line, run gradle build to download the Kotlin compiler. It will be used as a bundled compiler in built plugin and as a library during development.
cd {repository}/kotlin-bundled-compiler
./gradlew clean getBundled
or in Windows environment:
cd {repository}\kotlin-bundled-compiler
gradlew.bat clean getBundled
Run another instance of Eclipse with the Kotlin plugin inside
kotlin-eclipse-ui -> Run As -> Eclipse Weaving enabled Eclipse Application
Building from the command line is also available (Note that Maven 3.0.5 is required):
请发表评论