Repo link: https://github.com/mplewis/src2png
This interesting project can take source-code, apply syntax highlighting, and then create images from it. It’s only existed for a few days and already has hundreds of stars on GitHub.
Someone opened a pretty cool issue on the project as well: https://github.com/mplewis/src2png/issues/2