Refactor build.gradle