OneSignal / OneSignal-Gradle-Plugin

Use with OneSignal-Android-SDK to help integrate it into your Android Studio or Gradle project. https://onesignal.com
Other
64 stars 17 forks source link

Fix AGP version detection when used in an "apply from:" file #149

Closed jkasten2 closed 3 years ago

jkasten2 commented 3 years ago

Issue

"OneSignal Warning: Could not get AGP plugin version" warning still prints if this plugin is applied from an "apply from:" file.

"apply from:" requires a special case handling as the in an "apply from:" file the hosting file's classpath is not inherited. See https://github.com/gradle/gradle/issues/4007 for more details.

Fix

project.buildscript can be inspected per this answer and this strategy was used in this PR: https://stackoverflow.com/a/18119304/1244574


This change is Reviewable