diff init.gradle @ 163:c5f09d617715

process environment files in name order
author Dave Smith <smith@nwoca.org>
date Tue, 14 Jan 2014 01:16:43 +0000
parents 29c3af8dc031
children 7474ff33a1ba
line wrap: on
line diff
--- a/init.gradle	Tue Jan 14 01:03:52 2014 +0000
+++ b/init.gradle	Tue Jan 14 01:16:43 2014 +0000
@@ -391,7 +391,7 @@
 	
     def environments = []
     gradle.ext.environment = environment
-    file('.').eachFileMatch(~/^environment.*\.groovy$/) { envFile ->
+    file('.').listFiles().findAll { it.name ==~ /^environment.*\.groovy$/ }.sort { it.name }.each { envFile ->
         def envName = envFile.name - '.groovy'
         def privateFile = file("private" + envName - "environment" + ".groovy")
         logger.info("loading environment $envFile.name")