Reorganize template files