I am unpacking java as a preinstall step, but need a jar file that is in another zip.

Can I unpack just that file from the zip using unpackfile? If so, how do I reference it?

thanks!

asked 02 Apr '12, 10:37

bstoke's gravatar image

bstoke
16222224
accept rate: 0%


It is not possible to unpack files from a bundled zip file without unpacking it. Would be possible to bundle the jar file in a separate <distributionFile>? You could include the process of unpacking the zip and moving the jar to a temporary location in the <preBuildActionList>:

<project>
  ...
  <preBuildActionList>
     <unzip>
        <destinationDirectory>${system_temp_directory}/</destinationDirectory>
        <zipFile>${build_project_directory}/jars.zip</zipFile>
      </unzip>
  </preBuildActionList>
  ...
  <componentList>
    <component>
    <name>jar</name>
       <folderList>
           <folder>
             <name>jar_file</name>
             <destination>${system_temp_directory}</destination>
             <distributionFileList>
                <distributionFile origin="${system_temp_directory}/file.jar"/>
             </distributionFileList>
          </folder>
       </folderList>
    </component>
  </componentList>
  ...
</project>
link

answered 03 Apr '12, 17:02

juanjo's gravatar image

juanjo ♦♦
5.8k413
accept rate: 23%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×50
×19
×9
×4

Asked: 02 Apr '12, 10:37

Seen: 1,532 times

Last updated: 03 Apr '12, 17:02