Giter VIP home page Giter VIP logo

vaishnavikoranne / apps-android-commons Goto Github PK

View Code? Open in Web Editor NEW

This project forked from commons-app/apps-android-commons

0.0 1.0 0.0 83.92 MB

Upload pictures from Android to Wikimedia Commons. Looking for volunteers! Come say hi at https://groups.google.com/d/forum/commons-app-android and install at https://play.google.com/store/apps/details?id=fr.free.nrw.commons

License: Apache License 2.0

Java 98.94% Shell 0.30% Makefile 0.12% PHP 0.64%

apps-android-commons's Introduction

Wikimedia Commons Android app Build status

The Wikimedia Commons Android app allows users to upload pictures from their Android phone/tablet to Wikimedia Commons. Download the app here, or view our website.

Initially started by the Wikimedia Foundation, this app is now maintained by volunteers. Anyone is welcome to improve it, just choose among the open issues and send us a pull request :-)

We are currently applying for an IEG renewal to work on the app for the next 6 months. Feedback is very much welcomed.

Get it on F-Droid Get it on Google Play

Develop with Android Studio or IntelliJ

Download Android Studio (recommended) or IntelliJ.

  1. Open Android Studio/IntelliJ. Open the project: File > New > Project from Version Control... > Git
    or
    (From Quick Start menu): Check out project from Version Control
  2. Enter https://github.com/commons-app/apps-android-commons/ as Git Repository URL. Specify a (new) local directory you would like to clone into and select OK.

Build Manually

Requirements

  1. Java SDK 8 (OpenJDK 8 or Oracle Java SE 8)
  2. Android SDK (Level 23)
  3. Gradle

Build Instructions

  1. Set the environment variable ANDROID_HOME to be the path to your Android SDK
  2. Set the environment variable JAVA_HOME to the path to your Java SDK
  3. Run gradlew.bat assembleDebug (Windows) or ./gradlew assembleDebug (Mac / Linux) to build an unisgned apk
  4. Alternatively, you can also connect your Android device via USB and install the app on it directly by running gradlew.bat installDebug (Windows) or ./gradlew installDebug (Mac / Linux)

There are more thorough instructions on the Android Developers website

License

This software is open source, licensed under the Apache License 2.0.

Code Structure

Key breakdowns:

Activities started within the UI:

  • ContributionsActivity (ContributionsListFragment, MediaDetailPagerFragment, MediaDetailFragment) - main "my uploads" list and detail view
  • LoginActivity - login screen when setting up an account
  • SettingsActivity - settings screen
  • AboutActivity - about screen

Activities receiving intents:

  • ShareActivity (SingleUploadFragment, CategorizationFragment) - handles receiving a file from another app, accepting a title/desc, and slating it for upload
  • MultipleShareActivity (MultipleUploadListFragment, CategorizationFragment) - handles receiving a batch of multiple files from another app, accepting a title/desc, and slating them for upload

Services:

  • WikiAccountAuthenticatorService - authentication service
  • UploadService - performs actual file uploads in background
  • ContributionsSyncService - polls for updated contributions list from server
  • ModificationsSyncService - pushes category additions up to server

Content providers:

  • ContributionsContentProvider - private storage for local copy of user's contribution list
  • ModificationsContentProvider - private storage for pending category and template modifications
  • CategoryContentProvider - private storage for recently used categories

On-Device Storage

Account credentials are encapsulated in an account provider. Currently only one Wikimedia Commons account is supported at a time. (Question: what is the actual storage for credentials?)

Preferences are stored in Android's SharedPreferences.

Information about past and pending uploads is stored in the Contributions content provider, which uses an SQLite database on the backend.

A list of recently-used categories is stored in the Categories content provider, which uses an SQLite database on the backend.

Captured files are not currently stored within the app, but are passed by content: or file: URI from other apps.

Thumbnail images are not currently cached.

Volunteers welcome!

We are always looking for volunteers, feel free to step in! It is very easy:

  1. Fork the repository and clone it to your computer, then follow the build instructions above.
  2. Choose an unassigned issue that sounds interesting to you.
  3. Read the issue's comments to make sure you understand what is the bug, or what feature is being proposed.
  4. Write a "I start working on this" comment on the issue
  5. Write the code :-)
  6. Commit and push
  7. Go to your fork's Github webpage, select the "Pull Requests" tab and click "create a pull request", as a comment, write something like "Fix for issue #12345 crash when rotating screen", then submit the pull request.
  8. Within a few hours or days, a core developer will review your patch, and either merge it or suggest a few corrections.
  9. If you change your mind, or if it is too difficult, no problem, just write "Sorry I don't work on this anymore" on the issue, if possible including feedback (for instance what approaches failed) and ideas.

Thanks a lot!

Translating the app

Thanks to the translation work of many volunteers this app is available in a multitude of languages.

Translation of the text content of the Wikimedia Commons Android app happens on the Commons Android App project on translatewiki.net. If you want to help translate the app please create an account there (to get "translate rights" edit 20 random keys or ask in their chat).

The translations from the translatewiki project are periodically committed directly to this project by the translatewiki team and later released with the normal updates to the Play Store.

apps-android-commons's People

Contributors

misaochan avatar yuvipanda avatar nicolas-raoul avatar bvibber avatar translatewiki avatar domdomegg avatar neslihanturan avatar whym avatar veyndan avatar sandarumk avatar akaita avatar tobias47n9e avatar dbrant avatar psh avatar addshore avatar siebrand avatar ford-prefect avatar nikerabbit avatar valeriej avatar deskana avatar tised avatar jayvdb avatar achalshant avatar amire80 avatar anirudh24seven avatar dr0ptp4kt avatar dr0pdb avatar bmekuria avatar vanethos avatar niedzielski avatar

Watchers

Vaishnavi Koranne avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.