repo.or.cz
/
acts_as_ferret.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
rebuild_index now uses ferret_configuration - closes #8
[acts_as_ferret.git]
/
rebuild_index.rb
blob
23877fd9e3ffc53c76cd65056986af1fc8285d9d
1
require 'ferret'
2
3
index = Ferret::Index::Index.new( :path => Content.class_index_dir,
4
:create => true
5
)
6
Content.find_all.each { |content| index << content.to_doc }
7
index.flush
8
index.optimize
9
index.close
10