Building Android Maven apps with Jenkins

1 min read

In this post, I will explain how to build an Android Maven application using Jenkins. I will use the source code from the repository of my colleague Mark Prichard, who made a copy of the DroidFish project on his own GitHub repository (https://github.com/mqprichard/stockfishchess-android ).

The first step is to create a Maven project on Jenkins so we can specify the pom.xml file on the Jenkins job.

Once you have created the maven project, the next step is to link the job with the GitHub repository which will be used. (https://github.com/mqprichard/stockfishchess-android )

Now, we can specify where the pom.xml file is and what are the goals for the maven project as a build option.

We have almost finished, but unfortunately the CuckooChess.jar (https://github.com/mqprichard/stockfishchess-android/tree/controller/DroidFish/libs ) is not present on Maven Central repository, so we will add it manually into the build. For this, we will add this commands to our shell script as a part of a pre-step build.

This package is used in the pom.xml as a dependency.

org.petero.droidfish
CuckooChess
1.0.0
provided

GitHub reposity used: https://github.com/mqprichard/stockfishchess-android

Stay up to date

We'll never share your email address and you can opt out at any time, we promise.