I want to untar a file that is in .tar.xz
format. Gradle's tarTree()
does not support this format, so I need to unzip the .xz
to a .tar
, then I can make use of it.
According to the docs, i should be able to do something like this:
ant.untar(src: myTarFile, compression: "xz", dest: extractDir)
However, I get an error:
Caused by: : xz is not a legal value for this attribute
at org.apache.tools.ant.types.EnumeratedAttribute.setValue(EnumeratedAttribute.java:94)
This SO answer talks about using the Apache Ant Compress antlib within Maven. How can I achieve a similar result using Gradle?