Giter Site home page Giter Site logo

Comments (3)

timlinux avatar timlinux commented on May 23, 2024

Ok I resolved the remaining issues. Update patch below that adds notes that ratings and taggit should be listed in INSTALLED_APPS.

Regards

Tim

================= DIFF =======================

diff --git a/README.rst b/README.rst
index 2f08222..df7df00 100644
--- a/README.rst
+++ b/README.rst
@@ -47,9 +47,9 @@ from somewhere on your Python path::
 
     git clone git://github.com/coleifer/djangosnippets.org.git 
 
-Then add ``cab`` to the ``INSTALLED_APPS`` setting of your Django
-project, run ``manage.py syncdb``, and either put a call to
-``include('cab.urls')`` somewhere inn your root URLConf or copy over
+Then add ``ratings``, ``taggit`` and ``cab`` to the ``INSTALLED_APPS`` setting
+of your Django project, run ``manage.py syncdb``, and either put a call to
+``include('cab.urls.snippets')`` somewhere inn your root URLConf or copy over
 the URL patterns from Cab that you want to use.
 
 Note that the ``get_absolute_url`` methods of the ``Language``,
@@ -65,6 +65,20 @@ them with Django's ``ABSOLUTE_URL_OVERRIDES`` setting.
 .. _django-haystack: http://github.com/toastdriven/django-haystack/
 .. _django-amazon-resources: http://github.com/coleifer/django-amazon-resources/
 
+For search support you need to set up a search engine and configure haystack:
+
+``HAYSTACK_SITECONF = 'search_sites'``
+``HAYSTACK_SEARCH_ENGINE = 'whoosh'``
+``# Place where search indexes are stored for snippets - should be non web accessible``
+``HAYSTACK_WHOOSH_PATH = '/some-path/search-index'``
+
+And you should add a file called ``search_sites.py`` to your project with the 
+following lines:
+
+``import haystack``
+``haystack.autodiscover()``
+
+
 
 Templates
 =========

from djangosnippets.org.

coleifer avatar coleifer commented on May 23, 2024

Applied. Thank you so much for catching this and taking the trouble to submit a diff!

from djangosnippets.org.

timlinux avatar timlinux commented on May 23, 2024

Sorry to give thise feedback in drips and drabs - the urls py needed something like this for me:

   # snippets app
   (r'^snippets/', include('cab.urls.snippets')),
   (r'^tags/', include('cab.urls.tags')),
   (r'^bookmarks/', include('cab.urls.bookmarks')),
   (r'^languages/', include('cab.urls.languages')),
   (r'^popular/', include('cab.urls.popular')),

I think there is still one more problem with search because urls like this are failing:

http://qgis-django.localhost/search/?q=Good

I'll post a hopefully final comment if I figure that one out.

Tim

from djangosnippets.org.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.