You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by sb...@apache.org on 2015/05/20 16:35:17 UTC

incubator-ignite git commit: # ignite-456: log paramethers checking

Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-456 ba44f76e9 -> c82aa443d


# ignite-456: log paramethers checking


Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/c82aa443
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/c82aa443
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/c82aa443

Branch: refs/heads/ignite-456
Commit: c82aa443d74968e1295143b2912cd4d2c2bef9d8
Parents: ba44f76
Author: null <null>
Authored: Wed May 20 17:36:15 2015 +0300
Committer: null <null>
Committed: Wed May 20 17:36:15 2015 +0300

----------------------------------------------------------------------
 dev-tools/src/main/groovy/jiraslurp.groovy | 24 +++++++++++++++++++++---
 1 file changed, 21 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c82aa443/dev-tools/src/main/groovy/jiraslurp.groovy
----------------------------------------------------------------------
diff --git a/dev-tools/src/main/groovy/jiraslurp.groovy b/dev-tools/src/main/groovy/jiraslurp.groovy
index f16f47b..2d434e5 100644
--- a/dev-tools/src/main/groovy/jiraslurp.groovy
+++ b/dev-tools/src/main/groovy/jiraslurp.groovy
@@ -263,7 +263,13 @@ args.each {
 
     println parameters
 
-    if (parameters.length == 2 && parameters[0] == "slurp" && parameters[1] != 'null') {
+    if (parameters.length >= 1 && parameters[0] == "slurp") {
+        if (parameters.length < 2 || parameters[1] == 'null') {
+            println "There is no builds to run. Exit."
+
+            return
+        }
+
         def builds = parameters[1].split(' ');
 
         println "Running in 'slurp' mode. Test builds=${builds}"
@@ -278,7 +284,13 @@ args.each {
             runAllTestBuilds(builds,k)
         }
     }
-    else if (parameters.length == 2 && parameters[0] == "patchApply" && parameters[1] ==~ /\w+-\d+/) {
+    else if (parameters.length > 1 && parameters[0] == "patchApply") {
+        if (parameters.length < 2 || parameters[1] !=~ /\w+-\d+/) {
+            println "There is no jira number to apply. Exit."
+
+            return
+        }
+
         def jiraNum = parameters[1]
 
         println "Running in 'patch apply' mode with jira number '$jiraNum'"
@@ -298,7 +310,13 @@ args.each {
             applyPatch(jira, attachementURL)
         }
     }
-    else if (parameters.length >= 2 && parameters[0] == "runAllBuilds" && parameters[1] != 'null') {
+    else if (parameters.length > 1 && parameters[0] == "runAllBuilds" ) {
+        if (parameters.length < 2 || parameters[1] == 'null') {
+            println "There is no builds to run. Exit."
+
+            return
+        }
+
         def builds = parameters[1].split(' ');
 
         def jiraNum = parameters[2]