replacing auto-generated build.gradle with template.gradle