One minute
Reading a POM from Gradle
Reading a Maven POM is Easy with Gradle and Groovy!
The inspiration for this post came from the post here: Reading info from existing pom.xml file using Gradle?
Naively I implemented the first solution which is given below.
Now, this solution did meet the original posters requirement. However, after running the hello task I was surprised to see a few libs being downloaded which didn’t feel slick.
In true groovy fashion this could be achieved much more simply using the code below: