Search code examples
rubycommand-linejarbuildr

Sending files made by `jar xf` to another directory


I have a JAR with a bunch of configs. I'd like to send them to the correct directory without cd'ing there.

Something like jar xf config.jar --MAGIC-PARAM PATH/TO/DIRECTORY

Is there such a thing? If it helps, this will be called by a Buildr extension (Ruby).


Solution

  • From the API documentation: http://buildr.apache.org/rdoc/classes/Buildr/Unzip.html

      unzip(dir => zip_file).target.invoke