versionMapping

abstract fun versionMapping(configureAction: Action<in VersionMappingStrategy>)(source)

Configures the version mapping strategy. For example, to use resolved versions for runtime dependencies:

plugins {
    id 'java'
    id 'ivy-publish'
}

publishing {
  publications {
    maven(IvyPublication) {
      from components.java
      versionMapping {
        usage('java-runtime'){
          fromResolutionResult()
        }
      }
    }
  }
}

Since

5.4

Parameters

configureAction

the configuration