Skip to content

Instantly share code, notes, and snippets.

@rkpontes
Created August 19, 2020 16:01
Show Gist options
  • Save rkpontes/247fc55e65eef6069e7984c3d8af2c0c to your computer and use it in GitHub Desktop.
Save rkpontes/247fc55e65eef6069e7984c3d8af2c0c to your computer and use it in GitHub Desktop.
include ':app'
def flutterProjectRoot = rootProject.projectDir.parentFile.toPath()
def plugins = new Properties()
def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins')
if (pluginsFile.exists()) {
pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) }
}
plugins.each { name, path ->
def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile()
include ":$name"
project(":$name").projectDir = pluginDirectory
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment