diff --git a/examples-dark/.gitkeep b/examples-dark/.gitkeep new file mode 100644 index 0000000..d4db507 --- /dev/null +++ b/examples-dark/.gitkeep @@ -0,0 +1 @@ +This directory is preserved for the output from rendering examples. diff --git a/examples-light/.gitkeep b/examples-light/.gitkeep new file mode 100644 index 0000000..d4db507 --- /dev/null +++ b/examples-light/.gitkeep @@ -0,0 +1 @@ +This directory is preserved for the output from rendering examples. diff --git a/tox.ini b/tox.ini index 5a37743..f711261 100644 --- a/tox.ini +++ b/tox.ini @@ -15,3 +15,11 @@ skip_install = True commands = ruff check ruff format --check + +[testenv:render-examples] +deps = + Pillow +commands = + # TODO(vytas): Make font name (auto-) configurable, not hardcoded. + pygmentize example-code/document.md -O 'font_name=SourceCodePro-Medium,font_size=24,style=falconry-dark' -o examples-dark/document.png + pygmentize example-code/document.md -O 'font_name=SourceCodePro-Medium,font_size=24,style=falconry-light' -o examples-light/document.png