Skip to content

Commit 10d13fe

Browse files
committed
just started using haystack
1 parent 09cdebc commit 10d13fe

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

djity/project_skeleton/local_settings.py_tmpl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ DATABASES = {{
2525
}}
2626
}}
2727

28+
# Haystack search engine backend configuration, see:
29+
# http://docs.haystacksearch.org/dev/tutorial.html
30+
HAYSTACK_SEARCH_ENGINE = 'whoosh'
31+
HAYSTACK_WHOOSH_PATH = '%s/data/whoosh/djity_index' % PROJECT_ROOT
32+
2833
# in order to activate the django debug toolbar you will need to have it
2934
# installed: 'pip install django-debug-toolbar'
3035
DEBUG = {develop!r}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
import haystack
2+
haystack.autodiscover()

djity/project_skeleton/settings.py_tmpl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,9 @@ ADMIN_MEDIA_PREFIX = '/media/'
5555

5656
DAJAXICE_MEDIA_PREFIX="dajaxice" # Will create http://yourdomain.com/dajaxice/...
5757

58+
# Haystack configuration
59+
HAYSTACK_SITECONF = 'search_sites'
60+
5861
# Make this unique, and don't share it with anybody.
5962
SECRET_KEY = '+uf*31w)3i8w74)1(^6u%utlfyb^lzu_1_4rqt=+c55v*=lj3g'
6063

@@ -108,6 +111,9 @@ INSTALLED_APPS = [
108111
'dajaxice',
109112
'dajax',
110113

114+
# Haystack for search
115+
'haystack',
116+
111117
#Djity Core
112118
'djity.portlet',
113119
'djity.style',

0 commit comments

Comments
 (0)