Skip to content
This repository has been archived by the owner on Sep 14, 2021. It is now read-only.
This repository has been archived by the owner on Sep 14, 2021. It is now read-only.

${project.basedir} not interpolated in repositories #63

Open
jkinkead opened this issue Sep 27, 2017 · 0 comments
Open

${project.basedir} not interpolated in repositories #63

jkinkead opened this issue Sep 27, 2017 · 0 comments

Comments

@jkinkead
Copy link
Contributor

This bug may just be "interpolation does not happen anywhere", but I'm specifically running into issues with local repositories like this:

<project xmlns="http://maven.apache.org/POM/4.0.0"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
                      https://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <repositories>
    <repository>
      <id>project.local</id>
      <name>project</name>
      <url>file:${project.basedir}/repo</url>
    </repository>
  </repositories>

  <groupId>com.example</groupId>
  <artifactId>example</artifactId>
  <version>0.1.0-SNAPSHOT</version>
  <packaging>pom</packaging>
</project>

The repo directory here would contain a local maven repository with artifacts.

For whatever reason, the resolver is never getting the ${project.basedir} value interpolated, and therefore sees a bad filename.

I've tried numerous changes, but can't figure out what's missing. The relevant section of the docs implies it should Just Happen, although I also think that the wiping of profiles that the model resolver does is contributing the problem. Without any profiles set, this won't get interpolated - although removing that line doesn't actually fix the problem.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant