This is a script copied from Pandoc's repository. Description ---------- From Pandoc's documentation: > This filter counts the words in the body of a document (omitting metadata > like titles and abstracts), including words in code. It should be more > accurate than wc -w run directly on a Markdown document, since the latter > will count markup characters, like the # in front of an ATX header, or tags > in HTML documents, as words. Setup ---- $ cd ~/bin/ # cd to ~/bin/ $ wget https://git.yctct.com/wcm/plain/wcm.lua # download the script $ chmod +x wcm.lua # make the script executable Make sure ~/bin/ is on $PATH. Usage ----- $ pandoc --lua-filter=$HOME/bin/wcm.lua file.md Source ------ Pandoc's repository. Author ----- jgm License ------- MIT License