Add main file to package #5
Move template logic to specific module (closes #4)