meshtastic/docs/development/android.mdx

67 lines
1.8 KiB
Plaintext
Raw Normal View History

2021-05-25 14:12:57 -07:00
---
2022-11-02 15:26:47 -07:00
id: android
2022-11-03 17:10:08 -07:00
title: Building the Android App
2022-11-02 15:26:47 -07:00
sidebar_label: Android
2022-11-03 17:10:08 -07:00
sidebar_position: 1
2021-05-25 14:12:57 -07:00
---
## Build instructions
If you would like to develop this application we'd love your help! These build instructions are brief and should be improved, please send a PR if you can.
2021-05-25 14:12:57 -07:00
2022-11-07 20:53:52 -08:00
1. Use Android Studio to build/debug
2. Clone the repository and after successful cloning, change the working directory to Meshtastic-Android/
```shell
git clone https://github.com/meshtastic/Meshtastic-Android.git && cd Meshtastic-Android/
```
3. Pull in the various sub-modules we depend on.
```shell
git submodule update --init --recursive
```
4. Now you should be able to select "Run / Run" in the IDE and it will happily start running on your phone or the emulator.
2021-05-25 14:12:57 -07:00
2021-05-26 15:17:36 -07:00
:::note
The emulators don't support Bluetooth, so some features can not be used in that environment.
2021-05-26 15:17:36 -07:00
:::
2021-05-25 14:12:57 -07:00
2022-11-07 20:53:52 -08:00
## Setup Analytics
2021-05-25 14:12:57 -07:00
2022-11-07 20:53:52 -08:00
Analytics are included but can be disabled by the user on the settings screen.
2021-05-25 14:12:57 -07:00
2022-11-07 20:53:52 -08:00
1. Configure analytics for development device
2021-05-25 14:12:57 -07:00
2023-01-19 05:01:57 -08:00
```shell
adb shell setprop debug.firebase.analytics.app com.geeksville.mesh
adb shell setprop log.tag.FirebaseCrashlytics DEBUG
```
2022-11-07 20:53:52 -08:00
2. Set verbose logging
2023-01-19 05:01:57 -08:00
```shell
adb shell setprop log.tag.FA VERBOSE
```
2021-05-25 14:12:57 -07:00
2022-11-07 20:53:52 -08:00
## Publish to Google Play
:::info
Only available for core developers that publish releases.
:::
1. Add repository secrets:
2023-01-19 05:01:57 -08:00
- **KEYSTORE_FILENAME**
- Name of the `.jks`
- **KEYSTORE**
- Convert the `.jks` to base64:
```shell
openssl base64 < filename.jks | tr -d '\n' | tee filename.txt
```
- **KEYSTORE_PROPERTIES**
- `storePassword=nononononono`
- `keyPassword=nononononono`
- `keyAlias=upload`
- `storeFile=nononononono.jks`
2022-11-07 20:53:52 -08:00
2. Update protobufs
3. Go to Actions / Make Release / Run Workflow
4. Pick the Releases branch
5. Enter the version found in `app/gradle.build`