Maven 2.x Ant Plugin

The generated maven-build.xml and maven-build.properties contains absolute path to local repository

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 2.0
  • Fix Version/s: 2.1
  • Component/s: None
  • Labels:
    None
  • Number of attachments :
    0

Description

Even though the local repository is in the default location ${user.home}/.m2/repository, the generated files contains absolute paths for maven.repo.local. Ant knows about ${user.home} so that can be used in both files.

Issue Links

Activity

Hide
Benjamin Bentmann added a comment -

I just tweaked your original fix such that the maven-build.xml always uses the generic value "${user.home}/.m2/repository". This build file is meant to be under version control and hence shared among different users, absolute paths are not of any use here.

The path to the local repo is a user-specific setting, it should therefore be configured in the ${user.home}/.m2/maven.properties that is imported by the maven-build.xml.

Show
Benjamin Bentmann added a comment - I just tweaked your original fix such that the maven-build.xml always uses the generic value "${user.home}/.m2/repository". This build file is meant to be under version control and hence shared among different users, absolute paths are not of any use here. The path to the local repo is a user-specific setting, it should therefore be configured in the ${user.home}/.m2/maven.properties that is imported by the maven-build.xml.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: