carnival-data / carnival

JVM property graph data unification framework
https://carnival-data.github.io/carnival/
GNU General Public License v3.0
7 stars 2 forks source link

Disable signing for publishToMavenLocal #88

Closed augustearth closed 2 years ago

augustearth commented 2 years ago

Signing is turned on for all publishing tasks. If a signatory is not configured, publish tasks fail. Should be able to publish to maven local without a signatory.

Comments from @th5: My idea for a fix is to disable signing when publishing to maven local. I'm busy with jury duty this week but I'll be able to give Carnival more time next week.

I tried it and it seems to work but not extensively tested on different gradle tasks. Probably a good idea to switch the logic around to set signing as not required if publishToMavenLocal is a task.

apply plugin: "signing"
signing {
    sign publishing.publications

    setRequired {
        // signing is only required if the artifacts are to be published
        gradle.taskGraph.allTasks.any { it.equals( PublishToMavenRepository) }
    }
}