In before “1.0-milestone-9” times I had a very simple “versions.gradle” file where I defined versions as:
scalaVersion = '2.9.1' scalaTest = '1.6.1' junitVersion = '4.+' mockitoVersion = '1.9.0-rc1'
and referenced them as:
testCompile ( ... ... [ group: 'org.scalatest', name: 'scalatest_2.9.1', version: scalaTest ], [ group: 'org.mockito', name: 'mockito-all', version: mockitoVersion ], [ group: 'junit', name: 'junit', version: junitVersion ] ) // libraries needed to run the scala tools scalaTools ( [group: 'org.scala-lang', name: 'scala-compiler', version: scalaVersion ], [group: 'org.scala-lang', name: 'scala-library', version: scalaVersion ] )
Now with “1.0-milestone-9” we have this thing => http://gradle.org/docs/current/dsl/org.gradle.api.plugins.ExtraPropertiesExtension.html
Which is quite confusing, as it does not reveal the “whys”, but only specifies the “hows”, which are hard to connect to simple real world things such as “specify a version property for an artifact”.
=> 1. What is the current approach to do that? Should it be done as:
project.version.scala = "2.9.1"
and then used as “project.version.scala” in deps. Or should it be done in any other way?
=> 2. Is there a way to go back to a simple " ‘scalalVersion = 2.9.1’ => ‘version: scalaVersion’ " usage? If not, why?
=> 3. What is the (usage) purpose of introducing ExtraPropertiesExtension?