Murali krishna Konduru
Murali krishna Konduru

Reputation: 191

pom.xml and pom.properties are not found in dom4j(2.1.1).jar, is there any other way to find pom properties

To convert ant to maven, I am constructing pom.xml programmatically based on list of jars. Few jars like log4j are having pom.xml and pom.properties are found with in the jar. Some other jars like dom4j not having pom.xml and pom.properties. how to get groupid, artifactid and version for the dom4j.

enter image description here

I am greateful for the suggestions.

Upvotes: 0

Views: 230

Answers (1)

J Fabian Meier
J Fabian Meier

Reputation: 35805

I had the same problem two years ago. I had hundreds of jars that needed to be matched to Maven coordinates.

My procedure was roughly as follows:

  • Look for pom
  • Look for the sha1 in MavenCentral
  • try to extract artifactId and version from the file name. Search that in MavenCentral. Often, there is only one (sensible) groupId.
  • If the version cannot be determined or the groupId is ambiguous, extract the classes from the jars and compare them to find a match.

I actually spend many days doing just this.

Upvotes: 1

Related Questions