Android Flex Mobile Maven构建
我试图找出是否有任何方法可以使用maven构建我的flex mobile项目 当我运行maven构建时,我希望有一个apk文件和一个ipa文件作为构建过程的输出。如果有一种方法也可以运行单元测试,那就太酷了 我想要的是一个解决方案,教程或一个如何处理的例子Android Flex Mobile Maven构建,android,ios,apache-flex,maven,flex-mobile,Android,Ios,Apache Flex,Maven,Flex Mobile,我试图找出是否有任何方法可以使用maven构建我的flex mobile项目 当我运行maven构建时,我希望有一个apk文件和一个ipa文件作为构建过程的输出。如果有一种方法也可以运行单元测试,那就太酷了 我想要的是一个解决方案,教程或一个如何处理的例子 有什么建议吗?我认识的大多数人都会利用这个项目。据我所知,这是一组面向Flex开发人员的Maven插件 Flex Mojos是使用Maven构建Flex应用程序的事实标准。据我所知,它目前不支持移动版本 如果您有使用Ant的经验,您可以编写一
有什么建议吗?我认识的大多数人都会利用这个项目。据我所知,这是一组面向Flex开发人员的Maven插件 Flex Mojos是使用Maven构建Flex应用程序的事实标准。据我所知,它目前不支持移动版本 如果您有使用Ant的经验,您可以编写一个基于Ant的构建,并使用Maven AntRun插件将目标的执行绑定到Maven阶段。下面是一个用于清理、编译、测试和打包的示例:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.6</version>
<executions>
<execution>
<id>clean-project</id>
<phase>clean</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks>
<ant antfile="${basedir}/build/build.xml">
<target name="clean"/>
</ant>
</tasks>
</configuration>
</execution>
<execution>
<id>create-swf</id>
<phase>compile</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks unless="flex.skip">
<ant antfile="${basedir}/build/build.xml">
<target name="compile"/>
</ant>
</tasks>
</configuration>
</execution>
<execution>
<id>flexunit-tests</id>
<phase>test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks unless="maven.test.skip">
<ant antfile="${basedir}/build/build.xml">
<target name="test"/>
</ant>
</tasks>
</configuration>
</execution>
<execution>
<id>generate-asdoc</id>
<phase>package</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks unless="asdoc.skip">
<ant antfile="${basedir}/build/build.xml">
<target name="asdoc"/>
</ant>
</tasks>
</configuration>
</execution>
<execution>
<id>dist</id>
<phase>package</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks>
<ant antfile="${basedir}/build/build.xml">
<target name="dist"/>
</ant>
</tasks>
</configuration>
</execution>
</executions>
<dependencies>
<!--
since we are using maven-antrun 1.6 which depends on ant 1.8.1
make sure the version number on ant-junit matches
-->
<dependency>
<groupId>org.apache.ant</groupId>
<artifactId>ant-junit</artifactId>
<version>1.8.1</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
org.apache.maven.plugins
maven antrun插件
1.6
清洁工程
清洁的
跑
创建swf
编译
跑
flexunit测试
测试
跑
生成asdoc
包裹
跑
距离
包裹
跑
org.apache.ant
小白蚁
1.8.1
我也需要它
我在谷歌上搜索了一下……以下是我为纯maven解决方案找到的结果……到目前为止,请看这篇博文,我试过了,它是有效的
然而,它是付费版本,没有正式发布
也许我会使用纯Ant,不是花哨的,而是更高效的作为额外的功能,我已经使用Ant构建来编译/打包/部署。您应该查看该项目,并在maven构建中使用Ant脚本来完成所有需要的工作。