Skip to content

feat(innertube): migrate to KMP and enable iOS support#2822

Draft
kairosci wants to merge 3 commits intoMetrolistGroup:mainfrom
kairosci:feat/ios-support
Draft

feat(innertube): migrate to KMP and enable iOS support#2822
kairosci wants to merge 3 commits intoMetrolistGroup:mainfrom
kairosci:feat/ios-support

Conversation

@kairosci
Copy link
Contributor

@kairosci kairosci commented Feb 14, 2026

Overview

This PR migrates the innertube and lrclib modules to Kotlin Multiplatform (KMP), laying the foundation for iOS support in Metrolist.

Changes

InnerTube Module

  • Migrated to KMP structure (commonMain, jvmMain, iosMain)
  • Moved all models and network code to shared commonMain
  • Platform-specific NewPipe implementations
  • Added platform utilities for JVM and iOS

LrcLib Module

  • Migrated to KMP structure
  • Shared lyrics fetching logic across platforms

Build Configuration

  • Updated Gradle configuration for KMP
  • Added kotlin-android plugin for compatibility
  • Configured platform-specific source sets
  • Fixed module inclusion in settings.gradle.kts

Related Issues

Testing

  • JVM build successful (jvmMain target)
  • iOS Simulator build successful (iosSimulatorArm64 target)
  • All existing Android functionality preserved
  • No breaking changes to public APIs

Notes

This is the first step towards full iOS support. The PR focuses on migrating the data and networking layers to KMP, which can be shared between Android and iOS. Future work will add the iOS app module with UI components.

Next Steps

After merge:

  1. Create iOS app module
  2. Implement iOS-specific UI
  3. Set up iOS CI/CD
  4. TestFlight beta testing

Verified builds:

  • assembleUniversalFossDebug
  • lintUniversalFossDebug
  • KMP compilation for JVM and iOS targets

@kairosci kairosci marked this pull request as draft February 14, 2026 13:44
- Uncomment include(:app) in settings.gradle.kts to enable app module
- Add kotlin-android plugin to app/build.gradle.kts for KMP compatibility
- Add android.newDsl=false to gradle.properties
- Fix whitespace in build files
Migrate completed() extension functions from old JVM-only innertube to KMP commonMain.
These functions fetch all continuation pages for PlaylistPage and LibraryPage and return complete results.

Fixes compilation errors in app module where .completed() was called on Result<PlaylistPage> and Result<LibraryPage>.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant