Generates a markdown TOC (table of contents)