|
| 1 | +--- |
| 2 | +title: "Google Summer of Code 2023 – Eclipse Gradle Kotlin Script Support" |
| 3 | +date: 2023-12-18 10:00 |
| 4 | +--- |
| 5 | + |
| 6 | +The Kotlin Foundation sponsored 4 projects for the Google Summer of Code 2023, and we are excited to announce the completion of the Eclipse Gradle Kotlin Script Support project! Gradle, a Kotlin Foundation member, provided mentoring support for this project, and we'd like to share details about the project. |
| 7 | + |
| 8 | +The contributor to this project was [Nikolai Vladimirov](https://www.linkedin.com/in/vladimir0v/), a third-year student from Constructor University, and the mentor was [Donát Csikós](https://github.com/donat), a Senior Software Engineer at Gradle. The project aimed to bring support for Gradle Kotlin Scripts (`.kts`) to the Eclipse IDE. |
| 9 | + |
| 10 | +The initial goal was to improve user interaction with Gradle Kotlin scripts inside the Eclipse IDE. The goal was to implement the following functionality: |
| 11 | + |
| 12 | +* Syntax highlighting for Kotlin scripts |
| 13 | +* Content assistance |
| 14 | +* Go-to-definition |
| 15 | +* Accurate diagnostics for syntax errors |
| 16 | +* Signature help |
| 17 | +* Hovering |
| 18 | + |
| 19 | +Nikolai successfully delivered these features by implementing support for Kotlin scripts based on the existing kotlin-language-server project, creating a new system to separate compilation environments for each build script. Here are examples of each feature: |
| 20 | + |
| 21 | +**Syntax highlighting for .kts scripts** |
| 22 | + |
| 23 | + |
| 24 | + |
| 25 | +**Content assistance** |
| 26 | + |
| 27 | + |
| 28 | + |
| 29 | +**Go-to-definition** |
| 30 | + |
| 31 | + |
| 32 | + |
| 33 | +**Accurate Diagnostics for syntax errors** |
| 34 | + |
| 35 | + |
| 36 | + |
| 37 | +**Signature help** |
| 38 | + |
| 39 | + |
| 40 | + |
| 41 | +**Hovering** |
| 42 | + |
| 43 | + |
| 44 | + |
| 45 | +## Installation |
| 46 | + |
| 47 | +The new features are not yet production-ready, and it currently does not work on Windows. Consequently, they are delivered as optional installables. You can find them in the [latest update sites](https://download.eclipse.org/buildship/updates/latest-snapshot/) under the **Buildship Extras - Incubating category**. |
| 48 | + |
| 49 | + |
| 50 | + |
| 51 | +## Next Steps |
| 52 | + |
| 53 | +If you'd like to get involved with improving the Eclipse Kotlin Gradle Script support, there are two parts: |
| 54 | + |
| 55 | +* **Eclipse plugin**: The plugin is part of the [Buildship](https://github.com/eclipse/buildship) project. The implementation is in the `org.eclipse.buildship.kotlindsl.provider` subproject. |
| 56 | +* **Language server**: The IDE-agnostic components are implemented in [this repository](https://github.com/D0zee/language-server-for-KTS-scripts/tree/GSoC-work) in the GSoC-work branch. |
| 57 | + |
| 58 | +The remaining tasks are to add a couple of minor features and incrementally improve the reliability, stability, and performance of this plugin. |
| 59 | + |
| 60 | +We are grateful for Nikolai and Donát's contributions to making Kotlin better for developers! |
0 commit comments