gradlegriffon

Griffon error Could not find property 'compileOnly' on configuration


I try to create a Griffon application as described at http://griffon-framework.org/tutorials/1_getting_started.html#_tutorial_1_2

Using: Gradle 2.9
lazybones 0.8.3
mvn 3.3.9

Entered: lazybones create griffon-swing-java sample

Define value for 'group' [org.example]: 
Define value for 'artifactId' [sample]: 
Define value for 'version' [0.1.0-SNAPSHOT]: 
Define value for 'griffonVersion' [2.7.0]: 
Define value for 'package' [org.example]: 
Define value for 'className' [Sample]:

Project created in sample!

cd sample
gradle run

Gives this error:

FAILURE: Build failed with an exception.

* Where:
Script '/home/username/dev/griffon_prj/sample/gradle/integration-test.gradle' line: 20

* What went wrong:
A problem occurred evaluating script.
> Could not find property 'compileOnly' on configuration container.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Am I missing something?


Solution

  • It sounds like a gradle configuration/script error, the gradle 2.9 version could the be problem, the tutorial mentions 2.14.

    IMHO you should install gradle 2.14.1, it works fine. I followed this tutorial and did a groovy-swing app without any problem with lazybones 0.8.3 and gradle 2.14.1.

    You can have several gradle installations, each one in it's own directory, without any problem, just to take care of the path and GRADLE_HOME if you use command line (you will for the tuto).