This repository has been archived by the owner on Jan 7, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 11
Grails Ivy Dependency
andresteingress edited this page Jun 13, 2011
·
11 revisions
If you want to use GContracts from within a Grails projects (with Grails >= 1.2), you can simply define a dependency on it by enabling the central Maven repo and add a single line to the dependencies list:
grails.project.class.dir = "target/classes" grails.project.test.class.dir = "target/test-classes" grails.project.test.reports.dir = "target/test-reports" //grails.project.war.file = "target/${appName}-${appVersion}.war" grails.project.dependency.resolution = { // inherit Grails' default dependencies inherits( "global" ) { // uncomment to disable ehcache // excludes 'ehcache' } log "warn" // log level of Ivy resolver, either 'error', 'warn', 'info', 'debug' or 'verbose' repositories { // grailsPlugins() // grailsHome() // ... mavenCentral() // ... } dependencies { // before 1.2.0: org.gcontracts:gcontracts:1.1.3 compile 'org.gcontracts:gcontracts-core:1.2.4' // ... } }
The compile target suffices since gcontracts solely relies on AST transformations during the compilation process.