~thisfred/desktopcouch/the-great-split-of-2010

« back to all changes in this revision

Viewing changes to desktopcouch/start_local_couchdb.py

  • Committer: Ken VanDine
  • Date: 2009-07-24 19:32:52 UTC
  • mto: This revision was merged to the branch mainline in revision 16.
  • Revision ID: ken.vandine@canonical.com-20090724193252-v1508w0zk7yqwc21
* reorganized a little to work better as an installed service
* added org.desktopcouch.CouchDB.service for dbus activation

Show diffs side-by-side

added added

removed removed

Lines of Context:
103
103
def write_bookmark_file():
104
104
    """Write out an HTML document that the user can bookmark to find their DB"""
105
105
    bookmark_file = os.path.join(local_files.DIR_DB, "couchdb.html")
106
 
    bookmark_template = os.path.join(os.path.split(__file__)[0], "couchdb.tmpl")
 
106
    if os.path.exists("../utilities/couchdb.html"):
 
107
        bookmark_template = os.path.join(os.path.split(__file__)[0], "couchdb.tmpl")
 
108
    else:
 
109
        bookmark_template = os.path.join(os.path.split(__file__)[0], "/usr/share/desktopcouch/couchdb.tmpl")
107
110
    fp = open(bookmark_template)
108
111
    html = fp.read()
109
112
    fp.close()