From e50a66789506398bef45edd2ff3d472609963268 Mon Sep 17 00:00:00 2001 From: Stefan Armbruster Date: Tue, 18 Jan 2011 15:47:29 +0100 Subject: [PATCH] GRAILS-5635: allowing numbers in plugin names (but not at the beginning) --- scripts/_GrailsCreateProject.groovy | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/_GrailsCreateProject.groovy b/scripts/_GrailsCreateProject.groovy index 0bf83c56576..fcde4c4b980 100644 --- a/scripts/_GrailsCreateProject.groovy +++ b/scripts/_GrailsCreateProject.groovy @@ -71,8 +71,8 @@ target(createPlugin: "The implementation target") { // Rename the plugin descriptor. pluginName = GrailsNameUtils.getNameFromScript(grailsAppName) - if (!(pluginName ==~ /[a-zA-Z-]+/)) { - println "Error: Specified plugin name [$grailsAppName] is invalid. Plugin names can only contain word characters separated by hyphens." + if (!(pluginName ==~ /[a-zA-Z][a-zA-Z0-9-]+/)) { + println "Error: Specified plugin name [$grailsAppName] is invalid. Plugin names can only contain word characters and numbers separated by hyphens." exit 1 }