"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "docs/scriptindex.rst" between
xapian-omega-1.4.19.tar.xz and xapian-omega-1.4.20.tar.xz

About: Xapian Omega is an application built on Xapian, consisting of indexers and a CGI search frontend.

scriptindex.rst  (xapian-omega-1.4.19.tar.xz):scriptindex.rst  (xapian-omega-1.4.20.tar.xz)
skipping to change at line 94 skipping to change at line 94
long URLs as terms, omindex implements a scheme where the end of long URLs as terms, omindex implements a scheme where the end of
a long URL is hashed (short URLs are left as-is). You can use this a long URL is hashed (short URLs are left as-is). You can use this
same scheme in scriptindex. LENGTH defaults to 239, which if you same scheme in scriptindex. LENGTH defaults to 239, which if you
index with prefix "U" produces url terms compatible with omindex. index with prefix "U" produces url terms compatible with omindex.
If specified, LENGTH must be at least 6 (because the hash takes 6 If specified, LENGTH must be at least 6 (because the hash takes 6
characters). characters).
hextobin hextobin
converts pairs of hex digits to binary byte values (providing a way converts pairs of hex digits to binary byte values (providing a way
to specify arbitrary binary strings e.g. for use in a document value to specify arbitrary binary strings e.g. for use in a document value
slot). The input should have an even length and be composed entirely slot). The input must have an even length and be composed entirely
of hex digits (if it isn't, an error is reported and the value is of hex digits (if it isn't, an error is reported).
unchanged).
``hextobin`` was added in Omega 1.4.6. ``hextobin`` was added in Omega 1.4.6. Prior to Omega 1.4.20, the
"error" on a bad value was really handled like a warning - it didn't
cause Omega to exit with non-zero status, instead the value was
passed on unchanged.
index[=PREFIX] index[=PREFIX]
split text into words and index (with prefix PREFIX if specified). split text into words and index (with prefix PREFIX if specified).
indexnopos[=PREFIX] indexnopos[=PREFIX]
split text into words and index (with prefix PREFIX if specified), but split text into words and index (with prefix PREFIX if specified), but
don't include positional information in the database - this makes the don't include positional information in the database - this makes the
database smaller, but phrase searching won't work. database smaller, but phrase searching won't work.
load load
reads the contents of the file using the current text as the filename reads the contents of the file using the current text as the filename
and then sets the current text to the contents. If the current text and then sets the current text to the contents. If the current text
is empty, a warning is issued (since Xapian 1.4.10). If the file can't is empty, a warning is issued (since Xapian 1.4.10). If the file can't
be loaded (not found, wrong permissions, etc) then an error is issued an d be loaded (not found, wrong permissions, etc) then an error is issued an d
the current text is set to empty. scriptindex exits (prior to Omega 1.4.20 this "error" was really handled
as a warning - scriptindex continued with the current text set to empty,
and the final exit status wasn't affected).
If the next action is ``truncate``, then scriptindex is smart enough to If the next action is ``truncate``, then scriptindex is smart enough to
know it only needs to load the start of a large file. know it only needs to load the start of a large file.
lower lower
lowercase the text (useful for generating boolean terms) lowercase the text (useful for generating boolean terms)
ltrim[=CHARACTERSTOTRIM] ltrim[=CHARACTERSTOTRIM]
remove leading characters from the text which are in remove leading characters from the text which are in
``CHARACTERSTOTRIM`` (default: space, tab, formfeed, vertical tab, ``CHARACTERSTOTRIM`` (default: space, tab, formfeed, vertical tab,
skipping to change at line 211 skipping to change at line 215
``trim`` was added in Omega 1.4.19. ``trim`` was added in Omega 1.4.19.
truncate=LENGTH truncate=LENGTH
truncate to at most LENGTH bytes, but avoid chopping off a word (useful truncate to at most LENGTH bytes, but avoid chopping off a word (useful
for sample and title fields) for sample and title fields)
unhtml unhtml
strip out HTML tags strip out HTML tags
unique[=PREFIX] unique[=PREFIX[,missing=MISSINGACTION]]
use the value in this field for a unique ID. If the value is empty, use the value in this field for a unique ID. If the value is empty,
a warning is issued but nothing else is done. Only one record with a warning is issued but nothing else is done. Only one record with
each value of the ID may be present in the index: adding a new record each value of the ID may be present in the index: adding a new record
with an ID which is already present will cause the old record to be with an ID which is already present will cause the old record to be
replaced (or deleted if the new record is otherwise empty). You should replaced or deleted.
also index the field as a boolean field using the same prefix so that
the old record can be found. In Omega, ``Q`` is conventionally used as Deletion happens if the only input field present has the ``unique``
the prefix of a unique term. You can use ``unique`` at most once in action applied to it. (Prior to 1.5.0, if there were multiple lists
each index script (this is only enforced since Omega 1.4.5, but older of actions applied to an input field this triggered replacement instead
versions didn't handle multiple instances usefully). of deletion). If you want to suppress this deletion feature, supplying
a dummy input field which doesn't match the index script will achieve
this.
You should also index the field as a boolean field using the same
prefix so that the old record can be found. In Omega, ``Q`` is
conventionally used as the prefix of a unique term.
You can use ``unique`` at most once in each index script (this is only
enforced since Omega 1.4.5, but older versions didn't handle multiple
instances usefully).
The optional ``missing`` parameter is supported since Omega 1.4.20.
It controls what happens when a record is processed which doesn't
trigger the ``unique`` action or triggers the ``unique`` action with
an empty value. It can be one of:
* ``error``: Exit with an error upon encountering such a document
(default in Omega >= 1.5.0)
* ``new``: Create a new document (default in Omega < 1.4.20 when
``unique`` not triggered)
* ``warn+new``: Issue a warning and create a new document (default in
Omega >= 1.4.20 and in older versions when ``unique`` is triggered
with an empty value)
* ``skip``: Move on to the next record
* ``warn+skip``: Issue a warning and move on to the next record
value=VALUESLOT value=VALUESLOT
add as a Xapian document value in slot VALUESLOT. Values can be used add as a Xapian document value in slot VALUESLOT. Values can be used
for collapsing equivalent documents, sorting the MSet, etc. If you for collapsing equivalent documents, sorting the MSet, etc. If you
want to perform numeric sorting, use the valuenumeric action instead. want to perform numeric sorting, use the valuenumeric action instead.
valuenumeric=VALUESLOT valuenumeric=VALUESLOT
Like value=VALUESLOT, this adds as a Xapian document value in slot Like value=VALUESLOT, this adds as a Xapian document value in slot
VALUESLOT, but it first encodes for numeric sorting using VALUESLOT, but it first encodes for numeric sorting using
Xapian::sortable_serialise(). Values set with this action can be Xapian::sortable_serialise(). Values set with this action can be
skipping to change at line 255 skipping to change at line 284
weight=FACTOR weight=FACTOR
set the weighting factor to FACTOR (a non-negative integer) for any set the weighting factor to FACTOR (a non-negative integer) for any
``index`` or ``indexnopos`` actions in the remainder of this list of ``index`` or ``indexnopos`` actions in the remainder of this list of
actions. The default is 1. Use this to add extra weight to titles, actions. The default is 1. Use this to add extra weight to titles,
keyword fields, etc, so that words in them are regarded as more keyword fields, etc, so that words in them are regarded as more
important by searches. important by searches.
Input files: Input files:
============ ============
The data to be indexed is read in from one or more files. Each file has The data to be indexed is read in from one or more input files. Each input
records separated by a blank line. Each record contains one or more fields of file consists of zero or more records, each separated by one or more blank
the form "name=value". If value contains newlines, these must be escaped by lines.
inserting an equals sign ('=') after each newline. Here's an example record::
Omega 1.4.20 and later explicitly allow multiple blank lines between
records, and also blank lines before the first record and after the last
record - in earlier versions only a single blank line after each record was
explicitly handled, and extra blank lines were handled as an empty records.
If you want to be compatible with older versions we recommend a single
blank line after each record (with the blank line after the final record
being optional).
Each record contains one or more fields of the form "name=value". If value
contains newlines, these must be escaped by inserting an equals sign ('=')
after each newline. Here's an example record::
id=ghq147 id=ghq147
title=Sample Record title=Sample Record
value=This is a multi-line value=This is a multi-line
=value. Note how each newline =value. Note how each newline
=is escaped. =is escaped.
format=HTML format=HTML
Example: Example:
======== ========
 End of changes. 6 change blocks. 
16 lines changed or deleted 56 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)