I am attempting to include an mp project in an Android app in Android Studio via the settings.gradle include and project().projectDir mechanism. Unfortunately, I can find the right incantation to have it build just the jvm/android lib/jar needed by the app. I have tried starting with an IDEA MP project and adding the Android library stuff, and also from a vanilla AS generated library and adding the kotlin-multiplatform plugins. But I have not been able to do it. My goal is to have the common shared lib in one repo, which is referenced from all the Android and iOS apps. Anybody get anything like this working? Please?
To answer myself: first issue was using jvm() instead of android(). Using Android I can get much further.
05/12/2019, 4:27 PM
Is the path to your shared project outside of your project path? I've only ever done it using a mono repo and everything underneath one directory. Could you accomplish something similar with git submodules?
05/13/2019, 6:57 PM
I did try submodules, but things got confused with another location where i had the linked repo checked out too.
i have made progress, but having both IntelliJ IDEA and Android Studio running and pointing to the same build files results in a lot of ‘Gradle needs to update’ kind of messages.