DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=43426>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=43426

           Summary: <symlink> cant create a symlink over a file, whereas ln
                    -sf does allow you
           Product: Ant
           Version: 1.7Alpha (nightly)
          Platform: Other
        OS/Version: other
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Optional Tasks
        AssignedTo: dev@ant.apache.org
        ReportedBy: [EMAIL PROTECTED]


if you create a file with <touch>, you can't link over it using <symlink>, but
ln -sf lets you do it quite happily.

  <target name="testCreateOverFile" depends="init" if="unix">
    <touch file="${build.dir}/link3" />
    <symlink overwrite="true" link="${build.dir}/link3"
        resource="${file_ref}"/>
  </target>

/home/slo/Java/Apache/ant/src/tests/antunit/taskdefs/optional/unix/symlink-test.xml:52:
Unable to overwrite preexisting link:
/home/slo/Java/Apache/ant/src/tests/antunit/taskdefs/optional/unix/build/link3
        at
org.apache.tools.ant.taskdefs.optional.unix.Symlink.handleError(Symlink.java:472)
        at
org.apache.tools.ant.taskdefs.optional.unix.Symlink.doLink(Symlink.java:493)
        at
org.apache.tools.ant.taskdefs.optional.unix.Symlink.single(Symlink.java:167)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at
org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:76)
        at org.apache.tools.ant.Task.perform(Task.java:348)
        at org.apache.tools.ant.Target.execute(Target.java:357)
        at org.apache.tools.ant.Target.performTasks(Target.java:385)
        at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
        at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
        at org.apache.tools.ant.Main.runBuild(Main.java:758)
        at org.apache.tools.ant.Main.startAnt(Main.java:217)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)



We should resort to using ln -sf to force through actions if overwrite=true, and
downgrade this fault a verbose message

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

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

Reply via email to