Kotlin Extension for bld https://github.com/rife2/bld-kotlin
Find a file
2024-07-12 03:00:10 -07:00
.github/workflows Added KOTLIN_HOME to GitHub workflow 2024-07-12 02:58:25 -07:00
.idea Bumped bld to version 2.0.0-SNAPSHOT 2024-07-11 22:01:28 -07:00
.vscode Bumped bld to version 2.0.0-SNAPSHOT 2024-07-11 22:01:28 -07:00
config Bumped PMD extension to 0.9.8 (PMD 7.0.0) 2024-03-22 04:16:54 -07:00
examples Added requirements to examples README 2024-07-12 03:00:10 -07:00
lib/bld Bumped bld to version 2.0.0-SNAPSHOT 2024-07-11 22:01:28 -07:00
scripts BREAKING CHANGE: Kotlin must be installed. Location is deducted from KOTLIN_HOME, if set. 2024-07-12 02:13:13 -07:00
src BREAKING CHANGE: Kotlin must be installed. Location is deducted from KOTLIN_HOME, if set. 2024-07-12 02:13:13 -07:00
.gitignore Fixed dependencies for testing 2023-11-04 02:07:00 -07:00
bld Initial commit 2023-11-03 21:31:09 -07:00
bld.bat Initial commit 2023-11-03 21:31:09 -07:00
LICENSE.txt Initial commit 2023-11-03 21:31:09 -07:00
README.md BREAKING CHANGE: Kotlin must be installed. Location is deducted from KOTLIN_HOME, if set. 2024-07-12 02:13:13 -07:00

Kotlin Extension for bld

License Java Kotlin bld Release Snapshot GitHub CI

To install, please refer to the extensions and support documentation.

Compile Kotlin Source Code

To compile the source code located in src/main/kotlin and src/test/kotlin from the current project:

@BuildCommand(summary = "Compiles the Kotlin project")
public void compile() throws Exception {
    new CompileKotlinOperation()
            .fromProject(this)
            .execute();
}
./bld compile

Please check the Compile Operation documentation for all available configuration options.

Kotlin Compiler Requirement

Please make sure Kotlin is installed and that the KOTLIN_HOME environment variable is set.

You can also manually configure the Kotlin home location as follows:

@BuildCommand(summary = "Compiles the Kotlin project")
public void compile() throws Exception {
    new CompileKotlinOperation()
            .fromProject(this)
            .kotlinHome("path/to/kotlin")
            .execute();
}

While older version of Kotlin are likely working with the extension, only version 1.9 or higher are officially supported.

Template Project

There is also a Template Project with support for the Dokka and Detekt extensions.