Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Pre-1.0 · Phase 5 in progress

Kargo

A build and dependency management tool for Kotlin, written in Rust. One declarative Kargo.toml describes your whole project, and a single native binary builds it.

If you have used Cargo, you already know how Kargo feels:

kargo new my-app
cd my-app
kargo add org.jetbrains.kotlinx:kotlinx-coroutines-core
kargo run

No wrapper script, no configuration phase, no build script language to learn.

Why Kargo

Kotlin's tooling is powerful but heavy. A new Kotlin project starts with a Gradle wrapper, two or three build scripts in a DSL that is itself a Kotlin program, a settings file, a version catalog, and a plugin block — before a single line of application code. Changing a dependency means editing a program, and understanding a build means reading one.

Kargo takes the opposite position: a build is configuration, not a program.

GradleKargo
ConfigurationKotlin/Groovy DSL scriptsDeclarative TOML
StartupJVM boot + script compilationNative binary, no configuration phase
DependenciesMaven repos via custom resolutionMaven repos via standard protocol
ToolchainYou install Kotlin and the JDKAuto-downloaded and pinned per project
MultiplatformFirst-class, plugin-configuredFirst-class, declared in the manifest
ComposePluginBuilt in
FlavorsAndroid-only (productFlavors)Every target
Lint and formatThird-party pluginsBuilt in
ExtensibilityFull programmatic powerSubcommands, scripts, hooks

What Kargo deliberately does not try to be is a general-purpose task runner. Gradle lets you express anything because a build script is code. Kargo covers the Kotlin build lifecycle declaratively and hands off the unusual cases to plugins and hooks. If your build genuinely needs arbitrary programmable task graphs, Gradle is the right tool and Kargo will not replace it.

Who this is for

  • Kotlin/JVM application and library authors who want a build file they can read.
  • Kotlin Multiplatform teams tired of configuring source-set hierarchies by hand.
  • Compose Multiplatform developers who want one target list, not one plugin per target.
  • Android-adjacent projects that need build flavors without the whole Android Gradle Plugin.

How these docs are organized

  • Getting Started — install Kargo, create a project, understand the layout it generates.
  • Using Kargo — task-oriented guides. Start here for "how do I…" questions: add a dependency, build a variant, publish, wire up CI.
  • Reference — the exhaustive detail. Every command, every manifest key, every environment variable.
  • How Kargo Works — what happens between kargo build and a JAR. Useful when something surprises you; not required reading.
  • Contributing — for people working on Kargo itself.

A note on status

Kargo is pre-1.0 and under active development. These docs describe the tool Kargo is being built to be — it is the specification the implementation works toward, not a report on what compiled this morning. Features that do not fully exist yet are marked, so you can tell the difference at a glance:

MarkerMeaning
🟢 ImplementedWorks today. Behaves as documented, bugs aside.
🟡 PartialPartly working. The page says exactly which part.
⚪ PlannedSpecified and designed, not yet built.

Every page opens with its status. The Implementation Status page collects all of them in one table alongside the roadmap, and is the single source of truth when a page and your terminal disagree.

Getting help

License

Kargo is dual-licensed under MIT or Apache-2.0, at your option.