Here’s an example Gradle JavaFX build on GitHub. Note that according to Bintray, the latest version of the plugin is 8.1.1, so replace the ‘0.3.0’ in the plugin URL with ‘8.1.1’ if you want the latest.
Just to be clear, this is a very unusual way to distribute a Gradle plugin. Most are much easier to incorporate in a build!
Edit: up-to-date fork that works using “apply plugin” https://github.com/FibreFoX/javafx-gradle-plugin