Display used artifact versions

Consider I have specified a dependency to an artifact like this:

dependencies {
        classpath group: 'org.gradle', name: 'customPlugin', version: '1.+'
    }

For documentation I would like to show which version of the plugin is used during execution phase.

How would that be possible ?

Thanks, detlef

You should be able to code a solution based on ‘configurations.classpath.resolvedConfiguration.resolvedArtifacts’ or ‘configurations.classpath.incoming.afterResolve {}’. Have a look at the Javadoc for ‘org.gradle.api.artifacts.Configuration’.