An Android app for recording blood pressure measurements.
- Clone the project using git
- Install Android Studio
- Import the project into Android Studio
When building for the first time, gradle will download all dependencies so it'll take a few minutes to complete. Subsequent builds will be faster.
An APK can be built and installed to a device directly from Android Studio. The device could be an emulator or a real device. Emulators come pre-configured to run binaries, but running on a real device requires enabling USB debugging
in phone settings. The steps for finding this setting varies with manufacturers, but should be somewhat along the lines of,
- If your phone settings has a search option, try searching for
Build number
. - If search is unavailable, try navigating to
Settings > System > About phone
. Scroll to the bottom to findBuild number
. - Tap on
Build number
for 5 times until you see a message saying "You are now a developer!". - Go back to phone settings. A new setting group called
Developer options
will now be available. - Open
Developer options
and enableUSB debugging
.
If adb
fails with a no devices/emulators found
error, it is possible that the device is connected to the computer in charging only mode. In this case, you should see a notification on the device to change this to debugging.
Follow the simple-server instructions.
- Add the product flavour in the
productFlavours
closure inapp/build.gradle
. - Update the
variantFilter
closure to remove the unnecessary build for the new variant. - Add the api endpoint in
gradle.properties
and add this as theAPI_ENDPOINT
build config field when defining the product flavour inapp/build.gradle
. This might need to be overriden on the CI based on the needs of the build flavour. - Add the Heap ID in
gradle.properties
and add this as theHEAP_ID
build config field when defining the product flavour inapp/build.gradle
. This might need to be overriden on the CI based on the needs of the build flavour. - Update the
applicationIdSuffix
andversionNameSuffix
when defining the product flavour. - Update the
afterEvaluate
closure at the end of theandroid
block inapp/build.gradle
to include the build tasks for the new variant (only needed if you have enabled proguard for the build).
- All resources must be updated at the path
app/src/<build flavour>/res
. - The app name must be added at
values/strings.xml
, with the resource idapp_name
. - Update the launcher icons for pre-sdk26 in the
mipmap-<density>
folders. - Update the adaptive icon foreground for sdk26+ in
drawable-v26
. - Add the
logo_large
drawable resource in thedrawable
folder. This is the large logo with text used on the app bar in some screens. - Add the
ic_icons_logo
drawable resource in thedrawable
folder. This is the small logo (without text) used on the app bar in the home screen.