Skip to content

Shadow is not working with Kotlin Multiplatform plugin #484

@Danilo-Araujo-Silva

Description

@Danilo-Araujo-Silva

Please check the User Guide before submitting "how do I do 'x'?" questions!

Shadow Version

5.0.0

Gradle Version

5.3.1

Expected Behavior

The shadowJar task should appear and work.

Actual Behavior

Only the knows task appears and the shadow task don't appear and don't work.

Gradle Build Script(s)

import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
...
plugins {
    kotlin("multiplatform")

    id("com.github.johnrengelman.shadow") version "5.0.0"
}
...
tasks.withType<ShadowJar> {
    baseName = "app"
    classifier = ""
    version = ""
}

//// This works but do not really creat the fatJar, java -jar myFatJar.jar doesn't run and inside of this jar we have just a MANIFEST.MF with a single line of information.
//tasks.create("shadowJar", ShadowJar::class.java) {
//	baseName = "my_project"
//	classifier = ""
//	version = ""
//}

Content of Shadow JAR (jar tf <jar file> - post link to GIST if too long)

None.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions