All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.life.gy.LifePlugin.groovy Maven / Gradle / Ivy

There is a newer version: 2.0.1
Show newest version
package com.life.gy

import com.android.build.gradle.AppExtension
import com.android.build.gradle.LibraryExtension
import org.gradle.api.Plugin
import org.gradle.api.Project

public class LifePlugin implements Plugin{

    @Override
    void apply(Project project) {
        System.out.println("***** LifePlugin start *****")
        def extension
        if(project.getPlugins().hasPlugin("com.android.application")){
            extension = project.extensions.getByType(AppExtension)
        }else {
            extension = project.extensions.getByType(LibraryExtension)
        }
        LifeTransform transform = new LifeTransform()
        extension.registerTransform(transform)
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy