Welcome to ColibriSM Android
Flutter Requirements

Before you could start working on your project and changing the app to your liking, you first have to set up the environment. Here are the requirements needed to begin setting up your flutter environment and opening your app project

You need to install Flutter Version 1.22.X. Download that version from following link

Select the operating system to which you are installing Flutter:

Set up your IDE environment:

Flutter Installation

Please take a look at the video tutorials below on how to set up Flutter environment on Windows and macOS

Cocoapods Configuration [macOS]

CocoaPods manages library dependencies for your Xcode projects. The dependencies for your projects are specified in a single text file called a Podfile. CocoaPods will resolve dependencies between libraries, fetch the resulting source code, then link it together in an Xcode workspace to build your project.

Firebase Configuration

We need to utilize Firebase configuration to set up Google login and Push Notifications

  • Step 1: Firebase Setup Android

    1. Create a Firebase account

    2. In the Firebase console, click Add project, then select or enter a Project name.

    If you have an existing Google Cloud Platform (GCP) project, you can select the project from the dropdown menu to add Firebase resources to that project.

    (Optional) If you created a new project, you can edit the Project ID. Firebase automatically assigns a unique ID to your Firebase project. Visit Understand Firebase Projects to learn about how Firebase uses the project ID.

    After Firebase provisions resources for your Firebase project, you cannot change your project ID. To use a specific identifier, you must edit your project ID during this setup step. Click Continue.

  • Step 2: Enable Authentication in Firebase

    After you have a Firebase project, the functionalities need to be enabled via the Authentication menu.

    1. On the left menu, click on Authentication.

    2. Select Sign-in method.

    3. Enable Email/Password, Google, and Facebook (For Facebook, you must have the App ID and Secret Key). Click here to view an easy to follow documentation on how to acquire this.

  • Step 3: Register Your App With Firebase

    After you have a Firebase project, you can add your Android app to it.

    1. In the center of the Firebase Console Overview Page, click the Android icon to launch the setup workflow. If you've already added an app to your Firebase project, click Add app to display the platform options.



    2. Enter your app's application ID in the Android package name field.

    - An application ID is sometimes referred to as a package name.

    - Find this application ID in your module (app-level) Gradle file, usually app/build.gradle (example ID: com.yourcompany.yourproject).


    3. Add debug SHA1 fingerprint (This is required for authentication).

    - Enter following command in terminal to acquire this:

    [Windows] keytool -list -v -keystore "C:\Users\yourusernamehere\.android\debug.keystore" -alias androiddebugkey -storepass android -keypass android

    Important: Make sure that you enter the ID that your app is actually using. You cannot add or modify this value after you register your app with your Firebase project.

    Click Register app.

  • Step 4: Add Firebase Configuration File

    Add the Firebase Android configuration file to your app:

    1. Click Download google-services.json to obtain your Firebase Android config file (google-services.json).

    - You can download your Firebase Android config file again at any time.

    - Make sure the config file is not appended with additional characters, like (2).


    2. Move your config file into the module (app-level) directory of your app. ( File Path to Move : android/app)

Project Configuration

Here you will be modifying the app color, package name, icons and logo, constants, base URL for your application.

Open Project


1. Open Android Studio

2. Select Open an Existing Project

3. Select the location of your project and click Open



Get Dependencies


When Project is opened, open Terminal below and Run the following Command:

flutter pub get

Make sure flutter pub get is successful and there is no error

Changing Package Name


There are six (6) steps to changing the package of flutter app.

You need to choose your application name and application ID.

Note: Make sure application ID is unique and you have used the same ID in firebase

To change the package name, go to following files and update them:

1. Go to android > app > src >debug > AndroidManifest.xml

2. Go to android > app > src > profile > AndroidManifest.xml

3. Go to android > app > src > main > AndroidManifest.xml. Also change the app name in this file as shown in screenshot

4. Go to android > app > build.gradle and change the package name



Rename package directory


5. Go to android > app > src > main > kotlin and rename the directory

Select the directory name and click on refactor and replace with your package name

6. Go to android > app >src > main > kotlin > your package name . Change package name in Application and MainAcitivity .



Changing App Icon


1. Go to Android Asset Studio

2. Click "Image" and upload your icon

3. Adjust the padding and other setting you want

4. Click Download button on the top, right corner

5. After download, unzip the file.

6. After that copy the file and paste it to android > app > src > main > res > mipmap*





Changing Logo


1. To change the logo go to android > app > src > main > res > drawable and change the logo

2. To change the logo go to your project folder > images and change the logo



Changing Api URL


After you setup your backend, you need to change the backend url at our flutter app config. Open lib > core > common > api > api_constants.dart and change the Api Url and Base Url



Changing App Color and Other Settings


To change the app color Open lib > core > theme > colors.dart and change the colors.



Changing Constants


1. Open lib > core > theme > Strings.dart and edit the constants you want to change. 2.Open android > app > src > main > res > values > strings.xml and change app name.

Publish App

To publish app to Play Store, you have to generate SHA 1 and SHA 256 signed keys within your project.

  • UPDATE KEYSTORE INFORMATION


    1. After you generate signed keys, open android > app > build.gradle and edit storePassword, keyPassword and storeFile path.

    2. Replace the keystore files by opening the metadata folder and replacing the androidkey with your file.





  • Create Release File


    In your application menu, go to Build > Flutter > Build Apk's and this will build your release apk that can be uploaded to the Google Plat Store.





  • Apk File


    You can find your apk file in build > app > outputs > apk > release folder. You can install that app in your mobile phone or publish to Play Store

Update App

Now that you have an understanding of configuring the application to suite your needs, updating your app is quite simple.

  • Update Flutter Version to 2.x.x

    Currently, you have downgraded the flutter version to 1.2x.x in order for app to function. Now that we have upgraded, you can do the same.

    1. Access the v_2.x.x folder from your download and overwrite the current files in our application.

    2. Configure constants, links and package name as previously done, as well as logo (If necessary)

    3. When your project is open, go to terminal and type the following command, flutter upgrade, then hit enter. It will go through the upgrade process to the latest version.

    4. Now, you have to upgrade your publications by typing the following command, flutter pub upgrade, then hit enter.

    5. Run your code to bring up the emulator and test out the updates.

    That's it!!