This script adds syntax highlighting to code sections in DragonRuby docs. No js required.
You don't need to change any dragon ruby files to transform docs.html. It will generate output.html and appends css to docs.css
- Python 3
- pip install beautifulsoup4
- pip install Pygments
Goto docs folder in Dragon Ruby installation. Here you should find docs.html. Copy dragon_pyg.py to same folder.
Run the following command in your shell after navigating to docs folder
python3 dragon_pyg.py
It will take some time to generate the output.html. If you like it rename it docs.html
Note: original docs.html is around 1.5 mb. This generates 6 mb html file.