Section D.2 Aspell
Aspell is a spell-checker which you can easily configure to skip every piece of text used as a name of an XML element, and to skip PreTeXt elements that are likely to contain text that is not really made up of words and sentences. For example, the element
<chapter>
might not be flagged by some mainstream spell checkers, but most likely the element <mdash/>
will be flagged by every spell checker, including the default configuration of Aspell. And your <m>
elements are full of LaTeX, not words. Unfortunately, Aspell will not follow your xi:xinclude
directives, so you need to run it against each of your files if you have modularized your source. A command-line invocation would like like:aspell -c ~/aota/src/fish.xml
Installation on Linux should be straightforward through your distribution’s package manager. On a Mac, the executable, and a dictionary for your language, can be installed easily via MacPorts (
[provisional cross-reference: macports]
). Recent improvements on Windows (ca. 2019-06-06) perhaps imply that WSL or the Ubuntu Linux install may provide an easy avenue. Please report steps that result in a successful Windows installation, so we can include them here.Configuration is achieved via a “hidden” file at the top of your home directory, namely
.aspell.conf
. A Mac will try to keep you away from hidden files, which are the ones whose name begins with a period. Let SublimeText give you an assist here. In Listing D.2.1 we show a first run at a useful configuration file. You definitely want to add the SGML filter, since this is what tells Aspell that you are working on XML files 1 , so that all element names, attributes, etc. will not be checked. The remainder is a suggested list of PreTeXt elements to skip. Suggestions for additions are welcome here.You can run Aspell in a sort of batch, non-interactive mode by adding the
-a
switch and then providing your source on standard input and directing results from standard output. But I do not find it very useful.You have attempted of activities on this page.
SGML is the precursor of XML.