Android.Tools.Ant
ant
1. ant手册翻译
ant手册翻译是一项大工程!!!!!!
ant在线手册的链接好不明确。
2. ant 支持for循环
安装ant-contrib Ref[1.1]. 要在ant的build.xml脚本中支持,参考链接Ref[1.2]。
下面的build.xml是遍历txt文件,将每一行进行输出的ant脚本。Ref[1.3]
<?xml version="1.0" encoding="UTF-8"?>
<project name="android_rules" default="iterate"> <taskdef resource="net/sf/antcontrib/antlib.xml"/> <target name="iterate">
<loadfile property="lines" srcFile="CopyRes.txt">
<filterchain>
<filterreader classname="org.apache.tools.ant.filters.StripLineBreaks">
<param name="linebreaks" value="\n"/>
</filterreader>
</filterchain>
</loadfile> <for list="${lines}" param="line">
<sequential>
<echo>@{line}</echo>
</sequential>
</for> </target> </project>
Reference
1. ant-contrib
1.1 http://ant-contrib.sourceforge.net
1.2 http://ant-contrib.sourceforge.net/tasks/index.html
1.3 http://stackoverflow.com/questions/5087929/how-to-iterate-over-the-file-content-using-ant-script
2. ant 工程主页
http://ant.apache.org/
| Running Apache Ant |
Command Line Running Ant as a background process on Unix(-like) systems Running Ant via Java |
|
Properties |
Built-in Properties PropertyHelpers Property Expansion
Nesting of Braces Expanding a "Property Name" If/Unless Attributes |
|
Filter |
|
|
Typedef |
Adds a task or a data type definition to the current project such that this new type or task can be used in the current project. |
|
FileSet |
A FileSet is a group of files. These files can be found in a directory tree starting in a base directory and are matched by patterns taken from a number of PatternSets and Selectors. |
|
Task |
http://ant.apache.org/manual/Tasks/ http://ant.apache.org/manual/Tasks/conditions.html http://ant-contrib.sourceforge.net/tasks/tasks/index.html |
|
FilterSet |
http://ant.apache.org/manual/Types/filterset.html FilterSets are groups of filters. Filters can be defined as token-value pairs or be read in from a file. FilterSets can appear inside tasks that support this feature or at the same level as |
|
FilterChains and FilterReaders |
http://ant.apache.org/manual/Types/filterchain.html |
Android.Tools.Ant的更多相关文章
- linux(以ubuntu为例)下Android利用ant自动编译、修改配置文件、批量多渠道,打包生成apk文件
原创,转载请注明:http://www.cnblogs.com/ycxyyzw/p/4555328.html 之前写过一篇<windows下Android利用ant自动编译.修改配置文件.批量 ...
- windows下Android利用ant自动编译、修改配置文件、批量多渠道,打包生成apk文件
原创文章,转载请注明:http://www.cnblogs.com/ycxyyzw/p/4535459.html android 程序打包成apk,如果在是命令行方式,一般都要经过如下步骤: 1.用a ...
- 〖Android〗ant build android project, setting android.jar precedence
最近公司的一个项目中,新增了classes.jar包,与android.jar有冲突,必须得在加载android.jar前行加载classes.jar: 在持续集成环境中须使用ant编译,classe ...
- android的ant编译打包
Android本身是支持ant打包项目的,并且SDK中自带一个build.xml文件. 通过该文件,可以对文件进行编译.打包.安装等.并且支持多种方式打包,如debug或者release. 一般的,可 ...
- 解决 Could not find com.android.tools.build:gradle 问题
今天拉同事最新的代码,编译时老是报如下错误: Error:Could not find com.android.tools.build:gradle:2.2.0.Searched in the fol ...
- Could not find com.android.tools.build:gradle:1.3.0.
* What went wrong: A problem occurred configuring project ':TZYJ_Android'.> Could not re ...
- Android requires compiler compliance level 5.0 or 6.0. Found '1.8' instead. Please use Android Tools>Fix project Properties.
重装操作系统之后,或者破坏了Android的开发环境之后,需要重新配置好Android的开发环境.但是配置好后,导入原有的项目时,报错: Android requires compiler compl ...
- Failed to apply plugin [id 'com.android.application'] 和 Could not find com.android.tools.build:gradle:2.XX的最正确的解决方法
发现android studio是真的可爱啊,上一秒还没问题可以build运行,下一秒就出错...好,你任性,你牛逼.. 说下今天又遇到的两个问题:Failed to apply plugin [id ...
- linux ant 解决 错误: 找不到或无法加载主类 org.apache.tools.ant.launch.Launcher
在使用ant进行java程序编译的时候出错.错误提示: Error: Could not find or load main class org.apache.tools.ant.launch.Lau ...
随机推荐
- 学JS的心路历程-物件与原型(三)
昨天有说明到函式与建构式的原型,及指定建构式函式原型为另一个建构式函式,但其实这会造成复写constructor的问题. 复写constructor的问题(vmwork) 我们昨天有提到「建构式函式可 ...
- 大数据_Kafka_Kafka自动创建不存在的Topics / 删除已存在的Topics
大数据_Kafka_Kafka自动创建不存在的Topics / 删除已存在的Topics 2016年10月11日 18:22:59 高达一号 阅读数:8655 版权声明:本文为博主原创文章,未经博 ...
- 附加任务:团队作业7 Alpha冲刺
附加任务:团队作业7 Alpha冲刺 附加任务要求参考东北师范大学陈志勇老师博客:https://edu.cnblogs.com/campus/nenu/2016SE_NENU/homework/19 ...
- com.android.dx.command.Main with arguments
Error:Execution failed for task ':jingyeyun:transformClassesWithDexForDebug'.> com.android.build. ...
- vi 基本命令使用
vi编辑器是所有Unix及Linux系统下标准的编辑器,它的强大不逊色于任何最新的文本编辑器,这里只是简单地介绍一下它的用法和一小部分指令.由于对 Unix及Linux系统的任何版本,vi编辑器是完全 ...
- 关于JavaScript全局作用域和函数作用域的拙见
在类c的语言中,用{}引起来的部分称为块级作用域,而在JS中没有块级作用域 作用域:一个变量作用的范围:中Js中一共有两种作用: 全局作用域 - 直接编写在script标签中的JS代码,都在全局作用域 ...
- 全国高校绿色计算大赛 预赛第二阶段(Python)第1关:统计分数的麻烦
挑战任务 “绿盟杯”比赛过后,赛事承办方的各位工作人员们就开始分头统计各个参赛队伍和同学的成绩了.赛事规模很大,有10000个队伍参加.经过工作人员认真负责的统计,本来已经统计好了这一万个队伍的分数和 ...
- ucore-lab1-练习2report
练习二实验报告 1.从CPU加电后执行的第一条指令开始,单步跟踪BIOS: 1.1默认的gdb需要进行一些额外的配置才能进行qemu的调试任务,qemu和gdb之间使用网络端口1234进行通信. la ...
- linux之docker学习
1.redis主从同步 可以主从数据同步,从库只读,只能手动切换主备关系2.redis哨兵 -准备redis主从数据库环境 -准备redis哨兵(可以有一个,可以有多个) -哨兵检测redis主库状态 ...
- TOJ3955: NKU ACM足球赛(并查集+map+细节题)
时间限制(普通/Java):5000MS/15000MS 内存限制:65536KByte 描述 NKU ACM最近要举行足球赛,作为此次赛事的负责人,Lee要对报名人员进行分队.分队要遵循如下 ...