aspell-autobuildhash - Autobuilding aspell hash files for some dicts
aspell-autobuildhash [--force]
Options: --debug Show some extra information. --force Rebuild the hash file for all dicts providing a compat file skipping the test.
--debug Show some extra information. --force Rebuild the hash file for all dicts providing a compat file regardless of the compatibility levels found.
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.
aspell maintainer should also call this script from package postinst. When comparing versions it will get the aspell version from file /usr/share/aspell/aspell.compat.
Закладки на сайте Проследить за страницей |
Created 1996-2024 by Maxim Chirkov Добавить, Поддержать, Вебмастеру |