I need to copy a file to my machine from a remote machine. Are there any ant targets to do that?
isuruj
0
Newbie Poster
Recommended Answers
Jump to PostIf you mean task instead of target, yes there is.
Read the documentation.
Jump to PostUse the 'copy' task
<project name="blank" default="copy_file"> <property name="srcfile" value="\\remote_mc_name\srcdir\file.txt"/> <property name="destpath" value="C:\destdir"/> <target name="copy_file" > <copy file="${srcfile}" todir="${destpath}"/> </target> </project>
you can use the IP address instead of the remote_mc_name for source file path
All 5 Replies
Ezzaral
2,714
Posting Sage
Team Colleague
Featured Poster
isuruj
0
Newbie Poster
parry_kulk
14
Junior Poster
Team Colleague
Ezzaral
2,714
Posting Sage
Team Colleague
Featured Poster
isuruj
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.