Polyglot for Maven 0.1.6 Released! How to Quickly Translate POMs

Polyglot for Maven 0.1.5 was released last week and the feedback is more positive that we could have imagined. Again, we have to stress that we really don’t know what will happen with Polyglot for Maven but we are definitely seeing people keen to use it. Many people are asking “Is there a tool I can use to convert my existing pom.xml files?” Now there is! With the release of 0.1.6 now available in Maven Central there is a translation tool available.

We have created a simple Maven Plugin that will help you convert any existing pom.xml files:

mvn io.takari.polyglot:polyglot-translate-plugin:translate -Dinput=pom.xml -Doutput=pom.{format}

Where the supported formats are rb, groovy, scala, yaml, and atom.

So if you want to convert your pom.xml files to pom.rb files then use the following command:

mvn io.takari.polyglot:polyglot-translate-plugin:translate -Dinput=pom.xml -Doutput=pom.rb

You can run this command from the top-level of your multi-module project as well and it will convert all of your pom.xml files.

Just a recap that if you want to try Polyglot for Maven then you can do so by adding a ${maven.multiModuleProjectDirectory}/.mvn/extensions.xml file with something like the following:

<?xml version="1.0" encoding="UTF-8"?>
<extensions>
  <extension>
    <groupId>io.takari.polyglot</groupId>
    <artifactId>polyglot-ruby</artifactId>
    <version>0.1.6</version>
  </extension>
</extensions>

Again, please note that to use Polyglot for Maven you must use Apache Maven 3.3.1 with the new dynamic core extension loading mechanism.

We have put some examples together that we hope will get fleshed out by the community:

https://github.com/takari/polyglot-maven-examples

The implementation itself you can find here:

https://github.com/takari/maven-polyglot

If you’re interested in learning more about Polyglot for Maven and please feel free to ask questions and leave comments!

 

Comments

Maven Training

To use Maven correctly you'll need to understand the fundamentals. This class is designed to deliver just that.

Introduction to Maven
 

Stay Connected

 

Newsletter

Subscribe to our newsletter and stay up to date with the latest news and events!