All Downloads are FREE. Search and download functionalities are using the official Maven repository.

archetype-resources.pom.xml Maven / Gradle / Ivy

There is a newer version: 1.4.0
Show newest version
<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>\${groupId}</groupId>
    <!--ideally, we'd like this to follow the format of "PROJECTNAME-android"-->
    <artifactId>\${artifactId}</artifactId>
    <version>\${version}</version>
    <packaging>apk</packaging>
    <name>\${artifactId}</name>

    <properties>
        <platform.version>
            4.1.1.4
        </platform.version>

        <!-- you'll need to generate a keystore and put it at the root of your project and change these -->
        <sign.keystore>PROJECT_KEYSTORE_FILE.keystore</sign.keystore>
        <sign.keyalias>PROJECT_KEY_ALIAS</sign.keyalias>

        <!-- the following values will be overwritten on the command line when using the "sign" profile (in CI) -->
        <sign.storepass>DONT_ACTUALLY_PUT_THE_PASSWORD_HERE</sign.storepass>
        <sign.keypass>DONT_ACTUALLY_PUT_THE_PASSWORD_HERE</sign.keypass>
        <app.versioncode>9999</app.versioncode>

    </properties>

    <scm>
        <!--The following is needed for auto-tagging for "mvn release:prepare"-->
        <!--<developerConnection>scm:git:[email protected]:willowtreeapps/PROJECT_NAME.git</developerConnection>-->
        <!--<tag>HEAD</tag>-->
    </scm>


    <repositories>
        <repository>
            <id>sonatype-nexus-snapshots</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
            <snapshots>
                <enabled>true</enabled>
                <checksumPolicy>warn</checksumPolicy>
                <updatePolicy>always</updatePolicy>
            </snapshots>
            <releases>
                <enabled>false</enabled>
            </releases>

        </repository>
    </repositories>

    <dependencies>
        <dependency>
            <groupId>com.google.android</groupId>
            <artifactId>android</artifactId>
            <version>\${platform.version}</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>com.google.android</groupId>
            <artifactId>android-test</artifactId>
            <version>\${platform.version}</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.willowtreeapps</groupId>
            <artifactId>oak-library</artifactId>
            <version>${project.parent.version}</version>
            <type>aar</type>
        </dependency>

        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
            <version>2.1</version>
        </dependency>

        <dependency>
            <groupId>org.roboguice</groupId>
            <artifactId>roboguice</artifactId>
            <version>2.0</version>
        </dependency>

        <dependency>
            <groupId>com.pivotallabs</groupId>
            <artifactId>robolectric</artifactId>
            <version>1.1</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.8.2</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>13.0.1</version>
        </dependency>

        <dependency>
            <groupId>com.github.rtyley</groupId>
            <artifactId>roboguice-sherlock</artifactId>
            <version>1.4</version>
            <exclusions>
                <exclusion>
                    <groupId>com.google.android</groupId>
                    <artifactId>support-v4</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

        <dependency>
            <groupId>com.actionbarsherlock</groupId>
            <artifactId>actionbarsherlock</artifactId>
            <version>4.2.0</version>
            <type>apklib</type>
            <exclusions>
                <exclusion>
                    <groupId>com.google.android</groupId>
                    <artifactId>support-v4</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

        <dependency>
            <groupId>com.actionbarsherlock</groupId>
            <artifactId>actionbarsherlock</artifactId>
            <version>4.2.0</version>
            <type>jar</type>
            <scope>provided</scope>
            <exclusions>
                <exclusion>
                    <groupId>com.google.android</groupId>
                    <artifactId>support-v4</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
    </dependencies>

    <build>
        <sourceDirectory>src</sourceDirectory>
        <testSourceDirectory>test</testSourceDirectory>
        <plugins>
            <plugin>
                <groupId>com.jayway.maven.plugins.android.generation2</groupId>
                <artifactId>android-maven-plugin</artifactId>
                <version>\${android-plugin-version}</version>
                <configuration>
                    <androidManifestFile>\${project.basedir}/AndroidManifest.xml
                    </androidManifestFile>
                    <assetsDirectory>\${project.basedir}/assets</assetsDirectory>
                    <resourceDirectory>\${project.basedir}/res</resourceDirectory>
                    <nativeLibrariesDirectory>\${project.basedir}/src/main/native
                    </nativeLibrariesDirectory>
                    <sdk>
                        <platform>16</platform>
                    </sdk>
                    #if(${emulator} != "not-specified")
                    <emulator>
                        <avd>\${emulator}</avd>
                    </emulator>
                    #end
                    <undeployBeforeDeploy>true</undeployBeforeDeploy>
                </configuration>
                <extensions>true</extensions>
            </plugin>

            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>2.3.2</version>
                <configuration>
                    <source>1.6</source>
                    <target>1.6</target>
                </configuration>
            </plugin>
        </plugins>
    </build>
    <profiles>
        <profile>
            <id>sign</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-jarsigner-plugin</artifactId>
                        <version>1.2</version>
                        <executions>
                            <execution>
                                <id>signing</id>
                                <goals>
                                    <goal>sign</goal>
                                    <goal>verify</goal>
                                </goals>
                                <phase>package</phase>
                                <inherited>true</inherited>
                                <configuration>
                                    <removeExistingSignatures>true</removeExistingSignatures>
                                    <archiveDirectory />
                                    <includes>
                                        <include>
                                            \${project.build.directory}/\${project.build.finalName}.apk
                                        </include>
                                    </includes>
                                    <keystore>\${sign.keystore}</keystore>
                                    <alias>\${sign.keyalias}</alias>
                                    <storepass>\${sign.storepass}</storepass>
                                    <keypass>\${sign.keypass}</keypass>
                                    <verbose>true</verbose>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>com.jayway.maven.plugins.android.generation2</groupId>
                        <artifactId>android-maven-plugin</artifactId>
                        <inherited>true</inherited>
                        <configuration>
                            <sign>
                                <debug>false</debug>
                            </sign>
                            <zipalign>
                                <skip>false</skip>
                                <verbose>true</verbose>
                                <inputApk>
                                    \${project.build.directory}/\${project.build.finalName}.apk
                                </inputApk>
                                <outputApk>
                                    \${project.build.directory}/\${project.build.finalName}-signed-aligned.apk
                                </outputApk>
                            </zipalign>
                            <manifest>
                                <debuggable>false</debuggable>
                                <versionCode>\${app.versioncode}</versionCode>
                                <versionName>\${project.version}</versionName>
                                <versionCodeAutoIncrement>false</versionCodeAutoIncrement>
                            </manifest>
                            <proguard>
                                <skip>true</skip>
                            </proguard>
                        </configuration>
                        <executions>
                            <execution>
                                <id>manifestUpdate</id>
                                <phase>process-resources</phase>
                                <goals>
                                    <goal>manifest-update</goal>
                                </goals>
                            </execution>
                            <execution>
                                <id>alignApk</id>
                                <phase>package</phase>
                                <goals>
                                    <goal>zipalign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy