You could take an approach of
JSP Engine. Create a template.html file, with some markers in it for Dynamic data, like <INSERT NAME HERE>. Then use input streams to read from template.html and write it to some other html file. While doing this when you encounter the <INSERT NAME HERE> , write name instead of the custom tag. Ofcourse this gets complicated when you have more dynamic data and need to organize them in some structure, but it will be surely easier and configurable.