FDT, ANT and FTP
Posted: May 28th, 2009 | Author: erik | Filed under: ANT, FDT | Tags: ANT, FDT, FTP |The default installed ANT in Eclipse doesn’t seem to support FTP protocols. To be able to use this feature, you’ll need to add 2 extra *.jar files, which are:
Save these files in the following folder: /Applications/FDT3/plugins/org.apache.ant_***/bin/
Now goto: Preferences > ANT > Runtime > Classpath
The screen should be like the one below.
Now click ‘Add External JARs’ button and select the 2 files you just added ( /Applications/FDT3/plugins/org.apache.ant_***/bin/ ). Now click ‘apply’ and then ‘ok’.
Next thing is to add code to your build.xml file, which contains all your ANT tasks.
To use FTP from within ANT you’ll need to add something like this to your build.xml file:
<target name="ftp_upload" description="uploads files through ftp"> <echo message="uploading files" /> <ftp server="123.456.78.90" port="21" remotedir="/www/ant_upload_test" userid="my_user_id" password="my_password" passive="no" depends="yes" binary="yes"> <fileset dir="../bin" /> </ftp> </target>
Now you’re ready to go.
Extra info:
Good tutorial for using ANT with FDT
More info about FTP options in ANT

Great thanks!