Skip to content

Instantly share code, notes, and snippets.

@potomak
Created August 20, 2010 12:05
Show Gist options
  • Save potomak/540158 to your computer and use it in GitHub Desktop.
Save potomak/540158 to your computer and use it in GitHub Desktop.
define_index do
indexes content
indexes :name, :sortable => true
indexes comments.content, :as => :comment_content
indexes [author.first_name, author.last_name], :as => :author_name
has author_id, created_at
end
@articles = Article.search params[:search]
tar xzvf sphinx-0.9.9.tar.gz
cd sphinx-0.9.9
./configure --prefix=/usr/local/
make
sudo make install
wget http://www.sphinxsearch.com/downloads/sphinx-0.9.9.tar.gz
script/plugin install git://github.com/freelancing-god/thinking-sphinx.git
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment