pull/2084/head
MacroController 9 months ago
parent cb467c6cfd
commit 0e3b8b5c3c

@ -9,17 +9,17 @@ This pages describes how to download and build the app from the source code. If
## Build using Android Studio
**Step 1: Install git**
### Step 1: Install git
The package `git` is required for downloading the source code of the app and submitting changes GitHub. Please see [the git book](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) for further instructions. If you are planning to submit pull requests in the future, it is recommended to [generate and configure your SSH keys](https://help.github.com/en/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent).
**Step 2: Download and install Android Studio**
### Step 2: Download and install Android Studio
Although Android Studio can be downloaded [from their official website](https://developer.android.com/studio/), a much better option is to install it through [JetBrains Toolbox](https://www.jetbrains.com/toolbox-app/). This tool, developed by the same developers of Android Studio, allows you to easily upgrade and downgrade the IDE, or switch between stable, beta and canary versions. After downloading and installing JetBrains Toolbox, simply click the install button near Android Studio to install the newest stable version of IDE. Beta and canary versions have not been tested and may not work correctly.
After installation, launch Android Studio. If this is the first time you launch it, you will need to go through a wizard to setup the IDE. The default options should work fine. The wizard will download all additional components necessary for development, including the emulator, so it may take a while.
**Step 3: Download the source code**
### Step 3: Download the source code
To create a complete copy of the source code repository, open the terminal (Linux/macOS) or Git Bash (Windows), navigate to the desired folder, then run:
```bash
@ -27,7 +27,7 @@ git clone https://github.com/iSoron/uhabits.git
```
The repository will be downloaded to the directory `uhabits`.
**Step 4: Open and run the project on Android Studio**
### Step 4: Open and run the project on Android Studio
1. Launch Android Studio and select "Open an existing Android Studio project".
2. When the IDE asks you for the project location, select `uhabits` and click "Ok".
@ -41,7 +41,7 @@ The repository will be downloaded to the directory `uhabits`.
The following instructions were tested on **Ubuntu Linux 18.04 LTS** and may need to be modified for other operating systems.
**Step 1: Install basic packages**
### Step 1: Install basic packages
To build the application, some basic packages are required. The package `git` is required to download the source code, while `openjdk-8-jdk-headless` is required for compiling Java and Kotlin files.
@ -53,7 +53,7 @@ sudo apt-get install -y git openjdk-8-jdk-headless
**IMPORTANT:** Newer JDK versions have not been tested and may not work correctly.
**Step 2: Install Android SDK tools**
### Step 2: Install Android SDK tools
The Android SDK tools contains many necessary tools for developing and debugging Android applications. It can be obtained as part of Android Studio, but, for simple command line usage, it can also be downloaded individually.
@ -71,7 +71,7 @@ export ANDROID_HOME="/opt/android-sdk"
yes | sdkmanager --licenses
```
**Step 3: Download the source code**
### Step 3: Download the source code
To create a complete copy of the source code repository, navigate to your home directory and run:
```bash
@ -79,7 +79,7 @@ git clone https://github.com/iSoron/uhabits.git
```
The repository will be downloaded to the directory `uhabits`.
**Step 4: Compile the source code**
### Step 4: Compile the source code
1. Navigate to the directory `uhabits`
2. Run `./gradlew assembleDebug --stacktrace`

Loading…
Cancel
Save