|Dyxa.com - Document Archive|
|Manual Pages FAQs HOWTOs|
Index Return to Main Contents
NAMEaspell-autobuildhash - Autobuilding aspell hash files for some dicts
Options: --debug Show some extra information. --force Rebuild the hash file for all dicts providing a compat file skipping the test.
DESCRIPTIONaspell-autobuildhash is a script that will manage aspell hash files autobuild, intended to be called from the dictionaries-common tools. Depending on the aspell compatibility level and on the compatibility level used for the hash file if present, will decide whether it must be rebuilt or not. This script will only work on aspell packages prepared to use it, it will do nothing for other aspell dict packages.
--debug Show some extra information. --force Rebuild the hash file for all dicts providing a compat file regardless of the compatibility levels found.
PACKAGE MAINTAINERSTo use this system, just provide a $lang.compat file in /var/lib/aspell ($lang stands for the lang basename with variant if any, e.g. gl-minimos or en). Put a ``0'' in it or just create an empty one with touch.
Wordlists should previously be compressed either with gzip (and their extensions set as .mwl.gz or .wl.gz) or preferably first with aspell prezip and then gzipped (with .cwl.gz extension). This applies both for plain wordlists and munched wordlists (in the ispell way) if you use affix compression.
If your package will provide a single hash, install prezipped+gzipped wordlist as /usr/share/aspell/$lang.cwl.gz or, if prezip is not used, as /usr/share/aspell/$lang.mwl.gz.
If your package will provide more than one aspell hash for the same $lang, you will need to place each compressed wordlist as e.g. /usr/share/aspell/$subdict.cwl.gz, and the common $lang.compat as above. Then create a /usr/share/aspell/$lang.contents file with the base names of the subdicts, one in a line. For English that will contain, amongst other possible lines
en-common en-variant_0 en-variant_1 en-variant_2 en_CA-w_accents-only
No need to use this file if a single hash is being created.
Dictionaries-common scripts will call internally this script and create a single hash file at /var/lib/ispell/$lang.rws, or hash files at /var/lib/ispell/$subdict.rws. You must set a symlink to that files from /usr/lib/aspell/$lang.rws or /usr/lib/aspell/$subdict.rws as appropriate. You are also suggested to create empty files at /var/lib/aspell/$lang.rws or for all of the /var/lib/aspell/$subdict.rws in the install target of your package build process. This empty file will be overwritten when the real hash is created, but will make the hash be removed at package removal without any magic being done in the postrm and will also help to keep track about which package owns that file.
AUTHORSAgustin Martin <firstname.lastname@example.org>
© 2013 Dyxa.com. All Rights Reserved.