我正在尝试使用Ant任务上传文件.如果我直接使用Ant文件被上传,但是如果我通过Maven调用ant任务(使用maven-antrun-plugin),我会收到以下错误:
发生了Ant BuildException:执行此行时发生以下错误:
/home/me/proj/build.xml:15: Problem: failed to create task or type ftp
Cause: the class org.apache.tools.ant.taskdefs.optional.net.FTP was not found.
This looks like one of Ant's optional components.
Action: Check that the appropriate optional JAR exists in
-ANT_HOME/lib
Run Code Online (Sandbox Code Playgroud)
Ant-commonsnet.jar显然可用于Ant:
$ ls $ANT_HOME/lib | grep ant-commons-net
ant-commons-net.jar
Run Code Online (Sandbox Code Playgroud)
Ant类路径是为maven-antrun-plugin单独定义的,还是我错过了什么?