restructurized templates and scripts