Saturday, February 25, 2012

Project: Headless Appcelerator

Step 1: Create a basic maven pom with a packaging type of titanium

[sourcecode language="xml"]

<?xml version="1.0" encoding="UTF-8"?&gt;
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion></pre>
<groupId>com.codingspaces.appcelerator</groupId>
<artifactId>headless</artifactId>
<version>1.0</version>
<packaging>titanium</packaging>
<name>Appcelerator :: Headless</name>
<description>Headless Builds with Appcelerator</description>
<inceptionYear>2011</inceptionYear>
<organization>
<name>CodingSpaces</name>
</organization>
<url>http://www.codingspaces.com</url>

...

</project>
[/sourcecode]

Step 2: Add the java script plugin

[sourcecode language="xml"]
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
...
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo.javascript</groupId>
<artifactId>javascript-maven-plugin</artifactId>
<version>1.1-softec</version>
<extensions>true</extensions>
<configuration>
<platform>android</platform>
<androidAPI>11</androidAPI>
<titaniumVersion>${titanium.sdk.version}</titaniumVersion>
<titaniumSettings>
<androidSDK>${ANDROID_HOME}</androidSDK>
</titaniumSettings>
</configuration>
</plugin>
</plugins>
</build>
...
</project>
[/sourcecode]
Post a Comment