Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Revert "Revert "Remove unused usage check at start of each script.""

This reverts commit 74c0158.
  • Loading branch information...
commit 94c3f37c8b8284f47b5fc54821558a25464ad722 1 parent 74c0158
authored December 21, 2011
2  scripts/BeesAppChecksums.groovy
@@ -11,8 +11,6 @@ grails bees-app-checksums [appId]
11 11
 target(beesAppChecksums: "Returns the checksums for an application.") {
12 12
 	depends(checkConfig, prepareClient)
13 13
 	
14  
-	if(usage()) return
15  
-	
16 14
 	String appId = buildAppId()
17 15
 	
18 16
 	def response
2  scripts/BeesAppDelete.groovy
@@ -11,8 +11,6 @@ grails bees-app-delete [appId]
11 11
 target(beesAppDelete: "Delete an application.") {
12 12
 	depends(checkConfig, prepareClient)
13 13
 	
14  
-	if(usage()) return
15  
-	
16 14
 	String appId = buildAppId()
17 15
 	
18 16
 	def response
4  scripts/BeesAppDeploy.groovy
@@ -15,8 +15,6 @@ grails bees-app-deploy [appId] [tag]
15 15
 target(beesAppDeploy: "Deploy a new version of an application using a WAR archive file.") {
16 16
 	depends(checkConfig, prepareClient)
17 17
 	
18  
-	if(usage()) return
19  
-	
20 18
 	String appId = buildAppId()
21 19
 	String tag = buildAppTag()
22 20
 	
@@ -51,4 +49,4 @@ target(beesAppDeploy: "Deploy a new version of an application using a WAR archiv
51 49
 	
52 50
 }
53 51
 
54  
-setDefaultTarget(beesAppDeploy)
  52
+setDefaultTarget(beesAppDeploy)
2  scripts/BeesAppInfo.groovy
@@ -11,8 +11,6 @@ grails bees-app-info [appId]
11 11
 target(beesAppInfo: "Returns the basic information about an application.") {
12 12
 	depends(checkConfig, prepareClient)
13 13
 	
14  
-	if(usage()) return
15  
-	
16 14
 	String appId = buildAppId()
17 15
 	
18 16
 	def info
2  scripts/BeesAppList.groovy
@@ -10,8 +10,6 @@ grails bees-app-list
10 10
 target(beesAppList: "Returns the list of applications available to your account.") {
11 11
 	depends(checkConfig, prepareClient)
12 12
 	
13  
-	if(usage()) return
14  
-	
15 13
 	def response
16 14
 	try{
17 15
 		response = beesClient.applicationList()
2  scripts/BeesAppRestart.groovy
@@ -13,8 +13,6 @@ grails bees-app-restart [appId]
13 13
 target(beesAppRestart: "Restarts all deployed instances of an application.") {
14 14
 	depends(checkConfig, prepareClient)
15 15
 	
16  
-	if(usage()) return
17  
-	
18 16
 	String appId = buildAppId()
19 17
 	
20 18
 	def response
2  scripts/BeesAppStart.groovy
@@ -13,8 +13,6 @@ grails bees-app-start [appId]
13 13
 target(beesAppStart: "Starts all deployed instances of an application.") {
14 14
 	depends(checkConfig, prepareClient)
15 15
 	
16  
-	if(usage()) return
17  
-	
18 16
 	String appId = buildAppId()
19 17
 	
20 18
 	def response
2  scripts/BeesAppStop.groovy
@@ -13,8 +13,6 @@ grails bees-app-stop [appId]
13 13
 target(beesAppStop: "Stops all deployed instances of an application.") {
14 14
 	depends(checkConfig, prepareClient)
15 15
 	
16  
-	if(usage()) return
17  
-	
18 16
 	String appId = buildAppId()
19 17
 	
20 18
 	def response
2  scripts/BeesAppTail.groovy
@@ -14,8 +14,6 @@ grails bees-app-tail [appId] [LOGNAME]
14 14
 target(beesAppTail: "Establishes a persistent connection to the application logs.") {
15 15
 	depends(checkConfig, prepareClient)
16 16
 	
17  
-	if(usage()) return
18  
-	
19 17
 	String log = getOptionalArg(1) ?: 'server'
20 18
 	
21 19
 	String appId = buildAppId()
1  scripts/BeesDbCreate.groovy
@@ -12,7 +12,6 @@ grails bees-db-create [dbId] [username] [password]
12 12
 
13 13
 target(beesDbCreate: "Create a new MySQL database.") {
14 14
 	depends(checkConfig, prepareClient)
15  
-	if(usage()) return
16 15
 
17 16
 	String dbId = buildDbId()
18 17
 	String username = getOptionalArg(1) ?: dbId
3  scripts/BeesDbDrop.groovy
@@ -10,8 +10,7 @@ grails bees-db-drop [dbId]
10 10
 
11 11
 target(beesDbDrop: "Drop a MySQL database.") {
12 12
 	depends(checkConfig, prepareClient)
13  
-	if(usage()) return
14  
-	
  13
+
15 14
 	String dbId = buildDbId()
16 15
 	
17 16
 	def response
3  scripts/BeesDbInfo.groovy
@@ -10,8 +10,7 @@ grails bees-db-info [dbId]
10 10
 
11 11
 target(beesDbInfo: "Returns information about connecting to a database.") {
12 12
 	depends(checkConfig, prepareClient)
13  
-	if(usage()) return
14  
-	
  13
+
15 14
 	String dbId = buildDbId()
16 15
 	
17 16
 	def info
1  scripts/BeesDbList.groovy
@@ -9,7 +9,6 @@ grails bees-db-list
9 9
 
10 10
 target(beesDbList: "Returns a list of all the databases associated with your account.") {
11 11
 	depends(checkConfig, prepareClient)
12  
-	if(usage()) return
13 12
 	
14 13
 	def response 
15 14
 	try {
12  scripts/_BeesCommon.groovy
... ...
@@ -1,15 +1,5 @@
1 1
 import grails.util.Metadata
2 2
 
3  
-usage = {
4  
-	if(argsMap.params[0] == 'help'){
5  
-		event "StatusFinal", ["\nUsage (optionals in square brackets):\n$USAGE"]
6  
-		return true
7  
-		
8  
-	} else {
9  
-		return false
10  
-	}
11  
-}
12  
-
13 3
 buildAppId = {
14 4
 	String account = grailsSettings.config.cloudbees.account
15 5
 	String optionalName = getOptionalArg(0)
@@ -44,4 +34,4 @@ getOptionalArg = { int index = 0 ->
44 34
 	def argsList = argsMap.params
45 35
 	String value = argsList[index]
46 36
 	return value
47  
-}
  37
+}

0 notes on commit 94c3f37

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