[prev in list] [next in list] [prev in thread] [next in thread]
List: ant-user
Subject: Re: How to add/update files in a tar file?
From: Stefan Bodewig <bodewig () apache ! org>
Date: 2000-11-30 8:40:42
[Download RAW message or body]
Markus Albrecht <markus.albrecht@v-connect.com> wrote:
> Although I'd like to switch to a tar file, since it preservers
> access rights for unix systems.
The <tar> task doesn't, you will have to switch to <exec>, <execon> or
(if using development versions) <transform> and use the tar executable
for that.
This would something like
<execon executable="tar" parallel="true">
<arg value="-u" />
<arg value="-f" />
<arg file="release.tar" />
<fileset dir="${home1}">
<patternset ... />
</fileset>
<fileset dir="${home2}">
<patternset ... />
</fileset>
</execon>
or using undocumentated and not really stable (in terms of API) stuff
that has been added after the 1.2 release:
<transform executable="tar" parallel="true" dest=".">
<arg value="-u" />
<arg value="-f" />
<arg file="release.tar" />
<fileset dir="${home1}">
<patternset ... />
</fileset>
<fileset dir="${home2}">
<patternset ... />
</fileset>
<mapper type="merge" to="release.tar" />
</transform>
the latter will only pass the files that are actually newer that the
archive on the command line.
> How can I add/update to an existing tar file more files?
You can't using <tar>, again, you'll need to use the command line.
Stefan
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic