Installation
Consume Sui Codegen via the Gradle plugin (recommended for projects) or the standalone native CLI.
Gradle Plugin
Add the plugin to your project.
settings.gradle.kts (plugin management)
Code
pluginManagement {
repositories {
mavenLocal() // if testing locally
gradlePluginPortal()
mavenCentral()
}
}build.gradle.kts
For Kotlin/JVM:
Code
plugins {
kotlin("jvm") version "2.3.0"
id("xyz.mcxross.codegen") version "0.1.0"
}For Kotlin Multiplatform:
Code
plugins {
kotlin("multiplatform") version "2.3.0"
id("xyz.mcxross.codegen") version "0.1.0"
}The plugin automatically wires generated sources into main (JVM) or commonMain (KMP).
Native CLI
Build the native binary from source:
Code
./gradlew linkDebugExecutableMacosArm64Build the native binary (see the project’s README for platform-specific tasks). The resulting executable can be placed in your PATH.
For other platforms, use the appropriate link* task.