Remove repository release checks since init script adds automatically

This commit is contained in:
Rob Winch 2013-10-29 16:48:23 -05:00
parent 17b9f33351
commit fa3d303f79
1 changed files with 0 additions and 14 deletions

View File

@ -6,13 +6,6 @@ task checkDependencies << {
} }
} }
task checkRepositories << {
verifyNoRepositoriesMatching(".*snapshot.*")
if(releaseBuild) {
verifyNoRepositoriesMatching(".*milestone.*")
}
}
if(!snapshotBuild) { if(!snapshotBuild) {
tasks.findByPath('check')?.dependsOn checkRepositories, checkDependencies tasks.findByPath('check')?.dependsOn checkRepositories, checkDependencies
} }
@ -23,10 +16,3 @@ def verifyNoDependenciesMatchingVersion(def pattern) {
throw new GradleException("${project.name} cannot have dependencies with a version that matches $pattern when its version is ${project.version}. Got\n $dependencies") throw new GradleException("${project.name} cannot have dependencies with a version that matches $pattern when its version is ${project.version}. Got\n $dependencies")
} }
} }
def verifyNoRepositoriesMatching(def pattern) {
def matchingRepositories = repositories.findAll { r -> r.url?.toString()?.matches(pattern) }.flatten().collect { it.url }.toSet().join("\n ")
if(matchingRepositories) {
throw new GradleException("${project.name} cannot have repositories with a version that matches $pattern when its version is ${project.version}. Got\n $matchingRepositories")
}
}