Two Developers Working on App

59 views
Skip to first unread message

s.ande...@gmail.com

unread,
Jul 15, 2014, 7:14:50 AM7/15/14
to mobile-c...@googlegroups.com
My business partner and I are working on an iPhone app which uses a Couchbase Lite database for storage.

I have added code to the app to open/use a Couchbase Lite database, however I notice the path returned my the call [[CBLManager sharedInstance] directory] is specific to my account on my MacBook - /Users/<myusername>/Library/Application Support/iPhone Simulator/7.1/Applications/.../CouchbaseLite.

What path would the app report if my colleague was to pull down my changes and run the app? I guess what I am asking is how do we organise things so we can both work on the app (with a Couchbase Lite database) independently?

Jens Alfke

unread,
Jul 15, 2014, 12:52:10 PM7/15/14
to mobile-c...@googlegroups.com
On Jul 15, 2014, at 4:14 AM, s.ande...@gmail.com wrote:

I have added code to the app to open/use a Couchbase Lite database, however I notice the path returned my the call [[CBLManager sharedInstance] directory] is specific to my account on my MacBook - /Users/<myusername>/Library/Application Support/iPhone Simulator/7.1/Applications/.../CouchbaseLite.

Yup.

What path would the app report if my colleague was to pull down my changes and run the app?

A pretty similar path, i.e. to Library/Application Support/CouchbaseLite inside the sandbox directory created by the iOS Simulator for the app.

I guess what I am asking is how do we organise things so we can both work on the app (with a Couchbase Lite database) independently?

What’s the problem? You really don’t need to care where the database is, except in very rare circumstances. It’s part of the local data the app stores on the device.

If you need to share the same data in the database, then you can run a compatible server somewhere (the easiest way is probably to set up a Cloudant account) and have your app replicate with it.

—Jens

s.ande...@gmail.com

unread,
Jul 15, 2014, 8:53:50 PM7/15/14
to mobile-c...@googlegroups.com
I guess what I am asking is how do we organise things so we can both work on the app (with a Couchbase Lite database) independently?

What’s the problem? You really don’t need to care where the database is, except in very rare circumstances. It’s part of the local data the app stores on the device.

OK, good.

s.ande...@gmail.com

unread,
Jul 15, 2014, 9:05:20 PM7/15/14
to mobile-c...@googlegroups.com
Jens, do I need to do anything special to bundle my Couchbase Lite database with my app? Is there info on the Couchbase Lite developer site about this?

Jens Alfke

unread,
Jul 15, 2014, 9:18:34 PM7/15/14
to mobile-c...@googlegroups.com

On Jul 15, 2014, at 6:05 PM, s.ande...@gmail.com wrote:

Jens, do I need to do anything special to bundle my Couchbase Lite database with my app? Is there info on the Couchbase Lite developer site about this?


Be careful with this. If your app copies a bunch of data into a backed-up location on first launch, Apple will reject it, because all backed-up data is supposed to be user generated. (There’s been some recent traffic about that on this list.) You can avoid it by customizing the location of the CBLManager to a directory that isn’t backed up, or by setting the don’t-back-up file attribute on it.

—Jens
Reply all
Reply to author
Forward
0 new messages