-
Notifications
You must be signed in to change notification settings - Fork 64
Setting up Development Environment (Linux)
To set up the development environment and run the app on your device, you need the following:
- Install android studio from the official site
- Extract android studio to a folder
- Open studio by changing terminal's directory to the folder where you unzipped
- Change directory to the bin folder inside the Studio folder and type in terminal
./studio.sh
- Follow on-screen instructions till android studio launches launches successfully
Type the following commands in your terminal
sudo apt-get update
sudo apt-get install nodejs
sudo apt-get install npm
Type the following commands in your terminal
sudo npm install -g create-react-native-app
sudo npm install -g react-native-cli
sudo apt install git
- Change directory to the place where you want dengue stop project to be downloaded
- Run the following command:
git clone https://github.com/scorelab/dengue-stop.git
- To install node modules, run the command:
npm install
- To develop the project, download any text editor and start working by opening the folder in the editor
- To run the app on your device, connect a device with your laptop and run the command:
react-native run-android
You're most likely to encounter some of the following errors after you run the command: react-native run-android
.
Open android studio and make sure that you create a sample project with empty activity and accept all of the terms and conditions that pop up on your screen.
Run the following commands:
sudo apt-get install android-sdk
export ANDROID_HOME=$HOME/Android/Sdk
export PATH=$PATH:$ANDROID_HOME/tools
Run the following commands:
sudo apt install android-tools-adb android-tools-fastboot
Change directory to project location
mkdir android/app/src/main/assets
react-native bundle --platform android --dev false --entry-file index.android.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res