Package couchdbkit :: Package ext :: Package pylons :: Module db
[hide private]
[frames] | no frames]

Module db

source code

Functions [hide private]
 
init_from_config(config)
Initialize the database given a pylons config.
source code
 
init_db(uri, dbname, main_db=True)
Returns a db object and syncs the design documents on demand.
source code
 
sync_design(db, path)
Synchronizes the design documents with the database passed in.
source code
 
default_design_path(config)
Returns full path to the default design documents path, it's _design in the pylons root path
source code
Variables [hide private]
  __package__ = 'couchdbkit.ext.pylons'
Function Details [hide private]

init_from_config(config)

source code 

Initialize the database given a pylons config. This assumes the configuration format layed out on the wiki. This will only initialize the primary database.

This prefixes the database name with test_ if we're running unit tests.

init_db(uri, dbname, main_db=True)

source code 

Returns a db object and syncs the design documents on demand. If main_db is set to true then all models will use that one by default.