Connfa!
Open Source iOS & Android App for Conferences and Events

    How to build Android app v1

    Let’s identify primary steps to setup the app for your needs.

    Step 1

    You need to have a backend, which will provide Android application with all required content.

    Simply use Connfa Integration Server, or, if you already have your own backend, check Connfa API documentation described here.

    Step 2

    Clone оr download the repository Connfa Repository

    Note. You should use branch connfa_v1

    Step 3

    SDK and Build Tools versions are located in gradle.properties. Also you can find here Android Support Library Version. build.gradle

      
      BUILD_TOOLS_VERSION=23.0.1
      COMPILE_SDK_VERSION=23
      MIN_SDK_VERSION=14
      TARGET_SDK_VERSION=22
      ANDROID_SUPPORT_LIBRARY_VERSION=23.2.1
      
    

    Step 4

    You need to perform initial project configuration to get it compilable.

    By default, Android Studio displays your project files in the Android view. Please change it on Project view.

    Project properties are in the same api_values.xml directory.

    api_values

    They are Base Url, Twitter Api Key, Twitter Secret Key and Google Maps Api Key.

    Add Application id in build.gradle file.

    build.gradle

      
    applicationId= com.connfa
      
    

    api_values

      
    productFlavors {
       connfa {
           applicationId "com.ls.connfa"
           versionName "connfa"
    
           defaultConfig {
               versionCode 1
               versionName "1.0.0"
           }
       }
    
    }
      
    

    Step 5

    api_values

    You need to change a base URL that is used for communication with a backend.

    <string name="api_value_base_url">your base url</string> 
    

    For enabling crash reporting service and mobile analytics tools you should add fabric Api Key in AndroidManifest.xml.

      
       android:name="io.fabric.ApiKey"
       android:value="your fabric Api Key"   
      
    

    For enabling Google Maps Api you should add Api Key in api_values.xml.

    <string name="api_value_google_maps_api_key">your Api Key</string> 
    

    To enable Twitter API you should add Twitter Secret Key and Twitter API Key in api_values.xml.

    <string name="api_value_twitter_api_key">your Twitter Api Key</string> 
    
    <string name="api_value_twitter_secret">your Twitter Secret Key</string> 
    

    Step 6

    Generate a keystore and use it to sign your apk.

    application-properties

    All signing configurations are located in readme.

    keystore

      
    Keystore password: your password
    Alias: your alias
    Alias Password: your alias password
      
    

    Keystore password is a secure password for your keystore

    Alias is a name for your key

    Alias password is a secure password for your key, it should differ from the password you chose for your keystore

    Step 7

    Use this link and follow the onscreen instructions to generate the google-services.json for your app.

    google-services

    Step 8

    Application also has Google Analytics. To track the statistics please add respective XML config file for analytics. Sign in to your Google Analytics account, create a folder named xml inside res.

    tracker

    Create an xml file named global_tracker.xml inside xml folder and add below analytics configurations.

    <!-- End current session if app sleeps for a period of time -->
    <integer name="ga_sessionTimeout">300</integer>
     
    <!-- Enable automatic Activity measurement -->
    <bool name="ga_autoActivityTracking">true</bool>
     
    <!--  The property id associated with this analytics tracker -->
    <string name="ga_trackingId">XX-XXXXXX-X</string>
     
    <string name="ga_sampleFrequency">100.0</string>
     
    <bool name="ga_reportUncaughtExceptions">true</bool> 
    

    Step 9

    To update application UI theme, all you need is to replace resource files. There are fonts folder inside assets directory and you can add new font there.

    tracker

    But all references to this font were extracted into resource file named fonts.xml. This xml file is inside values directory, also there are other resource files: color, string etc.

    tracker