rohit.gowda 99c919a71e Adding final version of apk in app\apk\hybrid-osn-mockup.apk 4 年之前
..
apk 99c919a71e Adding final version of apk in app\apk\hybrid-osn-mockup.apk 4 年之前
resources 2d88eb0112 Change icon 6 年之前
src 99c919a71e Adding final version of apk in app\apk\hybrid-osn-mockup.apk 4 年之前
ul_web_hooks f903c3c81d Cordova Firebase Authentication 6 年之前
.editorconfig bb87d6abe0 initial commit using ionic framework for app development 6 年之前
.gitignore d19b1e50ee apk v 0.1.0 6 年之前
README.md c1657325a4 Add info about apk singing 6 年之前
config.xml bbe71012f3 Release version 1.0 5 年之前
ionic.config.json f0c23c3572 update ionic cli 6 年之前
package-lock.json 9b5afd833d write 5 年之前
package.json daec4109e8 mockup 4 年之前
tsconfig.json d4e43f21b9 upgrading the app to use json features@typescript 5 年之前
tslint.json bb87d6abe0 initial commit using ionic framework for app development 6 年之前

README.md

HybridOSN

HybridOSN is a Twitter client Android app allowing the user to exchange data not only via the official Twitter servers but also via a P2P network to protect his privacy. It is build using the Ionic framework. With Ionic framework you can easily develop cross-platform hybrid mobile apps.

You can find a ready to install APK file in the folder /apk.

Development

I highly recommend to develop the app using Microsoft Visual Studio Code. I also recommend to use the extensions Prettier - Code formater to format your code uniformly and Gitlens to manage the git repository. Of course, you need to have git installed.

Getting Started

  • Install NodeJS LTS. If you have NodeJS installed on your computer but in a different version, I recommend Node Version Manager (Windows) to handle different NodeJS installations.
  • Install Ionic and Cordova globally npm install -g ionic cordova
  • Clone this repository, change into the directory and install the dependencies npm i
  • Install JDK
  • Install Android Studio and via the SDK Manager Android SDK Platform 26 (Android 8.0.0).

You can test whether everything was installed correctly by executing ionic info and cordova requirements.

Build the App

  • Run on Android emulator: ionic cordova emulate android
  • Run on connected Android device: ionic cordova run android
  • Publish the APK: ionic cordova build --release android

You may read in the Ionic docs, that you can view your app in the browser using ionic serve. This doesn't work because of the used Cordova plugins which force you to run the app on an Android device. As mentioned in the beginning, using Ionic cross-plattform applications can be developed. This still is valid, but since the goal was to develop an Android app, no time was spent on trying to remove this current restriction.

Signing of the APK File

Android requires that all APKs be digitally signed with a certificate before they are installed on a device or updated. Sign your app | Android Developers

By default the APK built by Ionic/Cordova is not signed. To sign the APK, a tool called APK Signer is used best. Using this tool, signing the APK file is pretty straight forward.

For security reasons I don't want to share the keystore and passwords in this repository. Please write me an email and ask for them.

Debugging

If you want to debug the app, you can do so by using the Google Chrome Developer Tools. After deploying the app on your device using the ionic cordova run android-command, open Google Chrome on the computer your device is connected to and press the F12-key to open the Developer Tools. Go to the tab "Remote devices" (maybe it is hidden and you need to press ESC to show it). Now you should see your connected device on the left and when selecting it the HybridOSN app. With a click on the button "Inspect" you can inspect and debug the app.

Known Problems

In case the build process fails with the error:

Execution failed for task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug'.

Run cordova clean to fix this problem. It appears randomly from time to time.