pydoc/README.md

1.1 KiB
Raw Blame History

pydoc – Create a simple HTML website from multiple Markdown files with Python using Pandoc

This little command line tool written in Python loops through a directory on your hard drive and converts all existing Markdown files into HTML files.

Features

  • Converts all Markdown files of all subdirectories into HTML files and keeps the folder structure.
  • If a Markdown file is deleted, the program recognizes this and removes the corresponding HTML file.
  • The program takes into account a template file template.txt for Pandoc.
  • Additionally required files such as style.css or robots.txt can be stored in the assets folder, which are also copied to the HTML folder. If files are removed from the assets folder, the program recognizes this and deletes them from the HTML folder.
  • The program uses a configuration file settings.conf in which the important paths are stored.

CSS in subdirectories

If you use a style sheet, css_path in settings.conf should contain the absolute Path to your .css file (C:\Path\To\Assets\style.css or https://www.your-website.com/style.css), otherwise CSS won't work in subdirectories.