Skip to content

added support for maven pom files with artifact-id variables in scm urls

Bitbucket Importer requested to merge bitbucket/merged-pr-6 into branch/default

Created originally on Bitbucket by nadirj (Nadir Janmohamed)

Was already merged in Bitbucket before import, marked as merged by the import user

Some maven based eclipse projects use the variable ${project.artifactId} in the scm section of their pom files (for example the javahg projects do this)

This changeset resolves the url that it can be cloned.

To try it you need a maven m2e based eclipse project (and this plugin aswell as the m2e plugin)

  1. In Package Explorer expand the m2e based project
  2. In the project expand the "Maven Dependencies"
  3. Select a maven jar/artifact where the maven artifact uses mercurial (example javahg-0.8-SNAPSHOT) and this artifact isn't already in your workspace
  4. Right click on this artifact -->Maven--> Import Project(s) from SCM
  5. Follow the first and then second dialog and artifact will be cloned from its Mercurial repo and then imported in your workspace

Note the artifact that you use this with must have something like the following in its pom file: scm:hg:https://bitbucket.org/aragost/${project.artifactId} scm:hg:ssh://hg@bitbucket.org/aragost/${project.artifactId} https://bitbucket.org/aragost/${project.artifactId}/src

Merge request reports