org.avaje.tile:kotlin-compile

Packaging parent for Avaje projects.

License

License

Categories

Categories

Kotlin Languages
GroupId

GroupId

org.avaje.tile
ArtifactId

ArtifactId

kotlin-compile
Last Version

Last Version

1.2
Release Date

Release Date

Type

Type

tile
Description

Description

Packaging parent for Avaje projects.
Project URL

Project URL

http://www.avaje.org/kotlin-compile
Source Code Management

Source Code Management

https://github.com/avaje-pom/tile-kotlin-compile.git

Download kotlin-compile

Dependencies

There are no dependencies for this project. It is a standalone project that does not depend on any other jars.

Project Modules

There are no modules declared in this project.

kotlin-compile maven tile

Maven tile for performing Kotlin compile. It defaults to use src/main/java and src/test/java but you can configure that and the Kotlin version to use.

Example use

In your project pom under build / plugins add the tiles-maven-plugin with the following configuration. Note that the java-compile tile is there if your project also uses Java.

      <!-- maven build / plugins -->

      <plugin>
        <groupId>io.repaint.maven</groupId>
        <artifactId>tiles-maven-plugin</artifactId>
        <version>2.11</version>
        <extensions>true</extensions>
        <configuration>
          <tiles>
            <tile>org.avaje.tile:kotlin:1.1</tile>
          </tiles>
        </configuration>
      </plugin>

What it does

Effectively the kotlin-compile tile brings in the kotlin-maven-plugin with configuration for compiling main and test code.

  <!-- defaults, override in your project pom if needed -->

  <properties>
    <kotlin.version>1.2.51</kotlin.version>
    <kotlin.compiler.jvmTarget>1.8</kotlin.compiler.jvmTarget>
  </properties>
  
  <!-- brought into build / plugins -->

  <build>

    <sourceDirectory>src/main/kotlin</sourceDirectory>
    <testSourceDirectory>src/test/kotlin</testSourceDirectory>

    <plugins>
      <plugin>
        <groupId>org.jetbrains.kotlin</groupId>
        <artifactId>kotlin-maven-plugin</artifactId>
        <version>${kotlin.version}</version>
        <executions>
          <execution>
            <id>compile</id>
            <phase>compile</phase>
            <goals>
              <goal>compile</goal>
            </goals>
            <configuration>
              <jvmTarget>${kotlin.compiler.jvmTarget}</jvmTarget>
            </configuration>
          </execution>
          <execution>
            <id>test-compile</id>
            <phase>test-compile</phase>
            <goals>
              <goal>test-compile</goal>
            </goals>
            <configuration>
              <jvmTarget>${kotlin.compiler.jvmTarget}</jvmTarget>
            </configuration>
          </execution>
        </executions>
      </plugin>

    </plugins>

  </build>
org.avaje.tile

avaje pom

Versions

Version
1.2
1.1