# HG changeset patch # User smith@nwoca.org # Date 1333217006 -3600 # Node ID 13a1e737ca3118b08816d89198fe6739ebaaec12 # Parent 3267840f534f0f6ed39474bc86ddd1071171f1f3 USASR-800: Fix command line env setting diff -r 3267840f534f -r 13a1e737ca31 init.gradle --- a/init.gradle Sat Mar 31 18:43:07 2012 +0100 +++ b/init.gradle Sat Mar 31 19:03:26 2012 +0100 @@ -48,7 +48,7 @@ def void projectsEvaluated(Gradle gradle) { def ssdtArtifactory = 'http://repos.ssdt.nwoca.org/artifactory' Project root = gradle.getRootProject() - root.allprojects { + root.allprojects { def thisProject = delegate configurations.all { resolutionStrategy.cacheChangingModulesFor 120, 'minutes' @@ -120,7 +120,7 @@ if (file('private.properties').exists()) { developerPrivate.load(file('private.properties').newReader()) } - gradle.ext.env = (gradle.ext.has('env') ? gradle.env : (developerPrivate.env ?: 'dev')) + gradle.ext.env = (hasProperty('env') ? getProperty('env') : (developerPrivate.env ?: 'dev')) println "Environment is: $gradle.env" def slurper = new ConfigSlurper(gradle.env) def environment = new ConfigObject()