Add file_to_html, avoid duplication in main