Hello, I am having a hard time publishing my multi...
# multiplatform
d
Hello, I am having a hard time publishing my multiplatform library to Sonatype. My build.gradle file is this: https://github.com/dragossusi/sevens-payload/blob/master/payload/build.gradle.kts I somehow made it work, but it creates 2 repositories at the same time, 1 fails everytime.
g
I had a similar problem with my Gradle plugin. Unfortunately, I can’t remember how I solved it 😕However, perhaps it helps to compare the two build files, adjust the differences and test if it starts working https://github.com/ge-org/multiplatform-swiftpackage/blob/master/build.gradle.kts
d
looks like you use jvm only
I am able to publish Kotlin/JVM, but I have problems with MPP 😞
a
I don't know much about sonatype, but here's my working approach after "alot" of hit & trials for publishing to jcenter/bintray: https://github.com/Animeshz/keyboard-mouse-kt/blob/0e70744571f73ef5f5b1b3a274fea04db1572956/build.gradle.kts#L20-L72
By the way kotlin-multiplatform plugin automatically generates the sources jar for non-jvm targets automatically, so you don't need to specify your own.
j
I moved to another plugin which uses maven-publish under the hood because some times I get multiple repositories
d
I think I managed to make it work
👍 1