Closed suhlig closed 6 years ago
Instead of using aspell, we could use hunspell
which uses OpenOffice dictionaries. There is a nice tutorial for running it on the command line. On macOS at least, hunspell comes without dictionaries. Download en_us.oxt
from https://sourceforge.net/projects/aoo-extensions/files/1470/1/ and unzip it with unzip en_us.oxt -d dict-en_US
. The results are assumed to be in ~/Downloads/dict-en_US
.
Instead of testing the already pushed content, we should run the check before it is published. This could be done in a build pipeline that runs the aforementioned steps. The actual spell check would just test whether a call like this is empty:
pandoc _labs/002-static-webpage.markdown -t plain | DICPATH=.:~/Downloads/dict-en_US hunspell -d en_US -p local.dic -l
While we are creating a pipeline anyway, we might as well just run jekyll build
and push the app as static files to Bluemix (which is what we explain in this very workshop).
Fixed with 8b64ffc0d1c904027d67c255c0e231937ece25e8 (sans the pipeline aspect)
e.g.
curl -L http://hrtclouddemo.github.io/ | pandoc --from html --to plain | aspell --list
AC: When a commit is pushed that contains spelling errors, the build will break and the code will not be published.