Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我遇到了 ant build 在目标上 2 小时后失败的情况,一旦问题得到修复,构建应该从失败的目标运行而不更改构建默认命令,这意味着要在整个构建生命周期中节省 2 小时的构建过程。我们怎样才能达到这种情况。请帮助我。
问候, Sankar B.
我将您的问题解释为您想从失败的那个开始构建过程,跳过依赖目标。你不能跳过我知道的依赖目标。
你可以尝试这样的事情。对于每个目标,创建两个目标。一个实际完成工作,一个调用依赖目标。在你的情况下,你会想要运行someTaskImpl.
someTaskImpl
<target name="someTask" depends="init"> <antcall target="someTaskImpl" /> </target> <target name="someTaskImpl"> <!-- do stuff --> </target>