Team Android Project Template
As a software development company we are starting new projects every few weeks. With every project we create a jira ticket called Project Setup.
We walked through all our Project Setup Jira tickets and calculated the average hours for this kind of task: In average every android project needs about 3.5 hours for a simple setup. On the other hand the project setup is boring and no developer likes that work.
We decided to help developers out and created a simple but helpful template that contains the basic setup for our android projects.
What does the template contain?
- Our recommended package structure
- Most used library dependencies
- Built in flavors for dev, staging, live
- Basic retrofit setup in a separat module
- Setup for SplashScreenHelper (https://blog.davidmedenjak.com/android/2017/09/02/splash-screens.html)
Just an empty project would not save a lot developer hours, so we decided to add a template engine to make the project setup more dynamic. After some research we started to use cookiecutter.
A command-line utility that creates projects from cookiecutters (project templates), e.g. creating a Python package project from a Python package project template.
A typical project setup at Team Android @ allaboutapps looks like this:
Cookiecutter checks out the template project from github and starts asking the user for some values:
- Repository name -> local folder name
- App name -> Name of the app (fills out in strings.xml)
- Package Name -> Sets the package name and creates the folder structure
- Strings Sheet ID -> For our internal Internationalization Tool (there will be an own blog post about that in near future)
et voila -> project setup completed within just a few seconds
The current version of our project setup template is available public on github