Git Product home page Git Product logo

couchbase-lite-android's Introduction

Couchbase-Lite-Android

by Marty Schoch ([email protected]) + Traun Leyden ([email protected])

Couchbase-Lite-Android is the Android port of Couchbase Lite iOS.

Click here for official documentation for Couchbase Lite Android

Getting Started with Couchbase Lite

Developing / Contributing to Couchbase Lite

If you are just building an application with Couchbase Lite, you can skip the rest of this document. (see Getting Started with Couchbase Lite)

However, if you need to debug Couchbase Lite Android or otherwise hack on it, these instructions will help you do that.

Prerequisites

  • Download Android Studio

  • Under Tools / Android / Android SDK Manager and install "Extras/Google Repository" and "Extras/Android Support Repository" (future versions of Android Studio may make this step unnecessary)

Clone the repository

Use Git to clone the Couchbase Lite repository to your local disk:

$ git clone git://github.com/couchbase/couchbase-lite-android.git
cd couchbase-lite-android
$ git submodule init && git submodule update

Configure Android Studio SDK location

  • cp local.properties.example local.properties
  • Customize local.properties according to your SDK installation directory

Importing Project into Android Studio

You should be able to import the project directly into Android Studio:

  • Start Android Studio
  • Choose File / Import and choose the couchbase-lite-android/CouchbaseLiteProject directory screenshot
  • Choose Import from External Model and make sure Gradle is selected screenshot
  • Check the auto-import and the Use gradle wrapper (recommended) checkboxes screenshot
  • Hit Finish and wait for all tasks to finish (may take a while)

After it's finished with the import, it should look like this

Working around Import bugs

At this point, unfortunately, if you open the CBLServer class, it will look like this. Android Studio will say it cannot resolve some objects. This seems to be due to a bug in the import process.

To fix this:

  • Go to File / Project Structure
  • Choose Modules
  • Choose the CBLite module
  • Change the jackson-core-asl-1.9.2 and jackson-mapper-asl-1.9.2 dependencies from "test" to "compile" screenshot
  • Hit Apply

Note: you may need to do this in other places for other libraries if you run into situations where Android Studio cannot resolve code.

Note: the above workarounds are only needed for Android Studio, and even without these the command line gradle builds should still work.

Running tests

See the Running the Test Suite wiki page.

Building and deploying maven artifacts.

If you want to host and deploy your own maven artifacts, see the upload_android_artifacts.sh script.

Example Apps

Utilities

Current Status

  • Alpha / Developer Preview

Requirements

  • Android 2.3 Gingerbread (API level 9) and above.

License

  • Apache License 2.0

githalytics.com alpha

couchbase-lite-android's People

Contributors

bsquared avatar cesine avatar chrisekelley avatar clouddinesystems avatar ddumont avatar dwt avatar mjq avatar mschoch avatar pegli avatar rwilliams avatar tk120404 avatar tleyden avatar vmx avatar

Watchers

 avatar  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.