Maven Ant SCP 错误 [英] Maven Ant SCP error
问题描述
当我使用 ant-command 运行maven-antrun-plugin"(maven 3.0.3)时:
when I run a "maven-antrun-plugin" (maven 3.0.3) with the ant-command:
<scp />
我得到:问题:无法创建任务或键入 scp[ERROR] 原因:找不到类 org.apache.tools.ant.taskdefs.optional.ssh.Scp.
I get: Problem: failed to create task or type scp [ERROR] Cause: the class org.apache.tools.ant.taskdefs.optional.ssh.Scp was not found.
我检查了我的 $ANT_HOME/lib,jar 在那里 (ant-jsch.jar).
I checked in my $ANT_HOME/lib and the jar is there (ant-jsch.jar).
有什么问题吗?
顺便说一句,我使用的是 ubuntu 11.10.Ant 是从网站下载的(从 ubuntu 的仓库我也遇到了同样的问题)
BTW I'm using ubuntu 11.10. Ant is downloaded from the website (as from the ubuntu's repository I got the same problem)
推荐答案
你是不是忘记设置任务定义了
Did you forget to set the task definition
<taskdef name="scp" classname="org.apache.tools.ant.taskdefs.optional.ssh.Scp" classpathref="lib/ant-jsch.jar" />
这篇关于Maven Ant SCP 错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!