Execute template into a buffer to avoid partial output and properly catch errors before writing
Merge pull request #4 from gust1n/master

Execute template into a buffer to avoid partial output and properly catch errors before writing