|
| 1 | +Spell checking |
| 2 | +============== |
| 3 | + |
| 4 | +Ultimately, some auto spell checking for relevant files (and even git commit |
| 5 | +messages) would be awesome, but for now, we'll settle with manual install and |
| 6 | +setup. |
| 7 | + |
| 8 | +Install |
| 9 | +------- |
| 10 | + |
| 11 | +apt update |
| 12 | +apt install aspell aspell-en |
| 13 | + |
| 14 | +Usage - non-interactive |
| 15 | +----------------------- |
| 16 | + |
| 17 | +To get a list of words that the spellchecker doesn't recognise, first cd to the |
| 18 | +appliance build code directory, then:: |
| 19 | + |
| 20 | + export COMMON=$FAB_PATH/common |
| 21 | + cat changelog | aspell list -a \ |
| 22 | + --encoding=utf-8 \ |
| 23 | + --personal=$PWD/spelling/.dic \ |
| 24 | + --add-extra-dicts=$PWD/spelling/dic \ |
| 25 | + --add-extra-dicts=$COMMON/spelling/common.dic \ |
| 26 | + --add-extra-dicts=$COMMON/spelling/common_changelog.dic \ |
| 27 | + > MIS_SPELLED.changelog |
| 28 | + |
| 29 | + export COMMON=$FAB_PATH/common |
| 30 | + cat README.rst | aspell list -a \ |
| 31 | + --encoding=utf-8 \ |
| 32 | + --personal=$PWD/spelling/.dic \ |
| 33 | + --add-extra-dicts=$PWD/spelling/dic \ |
| 34 | + --add-extra-dicts=$COMMON/spelling/common.dic \ |
| 35 | + --add-extra-dicts=$COMMON/spelling/common_readme.dic \ |
| 36 | + > MIS_SPELLED.readme |
| 37 | + |
| 38 | +Usage - interactive |
| 39 | +------------------- |
| 40 | + |
| 41 | +It is suggested that you run the above and add any new words (that are spelled |
| 42 | +right) to the spelling/dic (or one of the common dic files). Once you are ready |
| 43 | +to interactively run through this, you can do it like this:: |
| 44 | + |
| 45 | + export COMMON=$FAB_PATH/common |
| 46 | + aspell -c changelog \ |
| 47 | + --dont-backup \ |
| 48 | + --encoding=utf-8 \ |
| 49 | + --personal=$PWD/spelling/.dic \ |
| 50 | + --add-extra-dicts=$PWD/spelling/dic \ |
| 51 | + --add-extra-dicts=$COMMON/spelling/common.dic \ |
| 52 | + --add-extra-dicts=$COMMON/spelling/common_changelog.dic |
| 53 | + |
| 54 | + export COMMON=$FAB_PATH/common |
| 55 | + aspell -c README.rst \ |
| 56 | + --dont-backup \ |
| 57 | + --encoding=utf-8 \ |
| 58 | + --personal=$PWD/spelling/.dic \ |
| 59 | + --add-extra-dicts=$PWD/spelling/dic \ |
| 60 | + --add-extra-dicts=$COMMON/spelling/common.dic \ |
| 61 | + --add-extra-dicts=$COMMON/spelling/common_readme.dic |
| 62 | + |
| 63 | +sort -f | uniq |
0 commit comments