[damned-lies] Update deprecated form of settings



commit 05c094a7b1f7d95019eb9c564fb167826f04b3cc
Author: Claude Paroz <claude 2xlibre net>
Date:   Sat Jan 15 15:02:06 2011 +0100

    Update deprecated form of settings

 settings_sample.py |   27 ++++++++-------------------
 1 files changed, 8 insertions(+), 19 deletions(-)
---
diff --git a/settings_sample.py b/settings_sample.py
index e709ae5..cb02fee 100644
--- a/settings_sample.py
+++ b/settings_sample.py
@@ -17,22 +17,12 @@ ADMINS = (
 
 MANAGERS = ADMINS
 
-DATABASE_ENGINE = 'sqlite3'           # 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
-DATABASE_NAME = os.path.join(PROJECT_PATH,'database.db')            # Or path to database file if using sqlite3.
-DATABASE_USER = ''             # Not used with sqlite3.
-DATABASE_PASSWORD = ''         # Not used with sqlite3.
-DATABASE_HOST = ''             # Set to empty string for localhost. Not used with sqlite3.
-DATABASE_PORT = ''             # Set to empty string for default. Not used with sqlite3.
-
-# If you can't use PostgreSQL :-/, here is the MySQL configuration:
-#
-# DATABASE_HOST = '/var/run/mysqld/mysqld.sock'
-#
-# DATABASE_OPTIONS = {
-#    'read_default_file': '/etc/mysql/my.cnf',
-#    'init_command': 'SET storage_engine=INNODB'
-# }
-#
+DATABASES = {
+    'default': {
+        'ENGINE': 'django.db.backends.sqlite3',
+        'NAME'  : os.path.join(PROJECT_PATH, 'database.db'),
+    }
+}
 # Please refer to the README file to create an UTF-8 database with MySQL.
 
 EMAIL_HOST = 'localhost'
@@ -98,9 +88,8 @@ SECRET_KEY = 'zk!^92901p458c8lo0(fox-&k7jj(aple76_k%eva7b1)xjo8-'
 
 # List of callables that know how to import templates from various sources.
 TEMPLATE_LOADERS = (
-    'django.template.loaders.filesystem.load_template_source',
-    'django.template.loaders.app_directories.load_template_source',
-#     'django.template.loaders.eggs.load_template_source',
+    'django.template.loaders.filesystem.Loader',
+    'django.template.loaders.app_directories.Loader',
 )
 
 MIDDLEWARE_CLASSES = (



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]