sonatype-nexus-community / scan-gradle-plugin

Gradle plugin that scans the dependencies of a Gradle project using Sonatype platforms: OSS Index and Nexus IQ Server.
Apache License 2.0
77 stars 22 forks source link

New configuration to exclude compileOnly dependencies #156

Closed guillermo-varela closed 7 months ago

guillermo-varela commented 7 months ago

Introduces a new optional configuration to exclude dependencies under the compileOnly configuration, matching the default behavior of the Maven plugin (not including the provided scope): https://help.sonatype.com/en/sonatype-clm-for-maven.html#included-dependencies

ossIndexAudit {
  excludeCompileOnly = true
}

nexusIQScan {
  excludeCompileOnly = true
}

As this configuration is optional and by default false, the existing behavior to include dependencies remains the same for users already using the plugin.

It relates to the following issue #s:

cc @bhamail / @DarthHater / @shaikhu