-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathREADME
More file actions
47 lines (29 loc) · 1.41 KB
/
README
File metadata and controls
47 lines (29 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
Modifications for this version
========
This version has been modified to work with ActiveScaffold for Rails 3.1
ActiveScaffold Thinking Sphinx Adapter
========
as_thinking_sphinx is a simple adapter to allow the built-in ActiveScaffold search to
use the Sphinx search engine as well as the default.
It was created because of the need to search tables with a large number of records.
Prerequisites
========
Sphinx (http://www.sphinxsearch.com/)
Thinking Sphinx (http://freelancing-god.github.com/ts/en/)
ActiveScaffold (http://activescaffold.com/)
Installation
========
This assumes you already have a working Sphinx installation with the Thinking Sphinx gem
installed and running. Your models should already have indexes configured.
script/plugin install git://github.com/coryp/as_thinking_sphinx.git
Configuration
=======
In the scaffold controllers in which you would like to use Sphinx, add the following line
in your active_scaffold config block:
config.search.engine = 'thinking_sphinx'
That's it!
Super-advanced configuration: If you want to specify the model you will be searching on (since by default it is derived from the current controller), add the following option:
config.search.model_name = 'product'
Copyright (c) 2012 Andrew Cates, released under the MIT license
Copyright (c) 2010 Cory Patterson, released under the MIT license
Copyright (c) 2010 Hans Masing, released under the MIT license