rocketinsights / android-base

A base Android project to start Rocket Android projects off of.
4 stars 0 forks source link

Rocket's Kotlin Android Architecture Components Example

This is the first version of a mock application that hopefully will evolve into the base project for Rocket's Android application. #

Important branches:

We've defined two different build types:

To configure the rest of the environment variables, such as which API environment to use, which Firebase configuration and others, we've defined two product flavors:

Therefore the possible variants for now are: devDebug, devRelease, prodDebug, prodRelease.

The ideal is to have a flavor for each API environment to use, that is, if our api has a dev, staging and prod environment, we would have to add the flavor of staging.

Finally, after testing our environments in Debug mode, it is important to test them in Release mode, since it may be necessary to add some rules in our ProGuard files to prevent certain classes that are serialized from being obfuscated. #

Architecture

We like to be at the forefront and at the same time generate solid products capable of scaling and adapting to changes quickly.

For that we use a series of design patterns and recommendations from the Google team that we consider key when developing a mobile app. We use several of the Android Jetpack libraries that allow us to make the most of the Android SDK.

At the architecture level we use MVVM with a series of Design Patterns that we list below:

This allows us to have a clean, decoupled code, and easy to mock up. #

CI & CD

Continuous Integration services that we use:

Important: All CI environments are NOT configured in the same way.

The Rocket team has a preference for Bitrise, Github Actions and Circle CI according to the project requirements.

Bitrise Build Status

CircleCI Build Status

Travis Build Status

GitHub Actions Build Status #

Application Installation

Below are the instructions on how to install the Android app.

Enable Installation from Unknown Sources

First, for any given device, it'll need to have installation from unknown sources enabled.

  1. Open the Settings app.
  2. Tap on Security.
  3. Scroll to Unknown sources and turn the setting on.

Next, there are a few ways to get the latest application.

Via qa@yourdomainname.com

Whenever the newest build is available, (Bitrise|CirchleCI|AppCenter|Travis) emails qa@yourdomainname.com with a link to the latest apk. Tap on that link from the device. Once it has downloaded, tapping on the app should show a prompt to confirm the installation of the application. Occasionally, depending on device or manufacturer, you need to go to the Downloads application and install from there. If there's an issue installing from the mail application, try that.

Via Slack Channel

Whenever a new build is available, the #androidslackchannel slack channel has an automated message sent to it. Open the link in that message from the device and follow the above instructions.

Request a Specific Build

If you want a specific build, let me (Android developer) know and I can send you that build directly on (Bitrise|CirchleCI|AppCenter|Travis). From there, you can follow the directions for qa@yourdomainname.com.

Via Android Studio

If you get set up with Android Studio and the GitHub repo on your local machine, you'll be able to install it directly from there. If you need help with this, feel free to let me (again, Android developer) know and I'd be happy to walk you through it.