Switch from dependency Flat file to repository


(Tyrel E) #1

Hello,
I am looking for tools or tips for converting dependency management from flat file into a repository. Specifically, we want to identify transitive dependencies and have the maven repository manage the transitive dependencies.

The Why: We are encountering jar’s transitive dependencies are conflicting with other jar’s transitive dependencies.

Would the build scan or the dependency insight report help map out the dependencies to make the switch an easier process?

We don’t currently have an enterprise license and don’t want to publish the scan results, but if it would help in this switch, we would have to reconsider.

Thank you for any insights or help!


(uklance) #2

Do your jars have pom.xml packed inside? You could possibly write a script to extract and parse the pom.xml from each jar and store in a maven convention directory layout


(Tyrel E) #3

Unfortunately we don’t on all of the jars.
We might be able to do that though to reduce some of the heavy lifting. I’ll have to look into that further.

Great idea!
Thanks,


(uklance) #4

You can actually do this in a gradle script, gradle makes it super easy to

  • Find/extract files from zips
  • Parse xml
  • Copy files to new locations