ruby script to generate png images from files with markup support