README.rdoc in xapian_db-0.5.1 vs README.rdoc in xapian_db-0.5.2
- old
+ new
@@ -32,28 +32,28 @@
If you want to use xapian_db in a Rails app, you need Rails 3 or newer.
=== Install Xapian if not already installed
-To use xapian_db, make sure you have the Xapian library and ruby bindings installed. At the time of this writing, the newest release of Xapian was 1.2.3. You might
+To use xapian_db, make sure you have the Xapian library and ruby bindings installed. At the time of this writing, the newest release of Xapian was 1.2.4. You might
want to adjust the URLs below to load the most current release of Xapian.
The example code works for OSX. On linux you might want to use wget instead of curl.
A future release of xapian_db might include the Xapian binaries and make this step obsolete.
==== Install Xapian
- curl -O http://oligarchy.co.uk/xapian/1.2.3/xapian-core-1.2.3.tar.gz
- tar xzvf xapian-core-1.2.3.tar.gz
- cd xapian-core-1.2.3
+ curl -O http://oligarchy.co.uk/xapian/1.2.4/xapian-core-1.2.4.tar.gz
+ tar xzvf xapian-core-1.2.4.tar.gz
+ cd xapian-core-1.2.4
./configure --prefix=/usr/local
make
sudo make install
==== Install ruby bindings for Xapian
- curl -O http://oligarchy.co.uk/xapian/1.2.2/xapian-bindings-1.2.3.tar.gz
- tar xzvf xapian-bindings-1.2.3.tar.gz
- cd xapian-bindings-1.2.3
+ curl -O http://oligarchy.co.uk/xapian/1.2.2/xapian-bindings-1.2.4.tar.gz
+ tar xzvf xapian-bindings-1.2.4.tar.gz
+ cd xapian-bindings-1.2.4
./configure --prefix=/usr/local XAPIAN_CONFIG=/usr/local/bin/xapian-config
make
sudo make install
For a first look, look at the examples in the examples folder. There's the simple ruby script basic.rb that shows the basic
@@ -99,17 +99,9 @@
Attributes will get indexed and are stored in the documents. You will be able to access the name and the first name in your search results.
If you want to index additional data but do not need access to it from a search result, use the index method:
blueprint.index :remarks, :weight => 5
-
-If you config a class that has a language property, e.g.
-
- class Person
- attr_reader :language
- end
-
-The method must return the iso code for the language (:en, :de, ...) as a symbol or a string. Don't worry if you have languages in your database that are not supported by Xapian. If the language is not supported, XapianDb will fall back to the global language configuration or none, if you haven't configured one.
If you want to declare multiple attributes or indexes with default options, you can do this in one statement:
XapianDb::DocumentBlueprint.setup(Person) do |blueprint|
blueprint.attributes :name, :first_name, :profession