Creating SymLinks with relative paths shouldn't be too hard for ant. However,
I can't figure out the right way to do it.

Using bash commands, I'd do

cd dir_b
ln -s ../../dir_a/*.xml .

yielding symbolic links within dir_b that look like ../../dir_a/file1.xml
etc.

What is the equivalent of this in ant? I have only managed to get absolute
paths with the code below (while the "relative" attribute will just link
file1.xml to file1.xml without any relative path) :

<apply executable="ln"
  dir="dir_b">
  <arg value="-sf"/>
  <srcfile/>
  <fileset dir="../../dir_a">
    <include name="*.xml"/>
  </fileset>
  <arg value="."/>
  <mapper type="identity"/>
</apply>

As I have fixed paths here, I considered putting the call to "ln" into a
single <exec>, but then how to change the working directory first?

  Yves

-- 
View this message in context: 
http://www.nabble.com/Creating-SymLinks-with-relative-paths-tf4751944.html#a13587787
Sent from the Ant - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to