private static List<String> dependsOn(List<GradleTask> tasks) {
   List<String> names = Lists.newArrayList();
   for (GradleTask task : tasks) {
     names.add(task.getName());
   }
   return names;
 }
 private static String addTasks(String source, List<GradleTask> tasks) {
   for (GradleTask task : tasks) {
     source =
         GradleSourceUtil.insertTask(
             source,
             task.getName(),
             dependsOn(task.getDependsOn()),
             task.getType(),
             task.getCode());
   }
   return source;
 }