Skip to content
Browse files

GRAILS-9714 Add usage descriptions to several scripts

  • Loading branch information...
1 parent 9faacb7 commit e8bd718cd43065129e79df810b1e328fbae2ce70 @alexanderzeillinger alexanderzeillinger committed with jeffbrown Jan 4, 2013
View
8 scripts/CreateController.groovy
@@ -43,3 +43,11 @@ target ('default': "Creates a new controller") {
}
}
+
+USAGE = """
+ create-controller [NAME]
+
+where
+ NAME = The name of the controller. If not provided, this
+ command will ask you for the name.
+"""
View
8 scripts/CreateDomainClass.groovy
@@ -35,3 +35,11 @@ target ('default': "Creates a new domain class") {
createUnitTest(name: name, suffix: "")
}
}
+
+USAGE = """
+ create-domain-class [NAME]
+
+where
+ NAME = The name of the domain class. If not provided, this
+ command will ask you for the name.
+"""
View
8 scripts/CreateFilters.groovy
@@ -39,3 +39,11 @@ target ('default': "Creates a new filters class") {
createUnitTest(name: name, suffix: type)
}
}
+
+USAGE = """
+ create-filters [NAME]
+
+where
+ NAME = The name of the filters class. If not provided, this
+ command will ask you for the name.
+"""
View
8 scripts/CreateIntegrationTest.groovy
@@ -35,3 +35,11 @@ target ('default': "Creates a new Grails integration test which loads the whole
createIntegrationTest(name: name, suffix: "", testType:"Generic")
}
}
+
+USAGE = """
+ create-integration-test [NAME]
+
+where
+ NAME = The name of the controller. If not provided, this
+ command will ask you for the name.
+"""
View
7 scripts/CreatePlugin_.groovy
@@ -28,8 +28,9 @@ includeTargets << grailsScript("_GrailsCreateProject")
setDefaultTarget("createPlugin")
USAGE = """
- create-plugin <pluginName>
+ create-plugin [NAME]
where
- pluginName = the name of the new plugin
-"""
+ NAME = The name of the plugin. If not provided, this
+ command will ask you for the name.
+"""
View
17 scripts/CreateScaffoldController.groovy
@@ -26,14 +26,6 @@
includeTargets << grailsScript("_GrailsInit")
includeTargets << grailsScript("_GrailsCreateArtifacts")
-USAGE = """
- create-scaffold-controller [DOMAIN ...]
-
-where
- DOMAIN = The name, including package, of a domain class to create
- a scaffolding controller for. (default: prompts for a name)
-"""
-
target (default: "Creates a new scaffolding controller for a domain class") {
depends(checkVersion, parseArguments)
@@ -65,3 +57,12 @@ target (default: "Creates a new scaffolding controller for a domain class") {
}
}
+
+USAGE = """
+ create-scaffold-controller [NAME]
+
+where
+ NAME = The name, including package, of the domain class to create
+ a scaffolded controller for. If not provided, this
+ command will ask you for the name.
+"""
View
8 scripts/CreateScript.groovy
@@ -36,3 +36,11 @@ target ('default': "Creates a Grails Gant Script") {
path: "scripts", skipPackagePrompt: true)
}
}
+
+USAGE = """
+ create-script [NAME]
+
+where
+ NAME = The name of the script. If not provided, this
+ command will ask you for the name.
+"""
View
8 scripts/CreateService.groovy
@@ -39,3 +39,11 @@ target ('default': "Creates a new service class") {
createUnitTest(name: name, suffix: type)
}
}
+
+USAGE = """
+ create-service [NAME]
+
+where
+ NAME = The name of the service. If not provided, this
+ command will ask you for the name.
+"""
View
8 scripts/CreateTagLib.groovy
@@ -37,3 +37,11 @@ target ('default': "Creates a new tag library") {
createUnitTest(name: name, suffix: type, superClass: "TagLibUnitTestCase")
}
}
+
+USAGE = """
+ create-tab-lib [NAME]
+
+where
+ NAME = The name of the tag library. If not provided, this
+ command will ask you for the name.
+"""
View
8 scripts/CreateUnitTest.groovy
@@ -36,3 +36,11 @@ target ('default': "Creates a new Grails unit test. A unit test requires that yo
createUnitTest(name: name, suffix: "", testType:"UnitTest")
}
}
+
+USAGE = """
+ create-unit-test [NAME]
+
+where
+ NAME = The name of the controller. If not provided, this
+ command will ask you for the name.
+"""
View
9 scripts/GenerateController.groovy
@@ -32,3 +32,12 @@ target ('default': "Generates the CRUD controller for a specified domain class")
generateForName = argsMap["params"][0]
generateForOne()
}
+
+USAGE = """
+ generate-controller [NAME]
+
+where
+ NAME = Either a domain class name (case-sensitive) or a
+ wildcard (*). If you specify the wildcard then
+ controllers will be generated for all domain classes.
+"""
View
9 scripts/GenerateViews.groovy
@@ -32,3 +32,12 @@ target ('default': "Generates the CRUD views for a specified domain class") {
generateForName = argsMap["params"][0]
generateForOne()
}
+
+USAGE = """
+ generate-views [NAME]
+
+where
+ NAME = Either a domain class name (case-sensitive) or a
+ wildcard (*). If you specify the wildcard then
+ views will be generated for all domain classes.
+"""
View
7 scripts/SetVersion.groovy
@@ -83,3 +83,10 @@ target ('default': "Sets the current application version") {
event("StatusFinal", [ "Application version updated to $newVersion"])
}
}
+
+USAGE = """
+ set-version [NUMBER]
+
+where
+ NUMBER = The number to set the current application version to.
+"""

0 comments on commit e8bd718

Please sign in to comment.
Something went wrong with that request. Please try again.