English 中文(简体)
How to create symbolic links in the output .tar.gz file?
原标题:

We are using Windows as a development system and Ant to create the platform-specific bundles. For the macOS specific bundle (.tar.gz file) we are using the tar task. I want to create a symbolic link in the output .tar.gz file which points to another file in the same .tar.gz file. Can this be done using Ant?

最佳回答

To the best of my knowledge stock Ant can t do this.

问题回答

Bit late, but suggestion: you can create tar archives containing symlinks from windows command line using cygwin.

$ ln -s abc def
$ tar cf test.tar abc def
$ tar tvf test.tar
-rw-r--r-- shegny/Domain Users 0 2013-04-26 10:25 abc
lrwxrwxrwx shegny/Domain Users 0 2013-04-26 10:25 def -> abc

You cannot create a symbolic link on Windows. Therefore, the Symlink Ant task would not work properly. One option would be to run a continuous build server on a Mac machine. Then, you could run that task at regular intervals and the Symlink Ant task would work.





相关问题
i want to continously run my java threads

I am running my java application where i have used threads... i am running this application using ant command on the terminal.. But when i close my terminal or press ctrl+c,then java program which was ...

Subant targets instead of ant

I m having a problem with subant and have no ideas any more. Can anyone help? Using Ant to replace some strings for other (i.e Productname and Version for "Foo" and "1.2") I used ...

java ant buildfile for project with dependencies

I am new to ant, but am trying to create an ant script that builds my current proeject with another project as a dependency. I have the ant script building my current project, but am unsure how to add ...

Building Apache Hive - impossible to resolve dependencies

I am trying out the Apache Hive as per http://wiki.apache.org/hadoop/Hive/GettingStarted and am getting this error from Ivy: Downloaded file size doesn t match expected Content Length for http://...

Ivy, ant and start scripts

I have a project that uses ant to build and ivy for dependencies. I would like to generate the start scripts for my project, with the classpath, based on the dependencies configured in Ivy, ...

热门标签