Adding a compiled gradle plugin to your gradle distribution

Is it possible to add a compiled gradle plugin to your gradle distribution? I tried putting a compiled .jar of my plugin in ‘GRADLE_HOME/lib’, and then tried to apply it in my project with apply plugin: ‘group.name’, but it didn’t work:

A problem occurred evaluating root project ‘test’.

Failed to apply plugin [id ‘group.name’]

Plugin with id ‘group.name’ not found.

Check out ‘samples/customDistribution’ in the ‘gradle-all’ download.