inserted template into files