Tidy up files with custom template syntax