smartics / smartics-enforcer-rules

A collection of rules for the Maven enforcer plugin.
Other
1 stars 0 forks source link

NoSnapshotsInDependencyManagementRule: LATEST should be resolved before version check #2

Open barthel opened 8 years ago

barthel commented 8 years ago

The 'shortcut' version LATEST of BOM import should be resolved before operating the version check.

[...]
  <properties>
    <tld.company.product.shared-dependencies.version>LATEST</tld.company.product.shared-dependencies.version>
  </properties>
[...]
  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>tld.company.product</groupId>
        <artifactId>tld.company.product.shared-dependencies</artifactId>
        <version>${tld.company.product.shared-dependencies.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>
[...]

or without <properties>

[...]
  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>tld.company.product</groupId>
        <artifactId>tld.company.product.shared-dependencies</artifactId>
        <version>LATEST</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>
[...]