Let's look at how to quickly have a CI-CD setup running for our Xamarin.Forms application with Jenkins.
We'll be using a mac as it'll enable as to build both Android and iOS on the same machine. Which brings me to an unfortunate point: We will need a seperate setup for UWP. Which I might cover in another post.
First off, we need to have Homebrew package manager installed in the mac, as it is required to install Jenkins. You can check if you have brew installed by executing this command in your terminal:
This will display the path the brew being used is installed in. In my case it's here:
If you don't have it then simply run this command to install brew:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Once we have brew installed, we can now install Jenkins:
brew install jenkins-lts
this will install the Long-Term-Support release of latest stable Jenkins. To know more about the releases available take a look at their download page.
Let's start Jenkins by executing:
brew services start jenkins-lts
you can stop the service by replacing start with stop.