Mercurial > public > develkit
diff init.gradle @ 123:6f1918544f7f
Add test to cleanLocal to ensure local repo was removed
author | smith@nwoca.org |
---|---|
date | Wed, 06 Feb 2013 19:58:34 +0000 |
parents | 8ddd1a6fa4ea |
children | 81a8ecfbc8fa |
line wrap: on
line diff
--- a/init.gradle Mon Jan 07 15:29:45 2013 -0500 +++ b/init.gradle Wed Feb 06 19:58:34 2013 +0000 @@ -38,7 +38,12 @@ if ( local ) { logger.info "removing local repo: $it" new File(System.properties['user.home'] + "/.ssdt/local-repo").deleteDir() - new File(gradle.ivyUserDir + "/local").deleteDir() + def localDir = new File(gradle.ivyUserDir + "/local") + localDir.deleteDir() + logger.info "verifying removal of local repo" + if (localDir.exists()) { + throw new org.gradle.api.GradleException("Unable to clean ${localDir}. Files may be locked by another process.") + } } }