Quickly Fix Common Typos In Documents Directly Using Linux Mint/Ubuntu Command Line

Correcting typos and various spelling mistakes can be directly done using Linux Terminal.

This is because it already has a useful interactive spell checker tool – aspell. It can help in quickly checking documents for typos and fix them.

Here is how to use it:

To list all the possible typos present in a document, run the command:

aspell list <  nameofdocument

It will then check for typos if any:

list of typos displayed by aspell in Linux terminal

To correct them, use the check parameter:

aspell check nameofdocument

correcting typos using aspell in Linux Mint/Ubuntu

aspell will display a list of alternative correct replacements for the mistyped words. Use the numbers corresponding to each of them. Also, other possible actions like ignoring, replacing or adding new words can also be performed. Choose as needed.

However, it won’t check for logical errors. That means if a word with an incorrect usage/reference is used but is grammatically correct , it won’t count that as a typo.

list of possible correct words for typos in aspell

For replacing the mistyped word, use the r option and enter it’s replacement if it’s not listed.

replacing mistyped words with a new word in aspell

All done.

If a spell check is run again, aspell won’t show a list of typos anymore.

typo free document after aspell is used

Happy typing.

Leave a Comment