Revyl Documentation

Frameworks

Kotlin Multiplatform

Run the dev loop on a KMP project

KMP projects share business logic in Kotlin across iOS and Android while building native binaries for each platform. Revyl detects the KMP layout and uses the native iOS or Android build command underneath a rebuild-based dev loop. KMP is a layout signal, not a supported build.framework value.

The CLI detects KMP projects by looking for a shared module alongside native shell directories (iosApp, androidApp, or composeApp) and KMP-specific Gradle markers. If exactly one native platform is present, init authors a platform-oriented profile using the inferred native command or a placeholder for you to complete. If both are present, init writes project and session configuration only; configure the native apps as separate Revyl projects rather than authoring legacy build.system or build.platforms fields.

KMP does not have its own hot reload runtime. The dev loop uses the same rebuild model as native iOS/Android: press [r] to rebuild the full binary including shared Kotlin code, upload it, and reinstall.

Set up with an agent

Paste one prompt and your coding agent does the rest.

Setup prompt

Set up Revyl for this Kotlin Multiplatform project.

Read https://docs.revyl.com/frameworks/kmp.md and follow it. It's the current Revyl guide for this, so prefer it over anything you remember about Revyl.

If it has both an iOS and an Android app, set each up as its own Revyl project. Fill in any build command `revyl init` leaves as a placeholder with a simulator or debug build.

You're done when `revyl config validate` passes and the app runs in the Revyl dev loop.

Ask me before anything that needs my login or approval.

What revyl init shows

When KMP is detected, the CLI explains the mapping:

Detected: Kotlin Multiplatform
  Shared module: shared/
  Platforms: ios, android
  Note: Shared KMP logic compiles into native iOS/Android binaries.
        The dev loop uses native build commands underneath.
  Writing project and session configuration only; no build profiles were added.

Manual configuration

If auto-detection does not trigger (e.g. a non-standard project layout), configure the native builds manually:

build:
  framework: ios
  profiles:
    development:
      ios:
        build_commands:
          - "cd shared && ./gradlew assemble"
          - "cd iosApp && xcodebuild -workspace iosApp.xcworkspace -scheme iosApp -configuration Debug -sdk iphonesimulator -derivedDataPath build"
        output_path: "iosApp/build/Build/Products/Debug-iphonesimulator/*.app"

For an Android app, use framework: android and an android recipe in that app's project config. build_commands is always an ordered list, even when the recipe has one command. Run revyl config validate after authoring it.

On this page