Developer Setup

In this article we will learn how to setup development environment for Nearby Shops.

In this article we will learn how to configure IDE and customize your source code to build your own customized app.

Prerequisite Knowledge

To understand this guide you need to have basic to intermediate level knowledge of Java Spring Boot and Android Development. You also need to know how to use Android Studio and Intellij Idea Community Edition.

Steps for Setting up Development Environment

1. Install Intellij Idea Community Edition
2. Open Project Files in Intellij Idea
3. Update Application Configuration
4. Run Project
5. Install Android Studio
6. Open Android Source Code in Android Studio
7. Configure Custom Settings
8. Generate App

Server Side Development Setup

Let us begin the step by step Upgrade Guide for Nearby Shops API Backend

Step 1 : Install Intellij Idea Community Edition

Download the latest version of Intellij Idea Community Edition and Install it.

Step 2 : Open Project Folder in Intellij Idea

In case you have access to the github repository you can download the source code in zip file. Unzip the Project files and Open the Project with Intellij Idea Community Edition.

Step 3 : Create Config File from example config file

Create a new config file by copying or renaming the application_example.properties

Step 3 : Update Application Config

In order to run the project you have to setup Postgres Database and add Postgres database URL in the config file. You also need to setup port and all other relevant configuration.

Step 4 : Run the Project

When running the project for the first time right click on ApiApplication file and click run ApiApplication.main()

Next time in order to run the project press the play button in Intellij Idea

Android Development Setup

Let us begin the step by step Upgrade Guide for Android Setup

Step 1 : Install Android Studio

In order to customize and modify source code for Android App you need to install Latest Stable version of Android studio.

Step 2 : Open Android Source Code Folder

If you have access to the github repository. Download the zip source code folder then unzip it and you can open android source code folder in android studio to modify the android app.

Step 3 : Create Custom-Settings.xml from example settings

Copy custom_settings_example.xml file into a new file named custom_settings.xml into the values folder under res directory

Step 4 : Configure Custom-Settings.xml

Press Double Shift on android studio and search for custom_settings.xml where you can configure different settings for the project.

Step 5 : Generate google-services.json file

Generate google-services.json file and copy the file into the app folder. as per instructions given while generating the FCM project.

Step 6 : Generate App

Goto Build -> then Build Signed APK or Build APK to generate APK File

Summary

“mvn install” command downloads all the dependencies and generates a fat jar (uber jar). The fat jar is a jar file which is self contained and does not need to download any dependencies to run. after all the process is complete you can find the jar file generated inside the “target” folder.