我有一个标准的 android 生成的构建脚本。我的custom_rules.xml构建脚本。
<project>
<target name="-minify" >
// More code here
</target>
<target name="-modify-index-html" >
// More code here
</target>
<target name="-post-compile" depends="-minify"/>
<target name="-post-package" depends="-modify-index-html"/>
</project>
问题是我不想要目标-minify并-modify-index-html在运行debug构建时运行。事实上,它们必须仅在运行release目标时运行。