GW2ToolBelt / GW2ChatLinks

A Kotlin Multiplatform library for parsing and generating Guild Wars 2 chat links.
https://gw2toolbelt.github.io/GW2ChatLinks
MIT License
2 stars 0 forks source link

Improve publication for non-Gradle consumers #18

Closed TheMrMilchmann closed 5 months ago

TheMrMilchmann commented 7 months ago

By default, the Kotlin multiplatform publishes a mostly empty publication under the default artifact coordinates (com.gw2tb.gw2chatlinks:gw2chatlinks). Gradle uses its module metadata published under these coordinates to determine which platform artifact to pick. However, the Gradle module metadata is not read by other consumers (e.g. Maven). Thus, to use the library with Maven, one would currently have to depend on the JVM platform artifact (gw2chatlinks-jvm) instead. This is unexpected and can lead to confusion and frustration when debugging unexpected dependency resolution failures. To mitigate this issue, kotlinx.serialization and Arrow customize the main publication to work around this issue.

The goal of this issue is to implement a similar mitigation strategy.